Support dynamic 2–8 player Space Shooter from selected pods.
Replace the fixed left/right split with selectable pod slots and a scalable grid layout so player count follows the chosen pods. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
+25
-46
@@ -39,42 +39,19 @@ theme_override_colors/font_color = Color(0.75, 0.8, 0.9, 1)
|
||||
theme_override_font_sizes/font_size = 14
|
||||
text = "Starting…"
|
||||
|
||||
[node name="LeftScoreLabel" type="Label" parent="UiLayer"]
|
||||
offset_left = 24.0
|
||||
offset_top = 52.0
|
||||
offset_right = 280.0
|
||||
offset_bottom = 120.0
|
||||
theme_override_colors/font_color = Color(0.45, 0.75, 1, 1)
|
||||
theme_override_font_sizes/font_size = 18
|
||||
text = "Links · —"
|
||||
|
||||
[node name="RightScoreLabel" type="Label" parent="UiLayer"]
|
||||
anchors_preset = 1
|
||||
anchor_left = 1.0
|
||||
anchor_right = 1.0
|
||||
offset_left = -280.0
|
||||
offset_top = 52.0
|
||||
offset_right = -24.0
|
||||
offset_bottom = 120.0
|
||||
grow_horizontal = 0
|
||||
theme_override_colors/font_color = Color(1, 0.72, 0.35, 1)
|
||||
theme_override_font_sizes/font_size = 18
|
||||
horizontal_alignment = 2
|
||||
text = "Rechts · —"
|
||||
|
||||
[node name="SetupPanel" type="VBoxContainer" parent="UiLayer"]
|
||||
anchors_preset = 8
|
||||
anchor_left = 0.5
|
||||
anchor_top = 0.5
|
||||
anchor_right = 0.5
|
||||
anchor_bottom = 0.5
|
||||
offset_left = -280.0
|
||||
offset_top = -160.0
|
||||
offset_right = 280.0
|
||||
offset_bottom = 160.0
|
||||
offset_left = -300.0
|
||||
offset_top = -220.0
|
||||
offset_right = 300.0
|
||||
offset_bottom = 220.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
theme_override_constants/separation = 18
|
||||
theme_override_constants/separation = 16
|
||||
alignment = 1
|
||||
|
||||
[node name="SetupTitle" type="Label" parent="UiLayer/SetupPanel"]
|
||||
@@ -89,34 +66,36 @@ layout_mode = 2
|
||||
theme_override_colors/font_color = Color(0.6, 0.65, 0.75, 1)
|
||||
theme_override_font_sizes/font_size = 14
|
||||
horizontal_alignment = 1
|
||||
text = "Split-Screen · kippen oder Lenkrad drehen"
|
||||
text = "Raster · kippen oder Lenkrad drehen"
|
||||
|
||||
[node name="ClientGrid" type="GridContainer" parent="UiLayer/SetupPanel"]
|
||||
[node name="SlotControls" type="HBoxContainer" parent="UiLayer/SetupPanel"]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 4
|
||||
theme_override_constants/h_separation = 16
|
||||
theme_override_constants/v_separation = 12
|
||||
columns = 2
|
||||
theme_override_constants/separation = 12
|
||||
alignment = 1
|
||||
|
||||
[node name="LeftCaption" type="Label" parent="UiLayer/SetupPanel/ClientGrid"]
|
||||
[node name="RemoveSlotButton" type="Button" parent="UiLayer/SetupPanel/SlotControls"]
|
||||
custom_minimum_size = Vector2(44, 36)
|
||||
layout_mode = 2
|
||||
theme_override_colors/font_color = Color(0.45, 0.75, 1, 1)
|
||||
text = "−"
|
||||
|
||||
[node name="SlotCountLabel" type="Label" parent="UiLayer/SetupPanel/SlotControls"]
|
||||
custom_minimum_size = Vector2(110, 0)
|
||||
layout_mode = 2
|
||||
theme_override_colors/font_color = Color(0.85, 0.88, 0.95, 1)
|
||||
theme_override_font_sizes/font_size = 16
|
||||
text = "Links"
|
||||
horizontal_alignment = 1
|
||||
text = "2 Spieler"
|
||||
|
||||
[node name="LeftClientOption" type="OptionButton" parent="UiLayer/SetupPanel/ClientGrid"]
|
||||
custom_minimum_size = Vector2(220, 0)
|
||||
[node name="AddSlotButton" type="Button" parent="UiLayer/SetupPanel/SlotControls"]
|
||||
custom_minimum_size = Vector2(44, 36)
|
||||
layout_mode = 2
|
||||
text = "+"
|
||||
|
||||
[node name="RightCaption" type="Label" parent="UiLayer/SetupPanel/ClientGrid"]
|
||||
layout_mode = 2
|
||||
theme_override_colors/font_color = Color(1, 0.72, 0.35, 1)
|
||||
theme_override_font_sizes/font_size = 16
|
||||
text = "Rechts"
|
||||
|
||||
[node name="RightClientOption" type="OptionButton" parent="UiLayer/SetupPanel/ClientGrid"]
|
||||
custom_minimum_size = Vector2(220, 0)
|
||||
[node name="PlayerSlots" type="VBoxContainer" parent="UiLayer/SetupPanel"]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 4
|
||||
theme_override_constants/separation = 10
|
||||
|
||||
[node name="SetupHintLabel" type="Label" parent="UiLayer/SetupPanel"]
|
||||
layout_mode = 2
|
||||
|
||||
+526
-227
File diff suppressed because it is too large
Load Diff
@@ -25,6 +25,18 @@ static func named(name: String) -> AtlasTexture:
|
||||
return region(211, 941, 99, 75)
|
||||
"playerShip1_orange":
|
||||
return region(247, 84, 99, 75)
|
||||
"playerShip1_green":
|
||||
return region(237, 377, 99, 75)
|
||||
"playerShip1_red":
|
||||
return region(224, 832, 99, 75)
|
||||
"playerShip2_blue":
|
||||
return region(112, 791, 112, 75)
|
||||
"playerShip2_orange":
|
||||
return region(112, 716, 112, 75)
|
||||
"playerShip2_green":
|
||||
return region(112, 866, 112, 75)
|
||||
"playerShip2_red":
|
||||
return region(0, 941, 112, 75)
|
||||
"laserBlue01":
|
||||
return region(856, 421, 9, 54)
|
||||
"laserRed01":
|
||||
|
||||
Reference in New Issue
Block a user