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

Person cannot move when joined?

This is in a local script and this does not keep the player still when they join.

function onEntered()
	h=script.Parent.Parent.Parent.Parent.Character
	ll=h:FindFirstChild("Left Leg")
	ra=h:FindFirstChild("Right Arm")
	rl=h:FindFirstChild("Right Leg")
	la=h:FindFirstChild("Left Arm")
	he=h.Head
	if (h.Torso.Anchored==false) then
	h.Torso.Anchored=true
	ll.Anchored=true
	he.Anchored=true
	ra.Anchored=true
	la.Anchored=true
	rl.Anchored=true
	h.Humanoid.WalkSpeed=0
	end
end

1 comment

2

The problem might be the script fire to fast which basically means that the script runs before the Players character have loaded into the game.

2 answers

✓ Accepted answer
game.Players.PlayerAdded:connect(function(Player)
	Player.CharacterAdded:connect(function(Char)
	for _,v in pairs (Char:GetChildren()) do
if v:IsA("Part") then
	v.Anchored = true
end
	end
	end)
end)

Hi...Not sure what ur asking for me to figure out but i think u want to make a players walkspeed different.

game.Players.PlayerAdded:connect(function(player) -- We r using the PlayerAdded Function
	player.CharacterAdded:connect(function(character) -- Were fixing to get into the juicy stuff.
		local hum = character:WaitForChild("Humanoid") -- We have called the humanoid and named it hum.
       
        hum.Walkspeed = 100 -- This makes the players walkspeed 100
       
	end)
end)




Hope This Helped Let me know if it did or didnt i can change it if it didnt:)

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