342175f4c3
Includes full design documentation (ARCHITECTURE, DESIGN_NOTES, CONTENT_SPEC, PRODUCTION_NOTES) and active Godot 4 / GDScript codebase. Core systems built: player, floor generation, room system, enemy base, body part upgrades, run manager, save system, HUD, EventBus.
12 lines
254 B
GDScript
12 lines
254 B
GDScript
extends Area2D
|
|
|
|
var part: BodyPartData = null
|
|
|
|
func _ready() -> void:
|
|
body_entered.connect(_on_body_entered)
|
|
|
|
func _on_body_entered(body: Node) -> void:
|
|
if body.is_in_group("player") and part != null:
|
|
UpgradeManager.acquire_part(part)
|
|
queue_free()
|