Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Help with character appearance?

Asked by 9 years ago

the script doesnt work in studio, but in servers it automatically crashes the game.

1game.Players.PlayerAdded:connect(function(Player)
3Player.Character:BreakJoints()
4end)

1 answer

Log in to vote
1
Answered by 9 years ago

The Issue is that the script is running before the players character is loaded

1function onPlayerEntered(player)
2    wait(0.25)
3    player.CharacterAppearance = "http://www.roblox.com/Asset/CharacterFetch.ashx?userId=261" --Shedletsky
4    player:LoadCharacter(true)
5    repeat wait () until player.Character ~= nil
6end
7game.Players.PlayerAdded:connect(onPlayerEntered)

Hope this helps

Ad

Answer this question