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

Is it possible to prevent a player from moving/walking?

I was wondering, is it possible make a player unable to move for a period of time, then release them?

game.Workspace.??Player??.Torso.Anchored = true

1 answer

✓ Accepted answer

If you anchor their torso, then it will effectively stop them from moving.

As well as setting their walkspeed to 0, putting bodyvelocity on them, removing the walking script.. etc..

Lots of ways(:

--------------------------Edit1

c = game.Players:GetChildren() --Get all the children of players
for i = 1,#c do
	c[i].Character.Torso.Anchored  = true
end
wait(timehere) --Put the amount of time you want to hold them here
for i = 1,#c do
	c[i].Character.Torso.Anchored = false
end

-Goulstem

3 comments

0

example?

0

I have editted my question with something, but I dont know how to get all the players in workspace and their torsos.

0

Oh, ok. Edit.

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