client_ui.tscn 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140
  1. [gd_scene load_steps=3 format=2]
  2. [ext_resource path="res://lib/client_ui.gd" type="Script" id=1]
  3. [ext_resource path="res://lib/multiplayer_client.gd" type="Script" id=2]
  4. [node name="ClientUI" type="Control"]
  5. anchor_left = 0.0232267
  6. anchor_top = 0.00991005
  7. anchor_right = 0.0232267
  8. anchor_bottom = 0.00991007
  9. margin_right = 1024.0
  10. margin_bottom = 600.0
  11. size_flags_horizontal = 3
  12. size_flags_vertical = 3
  13. script = ExtResource( 1 )
  14. __meta__ = {
  15. "_edit_use_anchors_": true
  16. }
  17. [node name="Client" type="Node" parent="."]
  18. script = ExtResource( 2 )
  19. [node name="VBoxContainer" type="VBoxContainer" parent="."]
  20. anchor_right = 1.0
  21. anchor_bottom = 1.0
  22. custom_constants/separation = 8
  23. __meta__ = {
  24. "_edit_use_anchors_": false
  25. }
  26. [node name="Info" type="HBoxContainer" parent="VBoxContainer"]
  27. margin_right = 1024.0
  28. margin_bottom = 14.0
  29. [node name="1" type="Label" parent="VBoxContainer/Info"]
  30. margin_right = 72.0
  31. margin_bottom = 14.0
  32. text = "Connection"
  33. [node name="2" type="Label" parent="VBoxContainer/Info"]
  34. margin_left = 76.0
  35. margin_right = 141.0
  36. margin_bottom = 14.0
  37. text = "peercount"
  38. [node name="Connect" type="HBoxContainer" parent="VBoxContainer"]
  39. margin_top = 22.0
  40. margin_right = 1024.0
  41. margin_bottom = 46.0
  42. [node name="Label" type="Label" parent="VBoxContainer/Connect"]
  43. margin_top = 5.0
  44. margin_right = 73.0
  45. margin_bottom = 19.0
  46. text = "Connect to:"
  47. [node name="Host" type="LineEdit" parent="VBoxContainer/Connect"]
  48. margin_left = 77.0
  49. margin_right = 921.0
  50. margin_bottom = 24.0
  51. size_flags_horizontal = 3
  52. text = "wss://rc3.hacknplay.org:8443/play"
  53. [node name="Room" type="Label" parent="VBoxContainer/Connect"]
  54. margin_left = 925.0
  55. margin_right = 962.0
  56. margin_bottom = 24.0
  57. size_flags_vertical = 5
  58. text = "Room"
  59. valign = 1
  60. [node name="RoomSecret" type="LineEdit" parent="VBoxContainer/Connect"]
  61. margin_left = 966.0
  62. margin_right = 1024.0
  63. margin_bottom = 24.0
  64. placeholder_text = "secret"
  65. [node name="HBoxContainer" type="HBoxContainer" parent="VBoxContainer"]
  66. margin_top = 54.0
  67. margin_right = 1024.0
  68. margin_bottom = 74.0
  69. custom_constants/separation = 10
  70. __meta__ = {
  71. "_edit_use_anchors_": false
  72. }
  73. [node name="Start" type="Button" parent="VBoxContainer/HBoxContainer"]
  74. margin_right = 41.0
  75. margin_bottom = 20.0
  76. text = "Start"
  77. [node name="Stop" type="Button" parent="VBoxContainer/HBoxContainer"]
  78. margin_left = 51.0
  79. margin_right = 91.0
  80. margin_bottom = 20.0
  81. text = "Stop"
  82. [node name="Seal" type="Button" parent="VBoxContainer/HBoxContainer"]
  83. margin_left = 101.0
  84. margin_right = 139.0
  85. margin_bottom = 20.0
  86. text = "Seal"
  87. [node name="Ping" type="Button" parent="VBoxContainer/HBoxContainer"]
  88. margin_left = 149.0
  89. margin_right = 188.0
  90. margin_bottom = 20.0
  91. text = "Ping"
  92. [node name="Peers" type="Button" parent="VBoxContainer/HBoxContainer"]
  93. margin_left = 198.0
  94. margin_right = 280.0
  95. margin_bottom = 20.0
  96. text = "Print peers"
  97. [node name="TextEdit" type="TextEdit" parent="VBoxContainer"]
  98. margin_top = 82.0
  99. margin_right = 1024.0
  100. margin_bottom = 600.0
  101. size_flags_vertical = 3
  102. readonly = true
  103. [node name="HideButton" type="Button" parent="."]
  104. anchor_right = 0.029
  105. anchor_bottom = 0.059
  106. margin_left = -21.0
  107. margin_top = -1.0
  108. margin_right = -31.696
  109. margin_bottom = -16.4
  110. text = "X"
  111. __meta__ = {
  112. "_edit_use_anchors_": false
  113. }
  114. [connection signal="pressed" from="VBoxContainer/HBoxContainer/Start" to="." method="start"]
  115. [connection signal="pressed" from="VBoxContainer/HBoxContainer/Stop" to="." method="stop"]
  116. [connection signal="pressed" from="VBoxContainer/HBoxContainer/Seal" to="." method="_on_Seal_pressed"]
  117. [connection signal="pressed" from="VBoxContainer/HBoxContainer/Ping" to="." method="ping"]
  118. [connection signal="pressed" from="VBoxContainer/HBoxContainer/Peers" to="." method="_on_Peers_pressed"]
  119. [connection signal="pressed" from="HideButton" to="." method="_on_Hide_pressed"]