In my game I want to make it so that when the player spawns, they are grey, still have clothing, but have the default player model (Blocky w/ the rounded head). I was wondering these questions:
-
Local or Normal script?
-
What code can I use for this?
I checked the Roblox developer page but I couldn’t find out how to change the player model when somebody joins the game.
2 Likes
You can create a Dummy NPC and name the model StarterCharacter
and put them into the StarterPlayer
Service.
Alternatively when a player’s character is loaded you remove all of their accessories and change their head mesh and their skin color.
You also might be able to do this with the Avatar
settings in studio but I’m not sure what the mesh id’s for the default limbs are.
I personally would chose to use the StarterCharacter
route because it is easier.
Steps:
- To get a dummy rig just use the Animation Editor’s RigBuilder. Select
Block Rig
- Insert a
SpecialMesh
into the head, and change the MeshType
to Head
and the scale to 1.25, 1.25, 1.25
- Select the
HumanoidRootPart
and set Anchored
to false
- Name the Dummy’s Model “StarterCharacter”
- Drag it into
StarterPlayer
Bam: Players spawn with the avatar you’ve selected.
Steps with images:
If you want to skip the character model setup; here is a model I just uploaded that you can drag into StarterPlayer
: https://www.roblox.com/library/4778485601/StarterCharacter
8 Likes
Serverscript(normalscript).Code:
Note:Make sure to make the Player RigType,R6 so it makes it easier.
game.Workspace.ChildAdded:connect(function(Character)
if Character.Name == game.Players:FindFirstChild(Character.Name) then
Character.Torso.BrickColor = BrickColor.new("Grey")--Do this with every bodypart in the player's character.
end
end)
2 Likes
Thanks! that was WAY simpler than what I was trying to do!
Thanks! that’ll be useful.
(Has to be 30 chars)