aboutsummaryrefslogtreecommitdiff
path: root/client/map/items
diff options
context:
space:
mode:
authortpart <tpart120@proton.me>2025-10-12 21:58:16 +0200
committertpart <tpart120@proton.me>2025-10-12 21:58:16 +0200
commit7815ea3f45fa20692084d3d12344a58cb3be3162 (patch)
tree64b18d0def07d0e5d34a23206769a68df829a7bf /client/map/items
parent11d15d56b3169e2f22a57f039a78572b423dc45c (diff)
downloadhurrycurry-7815ea3f45fa20692084d3d12344a58cb3be3162.tar
hurrycurry-7815ea3f45fa20692084d3d12344a58cb3be3162.tar.bz2
hurrycurry-7815ea3f45fa20692084d3d12344a58cb3be3162.tar.zst
Fix pizza appearing incorrectly on plate
Diffstat (limited to 'client/map/items')
-rw-r--r--client/map/items/plate.gd7
-rw-r--r--client/map/items/rolled_dough.gd4
2 files changed, 7 insertions, 4 deletions
diff --git a/client/map/items/plate.gd b/client/map/items/plate.gd
index 10918595..088d8734 100644
--- a/client/map/items/plate.gd
+++ b/client/map/items/plate.gd
@@ -46,7 +46,7 @@ func add_contents(contents: Array[String]):
# Stack content items on top of each other
var height_sum := 0.
- for c in contents:
+ for c: String in contents:
var item: Item
match c:
"curry": add_child(PlateFill.new(self, Color(.75, .45, .1)))
@@ -66,7 +66,10 @@ func add_contents(contents: Array[String]):
base.add_child(seared_steak)
seared_steak.scale *= 0.5
seared_steak.position += Vector3(.1, 0, .1)
- _: item = ItemFactory.produce(c, base)
+ _:
+ item = ItemFactory.produce(c, base)
+ if c.contains("pizza"):
+ item.scale = Vector3(.7, .7, .7)
if item != null:
base.add_child(item)
item.position.y = height_sum
diff --git a/client/map/items/rolled_dough.gd b/client/map/items/rolled_dough.gd
index fd6ae3d8..86c12062 100644
--- a/client/map/items/rolled_dough.gd
+++ b/client/map/items/rolled_dough.gd
@@ -22,10 +22,10 @@ func _init(owned_by_: Node3D):
func add_contents(contents: Array[String]):
contents.sort()
- if contents.is_empty():
- base.add_child(load("res://map/items/rolled_dough.tscn").instantiate())
if contents.has("tomato-juice"):
base.add_child(load("res://map/items/raw_pizza.tscn").instantiate())
+ else:
+ base.add_child(load("res://map/items/rolled_dough.tscn").instantiate())
for c: String in contents:
match c: