From d301ff277f63d8d98168a651fd5abfcf14678c64 Mon Sep 17 00:00:00 2001 From: Rob Kelly Date: Thu, 3 Jul 2025 18:05:06 -0600 Subject: [PATCH] Extracted grunkable logic to component & extended to physical props as well --- .../level/corridor_1/corridor_1.tscn | 2 +- .../level/corridor_2/corridor_2.tscn | 2 +- .../level/crew_quarters/crew_quarters.tscn | 2 +- levels/ghost_ship/level/medbay/medbay.tscn | 4 +- .../ghost_ship/level/mess_hall/mess_hall.tscn | 2 +- .../level/ops_center/ops_center.tscn | 2 +- levels/pathing_test/pathing_test.tscn | 2 +- levels/physics_test/physics_test.tscn | 6 +- levels/prop_test/prop_test.tscn | 26 +- project.godot | 1 + src/equipment/point_spray/point_spray.gd | 7 +- src/equipment/toothbrush/toothbrush.gd | 9 +- src/equipment/toothbrush/toothbrush.tscn | 3 +- src/equipment/wide_spray/wide_spray.gd | 16 +- src/equipment/wide_spray/wide_spray.tscn | 5 - src/player/footsteps/footstep_controller.gd | 5 +- src/player/hold_component.gd | 4 +- src/player/player.tscn | 2 + src/props/cafe_table/cafe_table.tscn | 16 +- src/props/crate_long/phys_crate_long.tscn | 58 ++++ ...crate_long.tscn => static_crate_long.tscn} | 18 +- src/props/cupboard/cupboard.tscn | 16 +- src/props/eva_suit/empty_enclosure.tscn | 18 +- src/props/eva_suit/eva_suit.tscn | 56 +++- src/props/med_cart/phys_med_cart.tscn | 60 ++++ .../{med_cart.tscn => static_med_cart.tscn} | 40 ++- .../operating_table/operating_table.tscn | 18 +- src/props/overhead_light/burnout_light.tscn | 16 +- src/props/overhead_light/overhead_light.gd | 6 +- src/props/overhead_light/overhead_light.tscn | 20 +- src/props/physics/persistent_prop.gd | 18 + src/props/physics/persistent_prop.gd.uid | 1 + src/props/railing/railing.tscn | 16 +- src/props/sofa/sofa.tscn | 18 +- src/props/tarp_crate/tarp_crate.tscn | 16 +- src/props/trash_can/phys_trash_can.tscn | 70 ++++ .../{trash_can.tscn => static_trash_can.tscn} | 40 ++- .../vending_machine/vending_machine.tscn | 15 +- src/props/wall_switch/wall_switch.gd | 7 +- src/props/wall_switch/wall_switch.tscn | 19 +- src/world/gunk_body/gunkable.gd | 309 ++++++++++++++++++ src/world/gunk_body/gunkable.gd.uid | 1 + src/world/gunk_body/gunkable.tscn | 47 +++ src/world/world.tscn | 2 +- 44 files changed, 860 insertions(+), 161 deletions(-) create mode 100644 src/props/crate_long/phys_crate_long.tscn rename src/props/crate_long/{crate_long.tscn => static_crate_long.tscn} (84%) create mode 100644 src/props/med_cart/phys_med_cart.tscn rename src/props/med_cart/{med_cart.tscn => static_med_cart.tscn} (95%) create mode 100644 src/props/physics/persistent_prop.gd create mode 100644 src/props/physics/persistent_prop.gd.uid create mode 100644 src/props/trash_can/phys_trash_can.tscn rename src/props/trash_can/{trash_can.tscn => static_trash_can.tscn} (86%) create mode 100644 src/world/gunk_body/gunkable.gd create mode 100644 src/world/gunk_body/gunkable.gd.uid create mode 100644 src/world/gunk_body/gunkable.tscn diff --git a/levels/ghost_ship/level/corridor_1/corridor_1.tscn b/levels/ghost_ship/level/corridor_1/corridor_1.tscn index d299028..c10641b 100644 --- a/levels/ghost_ship/level/corridor_1/corridor_1.tscn +++ b/levels/ghost_ship/level/corridor_1/corridor_1.tscn @@ -2,7 +2,7 @@ [ext_resource type="ArrayMesh" uid="uid://cqd0a7ousx01n" path="res://assets/level/hallway/hallway_1.mesh" id="1_ckpmb"] [ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="2_a8b6q"] -[ext_resource type="PackedScene" uid="uid://cppd3scvxf3eg" path="res://src/props/crate_long/crate_long.tscn" id="3_8umoc"] +[ext_resource type="PackedScene" uid="uid://cppd3scvxf3eg" path="res://src/props/crate_long/static_crate_long.tscn" id="3_8umoc"] [ext_resource type="Texture2D" uid="uid://cd0w8eqpount3" path="res://assets/props/crate_long/crate_long_C.png" id="4_s4vba"] [ext_resource type="Texture2D" uid="uid://da5p04vbiy3xe" path="res://assets/props/crate_long/crate_long_M.png" id="5_n7a6q"] [ext_resource type="Texture2D" uid="uid://bsovubygl3go2" path="res://assets/props/crate_long/crate_long_N.png" id="6_hwbyh"] diff --git a/levels/ghost_ship/level/corridor_2/corridor_2.tscn b/levels/ghost_ship/level/corridor_2/corridor_2.tscn index 7b1e336..9cb5fa0 100644 --- a/levels/ghost_ship/level/corridor_2/corridor_2.tscn +++ b/levels/ghost_ship/level/corridor_2/corridor_2.tscn @@ -17,7 +17,7 @@ [ext_resource type="Material" uid="uid://dt73a25l7h8if" path="res://levels/ghost_ship/guide_sign/crew_quarters_sign.material" id="15_ygcwo"] [ext_resource type="ArrayMesh" uid="uid://b3f5p4o7qr1mf" path="res://assets/level/t-junction/t-junction_2.mesh" id="16_0fxnd"] [ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="17_wqkax"] -[ext_resource type="PackedScene" uid="uid://cppd3scvxf3eg" path="res://src/props/crate_long/crate_long.tscn" id="18_ew4hm"] +[ext_resource type="PackedScene" uid="uid://cppd3scvxf3eg" path="res://src/props/crate_long/static_crate_long.tscn" id="18_ew4hm"] [ext_resource type="Texture2D" uid="uid://cd0w8eqpount3" path="res://assets/props/crate_long/crate_long_C.png" id="19_0xbp3"] [ext_resource type="Texture2D" uid="uid://da5p04vbiy3xe" path="res://assets/props/crate_long/crate_long_M.png" id="20_wp8cq"] [ext_resource type="Texture2D" uid="uid://bsovubygl3go2" path="res://assets/props/crate_long/crate_long_N.png" id="21_opjmq"] diff --git a/levels/ghost_ship/level/crew_quarters/crew_quarters.tscn b/levels/ghost_ship/level/crew_quarters/crew_quarters.tscn index 2705cb0..9153356 100644 --- a/levels/ghost_ship/level/crew_quarters/crew_quarters.tscn +++ b/levels/ghost_ship/level/crew_quarters/crew_quarters.tscn @@ -18,7 +18,7 @@ [ext_resource type="Texture2D" uid="uid://bmwmajwul60ti" path="res://assets/level/ceiling/ceiling_1_N.png" id="16_jbppi"] [ext_resource type="Texture2D" uid="uid://8hav47a84uk" path="res://assets/level/ceiling/ceiling_1_R.png" id="17_ddwoq"] [ext_resource type="ArrayMesh" uid="uid://d0sdsir1hqnbu" path="res://assets/level/wall/wall_4.mesh" id="18_rwb8f"] -[ext_resource type="PackedScene" uid="uid://cppd3scvxf3eg" path="res://src/props/crate_long/crate_long.tscn" id="19_hpoqx"] +[ext_resource type="PackedScene" uid="uid://cppd3scvxf3eg" path="res://src/props/crate_long/static_crate_long.tscn" id="19_hpoqx"] [ext_resource type="Texture2D" uid="uid://cd0w8eqpount3" path="res://assets/props/crate_long/crate_long_C.png" id="20_77h2o"] [ext_resource type="Texture2D" uid="uid://da5p04vbiy3xe" path="res://assets/props/crate_long/crate_long_M.png" id="21_j4f2j"] [ext_resource type="Texture2D" uid="uid://bsovubygl3go2" path="res://assets/props/crate_long/crate_long_N.png" id="22_4q4f8"] diff --git a/levels/ghost_ship/level/medbay/medbay.tscn b/levels/ghost_ship/level/medbay/medbay.tscn index 49810fe..8c167f8 100644 --- a/levels/ghost_ship/level/medbay/medbay.tscn +++ b/levels/ghost_ship/level/medbay/medbay.tscn @@ -9,9 +9,9 @@ [ext_resource type="ArrayMesh" uid="uid://dkh2r61ydupb7" path="res://assets/level/floor/floor_2.mesh" id="7_bnexv"] [ext_resource type="ArrayMesh" uid="uid://dbgk0kdg1vufk" path="res://assets/level/ceiling/ceiling_1.mesh" id="8_p5an5"] [ext_resource type="PackedScene" uid="uid://oipf3w7hm5gf" path="res://src/props/operating_table/operating_table.tscn" id="9_1syyw"] -[ext_resource type="PackedScene" uid="uid://h2gswdcxyotk" path="res://src/props/med_cart/med_cart.tscn" id="10_loej8"] +[ext_resource type="PackedScene" uid="uid://h2gswdcxyotk" path="res://src/props/med_cart/static_med_cart.tscn" id="10_loej8"] [ext_resource type="PackedScene" uid="uid://c8pkhw0b47xdd" path="res://src/props/cupboard/cupboard.tscn" id="11_5abrm"] -[ext_resource type="PackedScene" uid="uid://cppd3scvxf3eg" path="res://src/props/crate_long/crate_long.tscn" id="12_t0ymk"] +[ext_resource type="PackedScene" uid="uid://cppd3scvxf3eg" path="res://src/props/crate_long/static_crate_long.tscn" id="12_t0ymk"] [ext_resource type="Texture2D" uid="uid://cd0w8eqpount3" path="res://assets/props/crate_long/crate_long_C.png" id="13_glbip"] [ext_resource type="Texture2D" uid="uid://da5p04vbiy3xe" path="res://assets/props/crate_long/crate_long_M.png" id="14_nqwfe"] [ext_resource type="Texture2D" uid="uid://bsovubygl3go2" path="res://assets/props/crate_long/crate_long_N.png" id="15_h56f5"] diff --git a/levels/ghost_ship/level/mess_hall/mess_hall.tscn b/levels/ghost_ship/level/mess_hall/mess_hall.tscn index c3b9a9b..580bfb4 100644 --- a/levels/ghost_ship/level/mess_hall/mess_hall.tscn +++ b/levels/ghost_ship/level/mess_hall/mess_hall.tscn @@ -13,7 +13,7 @@ [ext_resource type="Texture2D" uid="uid://dkilg200w8x4y" path="res://assets/props/vending_machine/vending_machine_M.png" id="11_ps4r1"] [ext_resource type="Texture2D" uid="uid://8v7jta2qdvut" path="res://assets/props/vending_machine/vending_machine_N.png" id="12_iie7g"] [ext_resource type="Texture2D" uid="uid://gbvtbiurxrop" path="res://assets/props/vending_machine/vending_machine_R.png" id="13_nvfj8"] -[ext_resource type="PackedScene" uid="uid://cklppdtyaadlo" path="res://src/props/trash_can/trash_can.tscn" id="14_3wo07"] +[ext_resource type="PackedScene" uid="uid://cklppdtyaadlo" path="res://src/props/trash_can/static_trash_can.tscn" id="14_3wo07"] [ext_resource type="PackedScene" uid="uid://30o8ltnnxpxo" path="res://src/effects/floating_dust.tscn" id="15_87puh"] [ext_resource type="PackedScene" uid="uid://d2feet02a603e" path="res://src/props/overhead_light/overhead_light.tscn" id="16_s0n7p"] [ext_resource type="Texture2D" uid="uid://wqqwtmtmp147" path="res://assets/level/overhead_light_maskC.png" id="17_6lrbi"] diff --git a/levels/ghost_ship/level/ops_center/ops_center.tscn b/levels/ghost_ship/level/ops_center/ops_center.tscn index 7d5085d..e89c1e1 100644 --- a/levels/ghost_ship/level/ops_center/ops_center.tscn +++ b/levels/ghost_ship/level/ops_center/ops_center.tscn @@ -14,7 +14,7 @@ [ext_resource type="Texture2D" uid="uid://bgc8oqsnimb8i" path="res://assets/level/floor/floor_1_N.png" id="12_ukiad"] [ext_resource type="Texture2D" uid="uid://23uupxc78b8n" path="res://assets/level/floor/floor_1_R.png" id="13_1vbec"] [ext_resource type="PackedScene" uid="uid://ctm84yms40858" path="res://src/props/railing/railing.tscn" id="14_mspvt"] -[ext_resource type="PackedScene" uid="uid://cppd3scvxf3eg" path="res://src/props/crate_long/crate_long.tscn" id="15_5lcoj"] +[ext_resource type="PackedScene" uid="uid://cppd3scvxf3eg" path="res://src/props/crate_long/static_crate_long.tscn" id="15_5lcoj"] [ext_resource type="Texture2D" uid="uid://cd0w8eqpount3" path="res://assets/props/crate_long/crate_long_C.png" id="16_bembv"] [ext_resource type="Texture2D" uid="uid://da5p04vbiy3xe" path="res://assets/props/crate_long/crate_long_M.png" id="17_8j8pa"] [ext_resource type="Texture2D" uid="uid://bsovubygl3go2" path="res://assets/props/crate_long/crate_long_N.png" id="18_ch7mi"] diff --git a/levels/pathing_test/pathing_test.tscn b/levels/pathing_test/pathing_test.tscn index 035dbd4..4bf481f 100644 --- a/levels/pathing_test/pathing_test.tscn +++ b/levels/pathing_test/pathing_test.tscn @@ -4,7 +4,7 @@ [ext_resource type="PackedScene" uid="uid://ehf5sg3ahvbf" path="res://src/world/grunk_beast/grunk_beast.tscn" id="2_1lom2"] [ext_resource type="ArrayMesh" uid="uid://cqd0a7ousx01n" path="res://assets/level/hallway/hallway_1.mesh" id="3_gyhlh"] [ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="4_jj0u7"] -[ext_resource type="PackedScene" uid="uid://cppd3scvxf3eg" path="res://src/props/crate_long/crate_long.tscn" id="5_18csx"] +[ext_resource type="PackedScene" uid="uid://cppd3scvxf3eg" path="res://src/props/crate_long/static_crate_long.tscn" id="5_18csx"] [ext_resource type="Texture2D" uid="uid://clofvb76pv6g" path="res://assets/red.png" id="5_jj0u7"] [ext_resource type="Texture2D" uid="uid://cd0w8eqpount3" path="res://assets/props/crate_long/crate_long_C.png" id="6_e2fuu"] [ext_resource type="Texture2D" uid="uid://da5p04vbiy3xe" path="res://assets/props/crate_long/crate_long_M.png" id="7_hv7qb"] diff --git a/levels/physics_test/physics_test.tscn b/levels/physics_test/physics_test.tscn index 84ae299..cb7e55a 100644 --- a/levels/physics_test/physics_test.tscn +++ b/levels/physics_test/physics_test.tscn @@ -1,9 +1,10 @@ -[gd_scene load_steps=16 format=3 uid="uid://c7us4smgk3487"] +[gd_scene load_steps=17 format=3 uid="uid://c7us4smgk3487"] [ext_resource type="Script" uid="uid://68r4ht5ut1ct" path="res://src/game/level.gd" id="1_252gx"] [ext_resource type="PackedScene" uid="uid://bwe2jdmvinhqd" path="res://src/player/player.tscn" id="1_sumi4"] [ext_resource type="ArrayMesh" uid="uid://dpr5cgq743f4s" path="res://assets/level/floor/floor_9x9.mesh" id="2_jjage"] [ext_resource type="Script" uid="uid://040xta01xqxd" path="res://src/props/physics/holdable.gd" id="4_252gx"] +[ext_resource type="PackedScene" uid="uid://drm5dspi48pf5" path="res://src/props/crate_long/phys_crate_long.tscn" id="5_35l2h"] [sub_resource type="ProceduralSkyMaterial" id="ProceduralSkyMaterial_hda7d"] @@ -164,3 +165,6 @@ shape = SubResource("SphereShape3D_hyy3g") [node name="Holdable" type="Node" parent="Ball"] script = ExtResource("4_252gx") metadata/_custom_type_script = "uid://040xta01xqxd" + +[node name="PhysCrateLong" parent="." instance=ExtResource("5_35l2h")] +transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -3, 0.9, -6) diff --git a/levels/prop_test/prop_test.tscn b/levels/prop_test/prop_test.tscn index cc4a53e..8041c55 100644 --- a/levels/prop_test/prop_test.tscn +++ b/levels/prop_test/prop_test.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=40 format=3 uid="uid://dc4tts6342cuj"] +[gd_scene load_steps=43 format=3 uid="uid://dc4tts6342cuj"] [ext_resource type="Script" uid="uid://dmbdkydqnbyqv" path="res://levels/prop_test/prop_test.gd" id="1_ibd1t"] [ext_resource type="PackedScene" uid="uid://bwe2jdmvinhqd" path="res://src/player/player.tscn" id="1_ml0ka"] @@ -9,23 +9,26 @@ [ext_resource type="PackedScene" uid="uid://b6eg8t04rkh0c" path="res://src/props/wall_switch/wall_switch.tscn" id="5_y13lv"] [ext_resource type="PackedScene" uid="uid://cvx5u0ttmri4q" path="res://src/props/sofa/sofa.tscn" id="6_kccq3"] [ext_resource type="PackedScene" uid="uid://ca7b5gjl3ri0p" path="res://src/props/cafe_table/cafe_table.tscn" id="6_tm4v6"] -[ext_resource type="PackedScene" uid="uid://cppd3scvxf3eg" path="res://src/props/crate_long/crate_long.tscn" id="7_4jlf1"] +[ext_resource type="PackedScene" uid="uid://cppd3scvxf3eg" path="res://src/props/crate_long/static_crate_long.tscn" id="7_4jlf1"] [ext_resource type="PackedScene" uid="uid://bpsiwx1517pk1" path="res://src/props/tarp_crate/tarp_crate.tscn" id="7_xlkhi"] +[ext_resource type="PackedScene" uid="uid://drm5dspi48pf5" path="res://src/props/crate_long/phys_crate_long.tscn" id="8_8a67w"] [ext_resource type="PackedScene" uid="uid://c8pkhw0b47xdd" path="res://src/props/cupboard/cupboard.tscn" id="8_kgrlx"] [ext_resource type="PackedScene" uid="uid://dl6vekf0joac4" path="res://src/props/eva_suit/eva_suit.tscn" id="9_7md1e"] [ext_resource type="PackedScene" uid="uid://b56sbxcwhveex" path="res://src/props/eva_suit/empty_enclosure.tscn" id="10_s7h0g"] -[ext_resource type="PackedScene" uid="uid://h2gswdcxyotk" path="res://src/props/med_cart/med_cart.tscn" id="11_s7h0g"] +[ext_resource type="PackedScene" uid="uid://h2gswdcxyotk" path="res://src/props/med_cart/static_med_cart.tscn" id="11_s7h0g"] [ext_resource type="PackedScene" uid="uid://bve6iya13lhah" path="res://src/props/monitor/monitor.tscn" id="12_wyhm4"] [ext_resource type="PackedScene" uid="uid://oipf3w7hm5gf" path="res://src/props/operating_table/operating_table.tscn" id="13_vp610"] [ext_resource type="PackedScene" uid="uid://d2feet02a603e" path="res://src/props/overhead_light/overhead_light.tscn" id="14_sbwfa"] +[ext_resource type="PackedScene" uid="uid://cv6sxj04rrkt2" path="res://src/props/med_cart/phys_med_cart.tscn" id="14_u3x5h"] [ext_resource type="PackedScene" uid="uid://rykf34p8n8x6" path="res://src/props/overhead_light/burnout_light.tscn" id="15_r8upy"] [ext_resource type="PackedScene" uid="uid://ctm84yms40858" path="res://src/props/railing/railing.tscn" id="16_kccq3"] [ext_resource type="PackedScene" uid="uid://ctr56p23cvupu" path="res://src/props/retinal_scanner/retinal_scanner.tscn" id="17_r8upy"] [ext_resource type="PackedScene" uid="uid://cjqayfrj2oxyr" path="res://src/props/tarp_crate/tarp_crate_logo.tscn" id="20_pfhf5"] -[ext_resource type="PackedScene" uid="uid://cklppdtyaadlo" path="res://src/props/trash_can/trash_can.tscn" id="21_wgtci"] +[ext_resource type="PackedScene" uid="uid://cklppdtyaadlo" path="res://src/props/trash_can/static_trash_can.tscn" id="21_wgtci"] [ext_resource type="PackedScene" uid="uid://dtus42gmb1kqq" path="res://src/props/vending_machine/vending_machine.tscn" id="22_6oadn"] [ext_resource type="Texture2D" uid="uid://d2xq0uvxh2ojk" path="res://assets/props/vending_machine/vending_machine_C.png" id="23_ibd1t"] [ext_resource type="Texture2D" uid="uid://d0xe37qm3k7d8" path="res://assets/props/vending_machine/vending_machine_E.png" id="24_mvw32"] +[ext_resource type="PackedScene" uid="uid://p86qtslgpe1i" path="res://src/props/trash_can/phys_trash_can.tscn" id="25_8eukv"] [ext_resource type="Texture2D" uid="uid://dkilg200w8x4y" path="res://assets/props/vending_machine/vending_machine_M.png" id="25_yijpk"] [ext_resource type="Texture2D" uid="uid://8v7jta2qdvut" path="res://assets/props/vending_machine/vending_machine_N.png" id="26_qnhar"] [ext_resource type="Texture2D" uid="uid://gbvtbiurxrop" path="res://assets/props/vending_machine/vending_machine_R.png" id="27_8a67w"] @@ -179,10 +182,13 @@ text = "Open" transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -2.7, 0.4, -9) skeleton = NodePath("../..") -[node name="CrateLong" parent="Props" instance=ExtResource("7_4jlf1")] +[node name="StaticCrateLong" parent="Props" instance=ExtResource("7_4jlf1")] transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.9, 1.5, -9) skeleton = NodePath("../..") +[node name="PhysCrateLong" parent="Props" instance=ExtResource("8_8a67w")] +transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 2.1, 1.5, -7.5) + [node name="Cupboard" parent="Props" instance=ExtResource("8_kgrlx")] transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 3.9, 2.4, -9) skeleton = NodePath("../..") @@ -193,10 +199,13 @@ transform = Transform3D(-1, 0, -8.74228e-08, 0, 1, 0, 8.74228e-08, 0, -1, 7.5223 [node name="EVASuit2" parent="Props" instance=ExtResource("10_s7h0g")] transform = Transform3D(-1, 0, -8.74228e-08, 0, 1, 0, 8.74228e-08, 0, -1, 10.8753, 1.49988, -11.2474) -[node name="MedCart" parent="Props" instance=ExtResource("11_s7h0g")] +[node name="StaticMedCart" parent="Props" instance=ExtResource("11_s7h0g")] transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 13.8, 0.5, -10.8) skeleton = NodePath("../..") +[node name="PhysMedCart" parent="Props" instance=ExtResource("14_u3x5h")] +transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 14.7, 0.5, -9.6) + [node name="Monitor" parent="Props" instance=ExtResource("12_wyhm4")] transform = Transform3D(-1, 0, -8.74228e-08, 0, 1, 0, 8.74228e-08, 0, -1, 15.3, 1.5, -10.8) @@ -229,10 +238,13 @@ skeleton = NodePath("../..") transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 39, 0.8, -12) skeleton = NodePath("../..") -[node name="TrashCan" parent="Props" instance=ExtResource("21_wgtci")] +[node name="StaticTrashCan" parent="Props" instance=ExtResource("21_wgtci")] transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 42, 0.5, -12) skeleton = NodePath("../..") +[node name="PhysTrashCan" parent="Props" instance=ExtResource("25_8eukv")] +transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 42.9, 0.5, -10.8) + [node name="VendingMachine" parent="Props" instance=ExtResource("22_6oadn")] unique_name_in_owner = true transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 45, 1.5654, -12) diff --git a/project.godot b/project.godot index d943bb3..7eb24b4 100644 --- a/project.godot +++ b/project.godot @@ -210,6 +210,7 @@ locale/translations=PackedStringArray("res://assets/text/text.en.translation") 3d_physics/layer_4="Player" 3d_physics/layer_5="GameSounds" 3d_physics/layer_6="Player Physics" +3d_physics/layer_7="Prop Physics" [physics] diff --git a/src/equipment/point_spray/point_spray.gd b/src/equipment/point_spray/point_spray.gd index 4993513..c457c4a 100644 --- a/src/equipment/point_spray/point_spray.gd +++ b/src/equipment/point_spray/point_spray.gd @@ -14,11 +14,10 @@ func _spray() -> void: spray_sfx.set_angle_from_normal(laser.get_collision_normal()) var collider := laser.get_collider() - if collider is GunkBody: + var gunk_component := Gunkable.get_component(collider) + if gunk_component: var point := laser.get_collision_point() var point_scale := point.distance_to(global_position) * spray_scale - (collider as GunkBody).paint_continuous( - point, laser.get_collision_normal(), point_scale - ) + gunk_component.paint_continuous(point, laser.get_collision_normal(), point_scale) if collider is Sprayable: (collider as Sprayable).hit(damage) diff --git a/src/equipment/toothbrush/toothbrush.gd b/src/equipment/toothbrush/toothbrush.gd index 1a31731..84dafac 100644 --- a/src/equipment/toothbrush/toothbrush.gd +++ b/src/equipment/toothbrush/toothbrush.gd @@ -19,15 +19,16 @@ func _fire() -> void: if raycast.is_colliding() and not World.instance.manager.is_tank_full(): brush_animation.play("brush") var collider := raycast.get_collider() - if collider is GunkBody: - (collider as GunkBody).paint_dot( + var gunk_component := Gunkable.get_component(collider) + if gunk_component: + gunk_component.paint_dot( raycast.get_collision_point(), raycast.get_collision_normal(), BRUSH_SCALE, PAINT_COLOR ) - if collider is GunkNode: - (collider as GunkNode).hit(damage) + if collider is Sprayable: + (collider as Sprayable).hit(damage) else: brush_animation.stop() diff --git a/src/equipment/toothbrush/toothbrush.tscn b/src/equipment/toothbrush/toothbrush.tscn index 1bcdddf..999d677 100644 --- a/src/equipment/toothbrush/toothbrush.tscn +++ b/src/equipment/toothbrush/toothbrush.tscn @@ -117,8 +117,7 @@ unique_name_in_owner = true visible = false texture_filter = 1 layout_mode = 0 -offset_left = -40.0 -offset_right = 24.0 +offset_right = 64.0 offset_bottom = 128.0 scale = Vector2(5, 5) texture = ExtResource("4_atd0h") diff --git a/src/equipment/wide_spray/wide_spray.gd b/src/equipment/wide_spray/wide_spray.gd index 901ff8f..c2df9dc 100644 --- a/src/equipment/wide_spray/wide_spray.gd +++ b/src/equipment/wide_spray/wide_spray.gd @@ -36,7 +36,7 @@ func _fire() -> void: func _spray() -> void: - var prev_target: GunkBody = null + var prev_target: Gunkable = null var prev_point: Vector3 var prev_normal: Vector3 @@ -46,19 +46,21 @@ func _spray() -> void: spray_sfx.set_angle_from_normal(laser.get_collision_normal()) var collider := laser.get_collider() - if collider is GunkBody: - var target := collider as GunkBody + var gunk_component := Gunkable.get_component(collider) + if gunk_component: var point := laser.get_collision_point() var normal := laser.get_collision_normal() # Always paint at least a dot, to cap the ends of the line - target.paint_dot(point, normal, spray_scale) - if target == prev_target: + gunk_component.paint_dot(point, normal, spray_scale) + if gunk_component == prev_target: # Continue the multiline if possible - target.add_to_multiline(prev_point, prev_normal, point, normal, spray_scale * 2) + gunk_component.add_to_multiline( + prev_point, prev_normal, point, normal, spray_scale * 2 + ) prev_point = point prev_normal = normal - prev_target = target + prev_target = gunk_component prev_point = point prev_normal = normal elif collider is Sprayable: diff --git a/src/equipment/wide_spray/wide_spray.tscn b/src/equipment/wide_spray/wide_spray.tscn index 9560077..aa6ea1b 100644 --- a/src/equipment/wide_spray/wide_spray.tscn +++ b/src/equipment/wide_spray/wide_spray.tscn @@ -321,11 +321,6 @@ offset_left = 344.0 offset_top = 211.0 offset_right = 344.0 offset_bottom = 211.0 -BUFFER_RUMBLE_FACTOR = 3.0 -RUMBLE_DECAY = 10 -NEEDLE_ACCEL = 1.0 -NEEDLE_VELOCITY_MAX = 1.0 -debug_collect = 0.0 [node name="AnimationPlayer" type="AnimationPlayer" parent="."] unique_name_in_owner = true diff --git a/src/player/footsteps/footstep_controller.gd b/src/player/footsteps/footstep_controller.gd index c99a2a3..30adac4 100644 --- a/src/player/footsteps/footstep_controller.gd +++ b/src/player/footsteps/footstep_controller.gd @@ -34,9 +34,10 @@ func play_footstep() -> void: func get_material_under_foot() -> SurfaceMaterial.Type: var collider := foot_cast.get_collider() as Node - if collider is GunkBody: + var gunk_component := Gunkable.get_component(collider) + if gunk_component: # Special case: check if collision surface is gunked - if (collider as GunkBody).is_point_gunked( + if gunk_component.is_point_gunked( foot_cast.get_collision_point(), foot_cast.get_collision_normal() ): return SurfaceMaterial.Type.GRUNK diff --git a/src/player/hold_component.gd b/src/player/hold_component.gd index 37fe137..6270713 100644 --- a/src/player/hold_component.gd +++ b/src/player/hold_component.gd @@ -14,10 +14,10 @@ extends Node3D @export var hold_damping := 8.0 ## Temporary collision layer. -@export_flags_3d_physics var hold_collision_layer := 0 +@export_flags_3d_physics var hold_collision_layer := 0b01000000 ## Temporary collision mask. -@export_flags_3d_physics var hold_collision_physics := 1 +@export_flags_3d_physics var hold_collision_physics := 0b01000001 ## The object currently being held. var _held_object: RigidBody3D diff --git a/src/player/player.tscn b/src/player/player.tscn index d517cae..a2e1827 100644 --- a/src/player/player.tscn +++ b/src/player/player.tscn @@ -684,6 +684,8 @@ script = ExtResource("7_x42xx") [node name="HoldComponent" type="Node3D" parent="CameraPosition/CameraPivot/TransformedPosition/CamRumbler/Camera3D"] script = ExtResource("11_h0enb") +hold_accel = 40.0 +hold_speed = 20.0 [node name="HoldPoint" type="Marker3D" parent="CameraPosition/CameraPivot/TransformedPosition/CamRumbler/Camera3D/HoldComponent"] unique_name_in_owner = true diff --git a/src/props/cafe_table/cafe_table.tscn b/src/props/cafe_table/cafe_table.tscn index ce31d69..311fa97 100644 --- a/src/props/cafe_table/cafe_table.tscn +++ b/src/props/cafe_table/cafe_table.tscn @@ -1,11 +1,12 @@ -[gd_scene load_steps=9 format=3 uid="uid://ca7b5gjl3ri0p"] +[gd_scene load_steps=10 format=3 uid="uid://ca7b5gjl3ri0p"] [ext_resource type="Texture2D" uid="uid://kji1r64xr62b" path="res://assets/props/cafe_table/cafe_table_C.png" id="1_8c2wd"] [ext_resource type="ArrayMesh" uid="uid://02pxl1iknwie" path="res://assets/props/cafe_table/cafe_table.obj" id="1_kbxmn"] [ext_resource type="Texture2D" uid="uid://chh8wcdsu601s" path="res://assets/props/cafe_table/cafe_table_M.png" id="2_atatm"] [ext_resource type="Texture2D" uid="uid://6nrac2ciprd4" path="res://assets/props/cafe_table/cafe_table_N.png" id="3_4grlf"] [ext_resource type="Texture2D" uid="uid://dryw5kjktefst" path="res://assets/props/cafe_table/cafe_table_R.png" id="4_naoko"] -[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="5_ywp2f"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="7_atatm"] +[ext_resource type="Material" uid="uid://cqjr3cbxtfg2j" path="res://assets/materials/gunk.material" id="8_4grlf"] [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_q50g7"] albedo_texture = ExtResource("1_8c2wd") @@ -23,7 +24,14 @@ data = PackedVector3Array(0.9, 0, -0.05, 0.9, 0, -2.95, 1.5, 0, -0.05, 1.5, 0, - mesh = ExtResource("1_kbxmn") surface_material_override/0 = SubResource("StandardMaterial3D_q50g7") -[node name="GunkBody" parent="." groups=["PlasticMaterial"] instance=ExtResource("5_ywp2f")] +[node name="StaticBody3D" type="StaticBody3D" parent="." groups=["PlasticMaterial"]] +collision_layer = 5 +collision_mask = 0 -[node name="CollisionShape3D" type="CollisionShape3D" parent="GunkBody"] +[node name="CollisionShape3D" type="CollisionShape3D" parent="StaticBody3D"] shape = SubResource("ConcavePolygonShape3D_c6qxl") + +[node name="Gunkable" parent="StaticBody3D" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("7_atatm")] +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("8_4grlf") diff --git a/src/props/crate_long/phys_crate_long.tscn b/src/props/crate_long/phys_crate_long.tscn new file mode 100644 index 0000000..e1b7cbc --- /dev/null +++ b/src/props/crate_long/phys_crate_long.tscn @@ -0,0 +1,58 @@ +[gd_scene load_steps=13 format=3 uid="uid://drm5dspi48pf5"] + +[ext_resource type="Script" uid="uid://sksndhqyo2bn" path="res://src/props/physics/persistent_prop.gd" id="1_q4djj"] +[ext_resource type="ArrayMesh" uid="uid://cd7vwjss7qytk" path="res://assets/props/crate_long/crate_long.obj" id="1_sao54"] +[ext_resource type="Texture2D" uid="uid://cd0w8eqpount3" path="res://assets/props/crate_long/crate_long_C.png" id="2_rlyiq"] +[ext_resource type="Texture2D" uid="uid://da5p04vbiy3xe" path="res://assets/props/crate_long/crate_long_M.png" id="3_p8srg"] +[ext_resource type="Texture2D" uid="uid://bsovubygl3go2" path="res://assets/props/crate_long/crate_long_N.png" id="4_q4djj"] +[ext_resource type="Texture2D" uid="uid://b1m1my5q2vlwi" path="res://assets/props/crate_long/crate_long_R.png" id="5_eb8p8"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="6_064yj"] +[ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="7_rlyiq"] +[ext_resource type="Script" uid="uid://040xta01xqxd" path="res://src/props/physics/holdable.gd" id="8_p8srg"] + +[sub_resource type="BoxShape3D" id="BoxShape3D_p8srg"] +size = Vector3(0.75, 0.5, 1.5) + +[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_8j27j"] +albedo_texture = ExtResource("2_rlyiq") +metallic = 1.0 +metallic_texture = ExtResource("3_p8srg") +roughness_texture = ExtResource("5_eb8p8") +normal_enabled = true +normal_texture = ExtResource("4_q4djj") +ao_enabled = true +texture_filter = 2 + +[sub_resource type="ConcavePolygonShape3D" id="ConcavePolygonShape3D_p8srg"] +data = PackedVector3Array(0.375, -0.15, 0.75, 0.275, -0.25, 0.75, 0.375, 0.15, 0.75, 0.375, 0.15, 0.75, 0.275, -0.25, 0.75, 0.275, 0.25, 0.75, 0.275, 0.25, 0.75, 0.275, -0.25, 0.75, -0.275, 0.25, 0.75, -0.275, 0.25, 0.75, 0.275, -0.25, 0.75, -0.375, 0.15, 0.75, -0.375, 0.15, 0.75, 0.275, -0.25, 0.75, -0.375, -0.15, 0.75, -0.375, -0.15, 0.75, 0.275, -0.25, 0.75, -0.275, -0.25, 0.75, 0.375, 0.15, -0.75, 0.375, -0.15, -0.75, 0.375, 0.15, 0.75, 0.375, 0.15, 0.75, 0.375, -0.15, -0.75, 0.375, -0.15, 0.75, -0.275, 0.25, -0.75, 0.275, 0.25, -0.75, -0.275, 0.25, 0.75, -0.275, 0.25, 0.75, 0.275, 0.25, -0.75, 0.275, 0.25, 0.75, -0.375, 0.15, 0.75, -0.375, -0.15, 0.75, -0.375, 0.15, -0.75, -0.375, 0.15, -0.75, -0.375, -0.15, 0.75, -0.375, -0.15, -0.75, -0.375, -0.15, -0.75, -0.275, -0.25, -0.75, -0.375, 0.15, -0.75, -0.375, 0.15, -0.75, -0.275, -0.25, -0.75, -0.275, 0.25, -0.75, -0.275, 0.25, -0.75, -0.275, -0.25, -0.75, 0.275, 0.25, -0.75, 0.275, 0.25, -0.75, -0.275, -0.25, -0.75, 0.375, 0.15, -0.75, 0.375, 0.15, -0.75, -0.275, -0.25, -0.75, 0.375, -0.15, -0.75, 0.375, -0.15, -0.75, -0.275, -0.25, -0.75, 0.275, -0.25, -0.75, -0.275, -0.25, 0.75, -0.275, -0.25, -0.75, -0.375, -0.15, 0.75, -0.375, -0.15, 0.75, -0.275, -0.25, -0.75, -0.375, -0.15, -0.75, -0.275, 0.25, -0.75, -0.275, 0.25, 0.75, -0.375, 0.15, -0.75, -0.375, 0.15, -0.75, -0.275, 0.25, 0.75, -0.375, 0.15, 0.75, 0.275, -0.25, -0.75, 0.275, -0.25, 0.75, 0.375, -0.15, -0.75, 0.375, -0.15, -0.75, 0.275, -0.25, 0.75, 0.375, -0.15, 0.75, 0.275, 0.25, 0.75, 0.275, 0.25, -0.75, 0.375, 0.15, 0.75, 0.375, 0.15, 0.75, 0.275, 0.25, -0.75, 0.375, 0.15, -0.75, 0.275, -0.25, -0.75, -0.275, -0.25, -0.75, 0.275, -0.25, 0.75, 0.275, -0.25, 0.75, -0.275, -0.25, -0.75, -0.275, -0.25, 0.75) + +[node name="PhysCrateLong" type="RigidBody3D" groups=["Persistent", "PlasticMaterial"]] +collision_layer = 67 +collision_mask = 73 +mass = 200.0 +script = ExtResource("1_q4djj") + +[node name="CollisionShape3D" type="CollisionShape3D" parent="."] +shape = SubResource("BoxShape3D_p8srg") + +[node name="MeshInstance3D" type="MeshInstance3D" parent="."] +mesh = ExtResource("1_sao54") +surface_material_override/0 = SubResource("StandardMaterial3D_8j27j") + +[node name="StaticBody3D" type="StaticBody3D" parent="MeshInstance3D"] +collision_layer = 4 +collision_mask = 0 + +[node name="CollisionShape3D" type="CollisionShape3D" parent="MeshInstance3D/StaticBody3D"] +shape = SubResource("ConcavePolygonShape3D_p8srg") + +[node name="Gunkable" parent="MeshInstance3D/StaticBody3D" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("6_064yj")] +mask_dim = 128 +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("7_rlyiq") + +[node name="Holdable" type="Node" parent="."] +script = ExtResource("8_p8srg") +hold_distance = 2.0 +metadata/_custom_type_script = "uid://040xta01xqxd" diff --git a/src/props/crate_long/crate_long.tscn b/src/props/crate_long/static_crate_long.tscn similarity index 84% rename from src/props/crate_long/crate_long.tscn rename to src/props/crate_long/static_crate_long.tscn index a319315..56b4e4d 100644 --- a/src/props/crate_long/crate_long.tscn +++ b/src/props/crate_long/static_crate_long.tscn @@ -5,7 +5,7 @@ [ext_resource type="Texture2D" uid="uid://da5p04vbiy3xe" path="res://assets/props/crate_long/crate_long_M.png" id="3_c6a2t"] [ext_resource type="Texture2D" uid="uid://bsovubygl3go2" path="res://assets/props/crate_long/crate_long_N.png" id="4_d06p6"] [ext_resource type="Texture2D" uid="uid://b1m1my5q2vlwi" path="res://assets/props/crate_long/crate_long_R.png" id="5_cmp6v"] -[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="5_d06p6"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="6_agrnx"] [ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="6_c6a2t"] [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_5pe4w"] @@ -21,13 +21,19 @@ texture_filter = 2 [sub_resource type="ConcavePolygonShape3D" id="ConcavePolygonShape3D_d06p6"] data = PackedVector3Array(0.375, -0.15, 0.75, 0.275, -0.25, 0.75, 0.375, 0.15, 0.75, 0.375, 0.15, 0.75, 0.275, -0.25, 0.75, 0.275, 0.25, 0.75, 0.275, 0.25, 0.75, 0.275, -0.25, 0.75, -0.275, 0.25, 0.75, -0.275, 0.25, 0.75, 0.275, -0.25, 0.75, -0.375, 0.15, 0.75, -0.375, 0.15, 0.75, 0.275, -0.25, 0.75, -0.375, -0.15, 0.75, -0.375, -0.15, 0.75, 0.275, -0.25, 0.75, -0.275, -0.25, 0.75, 0.375, 0.15, -0.75, 0.375, -0.15, -0.75, 0.375, 0.15, 0.75, 0.375, 0.15, 0.75, 0.375, -0.15, -0.75, 0.375, -0.15, 0.75, -0.275, 0.25, -0.75, 0.275, 0.25, -0.75, -0.275, 0.25, 0.75, -0.275, 0.25, 0.75, 0.275, 0.25, -0.75, 0.275, 0.25, 0.75, -0.375, 0.15, 0.75, -0.375, -0.15, 0.75, -0.375, 0.15, -0.75, -0.375, 0.15, -0.75, -0.375, -0.15, 0.75, -0.375, -0.15, -0.75, -0.375, -0.15, -0.75, -0.275, -0.25, -0.75, -0.375, 0.15, -0.75, -0.375, 0.15, -0.75, -0.275, -0.25, -0.75, -0.275, 0.25, -0.75, -0.275, 0.25, -0.75, -0.275, -0.25, -0.75, 0.275, 0.25, -0.75, 0.275, 0.25, -0.75, -0.275, -0.25, -0.75, 0.375, 0.15, -0.75, 0.375, 0.15, -0.75, -0.275, -0.25, -0.75, 0.375, -0.15, -0.75, 0.375, -0.15, -0.75, -0.275, -0.25, -0.75, 0.275, -0.25, -0.75, -0.275, -0.25, 0.75, -0.275, -0.25, -0.75, -0.375, -0.15, 0.75, -0.375, -0.15, 0.75, -0.275, -0.25, -0.75, -0.375, -0.15, -0.75, -0.275, 0.25, -0.75, -0.275, 0.25, 0.75, -0.375, 0.15, -0.75, -0.375, 0.15, -0.75, -0.275, 0.25, 0.75, -0.375, 0.15, 0.75, 0.275, -0.25, -0.75, 0.275, -0.25, 0.75, 0.375, -0.15, -0.75, 0.375, -0.15, -0.75, 0.275, -0.25, 0.75, 0.375, -0.15, 0.75, 0.275, 0.25, 0.75, 0.275, 0.25, -0.75, 0.375, 0.15, 0.75, 0.375, 0.15, 0.75, 0.275, 0.25, -0.75, 0.375, 0.15, -0.75, 0.275, -0.25, -0.75, -0.275, -0.25, -0.75, 0.275, -0.25, 0.75, 0.275, -0.25, 0.75, -0.275, -0.25, -0.75, -0.275, -0.25, 0.75) -[node name="CrateLong" type="MeshInstance3D"] +[node name="StaticCrateLong" type="MeshInstance3D"] mesh = ExtResource("1_d06p6") surface_material_override/0 = SubResource("StandardMaterial3D_5pe4w") -[node name="GunkBody" parent="." groups=["PlasticMaterial"] instance=ExtResource("5_d06p6")] -mask_dim = 128 -source_gunk_material = ExtResource("6_c6a2t") +[node name="StaticBody3D" type="StaticBody3D" parent="." groups=["PlasticMaterial"]] +collision_layer = 5 +collision_mask = 0 -[node name="CollisionShape3D" type="CollisionShape3D" parent="GunkBody"] +[node name="CollisionShape3D" type="CollisionShape3D" parent="StaticBody3D"] shape = SubResource("ConcavePolygonShape3D_d06p6") + +[node name="Gunkable" parent="StaticBody3D" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("6_agrnx")] +mask_dim = 128 +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("6_c6a2t") diff --git a/src/props/cupboard/cupboard.tscn b/src/props/cupboard/cupboard.tscn index 1ac4bed..0fbdd90 100644 --- a/src/props/cupboard/cupboard.tscn +++ b/src/props/cupboard/cupboard.tscn @@ -1,11 +1,12 @@ -[gd_scene load_steps=9 format=3 uid="uid://c8pkhw0b47xdd"] +[gd_scene load_steps=10 format=3 uid="uid://c8pkhw0b47xdd"] [ext_resource type="Texture2D" uid="uid://dg4odum5vfc2r" path="res://assets/props/cupboard/cupboard_C.png" id="1_00yk4"] [ext_resource type="ArrayMesh" uid="uid://dgfds7nbhxbbl" path="res://assets/props/cupboard/cupboard.obj" id="1_ssqwt"] [ext_resource type="Texture2D" uid="uid://dkx0128lukxme" path="res://assets/props/cupboard/cupboard_M.png" id="2_w0nd8"] [ext_resource type="Texture2D" uid="uid://c0qid1gqplbly" path="res://assets/props/cupboard/cupboard_N.png" id="3_ssqwt"] [ext_resource type="Texture2D" uid="uid://cdmgbmje8ub3y" path="res://assets/props/cupboard/cupboard_R.png" id="4_q3cl1"] -[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="5_q3cl1"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="7_wyuua"] +[ext_resource type="Material" uid="uid://cqjr3cbxtfg2j" path="res://assets/materials/gunk.material" id="8_rgfsf"] [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_wyuua"] albedo_texture = ExtResource("1_00yk4") @@ -23,7 +24,14 @@ data = PackedVector3Array(-0.5, 0.5, 2, -0.5, -0.5, 2, -0.5, 0.5, -2, -0.5, 0.5, mesh = ExtResource("1_ssqwt") surface_material_override/0 = SubResource("StandardMaterial3D_wyuua") -[node name="GunkBody" parent="." groups=["MetalMaterial"] instance=ExtResource("5_q3cl1")] +[node name="StaticBody3D" type="StaticBody3D" parent="." groups=["MetalMaterial"]] +collision_layer = 5 +collision_mask = 0 -[node name="CollisionShape3D" type="CollisionShape3D" parent="GunkBody"] +[node name="CollisionShape3D" type="CollisionShape3D" parent="StaticBody3D"] shape = SubResource("ConcavePolygonShape3D_tv0mb") + +[node name="Gunkable" parent="StaticBody3D" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("7_wyuua")] +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("8_rgfsf") diff --git a/src/props/eva_suit/empty_enclosure.tscn b/src/props/eva_suit/empty_enclosure.tscn index f65a854..fce8f40 100644 --- a/src/props/eva_suit/empty_enclosure.tscn +++ b/src/props/eva_suit/empty_enclosure.tscn @@ -1,18 +1,26 @@ -[gd_scene load_steps=4 format=3 uid="uid://b56sbxcwhveex"] +[gd_scene load_steps=5 format=3 uid="uid://b56sbxcwhveex"] [ext_resource type="PackedScene" uid="uid://b7ycqk0r7n2t" path="res://assets/props/eva_suit/eva_suit.gltf" id="1_2yqsa"] -[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="2_t7o5w"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="3_7qdo6"] +[ext_resource type="Material" uid="uid://cqjr3cbxtfg2j" path="res://assets/materials/gunk.material" id="4_2yqsa"] [sub_resource type="ConcavePolygonShape3D" id="ConcavePolygonShape3D_kbc8s"] data = PackedVector3Array(0.6, 1.5, 0.45, 0.5196, 1.5, -0.15, 0.6, 1.5, 0.15, -0.6, 1.5, 0.45, 0.5196, 1.5, -0.15, 0.6, 1.5, 0.45, 0.5196, 1.5, -0.15, -0.6, 1.5, 0.45, -0.5196, 1.5, -0.15, -0.5196, 1.5, -0.15, -0.6, 1.5, 0.45, -0.6, 1.5, 0.15, 0.5196, 1.5, -0.15, -0.5196, 1.5, -0.15, 0, 1.5, -0.45, 0, 1.5, -0.45, -0.5196, 1.5, -0.15, -0.3, 1.5, -0.3696, 0.5196, 1.5, -0.15, 0, 1.5, -0.45, 0.3, 1.5, -0.3696, 0, -1.3875, -0.45, -0.3, -1.5, -0.3696, 0, -1.5, -0.45, 0, -1.3875, -0.45, -0.3, -1.3875, -0.3696, -0.3, -1.5, -0.3696, -0.3, -1.3875, -0.3696, -0.5196, -1.5, -0.15, -0.3, -1.5, -0.3696, -0.3, -1.3875, -0.3696, -0.5196, -1.3875, -0.15, -0.5196, -1.5, -0.15, 0.5196, -1.3875, -0.15, 0.3, -1.5, -0.3696, 0.5196, -1.5, -0.15, 0.5196, -1.3875, -0.15, 0.3, -1.3875, -0.3696, 0.3, -1.5, -0.3696, 0.3, -1.3875, -0.3696, 0, -1.5, -0.45, 0.3, -1.5, -0.3696, 0.3, -1.3875, -0.3696, 0, -1.3875, -0.45, 0, -1.5, -0.45, -0.6, -1.5, 0.45, -0.5196, -1.5, -0.15, -0.6, -1.5, 0.15, 0.6, -1.5, 0.45, -0.5196, -1.5, -0.15, -0.6, -1.5, 0.45, -0.5196, -1.5, -0.15, 0.6, -1.5, 0.45, 0.5196, -1.5, -0.15, 0.5196, -1.5, -0.15, 0.6, -1.5, 0.45, 0.6, -1.5, 0.15, -0.5196, -1.5, -0.15, 0.5196, -1.5, -0.15, 0, -1.5, -0.45, 0, -1.5, -0.45, 0.5196, -1.5, -0.15, 0.3, -1.5, -0.3696, -0.5196, -1.5, -0.15, 0, -1.5, -0.45, -0.3, -1.5, -0.3696, 0.3, 0.875, -0.3696, 0, 0.75, -0.45, 0.3, 0.75, -0.3696, 0.3, 0.875, -0.3696, 0, 0.875, -0.45, 0, 0.75, -0.45, 0, 0.875, -0.45, -0.3, 0.75, -0.3696, 0, 0.75, -0.45, 0, 0.875, -0.45, -0.3, 0.875, -0.3696, -0.3, 0.75, -0.3696, -0.4157, 0.75, 0.24, -0.3, 0.75, -0.3696, -0.5196, 0.75, -0.15, 0.4157, 0.75, 0.24, -0.3, 0.75, -0.3696, -0.4157, 0.75, 0.24, -0.3, 0.75, -0.3696, 0.4157, 0.75, 0.24, 0.3, 0.75, -0.3696, 0.3, 0.75, -0.3696, 0.4157, 0.75, 0.24, 0.5196, 0.75, -0.15, -0.3, 0.75, -0.3696, 0.3, 0.75, -0.3696, 0, 0.75, -0.45, 0.6, 1.125, 0.45, -0.6, 1.5, 0.45, 0.6, 1.5, 0.45, 0.6, 1.125, 0.45, -0.6, 1.125, 0.45, -0.6, 1.5, 0.45, 0.6, 0.875, 0.45, -0.6, 1.125, 0.45, 0.6, 1.125, 0.45, 0.6, 0.875, 0.45, -0.6, 0.875, 0.45, -0.6, 1.125, 0.45, 0.6, 0.75, 0.45, -0.6, 0.875, 0.45, 0.6, 0.875, 0.45, 0.6, 0.75, 0.45, -0.6, 0.75, 0.45, -0.6, 0.875, 0.45, 0.6, -1.3875, 0.45, -0.6, 0.75, 0.45, 0.6, 0.75, 0.45, -0.6, 0.75, 0.45, 0.6, -1.3875, 0.45, -0.6, -1.3875, 0.45, -0.6, -1.3875, 0.45, 0.6, -1.3875, 0.45, -0.6, -1.5, 0.45, -0.6, -1.5, 0.45, 0.6, -1.3875, 0.45, 0.6, -1.5, 0.45, 0.6, 0.75, 0.15, 0.6, -1.5, 0.15, 0.6, -1.3875, 0.15, 0.6, 0.75, 0.15, 0.5196, -1.3875, -0.15, 0.6, -1.5, 0.15, 0.6, -1.5, 0.15, 0.5196, -1.3875, -0.15, 0.5196, -1.5, -0.15, 0.6, 0.875, 0.15, 0.5196, -1.3875, -0.15, 0.6, 0.75, 0.15, 0.6, 1.125, 0.15, 0.5196, -1.3875, -0.15, 0.6, 0.875, 0.15, 0.5196, -1.3875, -0.15, 0.6, 1.125, 0.15, 0.6, 1.5, 0.15, 0.5196, -1.3875, -0.15, 0.6, 1.5, 0.15, 0.5196, 1.125, -0.15, 0.5196, 1.125, -0.15, 0.6, 1.5, 0.15, 0.5196, 1.5, -0.15, 0.5196, -1.3875, -0.15, 0.5196, 1.125, -0.15, 0.5196, 0.875, -0.15, 0.5196, -1.3875, -0.15, 0.5196, 0.875, -0.15, 0.5196, 0.75, -0.15, 0.4157, -1.3875, 0.24, 0.3, -1.3875, -0.3696, 0.5196, -1.3875, -0.15, -0.4157, -1.3875, 0.24, 0.3, -1.3875, -0.3696, 0.4157, -1.3875, 0.24, 0.3, -1.3875, -0.3696, -0.4157, -1.3875, 0.24, -0.3, -1.3875, -0.3696, -0.3, -1.3875, -0.3696, -0.4157, -1.3875, 0.24, -0.5196, -1.3875, -0.15, 0.3, -1.3875, -0.3696, -0.3, -1.3875, -0.3696, 0, -1.3875, -0.45, 0.5196, 0.75, -0.15, 0.4157, -1.3875, 0.24, 0.5196, -1.3875, -0.15, 0.5196, 0.75, -0.15, 0.4157, 0.75, 0.24, 0.4157, -1.3875, 0.24, 0.4157, -1.3875, 0.24, -0.4157, 0.75, 0.24, -0.4157, -1.3875, 0.24, 0.4157, -1.3875, 0.24, 0.4157, 0.75, 0.24, -0.4157, 0.75, 0.24, -0.5196, -1.3875, -0.15, -0.4157, 0.75, 0.24, -0.5196, 0.75, -0.15, -0.5196, -1.3875, -0.15, -0.4157, -1.3875, 0.24, -0.4157, 0.75, 0.24, 0, 1.5, -0.45, -0.3, 1.125, -0.3696, 0, 1.125, -0.45, 0, 1.5, -0.45, -0.3, 1.5, -0.3696, -0.3, 1.125, -0.3696, -0.3, 0.875, -0.3696, 0, 0.875, -0.45, 0.3, 0.875, -0.3696, -0.5196, 0.75, -0.15, -0.5196, -1.5, -0.15, -0.5196, -1.3875, -0.15, -0.5196, 0.75, -0.15, -0.6, -1.3875, 0.15, -0.5196, -1.5, -0.15, -0.5196, -1.5, -0.15, -0.6, -1.3875, 0.15, -0.6, -1.5, 0.15, -0.5196, 0.875, -0.15, -0.6, -1.3875, 0.15, -0.5196, 0.75, -0.15, -0.5196, 1.125, -0.15, -0.6, -1.3875, 0.15, -0.5196, 0.875, -0.15, -0.6, -1.3875, 0.15, -0.5196, 1.125, -0.15, -0.5196, 1.5, -0.15, -0.6, -1.3875, 0.15, -0.5196, 1.5, -0.15, -0.6, 1.125, 0.15, -0.6, 1.125, 0.15, -0.5196, 1.5, -0.15, -0.6, 1.5, 0.15, -0.6, -1.3875, 0.15, -0.6, 1.125, 0.15, -0.6, 0.875, 0.15, -0.6, -1.3875, 0.15, -0.6, 0.875, 0.15, -0.6, 0.75, 0.15, -0.6, 1.125, 0.45, -0.6, 1.5, 0.15, -0.6, 1.5, 0.45, -0.6, 1.125, 0.45, -0.6, 1.125, 0.15, -0.6, 1.5, 0.15, -0.6, 0.875, 0.45, -0.6, 1.125, 0.15, -0.6, 1.125, 0.45, -0.6, 1.125, 0.15, -0.6, 0.75, 0.15, -0.6, 0.875, 0.15, -0.6, 1.125, 0.15, -0.6, -1.3875, 0.15, -0.6, 0.75, 0.15, -0.6, 0.875, 0.45, -0.6, -1.3875, 0.15, -0.6, 1.125, 0.15, -0.6, -1.3875, 0.15, -0.6, 0.875, 0.45, -0.6, 0.75, 0.45, -0.6, -1.3875, 0.15, -0.6, 0.75, 0.45, -0.6, -1.3875, 0.45, -0.6, -1.3875, 0.15, -0.6, -1.3875, 0.45, -0.6, -1.5, 0.45, -0.6, -1.3875, 0.15, -0.6, -1.5, 0.45, -0.6, -1.5, 0.15, 0.6, 1.125, 0.15, 0.6, 1.5, 0.45, 0.6, 1.5, 0.15, 0.6, 1.125, 0.15, 0.6, 1.125, 0.45, 0.6, 1.5, 0.45, 0.6, 0.75, 0.15, 0.6, 1.125, 0.45, 0.6, 1.125, 0.15, 0.6, 0.75, 0.15, 0.6, 1.125, 0.15, 0.6, 0.875, 0.15, 0.6, 0.75, 0.15, 0.6, 0.875, 0.45, 0.6, 1.125, 0.45, 0.6, 0.875, 0.45, 0.6, 0.75, 0.15, 0.6, 0.75, 0.45, 0.6, 0.75, 0.45, 0.6, 0.75, 0.15, 0.6, -1.3875, 0.45, 0.6, -1.3875, 0.45, 0.6, 0.75, 0.15, 0.6, -1.5, 0.45, 0.6, -1.5, 0.45, 0.6, 0.75, 0.15, 0.6, -1.3875, 0.15, 0.6, -1.5, 0.45, 0.6, -1.3875, 0.15, 0.6, -1.5, 0.15, -0.3, 0.875, -0.3696, -0.5196, 0.75, -0.15, -0.3, 0.75, -0.3696, -0.3, 0.875, -0.3696, -0.5196, 0.875, -0.15, -0.5196, 0.75, -0.15, -0.3, 1.125, -0.3696, -0.5196, 0.875, -0.15, -0.3, 0.875, -0.3696, -0.5196, 0.875, -0.15, -0.3, 1.125, -0.3696, -0.5196, 1.125, -0.15, -0.5196, 1.125, -0.15, -0.3, 1.125, -0.3696, -0.5196, 1.5, -0.15, -0.5196, 1.5, -0.15, -0.3, 1.125, -0.3696, -0.3, 1.5, -0.3696, 0.3, 1.5, -0.3696, 0, 1.125, -0.45, 0.3, 1.125, -0.3696, 0.3, 1.5, -0.3696, 0, 1.5, -0.45, 0, 1.125, -0.45, 0, 1.125, -0.45, -0.3, 1.125, -0.3696, 0.3, 1.125, -0.3696, -0.3, 1.125, -0.3696, 0.3, 0.875, -0.3696, 0.3, 1.125, -0.3696, -0.3, 1.125, -0.3696, -0.3, 0.875, -0.3696, 0.3, 0.875, -0.3696, 0.5196, 0.875, -0.15, 0.3, 0.75, -0.3696, 0.5196, 0.75, -0.15, 0.5196, 0.875, -0.15, 0.3, 0.875, -0.3696, 0.3, 0.75, -0.3696, 0.5196, 1.125, -0.15, 0.3, 0.875, -0.3696, 0.5196, 0.875, -0.15, 0.3, 0.875, -0.3696, 0.5196, 1.125, -0.15, 0.3, 1.125, -0.3696, 0.3, 1.125, -0.3696, 0.5196, 1.125, -0.15, 0.3, 1.5, -0.3696, 0.3, 1.5, -0.3696, 0.5196, 1.125, -0.15, 0.5196, 1.5, -0.15, 0.2188, -0.25, 0.0074, 0.1618, -0.2, -0.1176, 0.177, -0.25, -0.1211, 0.2188, -0.25, 0.0074, 0.2, -0.2, 0, 0.1618, -0.2, -0.1176, 0.2, -0.2, 0, 0.1456, -0.25, -0.1129, 0.1618, -0.2, -0.1176, 0.2, -0.2, 0, 0.18, -0.25, -0.0071, 0.1456, -0.25, -0.1129, 0.18, -0.25, -0.0071, 0.1618, -0.3, -0.1176, 0.1456, -0.25, -0.1129, 0.18, -0.25, -0.0071, 0.2, -0.3, 0, 0.1618, -0.3, -0.1176, 0.2, -0.3, 0, 0.177, -0.25, -0.1211, 0.1618, -0.3, -0.1176, 0.2, -0.3, 0, 0.2188, -0.25, 0.0074, 0.177, -0.25, -0.1211, -0.177, -0.25, -0.1211, -0.1456, -0.25, -0.1129, -0.1618, -0.2, -0.1176, -0.177, -0.25, -0.1211, -0.1618, -0.3, -0.1176, -0.1456, -0.25, -0.1129, 0.177, -0.25, -0.1211, 0.1456, -0.25, -0.1129, 0.1618, -0.3, -0.1176, 0.177, -0.25, -0.1211, 0.1618, -0.2, -0.1176, 0.1456, -0.25, -0.1129, -0.177, -0.25, -0.1211, -0.2, -0.2, 0, -0.2188, -0.25, 0.0074, -0.177, -0.25, -0.1211, -0.1618, -0.2, -0.1176, -0.2, -0.2, 0, -0.1618, -0.2, -0.1176, -0.18, -0.25, -0.0071, -0.2, -0.2, 0, -0.1618, -0.2, -0.1176, -0.1456, -0.25, -0.1129, -0.18, -0.25, -0.0071, -0.1456, -0.25, -0.1129, -0.2, -0.3, 0, -0.18, -0.25, -0.0071, -0.1456, -0.25, -0.1129, -0.1618, -0.3, -0.1176, -0.2, -0.3, 0, -0.1618, -0.3, -0.1176, -0.2188, -0.25, 0.0074, -0.2, -0.3, 0, -0.1618, -0.3, -0.1176, -0.177, -0.25, -0.1211, -0.2188, -0.25, 0.0074, -0.2188, -0.25, 0.0074, -0.1618, -0.2, 0.1176, -0.177, -0.25, 0.136, -0.2188, -0.25, 0.0074, -0.2, -0.2, 0, -0.1618, -0.2, 0.1176, -0.2, -0.2, 0, -0.1456, -0.25, 0.0987, -0.1618, -0.2, 0.1176, -0.2, -0.2, 0, -0.18, -0.25, -0.0071, -0.1456, -0.25, 0.0987, -0.18, -0.25, -0.0071, -0.1618, -0.3, 0.1176, -0.1456, -0.25, 0.0987, -0.18, -0.25, -0.0071, -0.2, -0.3, 0, -0.1618, -0.3, 0.1176, -0.2, -0.3, 0, -0.177, -0.25, 0.136, -0.1618, -0.3, 0.1176, -0.2, -0.3, 0, -0.2188, -0.25, 0.0074, -0.177, -0.25, 0.136, -0.177, -0.25, 0.136, -0.0618, -0.2, 0.1902, -0.0676, -0.25, 0.2155, -0.177, -0.25, 0.136, -0.1618, -0.2, 0.1176, -0.0618, -0.2, 0.1902, -0.1618, -0.2, 0.1176, -0.0556, -0.25, 0.1641, -0.0618, -0.2, 0.1902, -0.1618, -0.2, 0.1176, -0.1456, -0.25, 0.0987, -0.0556, -0.25, 0.1641, -0.1456, -0.25, 0.0987, -0.0618, -0.3, 0.1902, -0.0556, -0.25, 0.1641, -0.1456, -0.25, 0.0987, -0.1618, -0.3, 0.1176, -0.0618, -0.3, 0.1902, -0.1618, -0.3, 0.1176, -0.0676, -0.25, 0.2155, -0.0618, -0.3, 0.1902, -0.1618, -0.3, 0.1176, -0.177, -0.25, 0.136, -0.0676, -0.25, 0.2155, 0.0676, -0.25, 0.2155, 0.0618, -0.15, 0.2916, 0.0618, -0.2, 0.1902, 0.0676, -0.25, 0.2155, 0.0676, -0.2, 0.3168, 0.0618, -0.15, 0.2916, -0.0618, -0.2, 0.1902, 0.0556, -0.25, 0.1641, 0.0618, -0.2, 0.1902, -0.0618, -0.2, 0.1902, -0.0556, -0.25, 0.1641, 0.0556, -0.25, 0.1641, -0.0556, -0.25, 0.1641, 0.0618, -0.3, 0.1902, 0.0556, -0.25, 0.1641, -0.0556, -0.25, 0.1641, -0.0618, -0.3, 0.1902, 0.0618, -0.3, 0.1902, 0.0618, -0.3, 0.1902, 0.0676, -0.2, 0.3168, 0.0676, -0.25, 0.2155, 0.0618, -0.3, 0.1902, 0.0618, -0.25, 0.2916, 0.0676, -0.2, 0.3168, 0.0676, -0.25, 0.2155, 0.1618, -0.2, 0.1176, 0.177, -0.25, 0.136, 0.0676, -0.25, 0.2155, 0.0618, -0.2, 0.1902, 0.1618, -0.2, 0.1176, 0.0618, -0.2, 0.1902, 0.1456, -0.25, 0.0987, 0.1618, -0.2, 0.1176, 0.0618, -0.2, 0.1902, 0.0556, -0.25, 0.1641, 0.1456, -0.25, 0.0987, 0.0556, -0.25, 0.1641, 0.1618, -0.3, 0.1176, 0.1456, -0.25, 0.0987, 0.0556, -0.25, 0.1641, 0.0618, -0.3, 0.1902, 0.1618, -0.3, 0.1176, 0.0618, -0.3, 0.1902, 0.177, -0.25, 0.136, 0.1618, -0.3, 0.1176, 0.0618, -0.3, 0.1902, 0.0676, -0.25, 0.2155, 0.177, -0.25, 0.136, 0.177, -0.25, 0.136, 0.2, -0.2, 0, 0.2188, -0.25, 0.0074, 0.177, -0.25, 0.136, 0.1618, -0.2, 0.1176, 0.2, -0.2, 0, 0.1618, -0.2, 0.1176, 0.18, -0.25, -0.0071, 0.2, -0.2, 0, 0.1618, -0.2, 0.1176, 0.1456, -0.25, 0.0987, 0.18, -0.25, -0.0071, 0.1456, -0.25, 0.0987, 0.2, -0.3, 0, 0.18, -0.25, -0.0071, 0.1456, -0.25, 0.0987, 0.1618, -0.3, 0.1176, 0.2, -0.3, 0, 0.1618, -0.3, 0.1176, 0.2188, -0.25, 0.0074, 0.2, -0.3, 0, 0.1618, -0.3, 0.1176, 0.177, -0.25, 0.136, 0.2188, -0.25, 0.0074, -0.0676, -0.2, 0.3168, 0.0618, -0.15, 0.2916, 0.0676, -0.2, 0.3168, -0.0676, -0.2, 0.3168, -0.0618, -0.15, 0.2916, 0.0618, -0.15, 0.2916, -0.0618, -0.25, 0.2916, 0.0676, -0.2, 0.3168, 0.0618, -0.25, 0.2916, -0.0618, -0.25, 0.2916, -0.0676, -0.2, 0.3168, 0.0676, -0.2, 0.3168, -0.0676, -0.25, 0.2155, -0.0618, -0.25, 0.2916, -0.0618, -0.3, 0.1902, -0.0676, -0.25, 0.2155, -0.0676, -0.2, 0.3168, -0.0618, -0.25, 0.2916, -0.0618, -0.3, 0.1902, 0.0618, -0.25, 0.2916, 0.0618, -0.3, 0.1902, -0.0618, -0.3, 0.1902, -0.0618, -0.25, 0.2916, 0.0618, -0.25, 0.2916, -0.0618, -0.2, 0.1902, -0.0676, -0.2, 0.3168, -0.0676, -0.25, 0.2155, -0.0618, -0.2, 0.1902, -0.0618, -0.15, 0.2916, -0.0676, -0.2, 0.3168, 0.0618, -0.2, 0.1902, -0.0618, -0.15, 0.2916, -0.0618, -0.2, 0.1902, 0.0618, -0.2, 0.1902, 0.0618, -0.15, 0.2916, -0.0618, -0.15, 0.2916) [node name="EVASuit" instance=ExtResource("1_2yqsa")] -[node name="GunkBody" parent="Enclosure" index="0" groups=["MetalMaterial"] instance=ExtResource("2_t7o5w")] -mask_dim = 128 +[node name="StaticBody3D" type="StaticBody3D" parent="Enclosure" index="0" groups=["MetalMaterial"]] +collision_layer = 5 +collision_mask = 0 -[node name="CollisionShape3D" type="CollisionShape3D" parent="Enclosure/GunkBody" index="2"] +[node name="CollisionShape3D" type="CollisionShape3D" parent="Enclosure/StaticBody3D" index="0"] shape = SubResource("ConcavePolygonShape3D_kbc8s") +[node name="Gunkable" parent="Enclosure/StaticBody3D" index="1" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("3_7qdo6")] +mask_dim = 128 +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("4_2yqsa") + [node name="Suit" parent="." index="1"] visible = false diff --git a/src/props/eva_suit/eva_suit.tscn b/src/props/eva_suit/eva_suit.tscn index cb0b206..0082e24 100644 --- a/src/props/eva_suit/eva_suit.tscn +++ b/src/props/eva_suit/eva_suit.tscn @@ -1,8 +1,9 @@ -[gd_scene load_steps=8 format=3 uid="uid://dl6vekf0joac4"] +[gd_scene load_steps=9 format=3 uid="uid://dl6vekf0joac4"] [ext_resource type="PackedScene" uid="uid://b7ycqk0r7n2t" path="res://assets/props/eva_suit/eva_suit.gltf" id="1_ilt3k"] -[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="2_kbc8s"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="3_5ci27"] [ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="3_tba5c"] +[ext_resource type="Material" uid="uid://cqjr3cbxtfg2j" path="res://assets/materials/gunk.material" id="4_ghtie"] [sub_resource type="ConcavePolygonShape3D" id="ConcavePolygonShape3D_5ci27"] data = PackedVector3Array(0, -1.3875, -0.45, -0.3, -1.5, -0.3696, 0, -1.5, -0.45, 0, -1.3875, -0.45, -0.3, -1.3875, -0.3696, -0.3, -1.5, -0.3696, -0.3, -1.3875, -0.3696, -0.5196, -1.5, -0.15, -0.3, -1.5, -0.3696, -0.3, -1.3875, -0.3696, -0.5196, -1.3875, -0.15, -0.5196, -1.5, -0.15, 0.5196, -1.3875, -0.15, 0.3, -1.5, -0.3696, 0.5196, -1.5, -0.15, 0.5196, -1.3875, -0.15, 0.3, -1.3875, -0.3696, 0.3, -1.5, -0.3696, 0.3, -1.3875, -0.3696, 0, -1.5, -0.45, 0.3, -1.5, -0.3696, 0.3, -1.3875, -0.3696, 0, -1.3875, -0.45, 0, -1.5, -0.45, 0.3, 0.875, -0.3696, 0, 0.75, -0.45, 0.3, 0.75, -0.3696, 0.3, 0.875, -0.3696, 0, 0.875, -0.45, 0, 0.75, -0.45, 0, 0.875, -0.45, -0.3, 0.75, -0.3696, 0, 0.75, -0.45, 0, 0.875, -0.45, -0.3, 0.875, -0.3696, -0.3, 0.75, -0.3696, -0.4157, 0.75, 0.24, -0.3, 0.75, -0.3696, -0.5196, 0.75, -0.15, 0.4157, 0.75, 0.24, -0.3, 0.75, -0.3696, -0.4157, 0.75, 0.24, -0.3, 0.75, -0.3696, 0.4157, 0.75, 0.24, 0.3, 0.75, -0.3696, 0.3, 0.75, -0.3696, 0.4157, 0.75, 0.24, 0.5196, 0.75, -0.15, -0.3, 0.75, -0.3696, 0.3, 0.75, -0.3696, 0, 0.75, -0.45, 0.6, 1.5, 0.15, 0.5196, -1.5, -0.15, 0.6, -1.5, 0.15, 0.6, 1.5, 0.15, 0.5196, -1.3875, -0.15, 0.5196, -1.5, -0.15, 0.5196, -1.3875, -0.15, 0.6, 1.5, 0.15, 0.5196, 1.5, -0.15, 0.5196, -1.3875, -0.15, 0.5196, 1.5, -0.15, 0.5196, 0.75, -0.15, 0.4157, -1.3875, 0.24, 0.3, -1.3875, -0.3696, 0.5196, -1.3875, -0.15, -0.4157, -1.3875, 0.24, 0.3, -1.3875, -0.3696, 0.4157, -1.3875, 0.24, 0.3, -1.3875, -0.3696, -0.4157, -1.3875, 0.24, -0.3, -1.3875, -0.3696, -0.3, -1.3875, -0.3696, -0.4157, -1.3875, 0.24, -0.5196, -1.3875, -0.15, 0.3, -1.3875, -0.3696, -0.3, -1.3875, -0.3696, 0, -1.3875, -0.45, 0.5196, 0.75, -0.15, 0.4157, -1.3875, 0.24, 0.5196, -1.3875, -0.15, 0.5196, 0.75, -0.15, 0.4157, 0.75, 0.24, 0.4157, -1.3875, 0.24, 0.4157, -1.3875, 0.24, -0.4157, 0.75, 0.24, -0.4157, -1.3875, 0.24, 0.4157, -1.3875, 0.24, 0.4157, 0.75, 0.24, -0.4157, 0.75, 0.24, -0.5196, -1.3875, -0.15, -0.4157, 0.75, 0.24, -0.5196, 0.75, -0.15, -0.5196, -1.3875, -0.15, -0.4157, -1.3875, 0.24, -0.4157, 0.75, 0.24, 0, 1.5, -0.45, -0.3, 1.125, -0.3696, 0, 1.125, -0.45, 0, 1.5, -0.45, -0.3, 1.5, -0.3696, -0.3, 1.125, -0.3696, -0.3, 0.875, -0.3696, 0, 0.875, -0.45, 0.3, 0.875, -0.3696, -0.5196, 0.75, -0.15, -0.5196, -1.5, -0.15, -0.5196, -1.3875, -0.15, -0.5196, -1.5, -0.15, -0.5196, 0.75, -0.15, -0.6, 1.5, 0.15, -0.6, 1.5, 0.15, -0.5196, 0.75, -0.15, -0.5196, 1.5, -0.15, -0.5196, -1.5, -0.15, -0.6, 1.5, 0.15, -0.6, -1.5, 0.15, -0.6, 1.5, 0.45, -0.6, -1.5, 0.15, -0.6, 1.5, 0.15, -0.6, 1.5, 0.45, -0.6, -1.5, 0.45, -0.6, -1.5, 0.15, 0.6, 1.5, 0.15, 0.6, -1.5, 0.45, 0.6, 1.5, 0.45, 0.6, 1.5, 0.15, 0.6, -1.5, 0.15, 0.6, -1.5, 0.45, -0.3, 0.875, -0.3696, -0.5196, 0.75, -0.15, -0.3, 0.75, -0.3696, -0.3, 1.125, -0.3696, -0.5196, 0.75, -0.15, -0.3, 0.875, -0.3696, -0.5196, 0.75, -0.15, -0.3, 1.125, -0.3696, -0.3, 1.5, -0.3696, -0.5196, 0.75, -0.15, -0.3, 1.5, -0.3696, -0.5196, 1.5, -0.15, 0.3, 1.5, -0.3696, 0, 1.125, -0.45, 0.3, 1.125, -0.3696, 0.3, 1.5, -0.3696, 0, 1.5, -0.45, 0, 1.125, -0.45, 0, 1.125, -0.45, -0.3, 1.125, -0.3696, 0.3, 1.125, -0.3696, -0.3, 1.125, -0.3696, 0.3, 0.875, -0.3696, 0.3, 1.125, -0.3696, -0.3, 1.125, -0.3696, -0.3, 0.875, -0.3696, 0.3, 0.875, -0.3696, 0.5196, 1.5, -0.15, 0.3, 0.75, -0.3696, 0.5196, 0.75, -0.15, 0.5196, 1.5, -0.15, 0.3, 0.875, -0.3696, 0.3, 0.75, -0.3696, 0.3, 0.875, -0.3696, 0.5196, 1.5, -0.15, 0.3, 1.125, -0.3696, 0.3, 1.125, -0.3696, 0.5196, 1.5, -0.15, 0.3, 1.5, -0.3696, 0.2188, -0.25, 0.0074, 0.1618, -0.2, -0.1176, 0.177, -0.25, -0.1211, 0.2188, -0.25, 0.0074, 0.2, -0.2, 0, 0.1618, -0.2, -0.1176, 0.2, -0.2, 0, 0.1456, -0.25, -0.1129, 0.1618, -0.2, -0.1176, 0.2, -0.2, 0, 0.18, -0.25, -0.0071, 0.1456, -0.25, -0.1129, 0.18, -0.25, -0.0071, 0.1618, -0.3, -0.1176, 0.1456, -0.25, -0.1129, 0.18, -0.25, -0.0071, 0.2, -0.3, 0, 0.1618, -0.3, -0.1176, 0.2, -0.3, 0, 0.177, -0.25, -0.1211, 0.1618, -0.3, -0.1176, 0.2, -0.3, 0, 0.2188, -0.25, 0.0074, 0.177, -0.25, -0.1211, -0.177, -0.25, -0.1211, -0.1456, -0.25, -0.1129, -0.1618, -0.2, -0.1176, -0.177, -0.25, -0.1211, -0.1618, -0.3, -0.1176, -0.1456, -0.25, -0.1129, 0.177, -0.25, -0.1211, 0.1456, -0.25, -0.1129, 0.1618, -0.3, -0.1176, 0.177, -0.25, -0.1211, 0.1618, -0.2, -0.1176, 0.1456, -0.25, -0.1129, -0.177, -0.25, -0.1211, -0.2, -0.2, 0, -0.2188, -0.25, 0.0074, -0.177, -0.25, -0.1211, -0.1618, -0.2, -0.1176, -0.2, -0.2, 0, -0.1618, -0.2, -0.1176, -0.18, -0.25, -0.0071, -0.2, -0.2, 0, -0.1618, -0.2, -0.1176, -0.1456, -0.25, -0.1129, -0.18, -0.25, -0.0071, -0.1456, -0.25, -0.1129, -0.2, -0.3, 0, -0.18, -0.25, -0.0071, -0.1456, -0.25, -0.1129, -0.1618, -0.3, -0.1176, -0.2, -0.3, 0, -0.1618, -0.3, -0.1176, -0.2188, -0.25, 0.0074, -0.2, -0.3, 0, -0.1618, -0.3, -0.1176, -0.177, -0.25, -0.1211, -0.2188, -0.25, 0.0074, -0.2188, -0.25, 0.0074, -0.1618, -0.2, 0.1176, -0.177, -0.25, 0.136, -0.2188, -0.25, 0.0074, -0.2, -0.2, 0, -0.1618, -0.2, 0.1176, -0.2, -0.2, 0, -0.1456, -0.25, 0.0987, -0.1618, -0.2, 0.1176, -0.2, -0.2, 0, -0.18, -0.25, -0.0071, -0.1456, -0.25, 0.0987, -0.18, -0.25, -0.0071, -0.1618, -0.3, 0.1176, -0.1456, -0.25, 0.0987, -0.18, -0.25, -0.0071, -0.2, -0.3, 0, -0.1618, -0.3, 0.1176, -0.2, -0.3, 0, -0.177, -0.25, 0.136, -0.1618, -0.3, 0.1176, -0.2, -0.3, 0, -0.2188, -0.25, 0.0074, -0.177, -0.25, 0.136, -0.177, -0.25, 0.136, -0.0618, -0.2, 0.1902, -0.0676, -0.25, 0.2155, -0.177, -0.25, 0.136, -0.1618, -0.2, 0.1176, -0.0618, -0.2, 0.1902, -0.1618, -0.2, 0.1176, -0.0556, -0.25, 0.1641, -0.0618, -0.2, 0.1902, -0.1618, -0.2, 0.1176, -0.1456, -0.25, 0.0987, -0.0556, -0.25, 0.1641, -0.1456, -0.25, 0.0987, -0.0618, -0.3, 0.1902, -0.0556, -0.25, 0.1641, -0.1456, -0.25, 0.0987, -0.1618, -0.3, 0.1176, -0.0618, -0.3, 0.1902, -0.1618, -0.3, 0.1176, -0.0676, -0.25, 0.2155, -0.0618, -0.3, 0.1902, -0.1618, -0.3, 0.1176, -0.177, -0.25, 0.136, -0.0676, -0.25, 0.2155, 0.0676, -0.25, 0.2155, 0.0618, -0.18, 0.2416, 0.0618, -0.2, 0.1902, 0.0676, -0.25, 0.2155, 0.0676, -0.23, 0.2668, 0.0618, -0.18, 0.2416, -0.0618, -0.2, 0.1902, 0.0556, -0.25, 0.1641, 0.0618, -0.2, 0.1902, -0.0618, -0.2, 0.1902, -0.0556, -0.25, 0.1641, 0.0556, -0.25, 0.1641, -0.0556, -0.25, 0.1641, 0.0618, -0.3, 0.1902, 0.0556, -0.25, 0.1641, -0.0556, -0.25, 0.1641, -0.0618, -0.3, 0.1902, 0.0618, -0.3, 0.1902, 0.0618, -0.3, 0.1902, 0.0676, -0.23, 0.2668, 0.0676, -0.25, 0.2155, 0.0618, -0.3, 0.1902, 0.0618, -0.28, 0.2416, 0.0676, -0.23, 0.2668, 0.0676, -0.25, 0.2155, 0.1618, -0.2, 0.1176, 0.177, -0.25, 0.136, 0.0676, -0.25, 0.2155, 0.0618, -0.2, 0.1902, 0.1618, -0.2, 0.1176, 0.0618, -0.2, 0.1902, 0.1456, -0.25, 0.0987, 0.1618, -0.2, 0.1176, 0.0618, -0.2, 0.1902, 0.0556, -0.25, 0.1641, 0.1456, -0.25, 0.0987, 0.0556, -0.25, 0.1641, 0.1618, -0.3, 0.1176, 0.1456, -0.25, 0.0987, 0.0556, -0.25, 0.1641, 0.0618, -0.3, 0.1902, 0.1618, -0.3, 0.1176, 0.0618, -0.3, 0.1902, 0.177, -0.25, 0.136, 0.1618, -0.3, 0.1176, 0.0618, -0.3, 0.1902, 0.0676, -0.25, 0.2155, 0.177, -0.25, 0.136, 0.177, -0.25, 0.136, 0.2, -0.2, 0, 0.2188, -0.25, 0.0074, 0.177, -0.25, 0.136, 0.1618, -0.2, 0.1176, 0.2, -0.2, 0, 0.1618, -0.2, 0.1176, 0.18, -0.25, -0.0071, 0.2, -0.2, 0, 0.1618, -0.2, 0.1176, 0.1456, -0.25, 0.0987, 0.18, -0.25, -0.0071, 0.1456, -0.25, 0.0987, 0.2, -0.3, 0, 0.18, -0.25, -0.0071, 0.1456, -0.25, 0.0987, 0.1618, -0.3, 0.1176, 0.2, -0.3, 0, 0.1618, -0.3, 0.1176, 0.2188, -0.25, 0.0074, 0.2, -0.3, 0, 0.1618, -0.3, 0.1176, 0.177, -0.25, 0.136, 0.2188, -0.25, 0.0074, -0.0676, -0.25, 0.2155, -0.0618, -0.28, 0.2416, -0.0618, -0.3, 0.1902, -0.0676, -0.25, 0.2155, -0.0676, -0.23, 0.2668, -0.0618, -0.28, 0.2416, -0.0618, -0.3, 0.1902, 0.0618, -0.28, 0.2416, 0.0618, -0.3, 0.1902, -0.0618, -0.3, 0.1902, -0.0618, -0.28, 0.2416, 0.0618, -0.28, 0.2416, -0.0618, -0.2, 0.1902, -0.0676, -0.23, 0.2668, -0.0676, -0.25, 0.2155, -0.0618, -0.2, 0.1902, -0.0618, -0.18, 0.2416, -0.0676, -0.23, 0.2668, 0.0618, -0.2, 0.1902, -0.0618, -0.18, 0.2416, -0.0618, -0.2, 0.1902, 0.0618, -0.2, 0.1902, 0.0618, -0.18, 0.2416, -0.0618, -0.18, 0.2416) @@ -18,29 +19,54 @@ data = PackedVector3Array(0.2683, 0.1393, 0.0996, 0.3136, 0.0844, -0.0003, 0.284 [node name="EVASuit" instance=ExtResource("1_ilt3k")] -[node name="GunkBody" parent="Enclosure" index="0" groups=["MetalMaterial"] instance=ExtResource("2_kbc8s")] -mask_dim = 128 +[node name="StaticBody3D" type="StaticBody3D" parent="Enclosure" index="0" groups=["MetalMaterial"]] +collision_layer = 5 +collision_mask = 0 -[node name="CollisionShape3D" type="CollisionShape3D" parent="Enclosure/GunkBody" index="2"] +[node name="CollisionShape3D" type="CollisionShape3D" parent="Enclosure/StaticBody3D" index="0"] shape = SubResource("ConcavePolygonShape3D_5ci27") -[node name="GunkBody" parent="Suit/SuitGreebling/AirHose" index="0" instance=ExtResource("2_kbc8s")] -mask_dim = 32 -source_gunk_material = ExtResource("3_tba5c") +[node name="Gunkable" parent="Enclosure/StaticBody3D" index="1" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("3_5ci27")] +mask_dim = 128 +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("4_ghtie") -[node name="CollisionShape3D" type="CollisionShape3D" parent="Suit/SuitGreebling/AirHose/GunkBody" index="2"] +[node name="StaticBody3D" type="StaticBody3D" parent="Suit/SuitGreebling/AirHose" index="0"] +collision_layer = 5 +collision_mask = 0 + +[node name="CollisionShape3D" type="CollisionShape3D" parent="Suit/SuitGreebling/AirHose/StaticBody3D" index="0"] shape = SubResource("ConcavePolygonShape3D_ghtie") -[node name="GunkBody" parent="Suit/SuitGreebling" index="1" instance=ExtResource("2_kbc8s")] -mask_dim = 16 +[node name="Gunkable" parent="Suit/SuitGreebling/AirHose/StaticBody3D" index="1" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("3_5ci27")] +mask_dim = 32 +body = NodePath("..") +mesh_instance = NodePath("../..") source_gunk_material = ExtResource("3_tba5c") -[node name="CollisionShape3D" type="CollisionShape3D" parent="Suit/SuitGreebling/GunkBody" index="2"] +[node name="StaticBody3D" type="StaticBody3D" parent="Suit/SuitGreebling" index="1"] +collision_layer = 5 +collision_mask = 0 + +[node name="CollisionShape3D" type="CollisionShape3D" parent="Suit/SuitGreebling/StaticBody3D" index="0"] shape = SubResource("ConcavePolygonShape3D_dtepx") -[node name="GunkBody" parent="Suit" index="1" instance=ExtResource("2_kbc8s")] -mask_dim = 128 +[node name="Gunkable" parent="Suit/SuitGreebling/StaticBody3D" index="1" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("3_5ci27")] +mask_dim = 16 +body = NodePath("..") +mesh_instance = NodePath("../..") source_gunk_material = ExtResource("3_tba5c") -[node name="CollisionShape3D" type="CollisionShape3D" parent="Suit/GunkBody" index="2"] +[node name="StaticBody3D" type="StaticBody3D" parent="Suit" index="1"] +collision_layer = 5 +collision_mask = 0 + +[node name="CollisionShape3D" type="CollisionShape3D" parent="Suit/StaticBody3D" index="0"] shape = SubResource("ConcavePolygonShape3D_47wxn") + +[node name="Gunkable" parent="Suit/StaticBody3D" index="1" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("3_5ci27")] +mask_dim = 128 +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("3_tba5c") diff --git a/src/props/med_cart/phys_med_cart.tscn b/src/props/med_cart/phys_med_cart.tscn new file mode 100644 index 0000000..1d46331 --- /dev/null +++ b/src/props/med_cart/phys_med_cart.tscn @@ -0,0 +1,60 @@ +[gd_scene load_steps=13 format=3 uid="uid://cv6sxj04rrkt2"] + +[ext_resource type="Script" uid="uid://sksndhqyo2bn" path="res://src/props/physics/persistent_prop.gd" id="1_3jm8i"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="1_fu1y0"] +[ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="2_8v7ae"] +[ext_resource type="ArrayMesh" uid="uid://b3p2eh3b8jg4r" path="res://assets/props/med_cart/med_cart.obj" id="3_3jm8i"] +[ext_resource type="Texture2D" uid="uid://biqh5uq67dl55" path="res://assets/props/med_cart/med_cart_C.png" id="4_r1b3g"] +[ext_resource type="Texture2D" uid="uid://bds4qx6kqhplb" path="res://assets/props/med_cart/med_cart_M.png" id="5_u14ky"] +[ext_resource type="Texture2D" uid="uid://v4j34fh4vm06" path="res://assets/props/med_cart/med_cart_N.png" id="6_251s5"] +[ext_resource type="Texture2D" uid="uid://bcnsofhrfxyjk" path="res://assets/props/med_cart/med_cart_R.png" id="7_2wjh0"] +[ext_resource type="Script" uid="uid://040xta01xqxd" path="res://src/props/physics/holdable.gd" id="8_8v7ae"] + +[sub_resource type="BoxShape3D" id="BoxShape3D_fu1y0"] +size = Vector3(0.7, 1, 1.2) + +[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_xx4to"] +transparency = 2 +alpha_scissor_threshold = 0.5 +alpha_antialiasing_mode = 0 +albedo_texture = ExtResource("4_r1b3g") +metallic = 1.0 +metallic_texture = ExtResource("5_u14ky") +roughness_texture = ExtResource("7_2wjh0") +normal_enabled = true +normal_texture = ExtResource("6_251s5") +texture_filter = 2 + +[sub_resource type="ConcavePolygonShape3D" id="ConcavePolygonShape3D_rhern"] +data = PackedVector3Array(-0.3, -0.46, 0.52, -0.34, -0.46, 0.52, -0.3, -0.4883, 0.5317, -0.3, -0.4883, 0.5317, -0.34, -0.46, 0.52, -0.34, -0.4883, 0.5317, -0.3, -0.4883, 0.5317, -0.34, -0.4883, 0.5317, -0.3, -0.5, 0.56, -0.3, -0.5, 0.56, -0.34, -0.4883, 0.5317, -0.34, -0.5, 0.56, -0.3, -0.5, 0.56, -0.34, -0.5, 0.56, -0.3, -0.4883, 0.5883, -0.3, -0.4883, 0.5883, -0.34, -0.5, 0.56, -0.34, -0.4883, 0.5883, -0.3, -0.4883, 0.5883, -0.34, -0.4883, 0.5883, -0.3, -0.46, 0.6, -0.3, -0.46, 0.6, -0.34, -0.4883, 0.5883, -0.34, -0.46, 0.6, -0.3, -0.46, 0.6, -0.34, -0.46, 0.6, -0.3, -0.4317, 0.5883, -0.3, -0.4317, 0.5883, -0.34, -0.46, 0.6, -0.34, -0.4317, 0.5883, -0.3, -0.4317, 0.5883, -0.34, -0.4317, 0.5883, -0.3, -0.42, 0.56, -0.3, -0.42, 0.56, -0.34, -0.4317, 0.5883, -0.34, -0.42, 0.56, -0.3, -0.46, 0.52, -0.3, -0.4883, 0.5317, -0.3, -0.4317, 0.5317, -0.3, -0.4317, 0.5317, -0.3, -0.4883, 0.5317, -0.3, -0.42, 0.56, -0.3, -0.42, 0.56, -0.3, -0.4883, 0.5317, -0.3, -0.4317, 0.5883, -0.3, -0.4317, 0.5883, -0.3, -0.4883, 0.5317, -0.3, -0.46, 0.6, -0.3, -0.46, 0.6, -0.3, -0.4883, 0.5317, -0.3, -0.4883, 0.5883, -0.3, -0.4883, 0.5883, -0.3, -0.4883, 0.5317, -0.3, -0.5, 0.56, -0.3, -0.42, 0.56, -0.34, -0.42, 0.56, -0.3, -0.4317, 0.5317, -0.3, -0.4317, 0.5317, -0.34, -0.42, 0.56, -0.34, -0.4317, 0.5317, -0.3, -0.4317, 0.5317, -0.34, -0.4317, 0.5317, -0.3, -0.46, 0.52, -0.3, -0.46, 0.52, -0.34, -0.4317, 0.5317, -0.34, -0.46, 0.52, -0.34, -0.4883, 0.5317, -0.34, -0.46, 0.52, -0.34, -0.5, 0.56, -0.34, -0.5, 0.56, -0.34, -0.46, 0.52, -0.34, -0.4883, 0.5883, -0.34, -0.4883, 0.5883, -0.34, -0.46, 0.52, -0.34, -0.46, 0.6, -0.34, -0.46, 0.6, -0.34, -0.46, 0.52, -0.34, -0.4317, 0.5883, -0.34, -0.4317, 0.5883, -0.34, -0.46, 0.52, -0.34, -0.42, 0.56, -0.34, -0.42, 0.56, -0.34, -0.46, 0.52, -0.34, -0.4317, 0.5317, -0.3, -0.46, -0.6, -0.34, -0.46, -0.6, -0.3, -0.4883, -0.5883, -0.3, -0.4883, -0.5883, -0.34, -0.46, -0.6, -0.34, -0.4883, -0.5883, -0.3, -0.4883, -0.5883, -0.34, -0.4883, -0.5883, -0.3, -0.5, -0.56, -0.3, -0.5, -0.56, -0.34, -0.4883, -0.5883, -0.34, -0.5, -0.56, -0.3, -0.5, -0.56, -0.34, -0.5, -0.56, -0.3, -0.4883, -0.5317, -0.3, -0.4883, -0.5317, -0.34, -0.5, -0.56, -0.34, -0.4883, -0.5317, -0.3, -0.4883, -0.5317, -0.34, -0.4883, -0.5317, -0.3, -0.46, -0.52, -0.3, -0.46, -0.52, -0.34, -0.4883, -0.5317, -0.34, -0.46, -0.52, -0.3, -0.46, -0.52, -0.34, -0.46, -0.52, -0.3, -0.4317, -0.5317, -0.3, -0.4317, -0.5317, -0.34, -0.46, -0.52, -0.34, -0.4317, -0.5317, -0.3, -0.4317, -0.5317, -0.34, -0.4317, -0.5317, -0.3, -0.42, -0.56, -0.3, -0.42, -0.56, -0.34, -0.4317, -0.5317, -0.34, -0.42, -0.56, -0.3, -0.46, -0.6, -0.3, -0.4883, -0.5883, -0.3, -0.4317, -0.5883, -0.3, -0.4317, -0.5883, -0.3, -0.4883, -0.5883, -0.3, -0.42, -0.56, -0.3, -0.42, -0.56, -0.3, -0.4883, -0.5883, -0.3, -0.4317, -0.5317, -0.3, -0.4317, -0.5317, -0.3, -0.4883, -0.5883, -0.3, -0.46, -0.52, -0.3, -0.46, -0.52, -0.3, -0.4883, -0.5883, -0.3, -0.4883, -0.5317, -0.3, -0.4883, -0.5317, -0.3, -0.4883, -0.5883, -0.3, -0.5, -0.56, -0.3, -0.42, -0.56, -0.34, -0.42, -0.56, -0.3, -0.4317, -0.5883, -0.3, -0.4317, -0.5883, -0.34, -0.42, -0.56, -0.34, -0.4317, -0.5883, -0.3, -0.4317, -0.5883, -0.34, -0.4317, -0.5883, -0.3, -0.46, -0.6, -0.3, -0.46, -0.6, -0.34, -0.4317, -0.5883, -0.34, -0.46, -0.6, -0.34, -0.4883, -0.5883, -0.34, -0.46, -0.6, -0.34, -0.5, -0.56, -0.34, -0.5, -0.56, -0.34, -0.46, -0.6, -0.34, -0.4883, -0.5317, -0.34, -0.4883, -0.5317, -0.34, -0.46, -0.6, -0.34, -0.46, -0.52, -0.34, -0.46, -0.52, -0.34, -0.46, -0.6, -0.34, -0.4317, -0.5317, -0.34, -0.4317, -0.5317, -0.34, -0.46, -0.6, -0.34, -0.42, -0.56, -0.34, -0.42, -0.56, -0.34, -0.46, -0.6, -0.34, -0.4317, -0.5883, 0.34, -0.46, 0.52, 0.3, -0.46, 0.52, 0.34, -0.4883, 0.5317, 0.34, -0.4883, 0.5317, 0.3, -0.46, 0.52, 0.3, -0.4883, 0.5317, 0.34, -0.4883, 0.5317, 0.3, -0.4883, 0.5317, 0.34, -0.5, 0.56, 0.34, -0.5, 0.56, 0.3, -0.4883, 0.5317, 0.3, -0.5, 0.56, 0.34, -0.5, 0.56, 0.3, -0.5, 0.56, 0.34, -0.4883, 0.5883, 0.34, -0.4883, 0.5883, 0.3, -0.5, 0.56, 0.3, -0.4883, 0.5883, 0.34, -0.4883, 0.5883, 0.3, -0.4883, 0.5883, 0.34, -0.46, 0.6, 0.34, -0.46, 0.6, 0.3, -0.4883, 0.5883, 0.3, -0.46, 0.6, 0.34, -0.46, 0.6, 0.3, -0.46, 0.6, 0.34, -0.4317, 0.5883, 0.34, -0.4317, 0.5883, 0.3, -0.46, 0.6, 0.3, -0.4317, 0.5883, 0.34, -0.4317, 0.5883, 0.3, -0.4317, 0.5883, 0.34, -0.42, 0.56, 0.34, -0.42, 0.56, 0.3, -0.4317, 0.5883, 0.3, -0.42, 0.56, 0.34, -0.46, 0.52, 0.34, -0.4883, 0.5317, 0.34, -0.4317, 0.5317, 0.34, -0.4317, 0.5317, 0.34, -0.4883, 0.5317, 0.34, -0.42, 0.56, 0.34, -0.42, 0.56, 0.34, -0.4883, 0.5317, 0.34, -0.4317, 0.5883, 0.34, -0.4317, 0.5883, 0.34, -0.4883, 0.5317, 0.34, -0.46, 0.6, 0.34, -0.46, 0.6, 0.34, -0.4883, 0.5317, 0.34, -0.4883, 0.5883, 0.34, -0.4883, 0.5883, 0.34, -0.4883, 0.5317, 0.34, -0.5, 0.56, 0.34, -0.42, 0.56, 0.3, -0.42, 0.56, 0.34, -0.4317, 0.5317, 0.34, -0.4317, 0.5317, 0.3, -0.42, 0.56, 0.3, -0.4317, 0.5317, 0.34, -0.4317, 0.5317, 0.3, -0.4317, 0.5317, 0.34, -0.46, 0.52, 0.34, -0.46, 0.52, 0.3, -0.4317, 0.5317, 0.3, -0.46, 0.52, 0.3, -0.4883, 0.5317, 0.3, -0.46, 0.52, 0.3, -0.5, 0.56, 0.3, -0.5, 0.56, 0.3, -0.46, 0.52, 0.3, -0.4883, 0.5883, 0.3, -0.4883, 0.5883, 0.3, -0.46, 0.52, 0.3, -0.46, 0.6, 0.3, -0.46, 0.6, 0.3, -0.46, 0.52, 0.3, -0.4317, 0.5883, 0.3, -0.4317, 0.5883, 0.3, -0.46, 0.52, 0.3, -0.42, 0.56, 0.3, -0.42, 0.56, 0.3, -0.46, 0.52, 0.3, -0.4317, 0.5317, 0.34, -0.46, -0.6, 0.3, -0.46, -0.6, 0.34, -0.4883, -0.5883, 0.34, -0.4883, -0.5883, 0.3, -0.46, -0.6, 0.3, -0.4883, -0.5883, 0.34, -0.4883, -0.5883, 0.3, -0.4883, -0.5883, 0.34, -0.5, -0.56, 0.34, -0.5, -0.56, 0.3, -0.4883, -0.5883, 0.3, -0.5, -0.56, 0.34, -0.5, -0.56, 0.3, -0.5, -0.56, 0.34, -0.4883, -0.5317, 0.34, -0.4883, -0.5317, 0.3, -0.5, -0.56, 0.3, -0.4883, -0.5317, 0.34, -0.4883, -0.5317, 0.3, -0.4883, -0.5317, 0.34, -0.46, -0.52, 0.34, -0.46, -0.52, 0.3, -0.4883, -0.5317, 0.3, -0.46, -0.52, 0.34, -0.46, -0.52, 0.3, -0.46, -0.52, 0.34, -0.4317, -0.5317, 0.34, -0.4317, -0.5317, 0.3, -0.46, -0.52, 0.3, -0.4317, -0.5317, 0.34, -0.4317, -0.5317, 0.3, -0.4317, -0.5317, 0.34, -0.42, -0.56, 0.34, -0.42, -0.56, 0.3, -0.4317, -0.5317, 0.3, -0.42, -0.56, 0.34, -0.46, -0.6, 0.34, -0.4883, -0.5883, 0.34, -0.4317, -0.5883, 0.34, -0.4317, -0.5883, 0.34, -0.4883, -0.5883, 0.34, -0.42, -0.56, 0.34, -0.42, -0.56, 0.34, -0.4883, -0.5883, 0.34, -0.4317, -0.5317, 0.34, -0.4317, -0.5317, 0.34, -0.4883, -0.5883, 0.34, -0.46, -0.52, 0.34, -0.46, -0.52, 0.34, -0.4883, -0.5883, 0.34, -0.4883, -0.5317, 0.34, -0.4883, -0.5317, 0.34, -0.4883, -0.5883, 0.34, -0.5, -0.56, 0.34, -0.42, -0.56, 0.3, -0.42, -0.56, 0.34, -0.4317, -0.5883, 0.34, -0.4317, -0.5883, 0.3, -0.42, -0.56, 0.3, -0.4317, -0.5883, 0.34, -0.4317, -0.5883, 0.3, -0.4317, -0.5883, 0.34, -0.46, -0.6, 0.34, -0.46, -0.6, 0.3, -0.4317, -0.5883, 0.3, -0.46, -0.6, 0.3, -0.4883, -0.5883, 0.3, -0.46, -0.6, 0.3, -0.5, -0.56, 0.3, -0.5, -0.56, 0.3, -0.46, -0.6, 0.3, -0.4883, -0.5317, 0.3, -0.4883, -0.5317, 0.3, -0.46, -0.6, 0.3, -0.46, -0.52, 0.3, -0.46, -0.52, 0.3, -0.46, -0.6, 0.3, -0.4317, -0.5317, 0.3, -0.4317, -0.5317, 0.3, -0.46, -0.6, 0.3, -0.42, -0.56, 0.3, -0.42, -0.56, 0.3, -0.46, -0.6, 0.3, -0.4317, -0.5883, 0.29, -0.4203, -0.56, 0.32, -0.42, -0.53, 0.32, -0.48, -0.56, -0.29, -0.4203, -0.56, -0.32, -0.42, -0.59, -0.32, -0.48, -0.56, -0.29, -0.4203, 0.56, -0.32, -0.42, 0.53, -0.32, -0.48, 0.56, 0.32, -0.42, -0.59, 0.29, -0.4203, -0.56, 0.32, -0.48, -0.56, -0.32, 0.47, 0.59, -0.35, 0.47, 0.56, -0.32, 0.5, 0.56, -0.32, 0.47, -0.59, -0.32, 0.5, -0.56, -0.35, 0.47, -0.56, 0.32, 0.47, 0.59, 0.32, 0.5, 0.56, 0.35, 0.47, 0.56, 0.35, 0.47, -0.56, 0.32, 0.5, -0.56, 0.32, 0.47, -0.59, -0.32, 0.5, 0.56, -0.35, 0.47, 0.56, -0.32, 0.47, 0.53, -0.32, 0.47, -0.53, -0.35, 0.47, -0.56, -0.32, 0.5, -0.56, 0.32, 0.5, -0.56, 0.35, 0.47, -0.56, 0.32, 0.47, -0.53, 0.32, 0.47, 0.53, 0.35, 0.47, 0.56, 0.32, 0.5, 0.56, -0.32, 0.47, 0.59, -0.32, -0.42, 0.59, -0.35, 0.47, 0.56, -0.35, 0.47, 0.56, -0.32, -0.42, 0.59, -0.35, -0.4197, 0.56, -0.32, -0.42, -0.59, -0.32, 0.47, -0.59, -0.35, -0.4197, -0.56, -0.35, -0.4197, -0.56, -0.32, 0.47, -0.59, -0.35, 0.47, -0.56, 0.32, 0.5, -0.56, -0.32, 0.5, -0.56, 0.32, 0.47, -0.59, 0.32, 0.47, -0.59, -0.32, 0.5, -0.56, -0.32, 0.47, -0.59, 0.35, -0.4197, -0.56, 0.35, 0.47, -0.56, 0.32, -0.42, -0.59, 0.32, -0.42, -0.59, 0.35, 0.47, -0.56, 0.32, 0.47, -0.59, 0.32, -0.42, 0.59, 0.32, 0.47, 0.59, 0.35, -0.4197, 0.56, 0.35, -0.4197, 0.56, 0.32, 0.47, 0.59, 0.35, 0.47, 0.56, -0.32, 0.5, 0.56, 0.32, 0.5, 0.56, -0.32, 0.47, 0.59, -0.32, 0.47, 0.59, 0.32, 0.5, 0.56, 0.32, 0.47, 0.59, 0.32, 0.47, -0.53, -0.32, 0.47, -0.53, 0.32, 0.5, -0.56, 0.32, 0.5, -0.56, -0.32, 0.47, -0.53, -0.32, 0.5, -0.56, 0.32, 0.5, 0.56, -0.32, 0.5, 0.56, 0.32, 0.47, 0.53, 0.32, 0.47, 0.53, -0.32, 0.5, 0.56, -0.32, 0.47, 0.53, 0.32, -0.42, -0.53, 0.32, 0.47, -0.53, 0.35, -0.4197, -0.56, 0.35, -0.4197, -0.56, 0.32, 0.47, -0.53, 0.35, 0.47, -0.56, 0.35, -0.4197, 0.56, 0.35, 0.47, 0.56, 0.32, -0.42, 0.53, 0.32, -0.42, 0.53, 0.35, 0.47, 0.56, 0.32, 0.47, 0.53, -0.32, -0.42, 0.53, -0.32, 0.47, 0.53, -0.35, -0.4197, 0.56, -0.35, -0.4197, 0.56, -0.32, 0.47, 0.53, -0.35, 0.47, 0.56, -0.35, -0.4197, -0.56, -0.35, 0.47, -0.56, -0.32, -0.42, -0.53, -0.32, -0.42, -0.53, -0.35, 0.47, -0.56, -0.32, 0.47, -0.53, 0.32, -0.42, -0.59, 0.32, 0.47, -0.59, 0.29, -0.4203, -0.56, 0.29, -0.4203, -0.56, 0.32, 0.47, -0.59, 0.29, 0.44, -0.56, 0.32, -0.42, 0.53, 0.32, 0.47, 0.53, 0.29, -0.4203, 0.56, 0.29, -0.4203, 0.56, 0.32, 0.47, 0.53, 0.29, 0.44, 0.56, 0.32, 0.47, -0.53, 0.32, -0.42, -0.53, 0.29, 0.44, -0.56, 0.29, 0.44, -0.56, 0.32, -0.42, -0.53, 0.29, -0.4203, -0.56, 0.32, 0.47, 0.59, 0.32, -0.42, 0.59, 0.29, 0.44, 0.56, 0.29, 0.44, 0.56, 0.32, -0.42, 0.59, 0.29, -0.4203, 0.56, -0.29, -0.4203, -0.56, -0.29, 0.44, -0.56, -0.32, -0.42, -0.59, -0.32, -0.42, -0.59, -0.29, 0.44, -0.56, -0.32, 0.47, -0.59, -0.29, -0.4203, 0.56, -0.29, 0.44, 0.56, -0.32, -0.42, 0.53, -0.32, -0.42, 0.53, -0.29, 0.44, 0.56, -0.32, 0.47, 0.53, 0.32, 0.47, -0.59, -0.32, 0.47, -0.59, 0.29, 0.44, -0.56, 0.29, 0.44, -0.56, -0.32, 0.47, -0.59, -0.29, 0.44, -0.56, 0.29, 0.44, -0.56, -0.29, 0.44, -0.56, 0.32, 0.47, -0.53, 0.32, 0.47, -0.53, -0.29, 0.44, -0.56, -0.32, 0.47, -0.53, 0.32, 0.47, 0.53, -0.32, 0.47, 0.53, 0.29, 0.44, 0.56, 0.29, 0.44, 0.56, -0.32, 0.47, 0.53, -0.29, 0.44, 0.56, 0.29, 0.44, 0.56, -0.29, 0.44, 0.56, 0.32, 0.47, 0.59, 0.32, 0.47, 0.59, -0.29, 0.44, 0.56, -0.32, 0.47, 0.59, -0.29, 0.44, -0.56, -0.29, -0.4203, -0.56, -0.32, 0.47, -0.53, -0.32, 0.47, -0.53, -0.29, -0.4203, -0.56, -0.32, -0.42, -0.53, -0.32, -0.42, 0.59, -0.32, 0.47, 0.59, -0.29, -0.4203, 0.56, -0.29, -0.4203, 0.56, -0.32, 0.47, 0.59, -0.29, 0.44, 0.56, 0.35, -0.4197, -0.56, 0.32, -0.42, -0.59, 0.32, -0.48, -0.56, 0.35, -0.4197, 0.56, 0.32, -0.42, 0.53, 0.32, -0.48, 0.56, -0.32, -0.42, 0.53, -0.35, -0.4197, 0.56, -0.32, -0.48, 0.56, -0.35, -0.4197, 0.56, -0.32, -0.42, 0.59, -0.32, -0.48, 0.56, -0.32, -0.42, 0.59, -0.29, -0.4203, 0.56, -0.32, -0.48, 0.56, 0.32, -0.42, -0.53, 0.35, -0.4197, -0.56, 0.32, -0.48, -0.56, 0.29, -0.4203, 0.56, 0.32, -0.42, 0.59, 0.32, -0.48, 0.56, 0.32, -0.42, 0.59, 0.35, -0.4197, 0.56, 0.32, -0.48, 0.56, -0.32, -0.42, -0.53, -0.29, -0.4203, -0.56, -0.32, -0.48, -0.56, -0.35, -0.4197, -0.56, -0.32, -0.42, -0.53, -0.32, -0.48, -0.56, 0.32, -0.42, 0.53, 0.29, -0.4203, 0.56, 0.32, -0.48, 0.56, -0.32, -0.42, -0.59, -0.35, -0.4197, -0.56, -0.32, -0.48, -0.56, -0.28, 0.23, -0.52, -0.28, 0.17, -0.52, -0.28, 0.23, -0.6, -0.28, 0.23, -0.6, -0.28, 0.17, -0.52, -0.28, 0.17, -0.6, -0.28, 0.23, -0.6, -0.28, 0.17, -0.6, 0.2801, 0.23, -0.6, 0.2801, 0.23, -0.6, -0.28, 0.17, -0.6, 0.2801, 0.17, -0.6, -0.28, 0.17, -0.52, -0.28, 0.23, -0.52, -0.35, 0.17, -0.52, -0.35, 0.17, -0.52, -0.28, 0.23, -0.52, -0.35, 0.23, -0.52, -0.28, 0.17, -0.52, -0.35, 0.17, -0.52, -0.28, 0.17, -0.6, -0.28, 0.17, 0.52, -0.35, 0.17, -0.52, -0.35, 0.17, 0.52, -0.28, 0.17, -0.6, -0.35, 0.17, -0.52, 0.2801, 0.17, -0.6, 0.2801, 0.17, -0.6, -0.35, 0.17, -0.52, 0.2801, 0.17, -0.52, 0.2801, 0.17, -0.52, -0.35, 0.17, -0.52, 0.35, 0.17, -0.52, 0.35, 0.17, -0.52, -0.35, 0.17, -0.52, 0.35, 0.17, 0.52, 0.35, 0.17, 0.52, -0.35, 0.17, -0.52, 0.2799, 0.17, 0.52, 0.2799, 0.17, 0.52, -0.35, 0.17, -0.52, 0.2799, 0.17, 0.6, 0.2799, 0.17, 0.6, -0.35, 0.17, -0.52, -0.28, 0.17, 0.6, -0.28, 0.17, 0.6, -0.35, 0.17, -0.52, -0.28, 0.17, 0.52, 0.35, 0.23, -0.52, 0.35, 0.17, -0.52, 0.35, 0.23, 0.52, 0.35, 0.23, 0.52, 0.35, 0.17, -0.52, 0.35, 0.17, 0.52, 0.2001, 0.2, -0.44, 0.27, 0.2, -0.44, 0.2001, 0.2, -0.52, 0.1999, 0.2, 0.44, 0.27, 0.2, -0.44, 0.27, 0.2, 0.44, 0.2001, 0.2, -0.52, 0.27, 0.2, -0.44, -0.2, 0.2, -0.52, -0.2, 0.2, -0.52, 0.27, 0.2, -0.44, -0.2, 0.2, -0.44, -0.2, 0.2, -0.44, 0.27, 0.2, -0.44, -0.27, 0.2, -0.44, -0.27, 0.2, -0.44, 0.27, 0.2, -0.44, -0.27, 0.2, 0.44, -0.27, 0.2, 0.44, 0.27, 0.2, -0.44, -0.2, 0.2, 0.44, -0.2, 0.2, 0.44, 0.27, 0.2, -0.44, -0.2, 0.2, 0.52, -0.2, 0.2, 0.52, 0.27, 0.2, -0.44, 0.1999, 0.2, 0.52, 0.1999, 0.2, 0.52, 0.27, 0.2, -0.44, 0.1999, 0.2, 0.44, 0.2801, 0.23, -0.52, 0.2801, 0.17, -0.52, 0.35, 0.23, -0.52, 0.35, 0.23, -0.52, 0.2801, 0.17, -0.52, 0.35, 0.17, -0.52, 0.2801, 0.17, -0.52, 0.2801, 0.23, -0.52, 0.2801, 0.17, -0.6, 0.2801, 0.17, -0.6, 0.2801, 0.23, -0.52, 0.2801, 0.23, -0.6, -0.28, 0.17, 0.52, -0.28, 0.23, 0.52, -0.28, 0.17, 0.6, -0.28, 0.17, 0.6, -0.28, 0.23, 0.52, -0.28, 0.23, 0.6, -0.35, 0.23, 0.52, -0.35, 0.17, 0.52, -0.35, 0.23, -0.52, -0.35, 0.23, -0.52, -0.35, 0.17, 0.52, -0.35, 0.17, -0.52, -0.28, 0.23, 0.52, -0.28, 0.17, 0.52, -0.35, 0.23, 0.52, -0.35, 0.23, 0.52, -0.28, 0.17, 0.52, -0.35, 0.17, 0.52, 0.2799, 0.23, 0.6, 0.2799, 0.17, 0.6, -0.28, 0.23, 0.6, -0.28, 0.23, 0.6, 0.2799, 0.17, 0.6, -0.28, 0.17, 0.6, 0.2799, 0.23, 0.52, 0.2799, 0.17, 0.52, 0.2799, 0.23, 0.6, 0.2799, 0.23, 0.6, 0.2799, 0.17, 0.52, 0.2799, 0.17, 0.6, 0.2799, 0.17, 0.52, 0.2799, 0.23, 0.52, 0.35, 0.17, 0.52, 0.35, 0.17, 0.52, 0.2799, 0.23, 0.52, 0.35, 0.23, 0.52, -0.28, -0.27, -0.52, -0.28, -0.33, -0.52, -0.28, -0.27, -0.6, -0.28, -0.27, -0.6, -0.28, -0.33, -0.52, -0.28, -0.33, -0.6, -0.28, -0.27, -0.6, -0.28, -0.33, -0.6, 0.2801, -0.27, -0.6, 0.2801, -0.27, -0.6, -0.28, -0.33, -0.6, 0.2801, -0.33, -0.6, -0.28, -0.33, -0.52, -0.28, -0.27, -0.52, -0.35, -0.33, -0.52, -0.35, -0.33, -0.52, -0.28, -0.27, -0.52, -0.35, -0.27, -0.52, -0.28, -0.33, -0.52, -0.35, -0.33, -0.52, -0.28, -0.33, -0.6, -0.28, -0.33, 0.52, -0.35, -0.33, -0.52, -0.35, -0.33, 0.52, -0.28, -0.33, -0.6, -0.35, -0.33, -0.52, 0.2801, -0.33, -0.6, 0.2801, -0.33, -0.6, -0.35, -0.33, -0.52, 0.2801, -0.33, -0.52, 0.2801, -0.33, -0.52, -0.35, -0.33, -0.52, 0.35, -0.33, -0.52, 0.35, -0.33, -0.52, -0.35, -0.33, -0.52, 0.35, -0.33, 0.52, 0.35, -0.33, 0.52, -0.35, -0.33, -0.52, 0.2799, -0.33, 0.52, 0.2799, -0.33, 0.52, -0.35, -0.33, -0.52, 0.2799, -0.33, 0.6, 0.2799, -0.33, 0.6, -0.35, -0.33, -0.52, -0.28, -0.33, 0.6, -0.28, -0.33, 0.6, -0.35, -0.33, -0.52, -0.28, -0.33, 0.52, 0.35, -0.27, -0.52, 0.35, -0.33, -0.52, 0.35, -0.27, 0.52, 0.35, -0.27, 0.52, 0.35, -0.33, -0.52, 0.35, -0.33, 0.52, 0.2001, -0.3, -0.44, 0.27, -0.3, -0.44, 0.2001, -0.3, -0.52, 0.1999, -0.3, 0.44, 0.27, -0.3, -0.44, 0.27, -0.3, 0.44, 0.2001, -0.3, -0.52, 0.27, -0.3, -0.44, -0.2, -0.3, -0.52, -0.2, -0.3, -0.52, 0.27, -0.3, -0.44, -0.2, -0.3, -0.44, -0.2, -0.3, -0.44, 0.27, -0.3, -0.44, -0.27, -0.3, -0.44, -0.27, -0.3, -0.44, 0.27, -0.3, -0.44, -0.27, -0.3, 0.44, -0.27, -0.3, 0.44, 0.27, -0.3, -0.44, -0.2, -0.3, 0.44, -0.2, -0.3, 0.44, 0.27, -0.3, -0.44, -0.2, -0.3, 0.52, -0.2, -0.3, 0.52, 0.27, -0.3, -0.44, 0.1999, -0.3, 0.52, 0.1999, -0.3, 0.52, 0.27, -0.3, -0.44, 0.1999, -0.3, 0.44, 0.2801, -0.27, -0.52, 0.2801, -0.33, -0.52, 0.35, -0.27, -0.52, 0.35, -0.27, -0.52, 0.2801, -0.33, -0.52, 0.35, -0.33, -0.52, 0.2801, -0.33, -0.52, 0.2801, -0.27, -0.52, 0.2801, -0.33, -0.6, 0.2801, -0.33, -0.6, 0.2801, -0.27, -0.52, 0.2801, -0.27, -0.6, -0.28, -0.33, 0.52, -0.28, -0.27, 0.52, -0.28, -0.33, 0.6, -0.28, -0.33, 0.6, -0.28, -0.27, 0.52, -0.28, -0.27, 0.6, -0.35, -0.27, 0.52, -0.35, -0.33, 0.52, -0.35, -0.27, -0.52, -0.35, -0.27, -0.52, -0.35, -0.33, 0.52, -0.35, -0.33, -0.52, -0.28, -0.27, 0.52, -0.28, -0.33, 0.52, -0.35, -0.27, 0.52, -0.35, -0.27, 0.52, -0.28, -0.33, 0.52, -0.35, -0.33, 0.52, 0.2799, -0.27, 0.6, 0.2799, -0.33, 0.6, -0.28, -0.27, 0.6, -0.28, -0.27, 0.6, 0.2799, -0.33, 0.6, -0.28, -0.33, 0.6, 0.2799, -0.27, 0.52, 0.2799, -0.33, 0.52, 0.2799, -0.27, 0.6, 0.2799, -0.27, 0.6, 0.2799, -0.33, 0.52, 0.2799, -0.33, 0.6, 0.2799, -0.33, 0.52, 0.2799, -0.27, 0.52, 0.35, -0.33, 0.52, 0.35, -0.33, 0.52, 0.2799, -0.27, 0.52, 0.35, -0.27, 0.52, -0.24, 0.23, -0.56, -0.24, 0.23, -0.48, -0.28, 0.23, -0.6, -0.28, 0.23, -0.6, -0.24, 0.23, -0.48, -0.28, 0.23, -0.52, 0.2801, 0.23, -0.6, -0.24, 0.23, -0.56, -0.28, 0.23, -0.6, -0.24, 0.23, -0.48, -0.31, 0.23, -0.48, -0.28, 0.23, -0.52, 0.2401, 0.23, -0.56, -0.24, 0.23, -0.56, 0.2801, 0.23, -0.6, -0.28, 0.23, -0.52, -0.31, 0.23, -0.48, -0.35, 0.23, -0.52, 0.2801, 0.23, -0.52, 0.2401, 0.23, -0.56, 0.2801, 0.23, -0.6, -0.31, 0.23, -0.48, -0.31, 0.23, 0.48, -0.35, 0.23, -0.52, 0.2401, 0.23, -0.48, 0.2401, 0.23, -0.56, 0.2801, 0.23, -0.52, -0.35, 0.23, -0.52, -0.31, 0.23, 0.48, -0.35, 0.23, 0.52, 0.35, 0.23, -0.52, 0.2401, 0.23, -0.48, 0.2801, 0.23, -0.52, -0.31, 0.23, 0.48, -0.24, 0.23, 0.48, -0.35, 0.23, 0.52, 0.31, 0.23, -0.48, 0.2401, 0.23, -0.48, 0.35, 0.23, -0.52, -0.35, 0.23, 0.52, -0.24, 0.23, 0.48, -0.28, 0.23, 0.52, 0.35, 0.23, 0.52, 0.31, 0.23, -0.48, 0.35, 0.23, -0.52, -0.24, 0.23, 0.48, -0.24, 0.23, 0.56, -0.28, 0.23, 0.52, 0.31, 0.23, 0.48, 0.31, 0.23, -0.48, 0.35, 0.23, 0.52, -0.28, 0.23, 0.52, -0.24, 0.23, 0.56, -0.28, 0.23, 0.6, 0.2799, 0.23, 0.52, 0.31, 0.23, 0.48, 0.35, 0.23, 0.52, -0.24, 0.23, 0.56, 0.2399, 0.23, 0.56, -0.28, 0.23, 0.6, 0.2399, 0.23, 0.48, 0.31, 0.23, 0.48, 0.2799, 0.23, 0.52, -0.28, 0.23, 0.6, 0.2399, 0.23, 0.56, 0.2799, 0.23, 0.6, 0.2399, 0.23, 0.56, 0.2399, 0.23, 0.48, 0.2799, 0.23, 0.6, 0.2799, 0.23, 0.6, 0.2399, 0.23, 0.48, 0.2799, 0.23, 0.52, -0.24, -0.27, -0.56, -0.24, -0.27, -0.48, -0.28, -0.27, -0.6, -0.28, -0.27, -0.6, -0.24, -0.27, -0.48, -0.28, -0.27, -0.52, 0.2801, -0.27, -0.6, -0.24, -0.27, -0.56, -0.28, -0.27, -0.6, -0.24, -0.27, -0.48, -0.31, -0.27, -0.48, -0.28, -0.27, -0.52, 0.2401, -0.27, -0.56, -0.24, -0.27, -0.56, 0.2801, -0.27, -0.6, -0.28, -0.27, -0.52, -0.31, -0.27, -0.48, -0.35, -0.27, -0.52, 0.2801, -0.27, -0.52, 0.2401, -0.27, -0.56, 0.2801, -0.27, -0.6, -0.31, -0.27, -0.48, -0.31, -0.27, 0.48, -0.35, -0.27, -0.52, 0.2401, -0.27, -0.48, 0.2401, -0.27, -0.56, 0.2801, -0.27, -0.52, -0.35, -0.27, -0.52, -0.31, -0.27, 0.48, -0.35, -0.27, 0.52, 0.35, -0.27, -0.52, 0.2401, -0.27, -0.48, 0.2801, -0.27, -0.52, -0.31, -0.27, 0.48, -0.24, -0.27, 0.48, -0.35, -0.27, 0.52, 0.31, -0.27, -0.48, 0.2401, -0.27, -0.48, 0.35, -0.27, -0.52, -0.35, -0.27, 0.52, -0.24, -0.27, 0.48, -0.28, -0.27, 0.52, 0.35, -0.27, 0.52, 0.31, -0.27, -0.48, 0.35, -0.27, -0.52, -0.24, -0.27, 0.48, -0.24, -0.27, 0.56, -0.28, -0.27, 0.52, 0.31, -0.27, 0.48, 0.31, -0.27, -0.48, 0.35, -0.27, 0.52, -0.28, -0.27, 0.52, -0.24, -0.27, 0.56, -0.28, -0.27, 0.6, 0.2799, -0.27, 0.52, 0.31, -0.27, 0.48, 0.35, -0.27, 0.52, -0.24, -0.27, 0.56, 0.2399, -0.27, 0.56, -0.28, -0.27, 0.6, 0.2399, -0.27, 0.48, 0.31, -0.27, 0.48, 0.2799, -0.27, 0.52, -0.28, -0.27, 0.6, 0.2399, -0.27, 0.56, 0.2799, -0.27, 0.6, 0.2399, -0.27, 0.56, 0.2399, -0.27, 0.48, 0.2799, -0.27, 0.6, 0.2799, -0.27, 0.6, 0.2399, -0.27, 0.48, 0.2799, -0.27, 0.52, -0.2, 0.2, -0.52, -0.2, 0.2, -0.44, -0.24, 0.23, -0.56, -0.24, 0.23, -0.56, -0.2, 0.2, -0.44, -0.24, 0.23, -0.48, -0.2, 0.2, -0.44, -0.27, 0.2, -0.44, -0.24, 0.23, -0.48, -0.24, 0.23, -0.48, -0.27, 0.2, -0.44, -0.31, 0.23, -0.48, -0.27, 0.2, -0.44, -0.27, 0.2, 0.44, -0.31, 0.23, -0.48, -0.31, 0.23, -0.48, -0.27, 0.2, 0.44, -0.31, 0.23, 0.48, 0.2001, 0.2, -0.44, 0.2001, 0.2, -0.52, 0.2401, 0.23, -0.48, 0.2401, 0.23, -0.48, 0.2001, 0.2, -0.52, 0.2401, 0.23, -0.56, 0.27, 0.2, -0.44, 0.2001, 0.2, -0.44, 0.31, 0.23, -0.48, 0.31, 0.23, -0.48, 0.2001, 0.2, -0.44, 0.2401, 0.23, -0.48, 0.2001, 0.2, -0.52, -0.2, 0.2, -0.52, 0.2401, 0.23, -0.56, 0.2401, 0.23, -0.56, -0.2, 0.2, -0.52, -0.24, 0.23, -0.56, -0.2, 0.2, 0.44, -0.2, 0.2, 0.52, -0.24, 0.23, 0.48, -0.24, 0.23, 0.48, -0.2, 0.2, 0.52, -0.24, 0.23, 0.56, -0.27, 0.2, 0.44, -0.2, 0.2, 0.44, -0.31, 0.23, 0.48, -0.31, 0.23, 0.48, -0.2, 0.2, 0.44, -0.24, 0.23, 0.48, -0.2, 0.2, 0.52, 0.1999, 0.2, 0.52, -0.24, 0.23, 0.56, -0.24, 0.23, 0.56, 0.1999, 0.2, 0.52, 0.2399, 0.23, 0.56, 0.1999, 0.2, 0.44, 0.27, 0.2, 0.44, 0.2399, 0.23, 0.48, 0.2399, 0.23, 0.48, 0.27, 0.2, 0.44, 0.31, 0.23, 0.48, 0.1999, 0.2, 0.52, 0.1999, 0.2, 0.44, 0.2399, 0.23, 0.56, 0.2399, 0.23, 0.56, 0.1999, 0.2, 0.44, 0.2399, 0.23, 0.48, 0.27, 0.2, 0.44, 0.27, 0.2, -0.44, 0.31, 0.23, 0.48, 0.31, 0.23, 0.48, 0.27, 0.2, -0.44, 0.31, 0.23, -0.48, -0.2, -0.3, -0.52, -0.2, -0.3, -0.44, -0.24, -0.27, -0.56, -0.24, -0.27, -0.56, -0.2, -0.3, -0.44, -0.24, -0.27, -0.48, -0.2, -0.3, -0.44, -0.27, -0.3, -0.44, -0.24, -0.27, -0.48, -0.24, -0.27, -0.48, -0.27, -0.3, -0.44, -0.31, -0.27, -0.48, -0.27, -0.3, -0.44, -0.27, -0.3, 0.44, -0.31, -0.27, -0.48, -0.31, -0.27, -0.48, -0.27, -0.3, 0.44, -0.31, -0.27, 0.48, 0.2001, -0.3, -0.44, 0.2001, -0.3, -0.52, 0.2401, -0.27, -0.48, 0.2401, -0.27, -0.48, 0.2001, -0.3, -0.52, 0.2401, -0.27, -0.56, 0.27, -0.3, -0.44, 0.2001, -0.3, -0.44, 0.31, -0.27, -0.48, 0.31, -0.27, -0.48, 0.2001, -0.3, -0.44, 0.2401, -0.27, -0.48, 0.2001, -0.3, -0.52, -0.2, -0.3, -0.52, 0.2401, -0.27, -0.56, 0.2401, -0.27, -0.56, -0.2, -0.3, -0.52, -0.24, -0.27, -0.56, -0.2, -0.3, 0.44, -0.2, -0.3, 0.52, -0.24, -0.27, 0.48, -0.24, -0.27, 0.48, -0.2, -0.3, 0.52, -0.24, -0.27, 0.56, -0.27, -0.3, 0.44, -0.2, -0.3, 0.44, -0.31, -0.27, 0.48, -0.31, -0.27, 0.48, -0.2, -0.3, 0.44, -0.24, -0.27, 0.48, -0.2, -0.3, 0.52, 0.1999, -0.3, 0.52, -0.24, -0.27, 0.56, -0.24, -0.27, 0.56, 0.1999, -0.3, 0.52, 0.2399, -0.27, 0.56, 0.1999, -0.3, 0.44, 0.27, -0.3, 0.44, 0.2399, -0.27, 0.48, 0.2399, -0.27, 0.48, 0.27, -0.3, 0.44, 0.31, -0.27, 0.48, 0.1999, -0.3, 0.52, 0.1999, -0.3, 0.44, 0.2399, -0.27, 0.56, 0.2399, -0.27, 0.56, 0.1999, -0.3, 0.44, 0.2399, -0.27, 0.48, 0.27, -0.3, 0.44, 0.27, -0.3, -0.44, 0.31, -0.27, 0.48, 0.31, -0.27, 0.48, 0.27, -0.3, -0.44, 0.31, -0.27, -0.48) + +[node name="PhysMedCart" type="RigidBody3D" groups=["Persistent", "PlasticMaterial"]] +collision_layer = 67 +collision_mask = 73 +mass = 40.0 +script = ExtResource("1_3jm8i") + +[node name="CollisionShape3D" type="CollisionShape3D" parent="."] +shape = SubResource("BoxShape3D_fu1y0") + +[node name="MeshInstance3D" type="MeshInstance3D" parent="."] +mesh = ExtResource("3_3jm8i") +surface_material_override/0 = SubResource("StandardMaterial3D_xx4to") + +[node name="StaticBody3D" type="StaticBody3D" parent="MeshInstance3D"] +collision_layer = 4 +collision_mask = 0 + +[node name="CollisionShape3D" type="CollisionShape3D" parent="MeshInstance3D/StaticBody3D"] +shape = SubResource("ConcavePolygonShape3D_rhern") + +[node name="Gunkable" parent="MeshInstance3D/StaticBody3D" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("1_fu1y0")] +mask_dim = 96 +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("2_8v7ae") + +[node name="Holdable" type="Node" parent="."] +script = ExtResource("8_8v7ae") +hold_distance = 2.0 +metadata/_custom_type_script = "uid://040xta01xqxd" diff --git a/src/props/med_cart/med_cart.tscn b/src/props/med_cart/static_med_cart.tscn similarity index 95% rename from src/props/med_cart/med_cart.tscn rename to src/props/med_cart/static_med_cart.tscn index 528c546..9ef3541 100644 --- a/src/props/med_cart/med_cart.tscn +++ b/src/props/med_cart/static_med_cart.tscn @@ -1,35 +1,41 @@ [gd_scene load_steps=10 format=3 uid="uid://h2gswdcxyotk"] -[ext_resource type="ArrayMesh" uid="uid://b3p2eh3b8jg4r" path="res://assets/props/med_cart/med_cart.obj" id="1_hco3w"] -[ext_resource type="Texture2D" uid="uid://biqh5uq67dl55" path="res://assets/props/med_cart/med_cart_C.png" id="1_s6gun"] -[ext_resource type="Texture2D" uid="uid://bds4qx6kqhplb" path="res://assets/props/med_cart/med_cart_M.png" id="2_qivrt"] -[ext_resource type="Texture2D" uid="uid://v4j34fh4vm06" path="res://assets/props/med_cart/med_cart_N.png" id="3_t575c"] -[ext_resource type="Texture2D" uid="uid://bcnsofhrfxyjk" path="res://assets/props/med_cart/med_cart_R.png" id="4_hco3w"] -[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="5_hco3w"] -[ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="6_t575c"] +[ext_resource type="ArrayMesh" uid="uid://b3p2eh3b8jg4r" path="res://assets/props/med_cart/med_cart.obj" id="1_lt7v2"] +[ext_resource type="Texture2D" uid="uid://biqh5uq67dl55" path="res://assets/props/med_cart/med_cart_C.png" id="2_6d44d"] +[ext_resource type="Texture2D" uid="uid://bds4qx6kqhplb" path="res://assets/props/med_cart/med_cart_M.png" id="3_jdl4v"] +[ext_resource type="Texture2D" uid="uid://v4j34fh4vm06" path="res://assets/props/med_cart/med_cart_N.png" id="4_yjujg"] +[ext_resource type="Texture2D" uid="uid://bcnsofhrfxyjk" path="res://assets/props/med_cart/med_cart_R.png" id="5_6xe2u"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="6_cp525"] +[ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="7_n1l4q"] [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_ygl0i"] transparency = 2 alpha_scissor_threshold = 0.5 alpha_antialiasing_mode = 0 -albedo_texture = ExtResource("1_s6gun") +albedo_texture = ExtResource("2_6d44d") metallic = 1.0 -metallic_texture = ExtResource("2_qivrt") -roughness_texture = ExtResource("4_hco3w") +metallic_texture = ExtResource("3_jdl4v") +roughness_texture = ExtResource("5_6xe2u") normal_enabled = true -normal_texture = ExtResource("3_t575c") +normal_texture = ExtResource("4_yjujg") texture_filter = 2 [sub_resource type="ConcavePolygonShape3D" id="ConcavePolygonShape3D_qcskp"] data = PackedVector3Array(-0.3, -0.46, 0.52, -0.34, -0.46, 0.52, -0.3, -0.4883, 0.5317, -0.3, -0.4883, 0.5317, -0.34, -0.46, 0.52, -0.34, -0.4883, 0.5317, -0.3, -0.4883, 0.5317, -0.34, -0.4883, 0.5317, -0.3, -0.5, 0.56, -0.3, -0.5, 0.56, -0.34, -0.4883, 0.5317, -0.34, -0.5, 0.56, -0.3, -0.5, 0.56, -0.34, -0.5, 0.56, -0.3, -0.4883, 0.5883, -0.3, -0.4883, 0.5883, -0.34, -0.5, 0.56, -0.34, -0.4883, 0.5883, -0.3, -0.4883, 0.5883, -0.34, -0.4883, 0.5883, -0.3, -0.46, 0.6, -0.3, -0.46, 0.6, -0.34, -0.4883, 0.5883, -0.34, -0.46, 0.6, -0.3, -0.46, 0.6, -0.34, -0.46, 0.6, -0.3, -0.4317, 0.5883, -0.3, -0.4317, 0.5883, -0.34, -0.46, 0.6, -0.34, -0.4317, 0.5883, -0.3, -0.4317, 0.5883, -0.34, -0.4317, 0.5883, -0.3, -0.42, 0.56, -0.3, -0.42, 0.56, -0.34, -0.4317, 0.5883, -0.34, -0.42, 0.56, -0.3, -0.46, 0.52, -0.3, -0.4883, 0.5317, -0.3, -0.4317, 0.5317, -0.3, -0.4317, 0.5317, -0.3, -0.4883, 0.5317, -0.3, -0.42, 0.56, -0.3, -0.42, 0.56, -0.3, -0.4883, 0.5317, -0.3, -0.4317, 0.5883, -0.3, -0.4317, 0.5883, -0.3, -0.4883, 0.5317, -0.3, -0.46, 0.6, -0.3, -0.46, 0.6, -0.3, -0.4883, 0.5317, -0.3, -0.4883, 0.5883, -0.3, -0.4883, 0.5883, -0.3, -0.4883, 0.5317, -0.3, -0.5, 0.56, -0.3, -0.42, 0.56, -0.34, -0.42, 0.56, -0.3, -0.4317, 0.5317, -0.3, -0.4317, 0.5317, -0.34, -0.42, 0.56, -0.34, -0.4317, 0.5317, -0.3, -0.4317, 0.5317, -0.34, -0.4317, 0.5317, -0.3, -0.46, 0.52, -0.3, -0.46, 0.52, -0.34, -0.4317, 0.5317, -0.34, -0.46, 0.52, -0.34, -0.4883, 0.5317, -0.34, -0.46, 0.52, -0.34, -0.5, 0.56, -0.34, -0.5, 0.56, -0.34, -0.46, 0.52, -0.34, -0.4883, 0.5883, -0.34, -0.4883, 0.5883, -0.34, -0.46, 0.52, -0.34, -0.46, 0.6, -0.34, -0.46, 0.6, -0.34, -0.46, 0.52, -0.34, -0.4317, 0.5883, -0.34, -0.4317, 0.5883, -0.34, -0.46, 0.52, -0.34, -0.42, 0.56, -0.34, -0.42, 0.56, -0.34, -0.46, 0.52, -0.34, -0.4317, 0.5317, -0.3, -0.46, -0.6, -0.34, -0.46, -0.6, -0.3, -0.4883, -0.5883, -0.3, -0.4883, -0.5883, -0.34, -0.46, -0.6, -0.34, -0.4883, -0.5883, -0.3, -0.4883, -0.5883, -0.34, -0.4883, -0.5883, -0.3, -0.5, -0.56, -0.3, -0.5, -0.56, -0.34, -0.4883, -0.5883, -0.34, -0.5, -0.56, -0.3, -0.5, -0.56, -0.34, -0.5, -0.56, -0.3, -0.4883, -0.5317, -0.3, -0.4883, -0.5317, -0.34, -0.5, -0.56, -0.34, -0.4883, -0.5317, -0.3, -0.4883, -0.5317, -0.34, -0.4883, -0.5317, -0.3, -0.46, -0.52, -0.3, -0.46, -0.52, -0.34, -0.4883, -0.5317, -0.34, -0.46, -0.52, -0.3, -0.46, -0.52, -0.34, -0.46, -0.52, -0.3, -0.4317, -0.5317, -0.3, -0.4317, -0.5317, -0.34, -0.46, -0.52, -0.34, -0.4317, -0.5317, -0.3, -0.4317, -0.5317, -0.34, -0.4317, -0.5317, -0.3, -0.42, -0.56, -0.3, -0.42, -0.56, -0.34, -0.4317, -0.5317, -0.34, -0.42, -0.56, -0.3, -0.46, -0.6, -0.3, -0.4883, -0.5883, -0.3, -0.4317, -0.5883, -0.3, -0.4317, -0.5883, -0.3, -0.4883, -0.5883, -0.3, -0.42, -0.56, -0.3, -0.42, -0.56, -0.3, -0.4883, -0.5883, -0.3, -0.4317, -0.5317, -0.3, -0.4317, -0.5317, -0.3, -0.4883, -0.5883, -0.3, -0.46, -0.52, -0.3, -0.46, -0.52, -0.3, -0.4883, -0.5883, -0.3, -0.4883, -0.5317, -0.3, -0.4883, -0.5317, -0.3, -0.4883, -0.5883, -0.3, -0.5, -0.56, -0.3, -0.42, -0.56, -0.34, -0.42, -0.56, -0.3, -0.4317, -0.5883, -0.3, -0.4317, -0.5883, -0.34, -0.42, -0.56, -0.34, -0.4317, -0.5883, -0.3, -0.4317, -0.5883, -0.34, -0.4317, -0.5883, -0.3, -0.46, -0.6, -0.3, -0.46, -0.6, -0.34, -0.4317, -0.5883, -0.34, -0.46, -0.6, -0.34, -0.4883, -0.5883, -0.34, -0.46, -0.6, -0.34, -0.5, -0.56, -0.34, -0.5, -0.56, -0.34, -0.46, -0.6, -0.34, -0.4883, -0.5317, -0.34, -0.4883, -0.5317, -0.34, -0.46, -0.6, -0.34, -0.46, -0.52, -0.34, -0.46, -0.52, -0.34, -0.46, -0.6, -0.34, -0.4317, -0.5317, -0.34, -0.4317, -0.5317, -0.34, -0.46, -0.6, -0.34, -0.42, -0.56, -0.34, -0.42, -0.56, -0.34, -0.46, -0.6, -0.34, -0.4317, -0.5883, 0.34, -0.46, 0.52, 0.3, -0.46, 0.52, 0.34, -0.4883, 0.5317, 0.34, -0.4883, 0.5317, 0.3, -0.46, 0.52, 0.3, -0.4883, 0.5317, 0.34, -0.4883, 0.5317, 0.3, -0.4883, 0.5317, 0.34, -0.5, 0.56, 0.34, -0.5, 0.56, 0.3, -0.4883, 0.5317, 0.3, -0.5, 0.56, 0.34, -0.5, 0.56, 0.3, -0.5, 0.56, 0.34, -0.4883, 0.5883, 0.34, -0.4883, 0.5883, 0.3, -0.5, 0.56, 0.3, -0.4883, 0.5883, 0.34, -0.4883, 0.5883, 0.3, -0.4883, 0.5883, 0.34, -0.46, 0.6, 0.34, -0.46, 0.6, 0.3, -0.4883, 0.5883, 0.3, -0.46, 0.6, 0.34, -0.46, 0.6, 0.3, -0.46, 0.6, 0.34, -0.4317, 0.5883, 0.34, -0.4317, 0.5883, 0.3, -0.46, 0.6, 0.3, -0.4317, 0.5883, 0.34, -0.4317, 0.5883, 0.3, -0.4317, 0.5883, 0.34, -0.42, 0.56, 0.34, -0.42, 0.56, 0.3, -0.4317, 0.5883, 0.3, -0.42, 0.56, 0.34, -0.46, 0.52, 0.34, -0.4883, 0.5317, 0.34, -0.4317, 0.5317, 0.34, -0.4317, 0.5317, 0.34, -0.4883, 0.5317, 0.34, -0.42, 0.56, 0.34, -0.42, 0.56, 0.34, -0.4883, 0.5317, 0.34, -0.4317, 0.5883, 0.34, -0.4317, 0.5883, 0.34, -0.4883, 0.5317, 0.34, -0.46, 0.6, 0.34, -0.46, 0.6, 0.34, -0.4883, 0.5317, 0.34, -0.4883, 0.5883, 0.34, -0.4883, 0.5883, 0.34, -0.4883, 0.5317, 0.34, -0.5, 0.56, 0.34, -0.42, 0.56, 0.3, -0.42, 0.56, 0.34, -0.4317, 0.5317, 0.34, -0.4317, 0.5317, 0.3, -0.42, 0.56, 0.3, -0.4317, 0.5317, 0.34, -0.4317, 0.5317, 0.3, -0.4317, 0.5317, 0.34, -0.46, 0.52, 0.34, -0.46, 0.52, 0.3, -0.4317, 0.5317, 0.3, -0.46, 0.52, 0.3, -0.4883, 0.5317, 0.3, -0.46, 0.52, 0.3, -0.5, 0.56, 0.3, -0.5, 0.56, 0.3, -0.46, 0.52, 0.3, -0.4883, 0.5883, 0.3, -0.4883, 0.5883, 0.3, -0.46, 0.52, 0.3, -0.46, 0.6, 0.3, -0.46, 0.6, 0.3, -0.46, 0.52, 0.3, -0.4317, 0.5883, 0.3, -0.4317, 0.5883, 0.3, -0.46, 0.52, 0.3, -0.42, 0.56, 0.3, -0.42, 0.56, 0.3, -0.46, 0.52, 0.3, -0.4317, 0.5317, 0.34, -0.46, -0.6, 0.3, -0.46, -0.6, 0.34, -0.4883, -0.5883, 0.34, -0.4883, -0.5883, 0.3, -0.46, -0.6, 0.3, -0.4883, -0.5883, 0.34, -0.4883, -0.5883, 0.3, -0.4883, -0.5883, 0.34, -0.5, -0.56, 0.34, -0.5, -0.56, 0.3, -0.4883, -0.5883, 0.3, -0.5, -0.56, 0.34, -0.5, -0.56, 0.3, -0.5, -0.56, 0.34, -0.4883, -0.5317, 0.34, -0.4883, -0.5317, 0.3, -0.5, -0.56, 0.3, -0.4883, -0.5317, 0.34, -0.4883, -0.5317, 0.3, -0.4883, -0.5317, 0.34, -0.46, -0.52, 0.34, -0.46, -0.52, 0.3, -0.4883, -0.5317, 0.3, -0.46, -0.52, 0.34, -0.46, -0.52, 0.3, -0.46, -0.52, 0.34, -0.4317, -0.5317, 0.34, -0.4317, -0.5317, 0.3, -0.46, -0.52, 0.3, -0.4317, -0.5317, 0.34, -0.4317, -0.5317, 0.3, -0.4317, -0.5317, 0.34, -0.42, -0.56, 0.34, -0.42, -0.56, 0.3, -0.4317, -0.5317, 0.3, -0.42, -0.56, 0.34, -0.46, -0.6, 0.34, -0.4883, -0.5883, 0.34, -0.4317, -0.5883, 0.34, -0.4317, -0.5883, 0.34, -0.4883, -0.5883, 0.34, -0.42, -0.56, 0.34, -0.42, -0.56, 0.34, -0.4883, -0.5883, 0.34, -0.4317, -0.5317, 0.34, -0.4317, -0.5317, 0.34, -0.4883, -0.5883, 0.34, -0.46, -0.52, 0.34, -0.46, -0.52, 0.34, -0.4883, -0.5883, 0.34, -0.4883, -0.5317, 0.34, -0.4883, -0.5317, 0.34, -0.4883, -0.5883, 0.34, -0.5, -0.56, 0.34, -0.42, -0.56, 0.3, -0.42, -0.56, 0.34, -0.4317, -0.5883, 0.34, -0.4317, -0.5883, 0.3, -0.42, -0.56, 0.3, -0.4317, -0.5883, 0.34, -0.4317, -0.5883, 0.3, -0.4317, -0.5883, 0.34, -0.46, -0.6, 0.34, -0.46, -0.6, 0.3, -0.4317, -0.5883, 0.3, -0.46, -0.6, 0.3, -0.4883, -0.5883, 0.3, -0.46, -0.6, 0.3, -0.5, -0.56, 0.3, -0.5, -0.56, 0.3, -0.46, -0.6, 0.3, -0.4883, -0.5317, 0.3, -0.4883, -0.5317, 0.3, -0.46, -0.6, 0.3, -0.46, -0.52, 0.3, -0.46, -0.52, 0.3, -0.46, -0.6, 0.3, -0.4317, -0.5317, 0.3, -0.4317, -0.5317, 0.3, -0.46, -0.6, 0.3, -0.42, -0.56, 0.3, -0.42, -0.56, 0.3, -0.46, -0.6, 0.3, -0.4317, -0.5883, 0.29, -0.4203, -0.56, 0.32, -0.42, -0.53, 0.32, -0.48, -0.56, -0.29, -0.4203, -0.56, -0.32, -0.42, -0.59, -0.32, -0.48, -0.56, -0.29, -0.4203, 0.56, -0.32, -0.42, 0.53, -0.32, -0.48, 0.56, 0.32, -0.42, -0.59, 0.29, -0.4203, -0.56, 0.32, -0.48, -0.56, -0.32, 0.47, 0.59, -0.35, 0.47, 0.56, -0.32, 0.5, 0.56, -0.32, 0.47, -0.59, -0.32, 0.5, -0.56, -0.35, 0.47, -0.56, 0.32, 0.47, 0.59, 0.32, 0.5, 0.56, 0.35, 0.47, 0.56, 0.35, 0.47, -0.56, 0.32, 0.5, -0.56, 0.32, 0.47, -0.59, -0.32, 0.5, 0.56, -0.35, 0.47, 0.56, -0.32, 0.47, 0.53, -0.32, 0.47, -0.53, -0.35, 0.47, -0.56, -0.32, 0.5, -0.56, 0.32, 0.5, -0.56, 0.35, 0.47, -0.56, 0.32, 0.47, -0.53, 0.32, 0.47, 0.53, 0.35, 0.47, 0.56, 0.32, 0.5, 0.56, -0.32, 0.47, 0.59, -0.32, -0.42, 0.59, -0.35, 0.47, 0.56, -0.35, 0.47, 0.56, -0.32, -0.42, 0.59, -0.35, -0.4197, 0.56, -0.32, -0.42, -0.59, -0.32, 0.47, -0.59, -0.35, -0.4197, -0.56, -0.35, -0.4197, -0.56, -0.32, 0.47, -0.59, -0.35, 0.47, -0.56, 0.32, 0.5, -0.56, -0.32, 0.5, -0.56, 0.32, 0.47, -0.59, 0.32, 0.47, -0.59, -0.32, 0.5, -0.56, -0.32, 0.47, -0.59, 0.35, -0.4197, -0.56, 0.35, 0.47, -0.56, 0.32, -0.42, -0.59, 0.32, -0.42, -0.59, 0.35, 0.47, -0.56, 0.32, 0.47, -0.59, 0.32, -0.42, 0.59, 0.32, 0.47, 0.59, 0.35, -0.4197, 0.56, 0.35, -0.4197, 0.56, 0.32, 0.47, 0.59, 0.35, 0.47, 0.56, -0.32, 0.5, 0.56, 0.32, 0.5, 0.56, -0.32, 0.47, 0.59, -0.32, 0.47, 0.59, 0.32, 0.5, 0.56, 0.32, 0.47, 0.59, 0.32, 0.47, -0.53, -0.32, 0.47, -0.53, 0.32, 0.5, -0.56, 0.32, 0.5, -0.56, -0.32, 0.47, -0.53, -0.32, 0.5, -0.56, 0.32, 0.5, 0.56, -0.32, 0.5, 0.56, 0.32, 0.47, 0.53, 0.32, 0.47, 0.53, -0.32, 0.5, 0.56, -0.32, 0.47, 0.53, 0.32, -0.42, -0.53, 0.32, 0.47, -0.53, 0.35, -0.4197, -0.56, 0.35, -0.4197, -0.56, 0.32, 0.47, -0.53, 0.35, 0.47, -0.56, 0.35, -0.4197, 0.56, 0.35, 0.47, 0.56, 0.32, -0.42, 0.53, 0.32, -0.42, 0.53, 0.35, 0.47, 0.56, 0.32, 0.47, 0.53, -0.32, -0.42, 0.53, -0.32, 0.47, 0.53, -0.35, -0.4197, 0.56, -0.35, -0.4197, 0.56, -0.32, 0.47, 0.53, -0.35, 0.47, 0.56, -0.35, -0.4197, -0.56, -0.35, 0.47, -0.56, -0.32, -0.42, -0.53, -0.32, -0.42, -0.53, -0.35, 0.47, -0.56, -0.32, 0.47, -0.53, 0.32, -0.42, -0.59, 0.32, 0.47, -0.59, 0.29, -0.4203, -0.56, 0.29, -0.4203, -0.56, 0.32, 0.47, -0.59, 0.29, 0.44, -0.56, 0.32, -0.42, 0.53, 0.32, 0.47, 0.53, 0.29, -0.4203, 0.56, 0.29, -0.4203, 0.56, 0.32, 0.47, 0.53, 0.29, 0.44, 0.56, 0.32, 0.47, -0.53, 0.32, -0.42, -0.53, 0.29, 0.44, -0.56, 0.29, 0.44, -0.56, 0.32, -0.42, -0.53, 0.29, -0.4203, -0.56, 0.32, 0.47, 0.59, 0.32, -0.42, 0.59, 0.29, 0.44, 0.56, 0.29, 0.44, 0.56, 0.32, -0.42, 0.59, 0.29, -0.4203, 0.56, -0.29, -0.4203, -0.56, -0.29, 0.44, -0.56, -0.32, -0.42, -0.59, -0.32, -0.42, -0.59, -0.29, 0.44, -0.56, -0.32, 0.47, -0.59, -0.29, -0.4203, 0.56, -0.29, 0.44, 0.56, -0.32, -0.42, 0.53, -0.32, -0.42, 0.53, -0.29, 0.44, 0.56, -0.32, 0.47, 0.53, 0.32, 0.47, -0.59, -0.32, 0.47, -0.59, 0.29, 0.44, -0.56, 0.29, 0.44, -0.56, -0.32, 0.47, -0.59, -0.29, 0.44, -0.56, 0.29, 0.44, -0.56, -0.29, 0.44, -0.56, 0.32, 0.47, -0.53, 0.32, 0.47, -0.53, -0.29, 0.44, -0.56, -0.32, 0.47, -0.53, 0.32, 0.47, 0.53, -0.32, 0.47, 0.53, 0.29, 0.44, 0.56, 0.29, 0.44, 0.56, -0.32, 0.47, 0.53, -0.29, 0.44, 0.56, 0.29, 0.44, 0.56, -0.29, 0.44, 0.56, 0.32, 0.47, 0.59, 0.32, 0.47, 0.59, -0.29, 0.44, 0.56, -0.32, 0.47, 0.59, -0.29, 0.44, -0.56, -0.29, -0.4203, -0.56, -0.32, 0.47, -0.53, -0.32, 0.47, -0.53, -0.29, -0.4203, -0.56, -0.32, -0.42, -0.53, -0.32, -0.42, 0.59, -0.32, 0.47, 0.59, -0.29, -0.4203, 0.56, -0.29, -0.4203, 0.56, -0.32, 0.47, 0.59, -0.29, 0.44, 0.56, 0.35, -0.4197, -0.56, 0.32, -0.42, -0.59, 0.32, -0.48, -0.56, 0.35, -0.4197, 0.56, 0.32, -0.42, 0.53, 0.32, -0.48, 0.56, -0.32, -0.42, 0.53, -0.35, -0.4197, 0.56, -0.32, -0.48, 0.56, -0.35, -0.4197, 0.56, -0.32, -0.42, 0.59, -0.32, -0.48, 0.56, -0.32, -0.42, 0.59, -0.29, -0.4203, 0.56, -0.32, -0.48, 0.56, 0.32, -0.42, -0.53, 0.35, -0.4197, -0.56, 0.32, -0.48, -0.56, 0.29, -0.4203, 0.56, 0.32, -0.42, 0.59, 0.32, -0.48, 0.56, 0.32, -0.42, 0.59, 0.35, -0.4197, 0.56, 0.32, -0.48, 0.56, -0.32, -0.42, -0.53, -0.29, -0.4203, -0.56, -0.32, -0.48, -0.56, -0.35, -0.4197, -0.56, -0.32, -0.42, -0.53, -0.32, -0.48, -0.56, 0.32, -0.42, 0.53, 0.29, -0.4203, 0.56, 0.32, -0.48, 0.56, -0.32, -0.42, -0.59, -0.35, -0.4197, -0.56, -0.32, -0.48, -0.56, -0.28, 0.23, -0.52, -0.28, 0.17, -0.52, -0.28, 0.23, -0.6, -0.28, 0.23, -0.6, -0.28, 0.17, -0.52, -0.28, 0.17, -0.6, -0.28, 0.23, -0.6, -0.28, 0.17, -0.6, 0.2801, 0.23, -0.6, 0.2801, 0.23, -0.6, -0.28, 0.17, -0.6, 0.2801, 0.17, -0.6, -0.28, 0.17, -0.52, -0.28, 0.23, -0.52, -0.35, 0.17, -0.52, -0.35, 0.17, -0.52, -0.28, 0.23, -0.52, -0.35, 0.23, -0.52, -0.28, 0.17, -0.52, -0.35, 0.17, -0.52, -0.28, 0.17, -0.6, -0.28, 0.17, 0.52, -0.35, 0.17, -0.52, -0.35, 0.17, 0.52, -0.28, 0.17, -0.6, -0.35, 0.17, -0.52, 0.2801, 0.17, -0.6, 0.2801, 0.17, -0.6, -0.35, 0.17, -0.52, 0.2801, 0.17, -0.52, 0.2801, 0.17, -0.52, -0.35, 0.17, -0.52, 0.35, 0.17, -0.52, 0.35, 0.17, -0.52, -0.35, 0.17, -0.52, 0.35, 0.17, 0.52, 0.35, 0.17, 0.52, -0.35, 0.17, -0.52, 0.2799, 0.17, 0.52, 0.2799, 0.17, 0.52, -0.35, 0.17, -0.52, 0.2799, 0.17, 0.6, 0.2799, 0.17, 0.6, -0.35, 0.17, -0.52, -0.28, 0.17, 0.6, -0.28, 0.17, 0.6, -0.35, 0.17, -0.52, -0.28, 0.17, 0.52, 0.35, 0.23, -0.52, 0.35, 0.17, -0.52, 0.35, 0.23, 0.52, 0.35, 0.23, 0.52, 0.35, 0.17, -0.52, 0.35, 0.17, 0.52, 0.2001, 0.2, -0.44, 0.27, 0.2, -0.44, 0.2001, 0.2, -0.52, 0.1999, 0.2, 0.44, 0.27, 0.2, -0.44, 0.27, 0.2, 0.44, 0.2001, 0.2, -0.52, 0.27, 0.2, -0.44, -0.2, 0.2, -0.52, -0.2, 0.2, -0.52, 0.27, 0.2, -0.44, -0.2, 0.2, -0.44, -0.2, 0.2, -0.44, 0.27, 0.2, -0.44, -0.27, 0.2, -0.44, -0.27, 0.2, -0.44, 0.27, 0.2, -0.44, -0.27, 0.2, 0.44, -0.27, 0.2, 0.44, 0.27, 0.2, -0.44, -0.2, 0.2, 0.44, -0.2, 0.2, 0.44, 0.27, 0.2, -0.44, -0.2, 0.2, 0.52, -0.2, 0.2, 0.52, 0.27, 0.2, -0.44, 0.1999, 0.2, 0.52, 0.1999, 0.2, 0.52, 0.27, 0.2, -0.44, 0.1999, 0.2, 0.44, 0.2801, 0.23, -0.52, 0.2801, 0.17, -0.52, 0.35, 0.23, -0.52, 0.35, 0.23, -0.52, 0.2801, 0.17, -0.52, 0.35, 0.17, -0.52, 0.2801, 0.17, -0.52, 0.2801, 0.23, -0.52, 0.2801, 0.17, -0.6, 0.2801, 0.17, -0.6, 0.2801, 0.23, -0.52, 0.2801, 0.23, -0.6, -0.28, 0.17, 0.52, -0.28, 0.23, 0.52, -0.28, 0.17, 0.6, -0.28, 0.17, 0.6, -0.28, 0.23, 0.52, -0.28, 0.23, 0.6, -0.35, 0.23, 0.52, -0.35, 0.17, 0.52, -0.35, 0.23, -0.52, -0.35, 0.23, -0.52, -0.35, 0.17, 0.52, -0.35, 0.17, -0.52, -0.28, 0.23, 0.52, -0.28, 0.17, 0.52, -0.35, 0.23, 0.52, -0.35, 0.23, 0.52, -0.28, 0.17, 0.52, -0.35, 0.17, 0.52, 0.2799, 0.23, 0.6, 0.2799, 0.17, 0.6, -0.28, 0.23, 0.6, -0.28, 0.23, 0.6, 0.2799, 0.17, 0.6, -0.28, 0.17, 0.6, 0.2799, 0.23, 0.52, 0.2799, 0.17, 0.52, 0.2799, 0.23, 0.6, 0.2799, 0.23, 0.6, 0.2799, 0.17, 0.52, 0.2799, 0.17, 0.6, 0.2799, 0.17, 0.52, 0.2799, 0.23, 0.52, 0.35, 0.17, 0.52, 0.35, 0.17, 0.52, 0.2799, 0.23, 0.52, 0.35, 0.23, 0.52, -0.28, -0.27, -0.52, -0.28, -0.33, -0.52, -0.28, -0.27, -0.6, -0.28, -0.27, -0.6, -0.28, -0.33, -0.52, -0.28, -0.33, -0.6, -0.28, -0.27, -0.6, -0.28, -0.33, -0.6, 0.2801, -0.27, -0.6, 0.2801, -0.27, -0.6, -0.28, -0.33, -0.6, 0.2801, -0.33, -0.6, -0.28, -0.33, -0.52, -0.28, -0.27, -0.52, -0.35, -0.33, -0.52, -0.35, -0.33, -0.52, -0.28, -0.27, -0.52, -0.35, -0.27, -0.52, -0.28, -0.33, -0.52, -0.35, -0.33, -0.52, -0.28, -0.33, -0.6, -0.28, -0.33, 0.52, -0.35, -0.33, -0.52, -0.35, -0.33, 0.52, -0.28, -0.33, -0.6, -0.35, -0.33, -0.52, 0.2801, -0.33, -0.6, 0.2801, -0.33, -0.6, -0.35, -0.33, -0.52, 0.2801, -0.33, -0.52, 0.2801, -0.33, -0.52, -0.35, -0.33, -0.52, 0.35, -0.33, -0.52, 0.35, -0.33, -0.52, -0.35, -0.33, -0.52, 0.35, -0.33, 0.52, 0.35, -0.33, 0.52, -0.35, -0.33, -0.52, 0.2799, -0.33, 0.52, 0.2799, -0.33, 0.52, -0.35, -0.33, -0.52, 0.2799, -0.33, 0.6, 0.2799, -0.33, 0.6, -0.35, -0.33, -0.52, -0.28, -0.33, 0.6, -0.28, -0.33, 0.6, -0.35, -0.33, -0.52, -0.28, -0.33, 0.52, 0.35, -0.27, -0.52, 0.35, -0.33, -0.52, 0.35, -0.27, 0.52, 0.35, -0.27, 0.52, 0.35, -0.33, -0.52, 0.35, -0.33, 0.52, 0.2001, -0.3, -0.44, 0.27, -0.3, -0.44, 0.2001, -0.3, -0.52, 0.1999, -0.3, 0.44, 0.27, -0.3, -0.44, 0.27, -0.3, 0.44, 0.2001, -0.3, -0.52, 0.27, -0.3, -0.44, -0.2, -0.3, -0.52, -0.2, -0.3, -0.52, 0.27, -0.3, -0.44, -0.2, -0.3, -0.44, -0.2, -0.3, -0.44, 0.27, -0.3, -0.44, -0.27, -0.3, -0.44, -0.27, -0.3, -0.44, 0.27, -0.3, -0.44, -0.27, -0.3, 0.44, -0.27, -0.3, 0.44, 0.27, -0.3, -0.44, -0.2, -0.3, 0.44, -0.2, -0.3, 0.44, 0.27, -0.3, -0.44, -0.2, -0.3, 0.52, -0.2, -0.3, 0.52, 0.27, -0.3, -0.44, 0.1999, -0.3, 0.52, 0.1999, -0.3, 0.52, 0.27, -0.3, -0.44, 0.1999, -0.3, 0.44, 0.2801, -0.27, -0.52, 0.2801, -0.33, -0.52, 0.35, -0.27, -0.52, 0.35, -0.27, -0.52, 0.2801, -0.33, -0.52, 0.35, -0.33, -0.52, 0.2801, -0.33, -0.52, 0.2801, -0.27, -0.52, 0.2801, -0.33, -0.6, 0.2801, -0.33, -0.6, 0.2801, -0.27, -0.52, 0.2801, -0.27, -0.6, -0.28, -0.33, 0.52, -0.28, -0.27, 0.52, -0.28, -0.33, 0.6, -0.28, -0.33, 0.6, -0.28, -0.27, 0.52, -0.28, -0.27, 0.6, -0.35, -0.27, 0.52, -0.35, -0.33, 0.52, -0.35, -0.27, -0.52, -0.35, -0.27, -0.52, -0.35, -0.33, 0.52, -0.35, -0.33, -0.52, -0.28, -0.27, 0.52, -0.28, -0.33, 0.52, -0.35, -0.27, 0.52, -0.35, -0.27, 0.52, -0.28, -0.33, 0.52, -0.35, -0.33, 0.52, 0.2799, -0.27, 0.6, 0.2799, -0.33, 0.6, -0.28, -0.27, 0.6, -0.28, -0.27, 0.6, 0.2799, -0.33, 0.6, -0.28, -0.33, 0.6, 0.2799, -0.27, 0.52, 0.2799, -0.33, 0.52, 0.2799, -0.27, 0.6, 0.2799, -0.27, 0.6, 0.2799, -0.33, 0.52, 0.2799, -0.33, 0.6, 0.2799, -0.33, 0.52, 0.2799, -0.27, 0.52, 0.35, -0.33, 0.52, 0.35, -0.33, 0.52, 0.2799, -0.27, 0.52, 0.35, -0.27, 0.52, -0.24, 0.23, -0.56, -0.24, 0.23, -0.48, -0.28, 0.23, -0.6, -0.28, 0.23, -0.6, -0.24, 0.23, -0.48, -0.28, 0.23, -0.52, 0.2801, 0.23, -0.6, -0.24, 0.23, -0.56, -0.28, 0.23, -0.6, -0.24, 0.23, -0.48, -0.31, 0.23, -0.48, -0.28, 0.23, -0.52, 0.2401, 0.23, -0.56, -0.24, 0.23, -0.56, 0.2801, 0.23, -0.6, -0.28, 0.23, -0.52, -0.31, 0.23, -0.48, -0.35, 0.23, -0.52, 0.2801, 0.23, -0.52, 0.2401, 0.23, -0.56, 0.2801, 0.23, -0.6, -0.31, 0.23, -0.48, -0.31, 0.23, 0.48, -0.35, 0.23, -0.52, 0.2401, 0.23, -0.48, 0.2401, 0.23, -0.56, 0.2801, 0.23, -0.52, -0.35, 0.23, -0.52, -0.31, 0.23, 0.48, -0.35, 0.23, 0.52, 0.35, 0.23, -0.52, 0.2401, 0.23, -0.48, 0.2801, 0.23, -0.52, -0.31, 0.23, 0.48, -0.24, 0.23, 0.48, -0.35, 0.23, 0.52, 0.31, 0.23, -0.48, 0.2401, 0.23, -0.48, 0.35, 0.23, -0.52, -0.35, 0.23, 0.52, -0.24, 0.23, 0.48, -0.28, 0.23, 0.52, 0.35, 0.23, 0.52, 0.31, 0.23, -0.48, 0.35, 0.23, -0.52, -0.24, 0.23, 0.48, -0.24, 0.23, 0.56, -0.28, 0.23, 0.52, 0.31, 0.23, 0.48, 0.31, 0.23, -0.48, 0.35, 0.23, 0.52, -0.28, 0.23, 0.52, -0.24, 0.23, 0.56, -0.28, 0.23, 0.6, 0.2799, 0.23, 0.52, 0.31, 0.23, 0.48, 0.35, 0.23, 0.52, -0.24, 0.23, 0.56, 0.2399, 0.23, 0.56, -0.28, 0.23, 0.6, 0.2399, 0.23, 0.48, 0.31, 0.23, 0.48, 0.2799, 0.23, 0.52, -0.28, 0.23, 0.6, 0.2399, 0.23, 0.56, 0.2799, 0.23, 0.6, 0.2399, 0.23, 0.56, 0.2399, 0.23, 0.48, 0.2799, 0.23, 0.6, 0.2799, 0.23, 0.6, 0.2399, 0.23, 0.48, 0.2799, 0.23, 0.52, -0.24, -0.27, -0.56, -0.24, -0.27, -0.48, -0.28, -0.27, -0.6, -0.28, -0.27, -0.6, -0.24, -0.27, -0.48, -0.28, -0.27, -0.52, 0.2801, -0.27, -0.6, -0.24, -0.27, -0.56, -0.28, -0.27, -0.6, -0.24, -0.27, -0.48, -0.31, -0.27, -0.48, -0.28, -0.27, -0.52, 0.2401, -0.27, -0.56, -0.24, -0.27, -0.56, 0.2801, -0.27, -0.6, -0.28, -0.27, -0.52, -0.31, -0.27, -0.48, -0.35, -0.27, -0.52, 0.2801, -0.27, -0.52, 0.2401, -0.27, -0.56, 0.2801, -0.27, -0.6, -0.31, -0.27, -0.48, -0.31, -0.27, 0.48, -0.35, -0.27, -0.52, 0.2401, -0.27, -0.48, 0.2401, -0.27, -0.56, 0.2801, -0.27, -0.52, -0.35, -0.27, -0.52, -0.31, -0.27, 0.48, -0.35, -0.27, 0.52, 0.35, -0.27, -0.52, 0.2401, -0.27, -0.48, 0.2801, -0.27, -0.52, -0.31, -0.27, 0.48, -0.24, -0.27, 0.48, -0.35, -0.27, 0.52, 0.31, -0.27, -0.48, 0.2401, -0.27, -0.48, 0.35, -0.27, -0.52, -0.35, -0.27, 0.52, -0.24, -0.27, 0.48, -0.28, -0.27, 0.52, 0.35, -0.27, 0.52, 0.31, -0.27, -0.48, 0.35, -0.27, -0.52, -0.24, -0.27, 0.48, -0.24, -0.27, 0.56, -0.28, -0.27, 0.52, 0.31, -0.27, 0.48, 0.31, -0.27, -0.48, 0.35, -0.27, 0.52, -0.28, -0.27, 0.52, -0.24, -0.27, 0.56, -0.28, -0.27, 0.6, 0.2799, -0.27, 0.52, 0.31, -0.27, 0.48, 0.35, -0.27, 0.52, -0.24, -0.27, 0.56, 0.2399, -0.27, 0.56, -0.28, -0.27, 0.6, 0.2399, -0.27, 0.48, 0.31, -0.27, 0.48, 0.2799, -0.27, 0.52, -0.28, -0.27, 0.6, 0.2399, -0.27, 0.56, 0.2799, -0.27, 0.6, 0.2399, -0.27, 0.56, 0.2399, -0.27, 0.48, 0.2799, -0.27, 0.6, 0.2799, -0.27, 0.6, 0.2399, -0.27, 0.48, 0.2799, -0.27, 0.52, -0.2, 0.2, -0.52, -0.2, 0.2, -0.44, -0.24, 0.23, -0.56, -0.24, 0.23, -0.56, -0.2, 0.2, -0.44, -0.24, 0.23, -0.48, -0.2, 0.2, -0.44, -0.27, 0.2, -0.44, -0.24, 0.23, -0.48, -0.24, 0.23, -0.48, -0.27, 0.2, -0.44, -0.31, 0.23, -0.48, -0.27, 0.2, -0.44, -0.27, 0.2, 0.44, -0.31, 0.23, -0.48, -0.31, 0.23, -0.48, -0.27, 0.2, 0.44, -0.31, 0.23, 0.48, 0.2001, 0.2, -0.44, 0.2001, 0.2, -0.52, 0.2401, 0.23, -0.48, 0.2401, 0.23, -0.48, 0.2001, 0.2, -0.52, 0.2401, 0.23, -0.56, 0.27, 0.2, -0.44, 0.2001, 0.2, -0.44, 0.31, 0.23, -0.48, 0.31, 0.23, -0.48, 0.2001, 0.2, -0.44, 0.2401, 0.23, -0.48, 0.2001, 0.2, -0.52, -0.2, 0.2, -0.52, 0.2401, 0.23, -0.56, 0.2401, 0.23, -0.56, -0.2, 0.2, -0.52, -0.24, 0.23, -0.56, -0.2, 0.2, 0.44, -0.2, 0.2, 0.52, -0.24, 0.23, 0.48, -0.24, 0.23, 0.48, -0.2, 0.2, 0.52, -0.24, 0.23, 0.56, -0.27, 0.2, 0.44, -0.2, 0.2, 0.44, -0.31, 0.23, 0.48, -0.31, 0.23, 0.48, -0.2, 0.2, 0.44, -0.24, 0.23, 0.48, -0.2, 0.2, 0.52, 0.1999, 0.2, 0.52, -0.24, 0.23, 0.56, -0.24, 0.23, 0.56, 0.1999, 0.2, 0.52, 0.2399, 0.23, 0.56, 0.1999, 0.2, 0.44, 0.27, 0.2, 0.44, 0.2399, 0.23, 0.48, 0.2399, 0.23, 0.48, 0.27, 0.2, 0.44, 0.31, 0.23, 0.48, 0.1999, 0.2, 0.52, 0.1999, 0.2, 0.44, 0.2399, 0.23, 0.56, 0.2399, 0.23, 0.56, 0.1999, 0.2, 0.44, 0.2399, 0.23, 0.48, 0.27, 0.2, 0.44, 0.27, 0.2, -0.44, 0.31, 0.23, 0.48, 0.31, 0.23, 0.48, 0.27, 0.2, -0.44, 0.31, 0.23, -0.48, -0.2, -0.3, -0.52, -0.2, -0.3, -0.44, -0.24, -0.27, -0.56, -0.24, -0.27, -0.56, -0.2, -0.3, -0.44, -0.24, -0.27, -0.48, -0.2, -0.3, -0.44, -0.27, -0.3, -0.44, -0.24, -0.27, -0.48, -0.24, -0.27, -0.48, -0.27, -0.3, -0.44, -0.31, -0.27, -0.48, -0.27, -0.3, -0.44, -0.27, -0.3, 0.44, -0.31, -0.27, -0.48, -0.31, -0.27, -0.48, -0.27, -0.3, 0.44, -0.31, -0.27, 0.48, 0.2001, -0.3, -0.44, 0.2001, -0.3, -0.52, 0.2401, -0.27, -0.48, 0.2401, -0.27, -0.48, 0.2001, -0.3, -0.52, 0.2401, -0.27, -0.56, 0.27, -0.3, -0.44, 0.2001, -0.3, -0.44, 0.31, -0.27, -0.48, 0.31, -0.27, -0.48, 0.2001, -0.3, -0.44, 0.2401, -0.27, -0.48, 0.2001, -0.3, -0.52, -0.2, -0.3, -0.52, 0.2401, -0.27, -0.56, 0.2401, -0.27, -0.56, -0.2, -0.3, -0.52, -0.24, -0.27, -0.56, -0.2, -0.3, 0.44, -0.2, -0.3, 0.52, -0.24, -0.27, 0.48, -0.24, -0.27, 0.48, -0.2, -0.3, 0.52, -0.24, -0.27, 0.56, -0.27, -0.3, 0.44, -0.2, -0.3, 0.44, -0.31, -0.27, 0.48, -0.31, -0.27, 0.48, -0.2, -0.3, 0.44, -0.24, -0.27, 0.48, -0.2, -0.3, 0.52, 0.1999, -0.3, 0.52, -0.24, -0.27, 0.56, -0.24, -0.27, 0.56, 0.1999, -0.3, 0.52, 0.2399, -0.27, 0.56, 0.1999, -0.3, 0.44, 0.27, -0.3, 0.44, 0.2399, -0.27, 0.48, 0.2399, -0.27, 0.48, 0.27, -0.3, 0.44, 0.31, -0.27, 0.48, 0.1999, -0.3, 0.52, 0.1999, -0.3, 0.44, 0.2399, -0.27, 0.56, 0.2399, -0.27, 0.56, 0.1999, -0.3, 0.44, 0.2399, -0.27, 0.48, 0.27, -0.3, 0.44, 0.27, -0.3, -0.44, 0.31, -0.27, 0.48, 0.31, -0.27, 0.48, 0.27, -0.3, -0.44, 0.31, -0.27, -0.48) -[node name="MedCart" type="MeshInstance3D"] -mesh = ExtResource("1_hco3w") +[node name="StaticMedCart" type="MeshInstance3D"] +mesh = ExtResource("1_lt7v2") surface_material_override/0 = SubResource("StandardMaterial3D_ygl0i") -[node name="GunkBody" parent="." groups=["PlasticMaterial"] instance=ExtResource("5_hco3w")] -mask_dim = 96 -source_gunk_material = ExtResource("6_t575c") +[node name="StaticBody3D" type="StaticBody3D" parent="." groups=["PlasticMaterial"]] +collision_layer = 5 +collision_mask = 0 -[node name="CollisionShape3D" type="CollisionShape3D" parent="GunkBody"] +[node name="CollisionShape3D" type="CollisionShape3D" parent="StaticBody3D"] shape = SubResource("ConcavePolygonShape3D_qcskp") + +[node name="Gunkable" parent="StaticBody3D" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("6_cp525")] +mask_dim = 96 +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("7_n1l4q") diff --git a/src/props/operating_table/operating_table.tscn b/src/props/operating_table/operating_table.tscn index e572142..fe53555 100644 --- a/src/props/operating_table/operating_table.tscn +++ b/src/props/operating_table/operating_table.tscn @@ -1,11 +1,12 @@ -[gd_scene load_steps=9 format=3 uid="uid://oipf3w7hm5gf"] +[gd_scene load_steps=10 format=3 uid="uid://oipf3w7hm5gf"] [ext_resource type="ArrayMesh" uid="uid://c0nxj2li1pefb" path="res://assets/props/operating_table/operating_table.obj" id="1_pt2ft"] [ext_resource type="Texture2D" uid="uid://e7kat4x3brst" path="res://assets/props/operating_table/operating_table_C.png" id="2_73alj"] [ext_resource type="Texture2D" uid="uid://ctv1f41eefar0" path="res://assets/props/operating_table/operating_table_M.png" id="3_lhd0e"] [ext_resource type="Texture2D" uid="uid://uk3m431m6r0" path="res://assets/props/operating_table/operating_table_N.png" id="4_mevr1"] [ext_resource type="Texture2D" uid="uid://c4u3qvdtyoq4a" path="res://assets/props/operating_table/operating_table_R.png" id="5_lcrh2"] -[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="6_lhd0e"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="6_mevr1"] +[ext_resource type="Material" uid="uid://cqjr3cbxtfg2j" path="res://assets/materials/gunk.material" id="7_lcrh2"] [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_lhd0e"] albedo_texture = ExtResource("2_73alj") @@ -23,8 +24,15 @@ data = PackedVector3Array(-0.9749, 0.4, 0.5127, -0.9749, 0.3, 0.5127, -0.9715, 0 mesh = ExtResource("1_pt2ft") surface_material_override/0 = SubResource("StandardMaterial3D_lhd0e") -[node name="GunkBody" parent="." instance=ExtResource("6_lhd0e")] -mask_dim = 192 +[node name="StaticBody3D" type="StaticBody3D" parent="." groups=["MetalMaterial"]] +collision_layer = 5 +collision_mask = 0 -[node name="CollisionShape3D2" type="CollisionShape3D" parent="GunkBody"] +[node name="CollisionShape3D" type="CollisionShape3D" parent="StaticBody3D"] shape = SubResource("ConcavePolygonShape3D_5ju1e") + +[node name="Gunkable" parent="StaticBody3D" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("6_mevr1")] +mask_dim = 192 +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("7_lcrh2") diff --git a/src/props/overhead_light/burnout_light.tscn b/src/props/overhead_light/burnout_light.tscn index 96a9022..6f99d72 100644 --- a/src/props/overhead_light/burnout_light.tscn +++ b/src/props/overhead_light/burnout_light.tscn @@ -5,7 +5,7 @@ [ext_resource type="Texture2D" uid="uid://c3pfufk3r4611" path="res://assets/props/overhead_light/overhead_light_burnout_M.png" id="2_esawx"] [ext_resource type="Texture2D" uid="uid://buxuntbbfwvfg" path="res://assets/props/overhead_light/overhead_light_burnout_N.png" id="3_vg5ej"] [ext_resource type="Texture2D" uid="uid://c40m0iq5tot1a" path="res://assets/props/overhead_light/overhead_light_burnout_R.png" id="4_0f8x7"] -[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="5_qcusd"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="6_1oo6x"] [ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="6_8nypc"] [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_niury"] @@ -26,9 +26,15 @@ data = PackedVector3Array(0.4, -0.1, 0.75, 0.3, -0.2, 0.75, 0.4, 0, 0.75, 0.4, 0 mesh = ExtResource("1_esawx") surface_material_override/0 = SubResource("StandardMaterial3D_niury") -[node name="GunkBody" parent="MeshInstance3D" instance=ExtResource("5_qcusd")] -mask_dim = 64 -source_gunk_material = ExtResource("6_8nypc") +[node name="StaticBody3D" type="StaticBody3D" parent="MeshInstance3D"] +collision_layer = 5 +collision_mask = 0 -[node name="CollisionShape3D" type="CollisionShape3D" parent="MeshInstance3D/GunkBody"] +[node name="CollisionShape3D" type="CollisionShape3D" parent="MeshInstance3D/StaticBody3D"] shape = SubResource("ConcavePolygonShape3D_jad1v") + +[node name="Gunkable" parent="MeshInstance3D/StaticBody3D" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("6_1oo6x")] +mask_dim = 64 +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("6_8nypc") diff --git a/src/props/overhead_light/overhead_light.gd b/src/props/overhead_light/overhead_light.gd index 12fa614..e468fb3 100644 --- a/src/props/overhead_light/overhead_light.gd +++ b/src/props/overhead_light/overhead_light.gd @@ -4,18 +4,18 @@ extends Node3D @export var initial_mask: Texture @onready var spot_light_3d: SpotLight3D = %SpotLight3D -@onready var gunk_body: GunkBody = %GunkBody +@onready var gunkable: Gunkable = %Gunkable func _ready() -> void: if initial_mask: - gunk_body.initial_mask = initial_mask + gunkable.initial_mask = initial_mask _deferred_init.call_deferred() func _deferred_init() -> void: - gunk_body.trigger_recompute() + gunkable.trigger_recompute() func _on_clear_total_updated(clear_total: float) -> void: diff --git a/src/props/overhead_light/overhead_light.tscn b/src/props/overhead_light/overhead_light.tscn index b9b6204..043af0e 100644 --- a/src/props/overhead_light/overhead_light.tscn +++ b/src/props/overhead_light/overhead_light.tscn @@ -7,8 +7,8 @@ [ext_resource type="Texture2D" uid="uid://bh2jmk7jfjmyr" path="res://assets/props/overhead_light/overhead_light_M.png" id="3_ngq1d"] [ext_resource type="Texture2D" uid="uid://no4s7dsg8tih" path="res://assets/props/overhead_light/overhead_light_N.png" id="4_3gl0p"] [ext_resource type="Texture2D" uid="uid://cr5e4hk33wmwf" path="res://assets/props/overhead_light/overhead_light_R.png" id="5_210ch"] -[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="6_3gl0p"] [ext_resource type="Material" uid="uid://dutkfm4ek0ysh" path="res://assets/materials/gunk_bright.material" id="8_3gl0p"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="10_ljcul"] [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_ljcul"] resource_local_to_scene = true @@ -117,12 +117,18 @@ libraries = { } autoplay = "flicker" -[node name="GunkBody" parent="MeshInstance3D" instance=ExtResource("6_3gl0p")] -unique_name_in_owner = true -mask_dim = 64 -source_gunk_material = ExtResource("8_3gl0p") +[node name="StaticBody3D" type="StaticBody3D" parent="MeshInstance3D"] +collision_layer = 5 +collision_mask = 0 -[node name="CollisionShape3D" type="CollisionShape3D" parent="MeshInstance3D/GunkBody"] +[node name="CollisionShape3D" type="CollisionShape3D" parent="MeshInstance3D/StaticBody3D"] shape = SubResource("ConcavePolygonShape3D_jdrpd") -[connection signal="clear_total_updated" from="MeshInstance3D/GunkBody" to="." method="_on_clear_total_updated"] +[node name="Gunkable" parent="MeshInstance3D/StaticBody3D" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("10_ljcul")] +unique_name_in_owner = true +mask_dim = 64 +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("8_3gl0p") + +[connection signal="clear_total_updated" from="MeshInstance3D/StaticBody3D/Gunkable" to="." method="_on_clear_total_updated"] diff --git a/src/props/physics/persistent_prop.gd b/src/props/physics/persistent_prop.gd new file mode 100644 index 0000000..d3298c7 --- /dev/null +++ b/src/props/physics/persistent_prop.gd @@ -0,0 +1,18 @@ +extends RigidBody3D + + +func serialize() -> Dictionary: + return { + "transform": transform, + "linear_velocity": linear_velocity, + "angular_velocity": angular_velocity, + } + + +func deserialize(state: Dictionary) -> void: + @warning_ignore("unsafe_cast") + transform = state["transform"] as Transform3D + @warning_ignore("unsafe_cast") + linear_velocity = state["linear_velocity"] as Vector3 + @warning_ignore("unsafe_cast") + angular_velocity = state["angular_velocity"] as Vector3 diff --git a/src/props/physics/persistent_prop.gd.uid b/src/props/physics/persistent_prop.gd.uid new file mode 100644 index 0000000..a6d9e6e --- /dev/null +++ b/src/props/physics/persistent_prop.gd.uid @@ -0,0 +1 @@ +uid://sksndhqyo2bn diff --git a/src/props/railing/railing.tscn b/src/props/railing/railing.tscn index b4a088e..c4fa17a 100644 --- a/src/props/railing/railing.tscn +++ b/src/props/railing/railing.tscn @@ -5,8 +5,8 @@ [ext_resource type="Texture2D" uid="uid://dgyk61lmv3q66" path="res://assets/props/railing/railing_M.png" id="3_vgbo1"] [ext_resource type="Texture2D" uid="uid://cd142v5tbh10j" path="res://assets/props/railing/railing_N.png" id="4_d75t1"] [ext_resource type="Texture2D" uid="uid://tpweuhaqj3uy" path="res://assets/props/railing/railing_R.png" id="5_557y4"] -[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="6_vgbo1"] [ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="7_vgbo1"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="8_d75t1"] [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_nyaqk"] albedo_texture = ExtResource("2_2gmox") @@ -24,9 +24,15 @@ data = PackedVector3Array(1.475, 0.5, 0, 1.5, 0.5, 0.025, -1.475, 0.5, 0, -1.475 mesh = ExtResource("1_43h1k") surface_material_override/0 = SubResource("StandardMaterial3D_nyaqk") -[node name="GunkBody" parent="." instance=ExtResource("6_vgbo1")] -mask_dim = 128 -source_gunk_material = ExtResource("7_vgbo1") +[node name="StaticBody3D" type="StaticBody3D" parent="." groups=["MetalMaterial"]] +collision_layer = 5 +collision_mask = 0 -[node name="CollisionShape3D" type="CollisionShape3D" parent="GunkBody"] +[node name="CollisionShape3D" type="CollisionShape3D" parent="StaticBody3D"] shape = SubResource("ConcavePolygonShape3D_557y4") + +[node name="Gunkable" parent="StaticBody3D" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("8_d75t1")] +mask_dim = 128 +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("7_vgbo1") diff --git a/src/props/sofa/sofa.tscn b/src/props/sofa/sofa.tscn index 555c143..c2c952b 100644 --- a/src/props/sofa/sofa.tscn +++ b/src/props/sofa/sofa.tscn @@ -1,11 +1,12 @@ -[gd_scene load_steps=9 format=3 uid="uid://cvx5u0ttmri4q"] +[gd_scene load_steps=10 format=3 uid="uid://cvx5u0ttmri4q"] [ext_resource type="ArrayMesh" uid="uid://b8p36gpkqwmkb" path="res://assets/props/sofa/sofa.obj" id="1_xi4at"] [ext_resource type="Texture2D" uid="uid://c7wa2igxm2vta" path="res://assets/props/sofa/sofa_C.png" id="2_dd1m6"] [ext_resource type="Texture2D" uid="uid://bdutuchsgsudg" path="res://assets/props/sofa/sofa_M.png" id="3_tqm3d"] [ext_resource type="Texture2D" uid="uid://c0fmlt2f7h0l7" path="res://assets/props/sofa/sofa_N.png" id="4_kf17g"] [ext_resource type="Texture2D" uid="uid://bgedr6qe65yve" path="res://assets/props/sofa/sofa_R.png" id="5_0yugb"] -[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="6_dd1m6"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="6_tqm3d"] +[ext_resource type="Material" uid="uid://cqjr3cbxtfg2j" path="res://assets/materials/gunk.material" id="7_kf17g"] [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_dd1m6"] albedo_texture = ExtResource("2_dd1m6") @@ -23,8 +24,15 @@ data = PackedVector3Array(-1.25, 0.05, 0.6, -1.09, -0.35, 0.6, -1.25, -0.5, 0.6, mesh = ExtResource("1_xi4at") surface_material_override/0 = SubResource("StandardMaterial3D_dd1m6") -[node name="GunkBody" parent="." instance=ExtResource("6_dd1m6")] -mask_dim = 196 +[node name="StaticBody3D" type="StaticBody3D" parent="."] +collision_layer = 5 +collision_mask = 0 -[node name="CollisionShape3D" type="CollisionShape3D" parent="GunkBody"] +[node name="CollisionShape3D" type="CollisionShape3D" parent="StaticBody3D"] shape = SubResource("ConcavePolygonShape3D_tqm3d") + +[node name="Gunkable" parent="StaticBody3D" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("6_tqm3d")] +mask_dim = 196 +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("7_kf17g") diff --git a/src/props/tarp_crate/tarp_crate.tscn b/src/props/tarp_crate/tarp_crate.tscn index 692faaf..3f45765 100644 --- a/src/props/tarp_crate/tarp_crate.tscn +++ b/src/props/tarp_crate/tarp_crate.tscn @@ -5,7 +5,7 @@ [ext_resource type="Texture2D" uid="uid://boqywmqew0f1i" path="res://assets/props/tarp_crate/tarp_crate_M.png" id="2_4lu2x"] [ext_resource type="Texture2D" uid="uid://2eg8lmfp1r45" path="res://assets/props/tarp_crate/tarp_crate_N.png" id="3_vis60"] [ext_resource type="Texture2D" uid="uid://i031i4c162sf" path="res://assets/props/tarp_crate/tarp_crate_R.png" id="4_p1cm3"] -[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="5_p1cm3"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="6_p1cm3"] [ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="6_vis60"] [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_qbm60"] @@ -27,9 +27,15 @@ data = PackedVector3Array(-0.5, 0.7, 0.5, -0.5, -0.7, 0.5, -0.5, 0.7, -0.5, -0.5 mesh = ExtResource("1_p1cm3") surface_material_override/0 = SubResource("StandardMaterial3D_qbm60") -[node name="GunkBody" parent="." groups=["PlasticMaterial"] instance=ExtResource("5_p1cm3")] -mask_dim = 196 -source_gunk_material = ExtResource("6_vis60") +[node name="StaticBody3D" type="StaticBody3D" parent="." groups=["PlasticMaterial"]] +collision_layer = 5 +collision_mask = 0 -[node name="CollisionShape3D" type="CollisionShape3D" parent="GunkBody"] +[node name="CollisionShape3D" type="CollisionShape3D" parent="StaticBody3D"] shape = SubResource("ConcavePolygonShape3D_v6rol") + +[node name="Gunkable" parent="StaticBody3D" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("6_p1cm3")] +mask_dim = 196 +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("6_vis60") diff --git a/src/props/trash_can/phys_trash_can.tscn b/src/props/trash_can/phys_trash_can.tscn new file mode 100644 index 0000000..cc60048 --- /dev/null +++ b/src/props/trash_can/phys_trash_can.tscn @@ -0,0 +1,70 @@ +[gd_scene load_steps=13 format=3 uid="uid://p86qtslgpe1i"] + +[ext_resource type="ArrayMesh" uid="uid://c1npli5k7cmt1" path="res://assets/props/trash_can/trash_can.obj" id="1_2hi74"] +[ext_resource type="Script" uid="uid://sksndhqyo2bn" path="res://src/props/physics/persistent_prop.gd" id="1_g7pab"] +[ext_resource type="Texture2D" uid="uid://dg01fg62km4fq" path="res://assets/props/trash_can/trash_can_C.png" id="2_g7pab"] +[ext_resource type="Texture2D" uid="uid://dhj3w5ujnikf6" path="res://assets/props/trash_can/trash_can_M.png" id="3_kxk5h"] +[ext_resource type="Texture2D" uid="uid://c1ksjm73dg0jy" path="res://assets/props/trash_can/trash_can_N.png" id="4_g1iq2"] +[ext_resource type="Texture2D" uid="uid://b8wb1tr3lpdap" path="res://assets/props/trash_can/trash_can_R.png" id="5_gtvu8"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="6_teaen"] +[ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="7_7amwm"] +[ext_resource type="Script" uid="uid://040xta01xqxd" path="res://src/props/physics/holdable.gd" id="9_kxk5h"] + +[sub_resource type="BoxShape3D" id="BoxShape3D_kxk5h"] +size = Vector3(0.305, 1, 0.739) + +[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_2hi74"] +albedo_texture = ExtResource("2_g7pab") +metallic = 1.0 +metallic_texture = ExtResource("3_kxk5h") +roughness_texture = ExtResource("5_gtvu8") +normal_enabled = true +normal_texture = ExtResource("4_g1iq2") +texture_filter = 2 + +[sub_resource type="ConcavePolygonShape3D" id="ConcavePolygonShape3D_g7pab"] +data = PackedVector3Array(-0.2828, 0.4, -0.2828, -0.2828, 0.3069, -0.2828, 0, 0.4, -0.4, 0, 0.4, -0.4, -0.2828, 0.3069, -0.2828, 0, 0.3069, -0.4, 0.4, 0.4, 0, 0.4, 0.3069, 0, 0.2828, 0.4, 0.2828, 0.2828, 0.4, 0.2828, 0.4, 0.3069, 0, 0.2828, 0.3069, 0.2828, 0.2828, 0.4, 0.2828, 0.2828, 0.3069, 0.2828, 0, 0.4, 0.4, 0, 0.4, 0.4, 0.2828, 0.3069, 0.2828, 0, 0.3069, 0.4, 0, 0.4, 0.4, 0, 0.3069, 0.4, -0.2828, 0.4, 0.2828, -0.2828, 0.4, 0.2828, 0, 0.3069, 0.4, -0.2828, 0.3069, 0.2828, -0.2828, 0.4, 0.2828, -0.2828, 0.3069, 0.2828, -0.4, 0.4, 0, -0.4, 0.4, 0, -0.2828, 0.3069, 0.2828, -0.4, 0.3069, 0, -0.4, 0.4, 0, -0.4, 0.3069, 0, -0.2828, 0.4, -0.2828, -0.2828, 0.4, -0.2828, -0.4, 0.3069, 0, -0.2828, 0.3069, -0.2828, 0, 0.4, -0.4, 0, 0.3069, -0.4, 0.2828, 0.4, -0.2828, 0.2828, 0.4, -0.2828, 0, 0.3069, -0.4, 0.2828, 0.3069, -0.2828, 0.2828, 0.4, -0.2828, 0.2828, 0.3069, -0.2828, 0.4, 0.4, 0, 0.4, 0.4, 0, 0.2828, 0.3069, -0.2828, 0.4, 0.3069, 0, 0.2828, -0.5, -0.2828, 0, -0.5, -0.4, 0.4, -0.5, 0, 0.4, -0.5, 0, 0, -0.5, -0.4, 0.2828, -0.5, 0.2828, 0.2828, -0.5, 0.2828, 0, -0.5, -0.4, 0, -0.5, 0.4, 0, -0.5, 0.4, 0, -0.5, -0.4, -0.2828, -0.5, 0.2828, -0.2828, -0.5, 0.2828, 0, -0.5, -0.4, -0.4, -0.5, 0, -0.4, -0.5, 0, 0, -0.5, -0.4, -0.2828, -0.5, -0.2828, 0, 0.4, -0.4, 0.2828, 0.4, -0.2828, 0, 0.5, -0.3501, 0, 0.5, -0.3501, 0.2828, 0.4, -0.2828, 0.2476, 0.5, -0.2476, 0.2828, 0.4, -0.2828, 0.4, 0.4, 0, 0.2476, 0.5, -0.2476, 0.2476, 0.5, -0.2476, 0.4, 0.4, 0, 0.3501, 0.5, 0, 0.4, 0.4, 0, 0.2828, 0.4, 0.2828, 0.3501, 0.5, 0, 0.3501, 0.5, 0, 0.2828, 0.4, 0.2828, 0.2476, 0.5, 0.2476, 0.2828, 0.4, 0.2828, 0, 0.4, 0.4, 0.2476, 0.5, 0.2476, 0.2476, 0.5, 0.2476, 0, 0.4, 0.4, 0, 0.5, 0.3501, 0, 0.4, 0.4, -0.2828, 0.4, 0.2828, 0, 0.5, 0.3501, 0, 0.5, 0.3501, -0.2828, 0.4, 0.2828, -0.2476, 0.5, 0.2476, -0.2828, 0.4, 0.2828, -0.4, 0.4, 0, -0.2476, 0.5, 0.2476, -0.2476, 0.5, 0.2476, -0.4, 0.4, 0, -0.3501, 0.5, 0, -0.4, 0.4, 0, -0.2828, 0.4, -0.2828, -0.3501, 0.5, 0, -0.3501, 0.5, 0, -0.2828, 0.4, -0.2828, -0.2476, 0.5, -0.2476, -0.2828, 0.4, -0.2828, 0, 0.4, -0.4, -0.2476, 0.5, -0.2476, -0.2476, 0.5, -0.2476, 0, 0.4, -0.4, 0, 0.5, -0.3501, 0, 0.5, -0.3501, 0.2476, 0.5, -0.2476, -0.2476, 0.5, -0.2476, -0.2476, 0.5, -0.2476, 0.2476, 0.5, -0.2476, -0.3501, 0.5, 0, -0.3501, 0.5, 0, 0.2476, 0.5, -0.2476, -0.2476, 0.5, 0.2476, -0.2476, 0.5, 0.2476, 0.2476, 0.5, -0.2476, 0, 0.5, 0.3501, 0, 0.5, 0.3501, 0.2476, 0.5, -0.2476, 0.2476, 0.5, 0.2476, 0.2476, 0.5, 0.2476, 0.2476, 0.5, -0.2476, 0.3501, 0.5, 0, -0.2828, 0.3069, 0.2828, 0, 0.3069, 0.4, -0.2546, 0.3069, 0.2546, -0.2546, 0.3069, 0.2546, 0, 0.3069, 0.4, 0, 0.3069, 0.36, -0.36, 0.3069, 0, -0.2828, 0.3069, 0.2828, -0.2546, 0.3069, 0.2546, 0, 0.3069, 0.4, 0.2828, 0.3069, 0.2828, 0, 0.3069, 0.36, -0.4, 0.3069, 0, -0.2828, 0.3069, 0.2828, -0.36, 0.3069, 0, 0, 0.3069, 0.36, 0.2828, 0.3069, 0.2828, 0.2546, 0.3069, 0.2546, -0.2546, 0.3069, -0.2546, -0.4, 0.3069, 0, -0.36, 0.3069, 0, 0.2828, 0.3069, 0.2828, 0.4, 0.3069, 0, 0.2546, 0.3069, 0.2546, -0.2828, 0.3069, -0.2828, -0.4, 0.3069, 0, -0.2546, 0.3069, -0.2546, 0, 0.3069, -0.36, -0.2828, 0.3069, -0.2828, -0.2546, 0.3069, -0.2546, 0, 0.3069, -0.4, -0.2828, 0.3069, -0.2828, 0, 0.3069, -0.36, 0.2546, 0.3069, 0.2546, 0.4, 0.3069, 0, 0.36, 0.3069, 0, 0.4, 0.3069, 0, 0.2828, 0.3069, -0.2828, 0.36, 0.3069, 0, 0.36, 0.3069, 0, 0.2828, 0.3069, -0.2828, 0.2546, 0.3069, -0.2546, 0.2828, 0.3069, -0.2828, 0, 0.3069, -0.4, 0.2546, 0.3069, -0.2546, 0.2546, 0.3069, -0.2546, 0, 0.3069, -0.4, 0, 0.3069, -0.36, 0.2828, 0.2138, 0.2828, 0, 0.2138, 0.4, 0.2546, 0.2138, 0.2546, 0.2546, 0.2138, 0.2546, 0, 0.2138, 0.4, 0, 0.2138, 0.36, 0.36, 0.2138, 0, 0.2828, 0.2138, 0.2828, 0.2546, 0.2138, 0.2546, 0, 0.2138, 0.4, -0.2828, 0.2138, 0.2828, 0, 0.2138, 0.36, 0.4, 0.2138, 0, 0.2828, 0.2138, 0.2828, 0.36, 0.2138, 0, 0, 0.2138, 0.36, -0.2828, 0.2138, 0.2828, -0.2546, 0.2138, 0.2546, 0.2546, 0.2138, -0.2546, 0.4, 0.2138, 0, 0.36, 0.2138, 0, -0.2828, 0.2138, 0.2828, -0.4, 0.2138, 0, -0.2546, 0.2138, 0.2546, 0.2828, 0.2138, -0.2828, 0.4, 0.2138, 0, 0.2546, 0.2138, -0.2546, 0, 0.2138, -0.36, 0.2828, 0.2138, -0.2828, 0.2546, 0.2138, -0.2546, 0, 0.2138, -0.4, 0.2828, 0.2138, -0.2828, 0, 0.2138, -0.36, -0.2546, 0.2138, 0.2546, -0.4, 0.2138, 0, -0.36, 0.2138, 0, -0.4, 0.2138, 0, -0.2828, 0.2138, -0.2828, -0.36, 0.2138, 0, -0.36, 0.2138, 0, -0.2828, 0.2138, -0.2828, -0.2546, 0.2138, -0.2546, -0.2828, 0.2138, -0.2828, 0, 0.2138, -0.4, -0.2546, 0.2138, -0.2546, -0.2546, 0.2138, -0.2546, 0, 0.2138, -0.4, 0, 0.2138, -0.36, -0.2828, 0.2138, -0.2828, -0.2828, -0.5, -0.2828, 0, 0.2138, -0.4, 0, 0.2138, -0.4, -0.2828, -0.5, -0.2828, 0, -0.5, -0.4, 0.4, 0.2138, 0, 0.4, -0.5, 0, 0.2828, 0.2138, 0.2828, 0.2828, 0.2138, 0.2828, 0.4, -0.5, 0, 0.2828, -0.5, 0.2828, 0.2828, 0.2138, 0.2828, 0.2828, -0.5, 0.2828, 0, 0.2138, 0.4, 0, 0.2138, 0.4, 0.2828, -0.5, 0.2828, 0, -0.5, 0.4, 0, 0.2138, 0.4, 0, -0.5, 0.4, -0.2828, 0.2138, 0.2828, -0.2828, 0.2138, 0.2828, 0, -0.5, 0.4, -0.2828, -0.5, 0.2828, -0.2828, 0.2138, 0.2828, -0.2828, -0.5, 0.2828, -0.4, 0.2138, 0, -0.4, 0.2138, 0, -0.2828, -0.5, 0.2828, -0.4, -0.5, 0, -0.4, 0.2138, 0, -0.4, -0.5, 0, -0.2828, 0.2138, -0.2828, -0.2828, 0.2138, -0.2828, -0.4, -0.5, 0, -0.2828, -0.5, -0.2828, 0, 0.2138, -0.4, 0, -0.5, -0.4, 0.2828, 0.2138, -0.2828, 0.2828, 0.2138, -0.2828, 0, -0.5, -0.4, 0.2828, -0.5, -0.2828, 0.2828, 0.2138, -0.2828, 0.2828, -0.5, -0.2828, 0.4, 0.2138, 0, 0.4, 0.2138, 0, 0.2828, -0.5, -0.2828, 0.4, -0.5, 0, 0.2546, 0.3069, -0.2546, 0.2546, 0.2138, -0.2546, 0.36, 0.3069, 0, 0.36, 0.3069, 0, 0.2546, 0.2138, -0.2546, 0.36, 0.2138, 0, 0, 0.3069, -0.36, 0, 0.2138, -0.36, 0.2546, 0.3069, -0.2546, 0.2546, 0.3069, -0.2546, 0, 0.2138, -0.36, 0.2546, 0.2138, -0.2546, -0.36, 0.3069, 0, -0.36, 0.2138, 0, -0.2546, 0.3069, -0.2546, -0.2546, 0.3069, -0.2546, -0.36, 0.2138, 0, -0.2546, 0.2138, -0.2546, -0.2546, 0.3069, 0.2546, -0.2546, 0.2138, 0.2546, -0.36, 0.3069, 0, -0.36, 0.3069, 0, -0.2546, 0.2138, 0.2546, -0.36, 0.2138, 0, 0, 0.3069, 0.36, 0, 0.2138, 0.36, -0.2546, 0.3069, 0.2546, -0.2546, 0.3069, 0.2546, 0, 0.2138, 0.36, -0.2546, 0.2138, 0.2546, 0.2546, 0.3069, 0.2546, 0.2546, 0.2138, 0.2546, 0, 0.3069, 0.36, 0, 0.3069, 0.36, 0.2546, 0.2138, 0.2546, 0, 0.2138, 0.36, 0.36, 0.3069, 0, 0.36, 0.2138, 0, 0.2546, 0.3069, 0.2546, 0.2546, 0.3069, 0.2546, 0.36, 0.2138, 0, 0.2546, 0.2138, 0.2546, -0.2546, 0.3069, -0.2546, -0.2546, 0.2138, -0.2546, 0, 0.3069, -0.36, 0, 0.3069, -0.36, -0.2546, 0.2138, -0.2546, 0, 0.2138, -0.36) + +[node name="PhysTrashCan" type="RigidBody3D" groups=["MetalMaterial", "Persistent"]] +collision_layer = 66 +collision_mask = 73 +mass = 40.0 +script = ExtResource("1_g7pab") + +[node name="CollisionShape3D" type="CollisionShape3D" parent="."] +transform = Transform3D(0.92388, 0, 0.382683, 0, 1, 0, -0.382683, 0, 0.92388, 0, 0, 0) +shape = SubResource("BoxShape3D_kxk5h") + +[node name="CollisionShape3D2" type="CollisionShape3D" parent="."] +transform = Transform3D(0.382683, 0, 0.92388, 0, 1, 0, -0.92388, 0, 0.382683, 0, 0, 0) +shape = SubResource("BoxShape3D_kxk5h") + +[node name="CollisionShape3D3" type="CollisionShape3D" parent="."] +transform = Transform3D(-0.382683, 0, 0.92388, 0, 1, 0, -0.92388, 0, -0.382683, 0, 0, 0) +shape = SubResource("BoxShape3D_kxk5h") + +[node name="CollisionShape3D4" type="CollisionShape3D" parent="."] +transform = Transform3D(-0.923879, 0, 0.382683, 0, 1, 0, -0.382683, 0, -0.923879, 0, 0, 0) +shape = SubResource("BoxShape3D_kxk5h") + +[node name="MeshInstance3D" type="MeshInstance3D" parent="."] +mesh = ExtResource("1_2hi74") +surface_material_override/0 = SubResource("StandardMaterial3D_2hi74") + +[node name="StaticBody3D" type="StaticBody3D" parent="MeshInstance3D"] +collision_layer = 4 +collision_mask = 0 + +[node name="CollisionShape3D" type="CollisionShape3D" parent="MeshInstance3D/StaticBody3D"] +shape = SubResource("ConcavePolygonShape3D_g7pab") + +[node name="Gunkable" parent="MeshInstance3D/StaticBody3D" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("6_teaen")] +mask_dim = 64 +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("7_7amwm") + +[node name="Holdable" type="Node" parent="."] +script = ExtResource("9_kxk5h") +hold_distance = 1.5 +metadata/_custom_type_script = "uid://040xta01xqxd" diff --git a/src/props/trash_can/trash_can.tscn b/src/props/trash_can/static_trash_can.tscn similarity index 86% rename from src/props/trash_can/trash_can.tscn rename to src/props/trash_can/static_trash_can.tscn index 30fceff..7ed66df 100644 --- a/src/props/trash_can/trash_can.tscn +++ b/src/props/trash_can/static_trash_can.tscn @@ -1,32 +1,38 @@ [gd_scene load_steps=10 format=3 uid="uid://cklppdtyaadlo"] -[ext_resource type="ArrayMesh" uid="uid://c1npli5k7cmt1" path="res://assets/props/trash_can/trash_can.obj" id="1_fi1bf"] -[ext_resource type="Texture2D" uid="uid://dg01fg62km4fq" path="res://assets/props/trash_can/trash_can_C.png" id="1_jhjda"] -[ext_resource type="Texture2D" uid="uid://dhj3w5ujnikf6" path="res://assets/props/trash_can/trash_can_M.png" id="2_fi1bf"] -[ext_resource type="Texture2D" uid="uid://c1ksjm73dg0jy" path="res://assets/props/trash_can/trash_can_N.png" id="3_dd60s"] -[ext_resource type="Texture2D" uid="uid://b8wb1tr3lpdap" path="res://assets/props/trash_can/trash_can_R.png" id="4_k4m1t"] -[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="5_rwlhv"] -[ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="6_iulte"] +[ext_resource type="ArrayMesh" uid="uid://c1npli5k7cmt1" path="res://assets/props/trash_can/trash_can.obj" id="1_dmpmb"] +[ext_resource type="Texture2D" uid="uid://dg01fg62km4fq" path="res://assets/props/trash_can/trash_can_C.png" id="2_hbp6j"] +[ext_resource type="Texture2D" uid="uid://dhj3w5ujnikf6" path="res://assets/props/trash_can/trash_can_M.png" id="3_o21hy"] +[ext_resource type="Texture2D" uid="uid://c1ksjm73dg0jy" path="res://assets/props/trash_can/trash_can_N.png" id="4_o6pi7"] +[ext_resource type="Texture2D" uid="uid://b8wb1tr3lpdap" path="res://assets/props/trash_can/trash_can_R.png" id="5_m8g0a"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="6_dmpmb"] +[ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="7_c2e1y"] [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_7ctwk"] -albedo_texture = ExtResource("1_jhjda") +albedo_texture = ExtResource("2_hbp6j") metallic = 1.0 -metallic_texture = ExtResource("2_fi1bf") -roughness_texture = ExtResource("4_k4m1t") +metallic_texture = ExtResource("3_o21hy") +roughness_texture = ExtResource("5_m8g0a") normal_enabled = true -normal_texture = ExtResource("3_dd60s") +normal_texture = ExtResource("4_o6pi7") texture_filter = 2 [sub_resource type="ConcavePolygonShape3D" id="ConcavePolygonShape3D_eaq62"] data = PackedVector3Array(-0.2828, 0.4, -0.2828, -0.2828, 0.3069, -0.2828, 0, 0.4, -0.4, 0, 0.4, -0.4, -0.2828, 0.3069, -0.2828, 0, 0.3069, -0.4, 0.4, 0.4, 0, 0.4, 0.3069, 0, 0.2828, 0.4, 0.2828, 0.2828, 0.4, 0.2828, 0.4, 0.3069, 0, 0.2828, 0.3069, 0.2828, 0.2828, 0.4, 0.2828, 0.2828, 0.3069, 0.2828, 0, 0.4, 0.4, 0, 0.4, 0.4, 0.2828, 0.3069, 0.2828, 0, 0.3069, 0.4, 0, 0.4, 0.4, 0, 0.3069, 0.4, -0.2828, 0.4, 0.2828, -0.2828, 0.4, 0.2828, 0, 0.3069, 0.4, -0.2828, 0.3069, 0.2828, -0.2828, 0.4, 0.2828, -0.2828, 0.3069, 0.2828, -0.4, 0.4, 0, -0.4, 0.4, 0, -0.2828, 0.3069, 0.2828, -0.4, 0.3069, 0, -0.4, 0.4, 0, -0.4, 0.3069, 0, -0.2828, 0.4, -0.2828, -0.2828, 0.4, -0.2828, -0.4, 0.3069, 0, -0.2828, 0.3069, -0.2828, 0, 0.4, -0.4, 0, 0.3069, -0.4, 0.2828, 0.4, -0.2828, 0.2828, 0.4, -0.2828, 0, 0.3069, -0.4, 0.2828, 0.3069, -0.2828, 0.2828, 0.4, -0.2828, 0.2828, 0.3069, -0.2828, 0.4, 0.4, 0, 0.4, 0.4, 0, 0.2828, 0.3069, -0.2828, 0.4, 0.3069, 0, 0.2828, -0.5, -0.2828, 0, -0.5, -0.4, 0.4, -0.5, 0, 0.4, -0.5, 0, 0, -0.5, -0.4, 0.2828, -0.5, 0.2828, 0.2828, -0.5, 0.2828, 0, -0.5, -0.4, 0, -0.5, 0.4, 0, -0.5, 0.4, 0, -0.5, -0.4, -0.2828, -0.5, 0.2828, -0.2828, -0.5, 0.2828, 0, -0.5, -0.4, -0.4, -0.5, 0, -0.4, -0.5, 0, 0, -0.5, -0.4, -0.2828, -0.5, -0.2828, 0, 0.4, -0.4, 0.2828, 0.4, -0.2828, 0, 0.5, -0.3501, 0, 0.5, -0.3501, 0.2828, 0.4, -0.2828, 0.2476, 0.5, -0.2476, 0.2828, 0.4, -0.2828, 0.4, 0.4, 0, 0.2476, 0.5, -0.2476, 0.2476, 0.5, -0.2476, 0.4, 0.4, 0, 0.3501, 0.5, 0, 0.4, 0.4, 0, 0.2828, 0.4, 0.2828, 0.3501, 0.5, 0, 0.3501, 0.5, 0, 0.2828, 0.4, 0.2828, 0.2476, 0.5, 0.2476, 0.2828, 0.4, 0.2828, 0, 0.4, 0.4, 0.2476, 0.5, 0.2476, 0.2476, 0.5, 0.2476, 0, 0.4, 0.4, 0, 0.5, 0.3501, 0, 0.4, 0.4, -0.2828, 0.4, 0.2828, 0, 0.5, 0.3501, 0, 0.5, 0.3501, -0.2828, 0.4, 0.2828, -0.2476, 0.5, 0.2476, -0.2828, 0.4, 0.2828, -0.4, 0.4, 0, -0.2476, 0.5, 0.2476, -0.2476, 0.5, 0.2476, -0.4, 0.4, 0, -0.3501, 0.5, 0, -0.4, 0.4, 0, -0.2828, 0.4, -0.2828, -0.3501, 0.5, 0, -0.3501, 0.5, 0, -0.2828, 0.4, -0.2828, -0.2476, 0.5, -0.2476, -0.2828, 0.4, -0.2828, 0, 0.4, -0.4, -0.2476, 0.5, -0.2476, -0.2476, 0.5, -0.2476, 0, 0.4, -0.4, 0, 0.5, -0.3501, 0, 0.5, -0.3501, 0.2476, 0.5, -0.2476, -0.2476, 0.5, -0.2476, -0.2476, 0.5, -0.2476, 0.2476, 0.5, -0.2476, -0.3501, 0.5, 0, -0.3501, 0.5, 0, 0.2476, 0.5, -0.2476, -0.2476, 0.5, 0.2476, -0.2476, 0.5, 0.2476, 0.2476, 0.5, -0.2476, 0, 0.5, 0.3501, 0, 0.5, 0.3501, 0.2476, 0.5, -0.2476, 0.2476, 0.5, 0.2476, 0.2476, 0.5, 0.2476, 0.2476, 0.5, -0.2476, 0.3501, 0.5, 0, -0.2828, 0.3069, 0.2828, 0, 0.3069, 0.4, -0.2546, 0.3069, 0.2546, -0.2546, 0.3069, 0.2546, 0, 0.3069, 0.4, 0, 0.3069, 0.36, -0.36, 0.3069, 0, -0.2828, 0.3069, 0.2828, -0.2546, 0.3069, 0.2546, 0, 0.3069, 0.4, 0.2828, 0.3069, 0.2828, 0, 0.3069, 0.36, -0.4, 0.3069, 0, -0.2828, 0.3069, 0.2828, -0.36, 0.3069, 0, 0, 0.3069, 0.36, 0.2828, 0.3069, 0.2828, 0.2546, 0.3069, 0.2546, -0.2546, 0.3069, -0.2546, -0.4, 0.3069, 0, -0.36, 0.3069, 0, 0.2828, 0.3069, 0.2828, 0.4, 0.3069, 0, 0.2546, 0.3069, 0.2546, -0.2828, 0.3069, -0.2828, -0.4, 0.3069, 0, -0.2546, 0.3069, -0.2546, 0, 0.3069, -0.36, -0.2828, 0.3069, -0.2828, -0.2546, 0.3069, -0.2546, 0, 0.3069, -0.4, -0.2828, 0.3069, -0.2828, 0, 0.3069, -0.36, 0.2546, 0.3069, 0.2546, 0.4, 0.3069, 0, 0.36, 0.3069, 0, 0.4, 0.3069, 0, 0.2828, 0.3069, -0.2828, 0.36, 0.3069, 0, 0.36, 0.3069, 0, 0.2828, 0.3069, -0.2828, 0.2546, 0.3069, -0.2546, 0.2828, 0.3069, -0.2828, 0, 0.3069, -0.4, 0.2546, 0.3069, -0.2546, 0.2546, 0.3069, -0.2546, 0, 0.3069, -0.4, 0, 0.3069, -0.36, 0.2828, 0.2138, 0.2828, 0, 0.2138, 0.4, 0.2546, 0.2138, 0.2546, 0.2546, 0.2138, 0.2546, 0, 0.2138, 0.4, 0, 0.2138, 0.36, 0.36, 0.2138, 0, 0.2828, 0.2138, 0.2828, 0.2546, 0.2138, 0.2546, 0, 0.2138, 0.4, -0.2828, 0.2138, 0.2828, 0, 0.2138, 0.36, 0.4, 0.2138, 0, 0.2828, 0.2138, 0.2828, 0.36, 0.2138, 0, 0, 0.2138, 0.36, -0.2828, 0.2138, 0.2828, -0.2546, 0.2138, 0.2546, 0.2546, 0.2138, -0.2546, 0.4, 0.2138, 0, 0.36, 0.2138, 0, -0.2828, 0.2138, 0.2828, -0.4, 0.2138, 0, -0.2546, 0.2138, 0.2546, 0.2828, 0.2138, -0.2828, 0.4, 0.2138, 0, 0.2546, 0.2138, -0.2546, 0, 0.2138, -0.36, 0.2828, 0.2138, -0.2828, 0.2546, 0.2138, -0.2546, 0, 0.2138, -0.4, 0.2828, 0.2138, -0.2828, 0, 0.2138, -0.36, -0.2546, 0.2138, 0.2546, -0.4, 0.2138, 0, -0.36, 0.2138, 0, -0.4, 0.2138, 0, -0.2828, 0.2138, -0.2828, -0.36, 0.2138, 0, -0.36, 0.2138, 0, -0.2828, 0.2138, -0.2828, -0.2546, 0.2138, -0.2546, -0.2828, 0.2138, -0.2828, 0, 0.2138, -0.4, -0.2546, 0.2138, -0.2546, -0.2546, 0.2138, -0.2546, 0, 0.2138, -0.4, 0, 0.2138, -0.36, -0.2828, 0.2138, -0.2828, -0.2828, -0.5, -0.2828, 0, 0.2138, -0.4, 0, 0.2138, -0.4, -0.2828, -0.5, -0.2828, 0, -0.5, -0.4, 0.4, 0.2138, 0, 0.4, -0.5, 0, 0.2828, 0.2138, 0.2828, 0.2828, 0.2138, 0.2828, 0.4, -0.5, 0, 0.2828, -0.5, 0.2828, 0.2828, 0.2138, 0.2828, 0.2828, -0.5, 0.2828, 0, 0.2138, 0.4, 0, 0.2138, 0.4, 0.2828, -0.5, 0.2828, 0, -0.5, 0.4, 0, 0.2138, 0.4, 0, -0.5, 0.4, -0.2828, 0.2138, 0.2828, -0.2828, 0.2138, 0.2828, 0, -0.5, 0.4, -0.2828, -0.5, 0.2828, -0.2828, 0.2138, 0.2828, -0.2828, -0.5, 0.2828, -0.4, 0.2138, 0, -0.4, 0.2138, 0, -0.2828, -0.5, 0.2828, -0.4, -0.5, 0, -0.4, 0.2138, 0, -0.4, -0.5, 0, -0.2828, 0.2138, -0.2828, -0.2828, 0.2138, -0.2828, -0.4, -0.5, 0, -0.2828, -0.5, -0.2828, 0, 0.2138, -0.4, 0, -0.5, -0.4, 0.2828, 0.2138, -0.2828, 0.2828, 0.2138, -0.2828, 0, -0.5, -0.4, 0.2828, -0.5, -0.2828, 0.2828, 0.2138, -0.2828, 0.2828, -0.5, -0.2828, 0.4, 0.2138, 0, 0.4, 0.2138, 0, 0.2828, -0.5, -0.2828, 0.4, -0.5, 0, 0.2546, 0.3069, -0.2546, 0.2546, 0.2138, -0.2546, 0.36, 0.3069, 0, 0.36, 0.3069, 0, 0.2546, 0.2138, -0.2546, 0.36, 0.2138, 0, 0, 0.3069, -0.36, 0, 0.2138, -0.36, 0.2546, 0.3069, -0.2546, 0.2546, 0.3069, -0.2546, 0, 0.2138, -0.36, 0.2546, 0.2138, -0.2546, -0.36, 0.3069, 0, -0.36, 0.2138, 0, -0.2546, 0.3069, -0.2546, -0.2546, 0.3069, -0.2546, -0.36, 0.2138, 0, -0.2546, 0.2138, -0.2546, -0.2546, 0.3069, 0.2546, -0.2546, 0.2138, 0.2546, -0.36, 0.3069, 0, -0.36, 0.3069, 0, -0.2546, 0.2138, 0.2546, -0.36, 0.2138, 0, 0, 0.3069, 0.36, 0, 0.2138, 0.36, -0.2546, 0.3069, 0.2546, -0.2546, 0.3069, 0.2546, 0, 0.2138, 0.36, -0.2546, 0.2138, 0.2546, 0.2546, 0.3069, 0.2546, 0.2546, 0.2138, 0.2546, 0, 0.3069, 0.36, 0, 0.3069, 0.36, 0.2546, 0.2138, 0.2546, 0, 0.2138, 0.36, 0.36, 0.3069, 0, 0.36, 0.2138, 0, 0.2546, 0.3069, 0.2546, 0.2546, 0.3069, 0.2546, 0.36, 0.2138, 0, 0.2546, 0.2138, 0.2546, -0.2546, 0.3069, -0.2546, -0.2546, 0.2138, -0.2546, 0, 0.3069, -0.36, 0, 0.3069, -0.36, -0.2546, 0.2138, -0.2546, 0, 0.2138, -0.36) -[node name="TrashCan" type="MeshInstance3D"] -mesh = ExtResource("1_fi1bf") +[node name="StaticTrashCan" type="MeshInstance3D"] +mesh = ExtResource("1_dmpmb") surface_material_override/0 = SubResource("StandardMaterial3D_7ctwk") -[node name="GunkBody" parent="." instance=ExtResource("5_rwlhv")] -mask_dim = 64 -source_gunk_material = ExtResource("6_iulte") +[node name="StaticBody3D" type="StaticBody3D" parent="." groups=["MetalMaterial"]] +collision_layer = 5 +collision_mask = 0 -[node name="CollisionShape3D" type="CollisionShape3D" parent="GunkBody"] +[node name="CollisionShape3D" type="CollisionShape3D" parent="StaticBody3D"] shape = SubResource("ConcavePolygonShape3D_eaq62") + +[node name="Gunkable" parent="StaticBody3D" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("6_dmpmb")] +mask_dim = 64 +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("7_c2e1y") diff --git a/src/props/vending_machine/vending_machine.tscn b/src/props/vending_machine/vending_machine.tscn index 15c6ab2..cba02a8 100644 --- a/src/props/vending_machine/vending_machine.tscn +++ b/src/props/vending_machine/vending_machine.tscn @@ -7,8 +7,8 @@ [ext_resource type="Texture2D" uid="uid://8v7jta2qdvut" path="res://assets/props/vending_machine/vending_machine_N.png" id="4_m0mqe"] [ext_resource type="Texture2D" uid="uid://gbvtbiurxrop" path="res://assets/props/vending_machine/vending_machine_R.png" id="5_pmvmu"] [ext_resource type="Script" uid="uid://jybe7wejrtuj" path="res://src/props/vending_machine/vending_machine.gd" id="6_5b31a"] -[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="6_kgb1h"] [ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="8_b7lht"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="10_8xld6"] [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_v4lrk"] resource_local_to_scene = true @@ -31,9 +31,14 @@ mesh = ExtResource("1_5b31a") surface_material_override/0 = SubResource("StandardMaterial3D_v4lrk") script = ExtResource("6_5b31a") -[node name="GunkBody" parent="." groups=["MetalMaterial"] instance=ExtResource("6_kgb1h")] -source_gunk_material = ExtResource("8_b7lht") +[node name="StaticBody3D" type="StaticBody3D" parent="." groups=["MetalMaterial"]] +collision_layer = 5 +collision_mask = 0 -[node name="CollisionShape3D" type="CollisionShape3D" parent="GunkBody"] -visible = false +[node name="CollisionShape3D" type="CollisionShape3D" parent="StaticBody3D"] shape = SubResource("ConcavePolygonShape3D_1s701") + +[node name="Gunkable" parent="StaticBody3D" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("10_8xld6")] +body = NodePath("..") +mesh_instance = NodePath("../..") +source_gunk_material = ExtResource("8_b7lht") diff --git a/src/props/wall_switch/wall_switch.gd b/src/props/wall_switch/wall_switch.gd index 8bf39c9..c110f4f 100644 --- a/src/props/wall_switch/wall_switch.gd +++ b/src/props/wall_switch/wall_switch.gd @@ -12,7 +12,8 @@ const CLEAN_THRESHOLD := 1400 @onready var animation_player: AnimationPlayer = %AnimationPlayer @onready var light_animation: AnimationPlayer = %LightAnimation -@onready var gunk_body: GunkBody = %GunkBody +@onready var gunkable: Gunkable = %Gunkable + @onready var interactive: Interactive = %Interactive @onready var action_sfx: AudioStreamPlayer3D = %ActionSFX @onready var action_delay: Timer = %ActionDelay @@ -27,7 +28,7 @@ func _ready() -> void: func _deferred_init() -> void: if clean: - gunk_body.clear_all() + gunkable.clear_all() _on_clean() if enabled: _on_enable() @@ -82,7 +83,7 @@ func _animation_finished(anim_name: StringName) -> void: interactive.enabled = enabled -func _on_gunk_body_clear_total_updated(clear_total: float) -> void: +func _on_clear_total_updated(clear_total: float) -> void: if not clean and clear_total >= CLEAN_THRESHOLD: _on_clean() diff --git a/src/props/wall_switch/wall_switch.tscn b/src/props/wall_switch/wall_switch.tscn index 8d2803f..f81e6eb 100644 --- a/src/props/wall_switch/wall_switch.tscn +++ b/src/props/wall_switch/wall_switch.tscn @@ -6,8 +6,8 @@ [ext_resource type="Texture2D" uid="uid://bur4dtt4irwgd" path="res://assets/props/wall_switch/wall_switch_M.png" id="3_3fhmv"] [ext_resource type="Texture2D" uid="uid://ddve6jcfcuthx" path="res://assets/props/wall_switch/wall_switch_N.png" id="4_pg3hp"] [ext_resource type="Texture2D" uid="uid://rq5e0a3sco88" path="res://assets/props/wall_switch/wall_switch_R.png" id="5_555wb"] -[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="7_3ib1l"] [ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="8_2qpft"] +[ext_resource type="PackedScene" uid="uid://cdi5sl60mw1po" path="res://src/world/gunk_body/gunkable.tscn" id="9_eim2y"] [ext_resource type="Script" uid="uid://deg5xd87cy8rg" path="res://src/props/interactive.gd" id="10_qw6jt"] [ext_resource type="AudioStream" uid="uid://bgayfws34lg7q" path="res://assets/sfx/click_electronic_04.wav" id="11_7shuc"] [ext_resource type="AudioStream" uid="uid://cnje66wrijwxw" path="res://assets/sfx/wall_switch.wav" id="12_2qpft"] @@ -200,15 +200,20 @@ surface_material_override/0 = SubResource("StandardMaterial3D_jtkkw") [node name="AnimationPlayer" parent="." index="1"] unique_name_in_owner = true -[node name="GunkBody" parent="." index="2" node_paths=PackedStringArray("mesh_instance") instance=ExtResource("7_3ib1l")] +[node name="StaticBody3D" type="StaticBody3D" parent="." index="2" groups=["PlasticMaterial"]] +collision_layer = 5 +collision_mask = 0 + +[node name="CollisionShape3D" type="CollisionShape3D" parent="StaticBody3D" index="0"] +shape = SubResource("ConcavePolygonShape3D_2qpft") + +[node name="Gunkable" parent="StaticBody3D" index="1" node_paths=PackedStringArray("body", "mesh_instance") instance=ExtResource("9_eim2y")] unique_name_in_owner = true mask_dim = 64 -mesh_instance = NodePath("../Armature/Skeleton3D/WallSwitch_2") +body = NodePath("..") +mesh_instance = NodePath("../../Armature/Skeleton3D/WallSwitch_2") source_gunk_material = ExtResource("8_2qpft") -[node name="CollisionShape3D" type="CollisionShape3D" parent="GunkBody" index="2"] -shape = SubResource("ConcavePolygonShape3D_2qpft") - [node name="Lights" type="Node3D" parent="." index="3"] transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.137, 0.18, 0.08) @@ -267,7 +272,7 @@ metadata/_custom_type_script = "uid://c5o1d2shq2qig" [node name="CollisionShape3D" type="CollisionShape3D" parent="WallSwitchGameSoundEmitter" index="0"] shape = SubResource("SphereShape3D_mxsyy") -[connection signal="clear_total_updated" from="GunkBody" to="." method="_on_gunk_body_clear_total_updated"] +[connection signal="clear_total_updated" from="StaticBody3D/Gunkable" to="." method="_on_clear_total_updated"] [connection signal="activated" from="Interactive" to="." method="_activate"] [connection signal="timeout" from="ActionDelay" to="." method="_on_action_delay_timeout"] [connection signal="timeout" from="ActionDelay" to="WallSwitchGameSoundEmitter" method="emit_sound_here"] diff --git a/src/world/gunk_body/gunkable.gd b/src/world/gunk_body/gunkable.gd new file mode 100644 index 0000000..c487183 --- /dev/null +++ b/src/world/gunk_body/gunkable.gd @@ -0,0 +1,309 @@ +class_name Gunkable extends Node +## Component behavior for gunkable props & geometry. + +## Emitted from the main thread after the clear total is asynchronously updated. +signal clear_total_updated(clear_total: float) + +const CONTINUITY_LIMIT := 32 +const BUFFER_LIMIT := 3 +const FACE_EPSILON := 0.01 +const CLEAR_COLOR := Color.BLACK +const MASK_COLOR := Color.RED +const CLEAR_TOTAL_EPSILON := 1 +const MASK_THRESHOLD := 0.5 + +@export var mask_dim := 256 +@export var body: PhysicsBody3D +@export var mesh_instance: MeshInstance3D +@export var initial_mask: Texture + +@export var source_gunk_material: ShaderMaterial + +var meshtool := MeshDataTool.new() + +var _polyline_buffer: Array[Vector2] = [] +var _continued_paint_this_frame := false + +var _multiline_buffer := PackedVector2Array() +var _multiline_width := 1.0 + +var _clear_total := 0.0 +var _prev_clear_total := -1.0 + +# _clear_total is async computed in separate thread +var _mask_tx: Texture2D +var _cached_mask: Image +var _thread: Thread +var _mutex: Mutex = Mutex.new() +var _semaphore: Semaphore = Semaphore.new() +var _exit_thread := false + +@onready var mask_viewport: SubViewport = %MaskViewport +@onready var mask_control: DrawController = %MaskControl +@onready var mask_texture: TextureRect = %MaskTexture + + +func _ready() -> void: + # If no physics body was provided, use the parent. + if not body: + body = get_parent() as PhysicsBody3D + assert(body, "GunkBody %s has no associated physics body!" % str(self)) + + # If no mesh_instance was provided, use the parent. + if not mesh_instance: + mesh_instance = get_parent() as MeshInstance3D + assert(mesh_instance, "GunkBody %s has no associated mesh!" % str(self)) + + mask_viewport.size = Vector2(mask_dim, mask_dim) + + # Create a new instance of the gunk material + var mat_instance: ShaderMaterial = source_gunk_material.duplicate() + # Set material gunk mask to our mask viewport texture + mat_instance.set_shader_parameter("gunk_mask", mask_viewport.get_texture()) + # Overlay mesh with gunk material + mesh_instance.material_overlay = mat_instance + + _deferred_init.call_deferred() + + # Initialize meshtool + meshtool.create_from_surface(mesh_instance.mesh as ArrayMesh, 0) + + _thread = Thread.new() + _thread.start(_async_compute_clear_total) + + +func _deferred_init() -> void: + if initial_mask: + mask_texture.texture = initial_mask + mask_texture.visible = true + + +func _async_compute_clear_total() -> void: + # Ignore first two calls (initial mask clear & texture) + # NOTE: this technically could put us in a glitched state if that mask clear & texture don't happen + # and the thread wouldn't be able to hit the exit condition. + # If the application hangs in a weird way immediately after loading a scene, maybe this is why! + _semaphore.wait() + _semaphore.wait() + while true: + _semaphore.wait() + + # check exit flag + _mutex.lock() + var exiting := _exit_thread + _mutex.unlock() + + if exiting: + break + + # Get mask from GPU + # TODO: does this need mutex protection? + _mutex.lock() + _cached_mask = _mask_tx.get_image() + _cached_mask.convert(Image.FORMAT_R8) + _mutex.unlock() + var px_data := _cached_mask.get_data() + var px_sum := 0 + for px in px_data: + px_sum += px + var new_total := px_sum / 255.0 + + # Write total + _mutex.lock() + _clear_total = new_total + _mutex.unlock() + + +func _exit_tree() -> void: + # Flag processing flag to cleanly exit + _mutex.lock() + _exit_thread = true + _mutex.unlock() + _semaphore.post() + _thread.wait_to_finish() + + +func clear_all() -> void: + mask_control.clear(MASK_COLOR) + + +## Get the precise number of gunk pixels cleared from this image. +## +## This will use a cached result unless the mask has been painted since the last calculation. +## Be aware that cache misses are potentially quite expensive. +func get_clear_total() -> float: + # Protect with mutex + _mutex.lock() + var total := _clear_total + _mutex.unlock() + + return total + + +## Get the index of the mesh face on which the given point+normal lies. +## +## Returns -1 if the given point+normal does not lie on a mesh face within tolerance. +func _get_face(point: Vector3, normal: Vector3) -> int: + var min_i := -1 + var min_planar_dist := INF + + for i in range(meshtool.get_face_count()): + var sdist := meshtool.get_face_normal(i).distance_squared_to(normal) + if sdist > FACE_EPSILON: + continue + # Normals match, so check if the point is on this face + var v1 := meshtool.get_vertex(meshtool.get_face_vertex(i, 0)) + var v2 := meshtool.get_vertex(meshtool.get_face_vertex(i, 1)) + var v3 := meshtool.get_vertex(meshtool.get_face_vertex(i, 2)) + if GeometryTools.is_in_triangle(point, v1, v2, v3): + var planar_dist := absf(Plane(v1, v2, v3).distance_to(point)) + if planar_dist < min_planar_dist: + min_i = i + min_planar_dist = planar_dist + return min_i + + +## UV-unwrap a point+normal in 3D space onto the UV space of this mesh. +## +## Returns Vector2.INF if the given point+normal does not lie on this mesh within tolerance. +func _get_uv(point: Vector3, normal: Vector3) -> Vector2: + var face := _get_face(point, normal) + if face < 0: + return Vector2.INF + var fv0 := meshtool.get_face_vertex(face, 0) + var fv1 := meshtool.get_face_vertex(face, 1) + var fv2 := meshtool.get_face_vertex(face, 2) + var v1 := meshtool.get_vertex(fv0) + var v2 := meshtool.get_vertex(fv1) + var v3 := meshtool.get_vertex(fv2) + var bc := GeometryTools.barycentric(point, v1, v2, v3) # TODO memoize + var uv1 := meshtool.get_vertex_uv(fv0) + var uv2 := meshtool.get_vertex_uv(fv1) + var uv3 := meshtool.get_vertex_uv(fv2) + return (uv1 * bc.x) + (uv2 * bc.y) + (uv3 * bc.z) + + +## UV-unwrap a point+normal in 3D space onto the pixel space of this mesh's texture. +## +## Returns Vector2.INF if the given point+normal does not lie on this mesh within tolerance. +func _get_px(point: Vector3, normal: Vector3) -> Vector2: + return _get_uv(point * body.global_transform, normal * body.global_basis) * mask_control.size + + +func is_point_gunked(point: Vector3, normal: Vector3) -> bool: + var px := _get_px(point, normal) + var result := false + # XXX deadlock potential? + _mutex.lock() + result = _cached_mask and _cached_mask.get_pixelv(px).r < MASK_THRESHOLD + _mutex.unlock() + + return result + + +## Paint a dot on the gunk mask. +func paint_dot(point: Vector3, normal: Vector3, radius: float, color: Color = MASK_COLOR) -> void: + var px := _get_px(point, normal) + if px == Vector2.INF: + return + + mask_control.queue_draw( + func() -> void: mask_control.draw_circle(px, radius, color, true, -1, true) + ) + + +## Paint a continuous line on the gunk mask if called on successive frames. +func paint_continuous( + point: Vector3, normal: Vector3, width: float, color: Color = MASK_COLOR +) -> void: + var px := _get_px(point, normal) + if _polyline_buffer and px.distance_to(_polyline_buffer[0]) <= CONTINUITY_LIMIT: + _polyline_buffer.push_front(px) + if len(_polyline_buffer) > BUFFER_LIMIT: + _polyline_buffer.pop_back() + var polyline := PackedVector2Array(_polyline_buffer) + mask_control.queue_draw( + func() -> void: mask_control.draw_polyline(polyline, color, width * 2, true) + ) + else: + _polyline_buffer = [px] + + # Always paint a circle, to round out corners & cap ends + mask_control.queue_draw( + func() -> void: mask_control.draw_circle(px, width, color, true, -1, true) + ) + _continued_paint_this_frame = true + + +## Add a segment to the multiline to paint this frame. +func add_to_multiline( + point_a: Vector3, normal_a: Vector3, point_b: Vector3, normal_b: Vector3, width: float +) -> void: + var px_a := _get_px(point_a, normal_a) + var px_b := _get_px(point_b, normal_b) + if px_a == Vector2.INF or px_b == Vector2.INF or px_a.distance_to(px_b) > CONTINUITY_LIMIT: + return + _multiline_buffer.append(px_a) + _multiline_buffer.append(px_b) + _multiline_width = width + + +func _process(_delta: float) -> void: + # Check if processing thread has updated the clear total + _mutex.lock() + var new_total := _clear_total + _mutex.unlock() + var delta := new_total - _prev_clear_total + if abs(delta) > CLEAR_TOTAL_EPSILON: + clear_total_updated.emit(new_total) + # Do not fire signal on first compute after initialization + # This prevents the player from collecting the grunk from the initial mask. + if _prev_clear_total >= 0: + # XXX due to fp error, this will drift from the "true count" over time + # but it probably won't matter :shrug: + World.instance.manager.collect_grunk(delta) + _prev_clear_total = new_total + + # If paint_continuous wasn't called last frame, stop the current polyline. + if not _continued_paint_this_frame: + _polyline_buffer = [] + _continued_paint_this_frame = false + + # If we've buffered a multiline in the last frame, draw it & clear the buffer. + # The width of the multiline will just be the width of the last call. + if _multiline_buffer: + var points := _multiline_buffer.duplicate() + var width := _multiline_width + mask_control.queue_draw( + func() -> void: mask_control.draw_multiline(points, MASK_COLOR, width, true) + ) + _multiline_buffer = PackedVector2Array() + + +func trigger_recompute() -> void: + _mutex.lock() + _mask_tx = mask_viewport.get_texture() + _mutex.unlock() + _semaphore.post() + + +func _on_mask_painted() -> void: + # XXX any problem with posting each frame? + trigger_recompute.call_deferred() + + +func serialize() -> Dictionary: + var state := {"mask": mask_viewport.get_texture().get_image()} + return state + + +func deserialize(state: Dictionary) -> void: + @warning_ignore("unsafe_cast") + initial_mask = ImageTexture.create_from_image(state["mask"] as Image) + + +static func get_component(o: Object) -> Gunkable: + var n := o as Node + if n and n.has_node("Gunkable"): + return n.get_node_or_null("Gunkable") as Gunkable + return null diff --git a/src/world/gunk_body/gunkable.gd.uid b/src/world/gunk_body/gunkable.gd.uid new file mode 100644 index 0000000..2cdcbc9 --- /dev/null +++ b/src/world/gunk_body/gunkable.gd.uid @@ -0,0 +1 @@ +uid://co0g2klfmor48 diff --git a/src/world/gunk_body/gunkable.tscn b/src/world/gunk_body/gunkable.tscn new file mode 100644 index 0000000..c78d29f --- /dev/null +++ b/src/world/gunk_body/gunkable.tscn @@ -0,0 +1,47 @@ +[gd_scene load_steps=3 format=3 uid="uid://cdi5sl60mw1po"] + +[ext_resource type="Script" uid="uid://co0g2klfmor48" path="res://src/world/gunk_body/gunkable.gd" id="1_47xoo"] +[ext_resource type="Script" uid="uid://bom5qysgfvap1" path="res://src/world/gunk_body/draw_controller.gd" id="2_srn13"] + +[node name="Gunkable" type="Node" groups=["Persistent"]] +script = ExtResource("1_47xoo") +metadata/_custom_type_script = "uid://co0g2klfmor48" + +[node name="MaskViewport" type="SubViewport" parent="."] +unique_name_in_owner = true +transparent_bg = true +handle_input_locally = false +size = Vector2i(1024, 1024) +render_target_clear_mode = 1 +render_target_update_mode = 4 + +[node name="MaskClear" type="ColorRect" parent="MaskViewport"] +unique_name_in_owner = true +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +color = Color(0, 0, 0, 1) + +[node name="MaskTexture" type="TextureRect" parent="MaskViewport"] +unique_name_in_owner = true +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 + +[node name="MaskControl" type="Control" parent="MaskViewport"] +unique_name_in_owner = true +layout_mode = 3 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +script = ExtResource("2_srn13") + +[connection signal="visibility_changed" from="MaskViewport/MaskClear" to="MaskViewport/MaskControl" method="_set_dirty"] +[connection signal="visibility_changed" from="MaskViewport/MaskTexture" to="MaskViewport/MaskControl" method="_set_dirty"] +[connection signal="draw" from="MaskViewport/MaskControl" to="." method="_on_mask_painted"] diff --git a/src/world/world.tscn b/src/world/world.tscn index 9870593..4d2d566 100644 --- a/src/world/world.tscn +++ b/src/world/world.tscn @@ -4,7 +4,7 @@ [ext_resource type="Resource" uid="uid://tgac5tnfx56r" path="res://src/world/world_manager.tres" id="2_5kmgb"] [ext_resource type="PackedScene" uid="uid://byvjsvavbg5xe" path="res://src/ui/menus/pause_menu/pause_menu.tscn" id="2_6fy3g"] [ext_resource type="Resource" uid="uid://0i72bf8ip1lx" path="res://src/world/spook_manager.tres" id="3_l0av5"] -[ext_resource type="PackedScene" uid="uid://c7us4smgk3487" path="res://levels/physics_test/physics_test.tscn" id="4_5kmgb"] +[ext_resource type="PackedScene" uid="uid://dc4tts6342cuj" path="res://levels/prop_test/prop_test.tscn" id="4_5kmgb"] [ext_resource type="PackedScene" uid="uid://c0uitm5cg88h1" path="res://src/ui/menus/kill_screen/kill_screen.tscn" id="6_l0av5"] [ext_resource type="PackedScene" uid="uid://brknr57xc2cp0" path="res://src/ui/elements/save_icon/save_icon.tscn" id="7_5kmgb"]