forked from team-sg/hero-mark-2
death of the super slime
This commit is contained in:
parent
8f2b42f968
commit
13708b4046
2 changed files with 11 additions and 2 deletions
|
@ -1,6 +1,7 @@
|
|||
tool
|
||||
extends "res://objects/enemy/enemy.gd"
|
||||
|
||||
const SlimeParticles = preload("res://objects/enemy/slime_particles.tscn")
|
||||
|
||||
export var left_boundary: float = 0.0
|
||||
export var right_boundary: float = 0.0
|
||||
|
@ -83,3 +84,11 @@ func _draw() -> void:
|
|||
Vector2(4.0, -jump_distance * 8.0 - 4.0),
|
||||
Color(0.4, 0.2, 0.6, 0.75), 1.01, false
|
||||
)
|
||||
|
||||
|
||||
func die() -> void:
|
||||
.die()
|
||||
var death_particles = SlimeParticles.instance()
|
||||
death_particles.global_position = hitbox.global_position + Vector2(4.0, 4.0)
|
||||
death_particles.emitting = true
|
||||
get_parent().add_child(death_particles)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue