online multiplayer chess game (note server currently down)
Diffstat (limited to 'ui/Lobby.tscn')
-rw-r--r--ui/Lobby.tscn117
1 files changed, 47 insertions, 70 deletions
diff --git a/ui/Lobby.tscn b/ui/Lobby.tscn
index 02e0148..123bf11 100644
--- a/ui/Lobby.tscn
+++ b/ui/Lobby.tscn
@@ -1,12 +1,7 @@
-[gd_scene load_steps=5 format=2]
+[gd_scene load_steps=3 format=2]
[ext_resource path="res://ui/main.tres" type="Theme" id=1]
[ext_resource path="res://ui/Lobby.gd" type="Script" id=2]
-[ext_resource path="res://assets/ui/verdana-bold.ttf" type="DynamicFontData" id=3]
-
-[sub_resource type="DynamicFont" id=1]
-size = 30
-font_data = ExtResource( 3 )
[node name="Lobby" type="Control"]
anchor_right = 1.0
@@ -14,94 +9,76 @@ anchor_bottom = 1.0
theme = ExtResource( 1 )
script = ExtResource( 2 )
-[node name="Back" type="ColorRect" parent="."]
+[node name="Back" type="ColorRect" parent="." groups=["control"]]
anchor_right = 1.0
anchor_bottom = 1.0
color = Color( 0, 0, 0, 0.784314 )
-[node name="Center" type="CenterContainer" parent="Back"]
+[node name="Center" type="CenterContainer" parent="Back" groups=["control"]]
anchor_right = 1.0
anchor_bottom = 1.0
-[node name="HBox" type="HBoxContainer" parent="Back/Center"]
-margin_left = 437.0
-margin_top = 189.0
-margin_right = 763.0
-margin_bottom = 611.0
-
-[node name="VBox" type="VBoxContainer" parent="Back/Center/HBox"]
-margin_right = 311.0
-margin_bottom = 422.0
+[node name="HBox" type="HBoxContainer" parent="Back/Center" groups=["control"]]
+margin_left = 425.0
+margin_top = 286.0
+margin_right = 775.0
+margin_bottom = 513.0
-[node name="AddressLabel" type="Label" parent="Back/Center/HBox/VBox"]
-margin_right = 311.0
-margin_bottom = 50.0
-text = "address"
+[node name="VBox" type="VBoxContainer" parent="Back/Center/HBox" groups=["control"]]
+margin_right = 350.0
+margin_bottom = 227.0
-[node name="Address" type="LineEdit" parent="Back/Center/HBox/VBox"]
-margin_top = 65.0
-margin_right = 311.0
-margin_bottom = 171.0
+[node name="Address" type="LineEdit" parent="Back/Center/HBox/VBox" groups=["control"]]
+margin_right = 350.0
+margin_bottom = 106.0
+rect_min_size = Vector2( 350, 0 )
focus_mode = 1
-text = "127.0.0.1"
-placeholder_text = "127.0.0.1"
+text = "game_code"
+align = 1
+max_length = 10
+placeholder_text = "game_code"
caret_blink = true
caret_blink_speed = 0.35
-[node name="HBox" type="HBoxContainer" parent="Back/Center/HBox/VBox"]
-margin_top = 186.0
-margin_right = 311.0
-margin_bottom = 292.0
+[node name="buttons" type="HBoxContainer" parent="Back/Center/HBox/VBox" groups=["control"]]
+margin_top = 121.0
+margin_right = 350.0
+margin_bottom = 227.0
-[node name="HostButton" type="Button" parent="Back/Center/HBox/VBox/HBox"]
-margin_right = 154.0
+[node name="JoinButton" type="Button" parent="Back/Center/HBox/VBox/buttons" groups=["control"]]
+margin_right = 150.0
margin_bottom = 106.0
+rect_min_size = Vector2( 150, 0 )
focus_mode = 0
+size_flags_horizontal = 4
enabled_focus_mode = 0
-text = "host"
+text = "join"
-[node name="JoinButton" type="Button" parent="Back/Center/HBox/VBox/HBox"]
-margin_left = 169.0
-margin_right = 311.0
+[node name="HostButton" type="Button" parent="Back/Center/HBox/VBox/buttons" groups=["control"]]
+margin_left = 165.0
+margin_right = 350.0
margin_bottom = 106.0
focus_mode = 0
+size_flags_horizontal = 3
enabled_focus_mode = 0
-text = "join"
-
-[node name="StatusOK" type="Label" parent="Back/Center/HBox/VBox"]
-margin_top = 307.0
-margin_right = 311.0
-margin_bottom = 357.0
-custom_colors/font_color = Color( 1, 1, 1, 1 )
-
-[node name="StatusFail" type="Label" parent="Back/Center/HBox/VBox"]
-margin_top = 372.0
-margin_right = 311.0
-margin_bottom = 422.0
-custom_colors/font_color = Color( 0.698039, 0.415686, 0.415686, 1 )
-
-[node name="VBox2" type="VBoxContainer" parent="Back/Center/HBox"]
-margin_left = 326.0
-margin_right = 326.0
-margin_bottom = 422.0
+text = "host"
-[node name="Portforward" type="Label" parent="Back/Center/HBox/VBox2"]
+[node name="StatusOK" type="Label" parent="Back/Center/HBox/VBox" groups=["control"]]
visible = false
-margin_right = 600.0
-margin_bottom = 161.0
-rect_min_size = Vector2( 600, 0 )
-custom_fonts/font = SubResource( 1 )
-text = "If you want non-LAN clients to connect,
-make sure the port 8910 in UDP
-is forwarded on your router."
+margin_top = 242.0
+margin_right = 500.0
+margin_bottom = 292.0
+custom_colors/font_color = Color( 1, 1, 1, 1 )
autowrap = true
-[node name="FindPublicIP" type="LinkButton" parent="Back/Center/HBox/VBox2"]
+[node name="StatusFail" type="Label" parent="Back/Center/HBox/VBox" groups=["control"]]
visible = false
-margin_right = 295.0
-margin_bottom = 50.0
-text = "find public ip"
+margin_top = 307.0
+margin_right = 500.0
+margin_bottom = 357.0
+custom_colors/font_color = Color( 0.698039, 0.415686, 0.415686, 1 )
+autowrap = true
-[connection signal="pressed" from="Back/Center/HBox/VBox/HBox/HostButton" to="." method="_on_host_pressed"]
-[connection signal="pressed" from="Back/Center/HBox/VBox/HBox/JoinButton" to="." method="_on_join_pressed"]
-[connection signal="pressed" from="Back/Center/HBox/VBox2/FindPublicIP" to="." method="_on_find_public_ip_pressed"]
+[connection signal="text_entered" from="Back/Center/HBox/VBox/Address" to="." method="_on_Address_text_entered"]
+[connection signal="pressed" from="Back/Center/HBox/VBox/buttons/JoinButton" to="." method="_on_join_pressed"]
+[connection signal="pressed" from="Back/Center/HBox/VBox/buttons/HostButton" to="." method="_on_HostButton_pressed"]