Added killing area

This commit is contained in:
2026-01-26 23:12:04 +03:00
parent cd74b87ca2
commit 0092c72a64
3 changed files with 26 additions and 0 deletions
+11
View File
@@ -0,0 +1,11 @@
class_name KillingArea
extends Area2D
func _on_body_entered(body: Node2D) -> void:
if not body is CharacterBody2D: return
if body.has_method("kill"):
body.kill()
else:
body.queue_free()