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

PathfindingService:CreatePath() Returns Instance ?

Asked by 3 years ago
function DynamicSoftware.GetPath(destination)
    local path = PFS:CreatePath()
    if typeof(destination) == "Instance" then
        path:ComputeAsync(Jenny.HumanoidRootPart.Position,destination.HumanoidRootPart.Position)
    else
        path:ComputeAsync(Jenny.HumanoidRootPart.Position,destination)
    end
    return path
end

I dont know why but when I use GetWayPoints() it returns Instance

Answer this question