fix getting normal vector from raycast

This commit is contained in:
Georgiy Sadovnikov 2024-11-05 16:22:24 +03:00
parent c84fb0b11e
commit 20a86b5bae
1 changed files with 1 additions and 1 deletions

View File

@ -2438,7 +2438,7 @@ namespace DotRecast.Detour
// int va = a * 3;
// int vb = b * 3;
float dx = verts[b].X - verts[a].X;
float dz = verts[b].Z - verts[a].X;
float dz = verts[b].Z - verts[a].Z;
hit.hitNormal = RcVec3f.Normalize(new RcVec3f(dz, 0, -dx));
return DtStatus.DT_SUCCESS;
}