This repository has been archived on 2024-08-28. You can view files and clone it, but cannot push or open issues or pull requests.
gmtk-2024/scripts/killbox.gd

16 lines
386 B
GDScript3
Raw Permalink Normal View History

extends Area2D
@onready var kill_area = $VirulingKillArea
# Called when the node enters the scene tree for the first time.
func _ready() -> void:
body_entered.connect(kill_enemy)
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta: float) -> void:
pass
func kill_enemy(node: Node) -> void:
if node is Viruling:
node.is_dying = true