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

Humanoid:MoveTo() how to change location?

When i ask the humanoid to move the second time it just bugs trying to get to those 2 locations at the same time. Is there a way to reset the MoveTo function?

2 comments

0

wait() ?

0

wait()?

2 answers

✓ Accepted answer

Oh, for god's sake. If you want to move a Humanoid to two different positions, use CFrame and not Torso and use the wait() function, like this:

function Move(position)
	for i,j in pairs(game.Players:GetPlayers()) do
		i.Torso.CFrame = CFrame.new(position)
	end
end

Move(0,12,34)
wait(5)
Move(0,0,4)

Of course, this is just an example and you can expand upon it as you wish. You can replace the numbers passed to the argument "position" to the numbers of the position you want to move the Player to.

3 comments

0

Not an anwer to my question tho

0

You're not supposed to do it at the same time.

0

Plus, if you try to move the Humanoid and not the Player, the Player is a dud and becomes a Model instead of a Player.

Nvm, i noticed something i didn't before. The question probably doesn't make sense afterall so its normal that the answers wont satisfy me. Thanks anyways!!

1 comment

0

No prob.

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