- Main menu "Maze" button opens a setup panel (width, height in screens; complexity 1-5) and generates a maze of rock chambers joined by tubes, with Start and End pads and a win panel. - New one-way tube kind: orange tiles that only let the slime in at their entrance, with motes drifting into it (OneWayTube, TubeVacuum). The auto-tube trace moved to PixelStream.trace_tube so the player and the maze validator share it. - Generation: chamber graph (spanning tree rooted at End, one-way tubes only towards End on the route, extra tubes), carved with AStarGrid2D. MazeValidator re-derives the chamber graph from the tiles and checks that End is reachable from every chamber reachable from Start. - tests/maze_check.gd: headless batch check (360 mazes) plus a known soft-lock the validator must reject. See docs/MAZE.md. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
75 lines
2.5 KiB
Text
Executable file
75 lines
2.5 KiB
Text
Executable file
[gd_scene format=3]
|
|
|
|
[ext_resource type="Script" path="res://UI/main_menu.gd" id="1_main"]
|
|
[ext_resource type="PackedScene" path="res://UI/options_menu.tscn" id="2_options"]
|
|
[ext_resource type="PackedScene" path="res://UI/maze_setup_menu.tscn" id="3_maze"]
|
|
|
|
[node name="MainMenu" type="Control"]
|
|
layout_mode = 3
|
|
anchors_preset = 15
|
|
anchor_right = 1.0
|
|
anchor_bottom = 1.0
|
|
grow_horizontal = 2
|
|
grow_vertical = 2
|
|
script = ExtResource("1_main")
|
|
|
|
[node name="Background" type="ColorRect" parent="."]
|
|
layout_mode = 1
|
|
anchors_preset = 15
|
|
anchor_right = 1.0
|
|
anchor_bottom = 1.0
|
|
grow_horizontal = 2
|
|
grow_vertical = 2
|
|
color = Color(0.12, 0.1, 0.2, 1)
|
|
|
|
[node name="CenterContainer" type="CenterContainer" parent="."]
|
|
layout_mode = 1
|
|
anchors_preset = 15
|
|
anchor_right = 1.0
|
|
anchor_bottom = 1.0
|
|
grow_horizontal = 2
|
|
grow_vertical = 2
|
|
|
|
[node name="VBoxContainer" type="VBoxContainer" parent="CenterContainer"]
|
|
custom_minimum_size = Vector2(160, 0)
|
|
layout_mode = 2
|
|
theme_override_constants/separation = 8
|
|
|
|
[node name="Title" type="Label" parent="CenterContainer/VBoxContainer"]
|
|
layout_mode = 2
|
|
theme_override_font_sizes/font_size = 32
|
|
text = "Slime Platformer"
|
|
horizontal_alignment = 1
|
|
|
|
[node name="Spacer" type="Control" parent="CenterContainer/VBoxContainer"]
|
|
custom_minimum_size = Vector2(0, 16)
|
|
layout_mode = 2
|
|
|
|
[node name="StartButton" type="Button" parent="CenterContainer/VBoxContainer"]
|
|
layout_mode = 2
|
|
text = "Start"
|
|
|
|
[node name="MazeButton" type="Button" parent="CenterContainer/VBoxContainer"]
|
|
layout_mode = 2
|
|
text = "Maze"
|
|
|
|
[node name="OptionsButton" type="Button" parent="CenterContainer/VBoxContainer"]
|
|
layout_mode = 2
|
|
text = "Options"
|
|
|
|
[node name="QuitButton" type="Button" parent="CenterContainer/VBoxContainer"]
|
|
layout_mode = 2
|
|
text = "Quit"
|
|
|
|
[node name="OptionsMenu" parent="." instance=ExtResource("2_options")]
|
|
layout_mode = 1
|
|
|
|
[connection signal="pressed" from="CenterContainer/VBoxContainer/StartButton" to="." method="_on_start_button_pressed"]
|
|
[node name="MazeSetupMenu" parent="." instance=ExtResource("3_maze")]
|
|
layout_mode = 1
|
|
|
|
[connection signal="pressed" from="CenterContainer/VBoxContainer/MazeButton" to="." method="_on_maze_button_pressed"]
|
|
[connection signal="closed" from="MazeSetupMenu" to="." method="_on_maze_setup_menu_closed"]
|
|
[connection signal="pressed" from="CenterContainer/VBoxContainer/OptionsButton" to="." method="_on_options_button_pressed"]
|
|
[connection signal="pressed" from="CenterContainer/VBoxContainer/QuitButton" to="." method="_on_quit_button_pressed"]
|
|
[connection signal="closed" from="OptionsMenu" to="." method="_on_options_menu_closed"]
|