Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

Spawn in With a shaggy? Rainbow shaggy on spawn?

how can i convert this into making it give me a shaggy on spawn and replace my current hair, the shaggy i want is the rainbow shaggy.

local Character = script.Parent
local Head = Character:WaitForChild('Head')
wait(1)

    if Character.Name == "forsakern" then
Head.face.Texture = 'rbxassetid://20052028'
    end

1 answer

✓ Accepted answer

Add a script to ServerScriptService and add the following code to it.

Code:

local debounce = true

game.Players.PlayerAdded:Connect(function(player)
	player.CharacterAdded:Connect(function(character)
		local HumanoidDescription = character:WaitForChild("Humanoid"):WaitForChild("HumanoidDescription")
		local ID = 64082730 -- The Rainbow Shaggy ID.
		if character.Name == "Playername" and debounce == true then -- Replace "Playername" with the name you want to spawn with the Hair.
			debounce = false
			wait(0.5) -- Keep the wait, as I tested this without the wait it was just an infinite loading screen.
			HumanoidDescription.HairAccessory = ID
			player:LoadCharacterWithHumanoidDescription(HumanoidDescription)
		end
	end)
end)

6 comments

0

how can u make it so only works for a specific player

0

NVM I FIGURED IT OUT THANKYOu!!

0

Okay, no problem. I just finished editing the code lol. Happy to help.

0

wait can u make it so it stays spawning when u reset aswell character

0

can u help so the shaggy stays when u reset aswell

0

Sorry 'bout the late reply, having to rewrite the script and trying to get it to work, unfortunately I cannot get it to work, though I am not giving up, I'll still continue to get it to work for you, just not exactly sure on how long it will take. I'll make sure to update my answer and I'll make a comment whenever I get it done.

This discussion is preserved as it was. New answers, comments, and votes are closed.