fixed settings
This commit is contained in:
parent
63209ccc1e
commit
5ee6a7c4a8
3 changed files with 19 additions and 18 deletions
|
|
@ -32,7 +32,7 @@ layout_mode = 2
|
|||
layout_mode = 2
|
||||
text = "Чувствительность"
|
||||
|
||||
[node name="HSlider" type="HSlider" parent="CenterContainer/PanelContainer/VBoxContainer/Sensitivity"]
|
||||
[node name="SensitivitySlider" type="HSlider" parent="CenterContainer/PanelContainer/VBoxContainer/Sensitivity"]
|
||||
custom_minimum_size = Vector2(256, 0)
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
|
|
@ -41,7 +41,7 @@ max_value = 0.1
|
|||
step = 0.001
|
||||
value = 0.02
|
||||
|
||||
[node name="SpinBox" type="SpinBox" parent="CenterContainer/PanelContainer/VBoxContainer/Sensitivity"]
|
||||
[node name="SensitivityBox" type="SpinBox" parent="CenterContainer/PanelContainer/VBoxContainer/Sensitivity"]
|
||||
layout_mode = 2
|
||||
max_value = 0.1
|
||||
step = 0.001
|
||||
|
|
@ -63,7 +63,8 @@ max_value = 1.0
|
|||
step = 0.01
|
||||
value = 1.0
|
||||
|
||||
[connection signal="toggled" from="CenterContainer/PanelContainer/VBoxContainer/FullscreenButton" to="." method="_on_check_button_toggled"]
|
||||
[connection signal="value_changed" from="CenterContainer/PanelContainer/VBoxContainer/Sensitivity/HSlider" to="." method="_on_h_slider_value_changed"]
|
||||
[connection signal="value_changed" from="CenterContainer/PanelContainer/VBoxContainer/Sensitivity/SpinBox" to="." method="_on_spin_box_value_changed"]
|
||||
[connection signal="value_changed" from="CenterContainer/PanelContainer/VBoxContainer/GameplayMainAudio/GameplayMainSlider" to="." method="_on_gameplay_main_slider_value_changed"]
|
||||
[connection signal="pressed" from="CenterContainer/PanelContainer/VBoxContainer/FullscreenButton" to="CenterContainer/PanelContainer" method="_on_fullscreen_button_pressed"]
|
||||
[connection signal="toggled" from="CenterContainer/PanelContainer/VBoxContainer/FullscreenButton" to="CenterContainer/PanelContainer" method="_on_fullscreen_button_toggled"]
|
||||
[connection signal="value_changed" from="CenterContainer/PanelContainer/VBoxContainer/Sensitivity/SensitivitySlider" to="CenterContainer/PanelContainer" method="_on_sensitivity_slider_value_changed"]
|
||||
[connection signal="value_changed" from="CenterContainer/PanelContainer/VBoxContainer/Sensitivity/SensitivityBox" to="CenterContainer/PanelContainer" method="_on_sensitivity_box_value_changed"]
|
||||
[connection signal="value_changed" from="CenterContainer/PanelContainer/VBoxContainer/GameplayMainAudio/GameplayMainSlider" to="CenterContainer/PanelContainer" method="_on_gameplay_main_slider_value_changed"]
|
||||
|
|
|
|||
|
|
@ -2,18 +2,6 @@ extends Control
|
|||
|
||||
var cached_mouse_state: Input.MouseMode
|
||||
|
||||
func _on_check_button_toggled(toggled_on: bool) -> void:
|
||||
DisplayServer.window_set_mode(DisplayServer.WINDOW_MODE_FULLSCREEN if toggled_on else DisplayServer.WINDOW_MODE_WINDOWED)
|
||||
|
||||
func _on_h_slider_value_changed(value: float) -> void:
|
||||
$VBoxContainer/Sensitivity/SpinBox.set_value_no_signal(value)
|
||||
ClientSettings.SENSITIVITY = value
|
||||
|
||||
|
||||
func _on_spin_box_value_changed(value: float) -> void:
|
||||
$VBoxContainer/Sensitivity/HSlider.set_value_no_signal(value)
|
||||
ClientSettings.SENSITIVITY = value
|
||||
|
||||
func _input(event: InputEvent) -> void:
|
||||
if event.is_action_pressed("menu_settings"):
|
||||
visible = not visible
|
||||
|
|
@ -26,3 +14,14 @@ func _input(event: InputEvent) -> void:
|
|||
|
||||
func _on_gameplay_main_slider_value_changed(value: float) -> void:
|
||||
AudioServer.set_bus_volume_linear(1,value)
|
||||
|
||||
func _on_fullscreen_button_toggled(toggled_on: bool) -> void:
|
||||
DisplayServer.window_set_mode(DisplayServer.WINDOW_MODE_FULLSCREEN if toggled_on else DisplayServer.WINDOW_MODE_WINDOWED)
|
||||
|
||||
func _on_sensitivity_slider_value_changed(value: float) -> void:
|
||||
$VBoxContainer/Sensitivity/SpinBox.set_value_no_signal(value)
|
||||
ClientSettings.SENSITIVITY = value
|
||||
|
||||
func _on_sensitivity_box_value_changed(value: float) -> void:
|
||||
$VBoxContainer/Sensitivity/HSlider.set_value_no_signal(value)
|
||||
ClientSettings.SENSITIVITY = value
|
||||
|
|
|
|||
|
|
@ -15,6 +15,7 @@ var attack_team: Array[int] = []
|
|||
var defence_team: Array[int] = []
|
||||
var specators_team: Array[int] = []
|
||||
|
||||
# Host defined variables
|
||||
var win_score = 13
|
||||
var half_rounds = 12
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue