am making a rpg where the mob goes back to its normal position when he is done following you, so he would stop moving and go back
this is the code
local monster = game.Workspace.Grass_Monster1
local Humanoid = monster.Humanoid
local pointA = game.Workspace.PointA
if Humanoid.WalkSpeed == 0 then
Humanoid:MoveTo(266.565, 2.045, 814.35)
end
Grass_Monster1 is the mob am trying to move to this 266.565, 2.045, 814.35 position when he is not moving.

1 comment
You cannot move an NPC or player if their walkspeed is 0. They won't move... This also does not seem to be in a loop of any sorts. So this will only check the condition once.