Increase analog look sensitivity. Fix analog look sensitivity going unused.

This commit is contained in:
blujai831 2025-04-01 20:22:21 -07:00
parent c75c8e094c
commit 85b2d76138
No known key found for this signature in database
GPG Key ID: DDC31A0363AA5E66
1 changed files with 10 additions and 4 deletions

View File

@ -18,7 +18,7 @@ class_name GameplayCamera extends Camera3D
@export var zoom_speed: float = 4.0
@export var mouse_sensitivity: float = 0.03125
@export var mouse_wheel_sensitivity: float = 5.0
@export var analog_sensitivity: float = 1.0
@export var analog_sensitivity: float = 1.5
@export var analog_zoom_sensitivity: float = 1.0
var target_direction := Vector3.ZERO
@ -52,9 +52,15 @@ func _unhandled_input(event: InputEvent) -> void:
func _handle_analog_input() -> void:
if !player_control: return
look_impetus.x -= Input.get_axis(&'look_left', &'look_right')
look_impetus.y += Input.get_axis(&'look_down', &'look_up')
look_impetus.z += Input.get_axis(&'zoom_in', &'zoom_out')
look_impetus.x -= (
Input.get_axis(&'look_left', &'look_right')*analog_sensitivity
)
look_impetus.y += (
Input.get_axis(&'look_down', &'look_up')*analog_sensitivity
)
look_impetus.z += (
Input.get_axis(&'zoom_in', &'zoom_out')*analog_sensitivity
)
func _respond_to_impetus(delta: float) -> void:
if !target: return