File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed
addons/nodot/character/kits/FirstPerson Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -17,6 +17,8 @@ class_name FirstPersonCharacter extends NodotCharacter3D
1717@export var minimum_fall_damage : float = 5.0
1818## The amount of fall damage to inflict when hitting the ground at velocity (0 for disabled)
1919@export var fall_damage_multiplier : float = 0.5
20+ ## The strength that the character will push rigidbodies
21+ @export var push_strength : float = 0.5
2022
2123## Constructs the step up movement vector.
2224@onready var step_vector : Vector3 = Vector3 (0 , step_height , 0 )
@@ -171,7 +173,7 @@ func set_rigid_interaction():
171173 elif sign (char_basis .z ) == sign (lin_vel .z ):
172174 c .get_collider ().linear_velocity .z *= - 0.1
173175
174- c .get_collider ().apply_central_impulse (- c .get_normal () * 0.25 * c .get_collider ().mass )
176+ c .get_collider ().apply_central_impulse (- c .get_normal () * push_strength * c .get_collider ().mass )
175177
176178func move_air (delta : float ) -> void :
177179 velocity .y = min (terminal_velocity , velocity .y - gravity * delta )
You can’t perform that action at this time.
0 commit comments