Improved UI

This commit is contained in:
Eduard Urbach 2024-02-16 23:45:31 +01:00
parent 2b7c1028cc
commit b6a83031f9
Signed by: akyoto
GPG Key ID: C874F672B1AF20C0
2 changed files with 27 additions and 3 deletions

View File

@ -34,7 +34,7 @@ layout_mode = 2
layout_mode = 2
script = ExtResource("2_i200p")
[node name="Frame" parent="Canvas/TopLeft/VBoxContainer" instance=ExtResource("1_7s8uu")]
[node name="Process" parent="Canvas/TopLeft/VBoxContainer" instance=ExtResource("1_7s8uu")]
layout_mode = 2
script = ExtResource("5_ab7ln")
monitor = 1
@ -42,9 +42,21 @@ multiply = 1000.0
precision = 0.1
suffix = " ms"
[node name="Ping" parent="Canvas/TopLeft/VBoxContainer" instance=ExtResource("1_7s8uu")]
[node name="Physics" parent="Canvas/TopLeft/VBoxContainer" instance=ExtResource("1_7s8uu")]
layout_mode = 2
script = ExtResource("3_xjdws")
script = ExtResource("5_ab7ln")
monitor = 2
multiply = 1000.0
precision = 0.1
suffix = " ms"
[node name="Draw calls" parent="Canvas/TopLeft/VBoxContainer" instance=ExtResource("1_7s8uu")]
layout_mode = 2
script = ExtResource("5_ab7ln")
monitor = 13
multiply = 1.0
precision = 1.0
suffix = ""
[node name="BottomLeft" type="MarginContainer" parent="Canvas"]
anchors_preset = 2
@ -84,6 +96,11 @@ grow_vertical = 0
layout_mode = 2
alignment = 2
[node name="Ping" parent="Canvas/BottomRight/VBoxContainer" instance=ExtResource("1_7s8uu")]
layout_mode = 2
alignment = 2
script = ExtResource("3_xjdws")
[node name="Send" parent="Canvas/BottomRight/VBoxContainer" instance=ExtResource("1_7s8uu")]
layout_mode = 2
alignment = 2

View File

@ -1,5 +1,8 @@
extends LineEdit
func _ready():
modulate.a = 0.0
func _unhandled_input(event):
if Global.interacting_with_ui:
return
@ -9,9 +12,13 @@ func _unhandled_input(event):
get_viewport().set_input_as_handled()
func _on_focus_entered():
var tween := get_tree().create_tween()
tween.tween_property(self, "modulate", Color(1, 1, 1, 1), 0.2)
Global.interacting_with_ui = true
func _on_focus_exited():
var tween := get_tree().create_tween()
tween.tween_property(self, "modulate", Color(1, 1, 1, 0), 0.2)
Global.interacting_with_ui = false
func _on_text_submitted(message: String):