Fixed incorrect trasform after respawn causing renderer to collapse and other stuff too

remotes/1705223993883213877/tmp_refs/heads/damage
unfa 2021-10-23 22:34:51 +02:00
parent 2b0523b1c9
commit f3fd5de171
1 changed files with 5 additions and 4 deletions

View File

@ -358,6 +358,7 @@ func _process(delta):
$Head/Camera.position.y = 0
$Head/Camera.rotation.z = 0
jetpack_fuel = jetpack_tank
@rpc(any_peer, call_local, reliable) func die(killer_pid: int):
var gibs = gibs_vfx.instantiate()
@ -384,8 +385,8 @@ func _process(delta):
$Head/Camera.rotation.z = -20
jetpack_active = false
view_zoom_target = .0
view_zoom = 0
view_zoom_target = 1.0
view_zoom = 1
#queue_free()
@ -461,7 +462,7 @@ func _physics_process(delta):
$Head/Camera/Hand/Weapon.transform.origin.y -= motion_velocity.y * delta / 60
if Input.is_action_just_pressed("move_jump") and is_on_floor():
var tween = create_tween()
# var tween = create_tween()
$Head/Camera/Hand/Weapon.transform.origin.y -= 0.025
#$Head/Camera/Hand/Weapon.transform.origin.y -= 0.05
@ -485,7 +486,7 @@ func _physics_process(delta):
previously_on_floor = is_on_floor()
lagging_movement_velocity.lerp(motion_velocity, delta)
#lagging_movement_velocity.lerp(motion_velocity, delta)
rpc(&'update_movement', global_transform, head.get_rotation(), motion_velocity, jetpack_active)