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

Character Appearance help? #2

Now that the code is fixed (thanks to LordDragonZord) I wanted to know how I could make this code:

game.Players.PlayerAdded:connect(function(Player)
wait(.5)
    Player.CharacterAppearance = "http://www.roblox.com/Asset/CharacterFetch.ashx?userId=31790662" 
wait(15)
Player:LoadCharacter()--Wait 15 seconds then respawn.
end)

only change me to the character and no one else. Does anyone have some tips on doing this or something that might help?

3 comments

1

if player.Name:lower() == "vividex":lower() then --Sorry for not explaining in an answer, I'm feeling a bit lazy!

1

@Thetacah under the first line and above the second I added what you said, and now it doesn't char me at all! theres a red line under the : in :lower and says "Expected 'then', got ':'"

1

ye you have to add a but more, just follow Ditto I guess.

1 answer

✓ Accepted answer
game:service'Players'.playerAdded:connect(function(Player)
	Player:waitForChild'Backpack';--// Waits until they have a backpack, moreof character recognition.
	
	if(Player.userId==39704067)then--// 39704067 is Vividex's userId.
		wait(.5);--// A bit more delay.
		Player.CharacterAppearance='http://www.roblox.com/Asset/CharacterFetch.ashx?userId=31790662';--// Changed their appearance to the specified characterappearance.

		delay(15,function()--// Same as wait(15), but more efficient.
			if(Player and ypcall(function()assert(Player.Parent==game:service'Players','');end))then
				Player:loadCharacter();
			end;
		end);
	end;
	
end);

Updated.

5 comments

1

Game shuts down, Thanks for trying tho ;c.

0

How could the game shut down..? I changed my answer to put a bit of delay, just in case your code was interfering with the CoreScript code.

0

Also, I used userId instead of Name, so that you did not have to worry about name changes.

1

Thanks! It worked, I had a friend come and wait about a minute and it only changed me!

0

No problem. If you wish to change multiple people, just have a table that contains their userIds, and when they join, check to see if they are in the table.

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