diff --git a/ODIN-SampleProject/Assets/ODIN-Sample/Prefabs/Resources/ODINPlayer.prefab b/ODIN-SampleProject/Assets/ODIN-Sample/Prefabs/Resources/ODINPlayer.prefab index 0e6bf14..ccccf9f 100644 --- a/ODIN-SampleProject/Assets/ODIN-Sample/Prefabs/Resources/ODINPlayer.prefab +++ b/ODIN-SampleProject/Assets/ODIN-Sample/Prefabs/Resources/ODINPlayer.prefab @@ -1497,6 +1497,7 @@ MonoBehaviour: mouseDelta: {fileID: 8009718129426777221, guid: 569da38d22d72724586e88d08c36b7a6, type: 3} rotationSpeed: 0.6 mobileRotationSpeedMultiplier: 0.75 + mouseRotationSpeedMultiplier: 0.25 clampPitch: 80 yawTarget: {fileID: 2753487309498945351} pitchTarget: {fileID: 2488659525853046605} diff --git a/ODIN-SampleProject/Assets/ODIN-Sample/Scripts/Runtime/GameLogic/FirstPersonRotation.cs b/ODIN-SampleProject/Assets/ODIN-Sample/Scripts/Runtime/GameLogic/FirstPersonRotation.cs index ef31712..08da0c3 100644 --- a/ODIN-SampleProject/Assets/ODIN-Sample/Scripts/Runtime/GameLogic/FirstPersonRotation.cs +++ b/ODIN-SampleProject/Assets/ODIN-Sample/Scripts/Runtime/GameLogic/FirstPersonRotation.cs @@ -22,6 +22,7 @@ public class FirstPersonRotation : MonoBehaviour /// On mobile, a slower rotation speed is preferable. /// [SerializeField] private float mobileRotationSpeedMultiplier = 0.5f; + [SerializeField] private float mouseRotationSpeedMultiplier = 0.25f; /// @@ -61,9 +62,10 @@ private void Update() float yaw = gamepadInput.x * Time.deltaTime; float pitch = gamepadInput.y * Time.deltaTime; + // mouse delta is already multiplied by Time.deltaTime. Vector2 mouseInput = mouseDelta.action.ReadValue(); - yaw += mouseInput.x; - pitch += mouseInput.y; + yaw += mouseInput.x * mouseRotationSpeedMultiplier; + pitch += mouseInput.y * mouseRotationSpeedMultiplier; float rotationSpeedMultiplier = rotationSpeed; diff --git a/ODIN-SampleProject/ProjectSettings/ProjectSettings.asset b/ODIN-SampleProject/ProjectSettings/ProjectSettings.asset index e431cfd..e5f0901 100644 --- a/ODIN-SampleProject/ProjectSettings/ProjectSettings.asset +++ b/ODIN-SampleProject/ProjectSettings/ProjectSettings.asset @@ -134,7 +134,7 @@ PlayerSettings: 16:10: 1 16:9: 1 Others: 1 - bundleVersion: 0.16.2 + bundleVersion: 0.16.3 preloadedAssets: - {fileID: 0} - {fileID: 0}