Host settings 👍
This commit is contained in:
parent
162dbc13e8
commit
54b99eb20f
13 changed files with 203 additions and 148 deletions
33
gui/host_menu/host_menu.gd
Normal file
33
gui/host_menu/host_menu.gd
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
extends VBoxContainer
|
||||
|
||||
func _ready() -> void:
|
||||
%RoundTimeBox.set_value_no_signal(LobbySettings.round_time)
|
||||
%BombTimeBox.set_value_no_signal(LobbySettings.bomb_time)
|
||||
%BuyTimeBox.set_value_no_signal(LobbySettings.buy_time)
|
||||
%TeamSwitchBox.set_value_no_signal(LobbySettings.half_rounds)
|
||||
%RoundBox.set_value_no_signal(LobbySettings.win_score)
|
||||
%AllowMultipleAbilityButton.set_pressed_no_signal(LobbySettings.allow_multiple_abilities)
|
||||
|
||||
func _on_round_time_box_value_changed(value: float) -> void:
|
||||
LobbySettings.round_time = value
|
||||
|
||||
|
||||
func _on_bomb_time_box_value_changed(value: float) -> void:
|
||||
LobbySettings.bomb_time = value
|
||||
|
||||
|
||||
func _on_buy_time_box_value_changed(value: float) -> void:
|
||||
LobbySettings.buy_time = value
|
||||
|
||||
|
||||
func _on_round_box_value_changed(value: float) -> void:
|
||||
LobbySettings.win_score = int(value)
|
||||
%TeamSwitchBox.value = value-1
|
||||
|
||||
|
||||
func _on_team_switch_box_value_changed(value: float) -> void:
|
||||
LobbySettings.half_rounds = int(value)
|
||||
|
||||
|
||||
func _on_allow_multiple_ability_button_toggled(toggled_on: bool) -> void:
|
||||
LobbySettings.allow_multiple_abilities = toggled_on
|
||||
Loading…
Add table
Add a link
Reference in a new issue