From 89f6f27302b267c4b7424f942508e749ab1290a6 Mon Sep 17 00:00:00 2001 From: metamuffin Date: Tue, 25 Jun 2024 00:13:37 +0200 Subject: reconnect button --- client/menu/ingame_menu.gd | 3 +++ client/menu/ingame_menu.tscn | 6 ++++++ 2 files changed, 9 insertions(+) (limited to 'client/menu') diff --git a/client/menu/ingame_menu.gd b/client/menu/ingame_menu.gd index 7a6d8e1a..21bfa8ac 100644 --- a/client/menu/ingame_menu.gd +++ b/client/menu/ingame_menu.gd @@ -7,3 +7,6 @@ func _on_main_menu_pressed(): func _on_quit_pressed(): get_parent().quit() + +func _on_reconnect_pressed(): + get_parent().transition_to("res://game.tscn") diff --git a/client/menu/ingame_menu.tscn b/client/menu/ingame_menu.tscn index f9b0157c..cf35a7e7 100644 --- a/client/menu/ingame_menu.tscn +++ b/client/menu/ingame_menu.tscn @@ -97,6 +97,11 @@ text = "Undercooked" custom_minimum_size = Vector2(0, 10) layout_mode = 2 +[node name="reconnect" type="Button" parent="side/margin/options"] +layout_mode = 2 +text = "Reconnect" +alignment = 0 + [node name="main_menu" type="Button" parent="side/margin/options"] layout_mode = 2 text = "Main Menu" @@ -107,5 +112,6 @@ layout_mode = 2 text = "Quit" alignment = 0 +[connection signal="pressed" from="side/margin/options/reconnect" to="." method="_on_reconnect_pressed"] [connection signal="pressed" from="side/margin/options/main_menu" to="." method="_on_main_menu_pressed"] [connection signal="pressed" from="side/margin/options/quit" to="." method="_on_quit_pressed"] -- cgit v1.2.3-70-g09d2