From 7d86dd56c7065980ab03edd976b9f0a8abbd8807 Mon Sep 17 00:00:00 2001 From: Nick Date: Thu, 5 May 2022 22:27:17 -0400 Subject: [PATCH] Improve raft handling --- NewHorizons/Patches/RaftPatches.cs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/NewHorizons/Patches/RaftPatches.cs b/NewHorizons/Patches/RaftPatches.cs index 331edd69..79af3b4b 100644 --- a/NewHorizons/Patches/RaftPatches.cs +++ b/NewHorizons/Patches/RaftPatches.cs @@ -103,10 +103,9 @@ namespace NewHorizons.Patches var alignmentDirection = (__instance.transform.position - __instance._alignmentFluid.transform.position).normalized; var degreesToTarget = Vector3.Angle(currentDirection, alignmentDirection); - var adjustedSlerpRate = Mathf.Clamp01(10f / degreesToTarget * Time.fixedDeltaTime); + var adjustedSlerpRate = Mathf.Clamp01(0.01f * degreesToTarget * Time.fixedDeltaTime); Vector3 a = OWPhysics.FromToAngularVelocity(currentDirection, alignmentDirection); - //__instance._owRigidbody.SetAngularVelocity(Vector3.zero); __instance._owRigidbody.AddAngularVelocityChange(a * adjustedSlerpRate); }