Skip to content
Snippets Groups Projects
Commit f86c52c0 authored by biwa's avatar biwa
Browse files

UDBScript: fixed a bug in Vector3D's crossProduct method that resulted in wrong calculations

parent 7d11b0dd
No related branches found
No related tags found
1 merge request!2Merge current state of UDB
......@@ -452,7 +452,11 @@ namespace CodeImp.DoomBuilder.UDBScript.Wrapper
Vector3D a1 = (Vector3D)BuilderPlug.Me.GetVectorFromObject(a, true);
Vector3D b1 = (Vector3D)BuilderPlug.Me.GetVectorFromObject(b, true);
return new Vector3DWrapper(a1.y * b1.x - a1.z * b1.y, a1.z * b1.x - a1.x * b1.z, a1.x * b1.y - a1.y * b1.x);
return new Vector3DWrapper(
a1.y * b1.z - a1.z * b1.y,
a1.z * b1.x - a1.x * b1.z,
a1.x * b1.y - a1.y * b1.x
);
}
catch (CantConvertToVectorException e)
{
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment