added building mode for cart

This commit is contained in:
Nikolai Fesenko
2025-08-10 20:38:16 +02:00
parent dc6f0d2907
commit 83095a0b8d
25 changed files with 3806 additions and 244 deletions

74
Scenes/Prefabs/cart.tscn Normal file
View File

@@ -0,0 +1,74 @@
[gd_scene load_steps=7 format=3 uid="uid://dim2geqhn6d35"]
[ext_resource type="Script" uid="uid://dhls6unflalvd" path="res://Scripts/cart.gd" id="1_esjgi"]
[ext_resource type="ArrayMesh" uid="uid://p3d7iitismhf" path="res://Blends/Cart/cart-bottom.obj" id="1_ux2tx"]
[ext_resource type="ArrayMesh" uid="uid://docto7iocves6" path="res://Blends/Cart/wheels.obj" id="2_2wj72"]
[ext_resource type="ArrayMesh" uid="uid://cayqoyyq7nbij" path="res://Blends/Cart/cart-top.obj" id="3_2wj72"]
[sub_resource type="BoxShape3D" id="BoxShape3D_esjgi"]
size = Vector3(22.2341, 4.23804, 0.494629)
[sub_resource type="BoxShape3D" id="BoxShape3D_eosii"]
size = Vector3(17.5376, 0.0286865, 2.28394)
[node name="Cart" type="Node3D" node_paths=PackedStringArray("cartTop")]
script = ExtResource("1_esjgi")
cartTop = NodePath("Cart-top")
[node name="Cart-bottom" type="MeshInstance3D" parent="."]
mesh = ExtResource("1_ux2tx")
[node name="Wheels2" type="MeshInstance3D" parent="."]
transform = Transform3D(1, 3.49691e-07, 0, -3.49691e-07, 1, 0, 0, 0, 1, -6.05656, -1.694, -2.014)
mesh = ExtResource("2_2wj72")
skeleton = NodePath("../Wheels")
[node name="Wheels3" type="MeshInstance3D" parent="."]
transform = Transform3D(1, 5.24537e-07, 0, -5.24537e-07, 1, 0, 0, 0, 1, 9.27867, -1.6046, -2.03998)
mesh = ExtResource("2_2wj72")
skeleton = NodePath(".")
[node name="Wheels4" type="MeshInstance3D" parent="."]
transform = Transform3D(1, 3.49691e-07, 0, -3.49691e-07, 1, 0, 0, 0, 1, 7.44502, -1.60475, -2.03976)
mesh = ExtResource("2_2wj72")
skeleton = NodePath("../Wheels")
[node name="Wheels" type="MeshInstance3D" parent="."]
transform = Transform3D(1, 1.74846e-07, 0, -1.74846e-07, 1, 0, 0, 0, 1, -7.8902, -1.69414, -2.01378)
mesh = ExtResource("2_2wj72")
[node name="Cart-top" type="MeshInstance3D" parent="."]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.0203524, 4.13717, 13.0563)
visible = false
mesh = ExtResource("3_2wj72")
[node name="BlockBuildingArea" type="StaticBody3D" parent="."]
[node name="CollisionShape3D4" type="CollisionShape3D" parent="BlockBuildingArea"]
transform = Transform3D(-4.37114e-08, 0, 1, 0, 1, 0, -1, 0, -4.37114e-08, 11.1878, 1.59147, -0.622702)
shape = SubResource("BoxShape3D_esjgi")
[node name="CollisionShape3D3" type="CollisionShape3D" parent="BlockBuildingArea"]
transform = Transform3D(-4.37114e-08, 0, 1, 0, 1, 0, -1, 0, -4.37114e-08, -10.6143, 1.63224, 0.537586)
shape = SubResource("BoxShape3D_esjgi")
[node name="CollisionShape3D2" type="CollisionShape3D" parent="BlockBuildingArea"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.619003, 1.50816, 3.83996)
shape = SubResource("BoxShape3D_esjgi")
[node name="CollisionShape3D" type="CollisionShape3D" parent="BlockBuildingArea"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.282789, 1.61902, -2.6054)
shape = SubResource("BoxShape3D_esjgi")
[node name="BuildingArea" type="StaticBody3D" parent="."]
metadata/is_building_area = true
[node name="CollisionShape3D" type="CollisionShape3D" parent="BuildingArea"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.374649, -0.275452, 2.38014)
shape = SubResource("BoxShape3D_eosii")
metadata/is_building_area = true
[node name="CollisionShape3D2" type="CollisionShape3D" parent="BuildingArea"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.374649, -0.275452, -1.22106)
shape = SubResource("BoxShape3D_eosii")
metadata/is_building_area = true