aboutsummaryrefslogtreecommitdiff
path: root/client/map/items/plate.gd
diff options
context:
space:
mode:
authormetamuffin <metamuffin@disroot.org>2024-09-08 13:50:46 +0200
committermetamuffin <metamuffin@disroot.org>2024-09-08 13:50:46 +0200
commit3226addea9b2228ee75b84fc5165771c1935dd99 (patch)
tree5c851120431211ca79a00ddb98f1ff95180c09a0 /client/map/items/plate.gd
parentcd053cb7813160550bd83870c2b23604d147a8bd (diff)
downloadhurrycurry-3226addea9b2228ee75b84fc5165771c1935dd99.tar
hurrycurry-3226addea9b2228ee75b84fc5165771c1935dd99.tar.bz2
hurrycurry-3226addea9b2228ee75b84fc5165771c1935dd99.tar.zst
add item contents
Diffstat (limited to 'client/map/items/plate.gd')
-rw-r--r--client/map/items/plate.gd4
1 files changed, 3 insertions, 1 deletions
diff --git a/client/map/items/plate.gd b/client/map/items/plate.gd
index 61e097b8..2ff62d65 100644
--- a/client/map/items/plate.gd
+++ b/client/map/items/plate.gd
@@ -17,9 +17,11 @@
class_name Plate
extends Item
-func _init(owned_by_: Node3D):
+func _init(owned_by_: Node3D, contents: Array[String]):
super(owned_by_)
add_child(load("res://map/items/plate.tscn").instantiate())
+ for c in contents:
+ base.add_child(ItemFactory.produce(c, base))
func setup_sounds():
take_sound.setup([preload("res://map/items/sounds/plate_take.ogg")])