From d9d5bb3259a1f065ff6a86fb1ac9b53edb2aa227 Mon Sep 17 00:00:00 2001 From: debugman18 Date: Sat, 17 Oct 2026 23:03:24 -0500 Subject: [PATCH] Condensed worlds --- art/interact_button.png | Bin 0 -> 424 bytes art/interact_button.png.import | 43 ++++++++++++ interactable.gd | 2 + pharaoh.tscn | 7 ++ player_2d.gd | 5 +- world.tscn | 116 ++++++++++++++++----------------- 6 files changed, 111 insertions(+), 62 deletions(-) create mode 100644 art/interact_button.png create mode 100644 art/interact_button.png.import diff --git a/art/interact_button.png b/art/interact_button.png new file mode 100644 index 0000000000000000000000000000000000000000..34b39c39bf5df9795180da6f8e40871691cf2115 GIT binary patch literal 424 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!63?wyl`GbKJV{wqX6T`Z5GB1G~mUKs7M+SzC z{oH>NS%G}E0G|+7APodd(|4W+QcNX5e!>44o^Chr0`fQuJR*x382I*sFrx))unJI6 zvcxr_Bsf2 void: if body!=%Player2D: return is_interactable = true + $Sprite2D/ButtonPrompt.show() func _on_abandon(body) -> void: if body!=%Player2D: return is_interactable = false + $Sprite2D/ButtonPrompt.hide() diff --git a/pharaoh.tscn b/pharaoh.tscn index 2e85a14..0b9ec3e 100644 --- a/pharaoh.tscn +++ b/pharaoh.tscn @@ -2,6 +2,7 @@ [ext_resource type="Script" uid="uid://bh588bpddschq" path="res://pharaoh.gd" id="1_mt7kg"] [ext_resource type="Texture2D" uid="uid://b2nldodte5p6s" path="res://art/sarco_closed.png" id="2_mt7kg"] +[ext_resource type="Texture2D" uid="uid://d0cd1alr8k706" path="res://art/interact_button.png" id="3_6vea8"] [sub_resource type="RectangleShape2D" id="RectangleShape2D_eumkw"] size = Vector2(26, 32) @@ -18,6 +19,12 @@ texture = ExtResource("2_mt7kg") [node name="CollisionShape2D" type="CollisionShape2D" parent="Sprite2D/Area2D" unique_id=1560168165] shape = SubResource("RectangleShape2D_eumkw") +[node name="ButtonPrompt" type="Sprite2D" parent="Sprite2D" unique_id=1864817335] +visible = false +position = Vector2(0, -24) +scale = Vector2(0.8, 0.8) +texture = ExtResource("3_6vea8") + [connection signal="interacted" from="." to="." method="_on_interacted"] [connection signal="body_entered" from="Sprite2D/Area2D" to="." method="_on_approach"] [connection signal="body_exited" from="Sprite2D/Area2D" to="." method="_on_abandon"] diff --git a/player_2d.gd b/player_2d.gd index 95a77f5..2f595b3 100644 --- a/player_2d.gd +++ b/player_2d.gd @@ -178,8 +178,9 @@ func _process(delta: float) -> void: $Sprite2D/HatSprite.play("idle") $Parallax2D/Sprite2D.modulate = BACKGROUND_COLOR - for hidden_object in get_tree().get_nodes_in_group("Hidden"): - hidden_object.hide() + if get_tree(): + for hidden_object in get_tree().get_nodes_in_group("Hidden"): + hidden_object.hide() #Falling to death. if position.y >= death_threshold: diff --git a/world.tscn b/world.tscn index 2b6a46a..fe6ddd2 100644 --- a/world.tscn +++ b/world.tscn @@ -46,6 +46,58 @@ position = Vector2(-62, -24.616333) [node name="Tutorial" type="Node2D" parent="." unique_id=1391494772] +[node name="Block2" parent="Tutorial" unique_id=878186522 instance=ExtResource("2_036b0")] +position = Vector2(55, 118) + +[node name="LongBlock3" parent="Tutorial" unique_id=1035095840 instance=ExtResource("3_dwbse")] +position = Vector2(950, 505.12885) + +[node name="VerticalLongBlock2" parent="Tutorial" unique_id=1984351408 instance=ExtResource("4_pkg7o")] +position = Vector2(1695, 192.9927) + +[node name="VerticalLongBlock3" parent="Tutorial" unique_id=485343370 instance=ExtResource("4_pkg7o")] +position = Vector2(1695, 81.72651) + +[node name="VerticalLongBlock4" parent="Tutorial" unique_id=977741022 instance=ExtResource("4_pkg7o")] +position = Vector2(1589, 139.82124) + +[node name="VerticalLongBlock5" parent="Tutorial" unique_id=923671040 instance=ExtResource("4_pkg7o")] +position = Vector2(1589, 29.539703) + +[node name="Spike24" parent="Tutorial" unique_id=741914042 instance=ExtResource("12_k3n1d")] +position = Vector2(954, 520.88336) +rotation = -3.1415925 + +[node name="Spike25" parent="Tutorial" unique_id=1430493985 instance=ExtResource("12_k3n1d")] +position = Vector2(1827, 418.47906) +rotation = -3.1415925 + +[node name="Spike26" parent="Tutorial" unique_id=1849441610 instance=ExtResource("12_k3n1d")] +position = Vector2(1812, 418.47906) +rotation = -3.1415925 + +[node name="Spike27" parent="Tutorial" unique_id=102008874 instance=ExtResource("12_k3n1d")] +position = Vector2(1797, 418.47906) +rotation = -3.1415925 + +[node name="Spike28" parent="Tutorial" unique_id=1200843252 instance=ExtResource("12_k3n1d")] +position = Vector2(1871, 418.4791) +rotation = -3.1415925 + +[node name="LongBlock12" parent="Tutorial" unique_id=1003210040 instance=ExtResource("3_dwbse")] +position = Vector2(1299, 539.5918) + +[node name="Spike29" parent="Tutorial" unique_id=1503247741 instance=ExtResource("12_k3n1d")] +position = Vector2(1303, 555.34625) +rotation = -3.1415925 + +[node name="LongBlock13" parent="Tutorial" unique_id=483038350 instance=ExtResource("3_dwbse")] +position = Vector2(1837, 628.21094) + +[node name="Spike30" parent="Tutorial" unique_id=1550792049 instance=ExtResource("12_k3n1d")] +position = Vector2(1841, 643.96545) +rotation = -3.1415925 + [node name="LongBlock7" parent="Tutorial" unique_id=1405051006 instance=ExtResource("6_dwbse")] position = Vector2(1946, 401.7399) @@ -310,73 +362,18 @@ rotation = 4.712389 position = Vector2(1679, 181.17683) rotation = 4.712389 -[node name="ZoeLevel" type="Node2D" parent="." unique_id=980267417] -visible = false - -[node name="LongBlock4" parent="ZoeLevel" unique_id=469408536 instance=ExtResource("6_dwbse")] +[node name="LongBlock4" parent="Tutorial" unique_id=469408536 instance=ExtResource("6_dwbse")] position = Vector2(544, 399) -[node name="LongBlock5" parent="ZoeLevel" unique_id=1807703449 instance=ExtResource("6_dwbse")] +[node name="LongBlock5" parent="Tutorial" unique_id=1807703449 instance=ExtResource("6_dwbse")] position = Vector2(880, 399) -[node name="LongBlock6" parent="ZoeLevel" unique_id=1328813509 instance=ExtResource("6_dwbse")] +[node name="LongBlock6" parent="Tutorial" unique_id=1328813509 instance=ExtResource("6_dwbse")] position = Vector2(1368, 401) -[node name="LongBlock7" parent="ZoeLevel" unique_id=1016724328 instance=ExtResource("6_dwbse")] +[node name="LongBlock11" parent="Tutorial" unique_id=1016724328 instance=ExtResource("6_dwbse")] position = Vector2(1149, 629.44025) -[node name="Block" parent="ZoeLevel" unique_id=878186522 instance=ExtResource("2_036b0")] -position = Vector2(55, 118) - -[node name="LongBlock" parent="ZoeLevel" unique_id=1035095840 instance=ExtResource("3_dwbse")] -position = Vector2(950, 505.12885) - -[node name="VerticalLongBlock" parent="ZoeLevel" unique_id=1984351408 instance=ExtResource("4_pkg7o")] -position = Vector2(1695, 192.9927) - -[node name="VerticalLongBlock2" parent="ZoeLevel" unique_id=485343370 instance=ExtResource("4_pkg7o")] -position = Vector2(1695, 81.72651) - -[node name="VerticalLongBlock3" parent="ZoeLevel" unique_id=977741022 instance=ExtResource("4_pkg7o")] -position = Vector2(1589, 139.82124) - -[node name="VerticalLongBlock4" parent="ZoeLevel" unique_id=923671040 instance=ExtResource("4_pkg7o")] -position = Vector2(1589, 29.539703) - -[node name="Spike" parent="ZoeLevel" unique_id=741914042 instance=ExtResource("12_k3n1d")] -position = Vector2(954, 520.88336) -rotation = 3.1415927 - -[node name="Spike4" parent="ZoeLevel" unique_id=1430493985 instance=ExtResource("12_k3n1d")] -position = Vector2(1827, 418.47906) -rotation = 3.1415927 - -[node name="Spike5" parent="ZoeLevel" unique_id=1849441610 instance=ExtResource("12_k3n1d")] -position = Vector2(1812, 418.47906) -rotation = 3.1415927 - -[node name="Spike6" parent="ZoeLevel" unique_id=102008874 instance=ExtResource("12_k3n1d")] -position = Vector2(1797, 418.47906) -rotation = 3.1415927 - -[node name="Spike7" parent="ZoeLevel" unique_id=1200843252 instance=ExtResource("12_k3n1d")] -position = Vector2(1871, 418.4791) -rotation = 3.1415927 - -[node name="LongBlock2" parent="ZoeLevel" unique_id=1003210040 instance=ExtResource("3_dwbse")] -position = Vector2(1299, 539.5918) - -[node name="Spike2" parent="ZoeLevel" unique_id=1503247741 instance=ExtResource("12_k3n1d")] -position = Vector2(1303, 555.3463) -rotation = 3.1415927 - -[node name="LongBlock3" parent="ZoeLevel" unique_id=483038350 instance=ExtResource("3_dwbse")] -position = Vector2(1837, 628.21094) - -[node name="Spike3" parent="ZoeLevel" unique_id=1550792049 instance=ExtResource("12_k3n1d")] -position = Vector2(1841, 643.96545) -rotation = 3.1415927 - [node name="CanvasLayer" type="CanvasLayer" parent="." unique_id=1637221343] [node name="RichTextLabel2" type="RichTextLabel" parent="CanvasLayer" unique_id=1254950785] @@ -447,7 +444,6 @@ position = Vector2(6338, -58.09474) [node name="OldComputer" parent="." unique_id=1951254108 instance=ExtResource("19_cbp6q")] unique_name_in_owner = true -visible = false [node name="Block" parent="." unique_id=226580978 instance=ExtResource("2_036b0")] position = Vector2(6637, -253.12886)