I Want To Change Peoples Avatars But Keep Hats/Hair Only. I Know Of StarterCharacter But I Don’t Know If I Can Keep Things On People
First you have to find the players character Game.Players.LocalPlayer.Character
Then you can edit the entire avatar live without having to reset the player. Im not sure how to attach new items but you can easily use :Destroy()
to remove them or change the clothing ID’s on tshirts, Shirts and pants by setting them like this Local Shirt = ID
Example code (Not sure if it works, Removes the players shirt)
Local Playerchar = game.Players.LocalPlayer.Character
Local Shirt = PlayerChar.Shirt
Shirt:Destroy()
If you go into game settings>avatar, and then you scroll down you’ll be able to enter an ID for a clothing item. This will allow you to change some aspects of their body but keep their hat and hair.
It Doesnt Look Like “Character” Is A Part Of LocalPlayer
I believe its caused by the script loading before the avatar, I forgot how to fix it because I don’t usually work with avatars/humanoids and I might have messed up spelling or capitalization
That cant be done by a script while ingame…
That would only work locally, LocalPlayer doesn’t work in server scripts so nobody would be able to see changes. You should instead use game.Players.PlayerAdded:Connect(function(Player)
to get the player on the server, where everybody can see changes done.
You can use Humanoid:ApplyDescription()
as a way to change the character, here’s the link to a page more about it.
https://developer.roblox.com/en-us/api-reference/function/Humanoid/ApplyDescription
I was using as an example to find the player, You are right though