added gumba mushroom and sound
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
extends RigidBody2D
|
||||
@onready var animated_sprite_2d = $AnimatedSprite2D
|
||||
@export var hit_object:PackedScene
|
||||
|
||||
var destroyed = false
|
||||
|
||||
@@ -12,3 +13,10 @@ func _on_activate_body_entered(body):
|
||||
|
||||
destroyed = true
|
||||
animated_sprite_2d.play("destroy")
|
||||
|
||||
if hit_object == null:
|
||||
return
|
||||
|
||||
var instance = hit_object.instantiate()
|
||||
add_child(instance)
|
||||
instance.position.y -= 17
|
||||
|
||||
Reference in New Issue
Block a user