Finished basic PickupableItem

This commit is contained in:
Alexey 2025-08-01 13:11:26 +03:00
commit 88c56f8aed
21 changed files with 163 additions and 35 deletions

View file

@ -17,10 +17,11 @@ class WeaponSetData:
old_weapon = _old_weapon
func _ready():
has_weapon = get_child_count() > 0
var child_count = get_child_count()
has_weapon = child_count > 0
if has_weapon:
var child = get_child(0)
var child = get_child(child_count - 1)
assert(child is Weapon)
weapon = child as Weapon