Npc doesnt reach the part fully

So whenever i use the moveto to move the npc to a certain part the npc doesnt fully reach it and its like just stands in the first half of the part. How do i fix this?

robloxapp-20240601-0949129.wmv (669.1 KB)

Can you maybe send your code in here?

its not anything complicated

Humanoid:MoveTo(Part.Position)

I mean if you really want it to move further its gonna get more complicated.

local direction = (Vector3.new(1,0,1)*Part.Position - Vector3.new(1,0,1)*HumanoidRootPart.Position).Unit
local newPos    = Part.Position + Vector3.new(direction.X*Part.Size.X, 0, direction.Z*Part.Size.Z)*0.5

Humanoid:MoveTo(newPos)

try this and send me a screenshot of the end pose

it doesnt seem to work theres an error on the third line

“attempt to perform arithmetic (add) on Vector3 and number”

I have edited the code and it should be working now

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.