local dummy = game.Workspace.Dummy:WaitForChild("HumanoidRootPart") local human = dummy:WaitForChild("Humanoid") local point = game.Workspace.Part1 local PathfindingService = game:GetService("PathfindingService") local path = PathfindingService:CreatePath() path:ComputeAsync(dummy.HumanoidRootPart.Position, point.Position) local waypoints = path:GetWaypoints() for _, waypoint in pairs(waypoints) do local part = Instance.new("Part") part.Shape = "Ball" part.Material = "Neon" part.Size = Vector3.new(0.6, 0.6, 0.6) part.Position = waypoint.Position part.Anchored = true part.CanCollide = false part.Parent = game.Workspace human:MoveTo(waypoint.Position) human.MoveToFinished:Wait() end
The pathfinding service only works if the humanoid has somewhere to move to, and it seems like you tell the humanoid to move to what position, therefore the script doesn't know what the destination is. After your in pairs loop, add a human:MoveTo(point.Position) and it should work.
local dummy = game.Workspace.Dummy:WaitForChild("HumanoidRootPart") local human = dummy:WaitForChild("Humanoid") local point = game.Workspace.Part1 local PathfindingService = game:GetService("PathfindingService") local path = PathfindingService:CreatePath() path:ComputeAsync(dummy.HumanoidRootPart.Position, point.Position) local waypoints = path:GetWaypoints() for _, waypoint in pairs(waypoints) do local part = Instance.new("Part") part.Shape = "Ball" part.Material = "Neon" part.Size = Vector3.new(0.6, 0.6, 0.6) part.Position = waypoint.Position part.Anchored = true part.CanCollide = false part.Parent = game.Workspace human:MoveTo(waypoint.Position) human.MoveToFinished:Wait() end human:MoveTo(point.Position)