]> Untitled Git - mushroom-game.git/blob - mushroom/mushroom.gd
a0100a23dd3e0d378f3de5595b2912b4457496ba
[mushroom-game.git] / mushroom / mushroom.gd
1 extends Node3D
2
3 signal picked
4
5
6 # Called when the node enters the scene tree for the first time.
7 func _ready() -> void:
8         pass # Replace with function body.
9
10
11 # Called every frame. 'delta' is the elapsed time since the previous frame.
12 func _process(_delta: float) -> void:
13         pass
14
15
16 func _on_area_3d_area_entered(area: Area3D) -> void:
17         if(area.is_in_group("player")):
18                 print("Player picked a mushroom!")
19                 hide()
20                 picked.emit()
21                 $Area3D/CollisionShape3D.set_deferred("disabled", true)