What's that smell?

This commit is contained in:
Haze Weathers 2023-09-10 23:26:21 -04:00
parent dde551db56
commit 8c818ac174
16 changed files with 99 additions and 2 deletions

View file

@ -6,6 +6,7 @@ signal died()
# CONSTANTS #
const ArrowProjectile = preload("res://objects/player/arrow_projectile.tscn")
const DeathSplatter = preload("res://objects/player/player_death_particles.tscn")
const BloodSpray := preload("res://objects/environment/blood/blood_spray.tscn")
# EXPORTS #
## whether to be temporarily invulnerable after respawning
@ -275,6 +276,11 @@ func _on_Dead_state_entered() -> void:
particles.global_position = death_splatter_position.global_position
particles.emitting = true
get_parent().add_child(particles)
for i in 32:
var spray: RigidBody2D = BloodSpray.instance()
spray.global_position = global_position
spray.linear_velocity = Vector2(80.0, 0.0).rotated(randf() * TAU)
get_parent().add_child(spray)
else:
skip_blood = false
# fade into the ether