Hi ,
Im working on the runtime version for ProBuilder and im stack on the gizmo orientation local or planar for the face or vertex . any build in function to get it right ?
I know that we have a function to get the normal for the face :
Vector3 targetAxis = pb_Math.Normal(pbUtil.ValuesWithIndices(currentSelection.pb.VerticesInWorldSpace(), currentSelection.face.distinctIndices))
and for the axis creation i give this values to each axe:
xDirection = Vector3.Cross(Vector3.up.normalized, targetAxis.normalized);
yDirection = Vector3.up;
zDirection = targetAxis;
but the X and Z axes are not moving the right way when i rotate the object on the Y axe .
Any idea or help plz ?