From dd2fd3f37b1095ad95ced1a32fc989d595118c1d Mon Sep 17 00:00:00 2001 From: Jarrod Doyle Date: Sat, 7 Sep 2024 12:12:28 +0100 Subject: [PATCH] Fix off-by-one on rotation --- project/code/TMV/Mission.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/project/code/TMV/Mission.cs b/project/code/TMV/Mission.cs index c73f3d4..1716487 100644 --- a/project/code/TMV/Mission.cs +++ b/project/code/TMV/Mission.cs @@ -265,7 +265,7 @@ public partial class Mission : Node3D var modelName = modelNameProp.value + ".bin"; var pos = brush.position.ToGodotVec3(); var rawRot = brush.angle; - var rot = new Vector3(rawRot.Y, rawRot.Z, rawRot.X) * 360 / ushort.MaxValue; + var rot = new Vector3(rawRot.Y, rawRot.Z, rawRot.X) * 360 / (ushort.MaxValue + 1); var scale = scaleProp == null ? Vector3.One : scaleProp.value.ToGodotVec3(false); var model = Timing.TimeStage("Get Models", () => {