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

MoveTo() Method Help

I am not really comfortable using MoveTo() Method because I'm new to it. Here is like a snip-it of a MoveTo() Script(I NEED HELP UNDERSTANDING IT)

Workspace.Shedletsky.Humanoid:MoveTo(Vector3.new(0,0,0))

Or something other like this

Workspace.Shedletsky.Humanoid:MoveTo(Workspace.Part)

And another one

Workspace.Shedletsky:MoveTo(Vector3.new(0,0,0))

Help?

4 answers

✓ Accepted answer

Workspace.Shedletsky.Humanoid:MoveTo(Vector3.new(0,0,0)) The above line allows the character of "Shedletsky" to walk to the position, since the MoveTo method is used onto the Humanoid, not the character. The position is a Vector3 value.

Workspace.Shedletsky.Humanoid:MoveTo(Workspace.Part) This line is the same thing as the first, except that a Part is used as the argument instead of the Vector3 value. 'Shedletsky' will walk to the Part named.

Workspace.Shedletsky:MoveTo(Vector3.new(0,0,0)) This snip-it of code (above) looks similar to the first example but is different. Because you are using the MoveTo method to the character, not the Humanoid of that character, this line would teleport 'Shedletsky' to the position (which is a Vector3 value).

The MoveTo() method is a fairly simple one.

Workspace.Shedletsky.Humanoid:MoveTo(Vector3.new(0,0,0)) Will make Shedletsky try to walk to the Vector3 position

As for this: Workspace.Shedletsky.Humanoid:MoveTo(Workspace.Part) Will make Shedletsky try to walk to the Part.

And another one

Workspace.Shedletsky:MoveTo(Vector3.new(0,0,0)) Moves the block to 0,0,0 unless there is a brick there, then the brick will move to the lowest position above the Vector3 position.

I hope this helped.

To make a humanoid, you must specify a position and a part.

Workspace.Shedletsky.Humanoid:MoveTo(Vector3.new(0,0,0),Workspace.Part)

It's basic. ;)

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