Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How to subtract one from the total position of this?

Asked by 4 years ago

while true do wait(1) local target = findNearestTorso(script.Parent.HumanoidRootPart.Position) if target ~= nil then script.Parent.Humanoid:MoveTo(target.Position, target) load3:Stop() load:Play() script.Parent.Humanoid.MoveToFinished:Wait() load:Stop() load2:Play() load2:Stop() load3:Play() end end

Basically, when the robot comes to you it just pushes you so the move to never finishes, there for the animations doesn't play, I tried subtracting the values using - vector3(1,1,1) but it usually gave me a table error.

1 answer

Log in to vote
1
Answered by
crueluu 169
4 years ago
Edited 4 years ago

Try Using Vector3.new(-1,-1,-1) The Script Thought The Vector3 Was A Table You Forgot To Add .new

Ad

Answer this question