From faa774525705d703fc8846e104a4cda3a999b268 Mon Sep 17 00:00:00 2001 From: Rendo Date: Fri, 12 Dec 2025 16:56:47 +0500 Subject: [PATCH] Shop confines improrperly --- gui/buy_menu/buy_menu.gd | 5 ++++- gui/host_menu/host_menu.tscn | 14 +++++++++++--- 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/gui/buy_menu/buy_menu.gd b/gui/buy_menu/buy_menu.gd index de0e6e3..99339d3 100644 --- a/gui/buy_menu/buy_menu.gd +++ b/gui/buy_menu/buy_menu.gd @@ -12,7 +12,10 @@ func _input(event: InputEvent) -> void: if event.is_action_pressed("plr_buy"): if Session.round_state == Session.ROUND_STATES.BUY: visible = not visible - MouseConfiner.borrow() + if visible: + MouseConfiner.borrow() + else: + MouseConfiner.stop_borrow() elif visible: visible = false MouseConfiner.stop_borrow() diff --git a/gui/host_menu/host_menu.tscn b/gui/host_menu/host_menu.tscn index 2fecc82..17593f5 100644 --- a/gui/host_menu/host_menu.tscn +++ b/gui/host_menu/host_menu.tscn @@ -102,12 +102,12 @@ value = 2.0 rounded = true allow_greater = true -[node name="FoldableContainer" type="FoldableContainer" parent="."] +[node name="Gameplay" type="FoldableContainer" parent="."] layout_mode = 2 folded = true title = "Геймплей" -[node name="AllowMultipleAbilityButton" type="CheckButton" parent="FoldableContainer"] +[node name="AllowMultipleAbilityButton" type="CheckButton" parent="Gameplay"] unique_name_in_owner = true visible = false custom_minimum_size = Vector2(200, 0) @@ -139,10 +139,18 @@ layout_mode = 2 editable = false script = ExtResource("3_f5ibf") +[node name="Teams" type="FoldableContainer" parent="."] +layout_mode = 2 +title = "Команды" + +[node name="Shuffle" type="Button" parent="Teams"] +layout_mode = 2 +text = "Перемешать" + [connection signal="value_changed" from="Time/VBoxContainer/RoundTime/RoundTimeBox" to="." method="_on_round_time_box_value_changed"] [connection signal="value_changed" from="Time/VBoxContainer/BombTime/BombTimeBox" to="." method="_on_bomb_time_box_value_changed"] [connection signal="value_changed" from="Time/VBoxContainer/BuyTime/BuyTimeBox" to="." method="_on_buy_time_box_value_changed"] [connection signal="value_changed" from="Round/VBoxContainer/RoundAmount/RoundBox" to="." method="_on_round_box_value_changed"] [connection signal="value_changed" from="Round/VBoxContainer/TeamSwitchAmount/TeamSwitchBox" to="." method="_on_team_switch_box_value_changed"] -[connection signal="toggled" from="FoldableContainer/AllowMultipleAbilityButton" to="." method="_on_allow_multiple_ability_button_toggled"] +[connection signal="toggled" from="Gameplay/AllowMultipleAbilityButton" to="." method="_on_allow_multiple_ability_button_toggled"] [connection signal="update_ip" from="PortForward/PortForwardContainer/ForwardPortButton" to="PortForward/PortForwardContainer/PublicIP" method="on_update_ip"]