meat_madness_redux/godot/effects/SinkBlock.gd

15 lines
430 B
GDScript3
Raw Normal View History

extends Node
2022-11-27 13:31:09 -07:00
onready var util = get_node("/root/Util")
onready var global_event_bus = get_node("/root/GlobalEventBus")
onready var player = util.player
func _on_SinkRegion_body_entered(body: Node):
if body.get_parent() == player:
global_event_bus.emit_signal("player_entered_meat_sink")
func _on_SinkRegion_body_exited(body: Node):
if body.get_parent() == player:
global_event_bus.emit_signal("player_exited_meat_sink")