Different damage based on body part
This commit is contained in:
parent
f8fe9b0d56
commit
1d5065cbbf
8 changed files with 86 additions and 101 deletions
|
|
@ -2,9 +2,12 @@ extends WeaponState
|
|||
|
||||
@export var vertical_curve: Curve
|
||||
@export var horizontal_curve: Curve
|
||||
@export var damage_reduction_curve: Curve
|
||||
|
||||
@export var emptyable: bool
|
||||
@export var damage: int
|
||||
@export var torso_damage: int
|
||||
@export var head_damage: int
|
||||
@export var limb_damage: int
|
||||
@export var shoot_distance: float = 100
|
||||
|
||||
@export var fire_timer: Timer
|
||||
|
|
@ -38,7 +41,7 @@ func fire() -> void:
|
|||
machine.animation_player.play(with_morphems("shoot"))
|
||||
|
||||
if is_multiplayer_authority():
|
||||
Session.shoot(int(machine.player.name),damage,shoot_distance)
|
||||
Session.shoot(int(machine.player.name),limb_damage,torso_damage,head_damage,shoot_distance,damage_reduction_curve)
|
||||
machine.player.get_node("ShootAudio").multiplayer_play()
|
||||
|
||||
fire_timer.start()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue