Revert offset to the y value when adding a path

This is to revert it to the original without the offset because it has inconsistent results with meshes with no height, something that I need to investigate why. 

So for now to keep it consistent it stays without the offset.
This commit is contained in:
N8n5h 2019-10-14 19:13:18 -03:00 committed by GitHub
parent c6d74fc4ea
commit b06c665676
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -68,7 +68,7 @@ class NavMesh extends Trait {
if (!ready) return;
recast.findPath(from.x, from.z, from.y, to.x, to.z, to.y, 200, function(path:Array<RecastWaypoint>) {
var ar:Array<Vec4> = [];
for (p in path) ar.push(new Vec4(p.x, p.z, (p.y + 1.1)));
for (p in path) ar.push(new Vec4(p.x, p.z, p.y));
done(ar);
});
}