Fix the aiming and bullet creation
This commit is contained in:
17
scenes/characters/blue/hit_collision.gd
Normal file
17
scenes/characters/blue/hit_collision.gd
Normal file
@ -0,0 +1,17 @@
|
||||
extends PhysicalBone3D
|
||||
|
||||
@export var damage_multiplexer: float = 1.0
|
||||
|
||||
signal body_part_hit(damage: int)
|
||||
# Called when the node enters the scene tree for the first time.
|
||||
func _ready() -> void:
|
||||
pass # Replace with function body.
|
||||
|
||||
# Called every frame. 'delta' is the elapsed time since the previous frame.
|
||||
func _process(delta: float) -> void:
|
||||
pass
|
||||
|
||||
func hit(base_damage: int):
|
||||
print("HEAD")
|
||||
var final_damage = round(base_damage * damage_multiplexer)
|
||||
$"../../../../.."._hit_detected(final_damage)
|
Reference in New Issue
Block a user