I am having issues with my defense game. Currently, all the slowed-down enemies break off the path.
Video:
As you can see, the Strong Noob stops before it reaches the end, the Burly Noob seems to attempt shortcuts, and Goliath is completely broken. Why does this happen? All the humanoids are slowed down, but I don’t see why this would be a problem. Is there a function I am supposed to call?
Currently the movement script looks like this:
local path = game.Workspace.Points
local humanoid = script.Parent.Humanoid
local function move()
humanoid:MoveTo(path._04_5.Position)
humanoid.MoveToFinished:Wait()
humanoid:MoveTo(path._01.Position)
humanoid.MoveToFinished:Wait()
humanoid:MoveTo(path._02.Position)
humanoid.MoveToFinished:Wait()
humanoid:MoveTo(path._03.Position)
humanoid.MoveToFinished:Wait()
humanoid:MoveTo(path._04_5.Position)
humanoid.MoveToFinished:Wait()
humanoid:MoveTo(path._04.Position)
humanoid.MoveToFinished:Wait()
humanoid:MoveTo(path._05.Position)
humanoid.MoveToFinished:Wait()
humanoid:MoveTo(path._End.Position)
humanoid.MoveToFinished:Wait()
end
while wait(0.5) do
if script.Parent.Parent == game.Workspace then
move()
break
end
end