aboutsummaryrefslogtreecommitdiff
path: root/client/map
diff options
context:
space:
mode:
authortpart <tpart120@proton.me>2024-09-16 15:47:08 +0200
committertpart <tpart120@proton.me>2024-09-16 15:47:08 +0200
commit180b786bff761c9301898ca732d7bf24af6f14c7 (patch)
treee5828c015f748e4a1de0574572b1ef0303e4eab3 /client/map
parent503e0c59f8eb6186dd21171b7aaa0127a8580588 (diff)
downloadhurrycurry-180b786bff761c9301898ca732d7bf24af6f14c7.tar
hurrycurry-180b786bff761c9301898ca732d7bf24af6f14c7.tar.bz2
hurrycurry-180b786bff761c9301898ca732d7bf24af6f14c7.tar.zst
Add cheese and sliced cheese models; Implement items
Diffstat (limited to 'client/map')
-rw-r--r--client/map/item_factory.gd2
-rw-r--r--client/map/items/cheese.gd21
-rw-r--r--client/map/items/cheese.resbin0 -> 10028 bytes
-rw-r--r--client/map/items/cheese.tscn10
-rw-r--r--client/map/items/sliced_cheese.gd21
-rw-r--r--client/map/items/sliced_cheese.resbin0 -> 3862 bytes
-rw-r--r--client/map/items/sliced_cheese.tscn10
7 files changed, 64 insertions, 0 deletions
diff --git a/client/map/item_factory.gd b/client/map/item_factory.gd
index a1694cc0..31885cfe 100644
--- a/client/map/item_factory.gd
+++ b/client/map/item_factory.gd
@@ -25,6 +25,8 @@ static func produce(full_name: String, owned_by: Node3D) -> Item:
match name:
"bun": return Bun.new(owned_by)
+ "cheese": return Cheese.new(owned_by)
+ "sliced-cheese": return SlicedCheese.new(owned_by)
"dirt": return Dirt.new(owned_by)
"sliced-bun": return SlicedBun.new(owned_by)
"sliced-bun-top": return SlicedBunTop.new(owned_by)
diff --git a/client/map/items/cheese.gd b/client/map/items/cheese.gd
new file mode 100644
index 00000000..b3d1bc89
--- /dev/null
+++ b/client/map/items/cheese.gd
@@ -0,0 +1,21 @@
+# Hurry Curry! - a game about cooking
+# Copyright 2024 tpart
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Affero General Public License as published by
+# the Free Software Foundation, version 3 of the License only.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Affero General Public License for more details.
+#
+# You should have received a copy of the GNU Affero General Public License
+# along with this program. If not, see <https://www.gnu.org/licenses/>.
+#
+class_name Cheese
+extends Item
+
+func _init(owned_by_: Node3D):
+ super(owned_by_)
+ base.add_child(load("res://map/items/cheese.tscn").instantiate())
diff --git a/client/map/items/cheese.res b/client/map/items/cheese.res
new file mode 100644
index 00000000..6f868980
--- /dev/null
+++ b/client/map/items/cheese.res
Binary files differ
diff --git a/client/map/items/cheese.tscn b/client/map/items/cheese.tscn
new file mode 100644
index 00000000..515262c8
--- /dev/null
+++ b/client/map/items/cheese.tscn
@@ -0,0 +1,10 @@
+[gd_scene load_steps=2 format=3 uid="uid://0lbjf2sie4rk"]
+
+[ext_resource type="ArrayMesh" uid="uid://cshqtme8isvmw" path="res://map/items/cheese.res" id="1_p24nf"]
+
+[node name="Cheese" type="Node3D"]
+
+[node name="Mesh" type="MeshInstance3D" parent="."]
+transform = Transform3D(0.5, 0, 0, 0, 0.5, 0, 0, 0, 0.5, 0, 0, 0)
+mesh = ExtResource("1_p24nf")
+skeleton = NodePath("")
diff --git a/client/map/items/sliced_cheese.gd b/client/map/items/sliced_cheese.gd
new file mode 100644
index 00000000..26673bad
--- /dev/null
+++ b/client/map/items/sliced_cheese.gd
@@ -0,0 +1,21 @@
+# Hurry Curry! - a game about cooking
+# Copyright 2024 tpart
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Affero General Public License as published by
+# the Free Software Foundation, version 3 of the License only.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Affero General Public License for more details.
+#
+# You should have received a copy of the GNU Affero General Public License
+# along with this program. If not, see <https://www.gnu.org/licenses/>.
+#
+class_name SlicedCheese
+extends Item
+
+func _init(owned_by_: Node3D):
+ super(owned_by_)
+ base.add_child(load("res://map/items/sliced_cheese.tscn").instantiate())
diff --git a/client/map/items/sliced_cheese.res b/client/map/items/sliced_cheese.res
new file mode 100644
index 00000000..ece9c0e0
--- /dev/null
+++ b/client/map/items/sliced_cheese.res
Binary files differ
diff --git a/client/map/items/sliced_cheese.tscn b/client/map/items/sliced_cheese.tscn
new file mode 100644
index 00000000..4e9ba406
--- /dev/null
+++ b/client/map/items/sliced_cheese.tscn
@@ -0,0 +1,10 @@
+[gd_scene load_steps=2 format=3 uid="uid://cfdfhxgo4ot7m"]
+
+[ext_resource type="ArrayMesh" uid="uid://2qsg2dadmf1y" path="res://map/items/sliced_cheese.res" id="1_bbycg"]
+
+[node name="SlicedCheese" type="Node3D"]
+
+[node name="Mesh" type="MeshInstance3D" parent="."]
+transform = Transform3D(0.5, 0, 0, 0, 0.5, 0, 0, 0, 0.5, 0, 0.04, 0)
+mesh = ExtResource("1_bbycg")
+skeleton = NodePath("")