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

How can I make it only happen to me not to all players?

game.Players.PlayerAdded:Connect(function(Player)
 Player.CharacterAdded:Connect(function(Character)
  local Humanoid = Character:WaitForChild('Humanoid')
  for i,Child in pairs(Humanoid:GetChildren()) do
   if Child:IsA('NumberValue') then
	if Child.Name == 'BodyHeightScale' then
		Child.Value = 2
	end
   end
  end
 end)
end)

-- (I tried making myself look different, and I think it would happen to other players aswell.)

1 answer

✓ Accepted answer

Here

game.Players.PlayerAdded:Connect(function(Player)
if Player.UserId == game.CreatorId then
 Player.CharacterAdded:Connect(function(Character)
  local Humanoid = Character:WaitForChild('Humanoid')
  for i,Child in pairs(Humanoid:GetChildren()) do
   if Child:IsA('NumberValue') then
    if Child.Name == 'BodyHeightScale' then
        Child.Value = 2
    end
   end
  end
 end)
end
end)

10 comments

0

Thanks!

0

np

0

Where do I put my Name/Id

0

You don't have to

0

o

1

if YOU created the game it will work

1

if you didn't then change game.CreatorId to your UserID

0

It works based on who the creator of the game is. So if you put this script in a game you own, it will only work for you.

1

correct

0

I can't believe you thought this was a valid answer in any shape/form. -1 for not giving an explanation at all.

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