@icon("res://addons/at-icons/node3d/backpack.svg") class_name Backpack extends PickupableItem @export var inventory_size: int = 10 var inventory: Array[ItemData] = [] func change_backpack_mesh(new_mesh: MeshInstance3D): mesh = new_mesh func change_backpack(new_backpack: Backpack): mesh = new_backpack.mesh inventory_size = new_backpack.inventory_size inventory = new_backpack.inventory func _ready() -> void: for i in range(inventory_size): inventory.append(null) add_to_group("pickupable") for i in get_children(): i.add_to_group("pickupable")