Improved performance

This commit is contained in:
2024-02-17 19:43:47 +01:00
parent cb066f409a
commit 2bc4200f5b
12 changed files with 228 additions and 116 deletions

View File

@ -16,25 +16,21 @@
[ext_resource type="Script" path="res://ui/debug/StateLabel.gd" id="12_rr0mv"]
[ext_resource type="PackedScene" uid="uid://y6kdpmp5glv0" path="res://ui/inventory/Inventory.tscn" id="13_1fc2b"]
[node name="UI" type="Control"]
layout_mode = 3
anchors_preset = 0
[node name="UI" type="CanvasLayer"]
script = ExtResource("1_l5b6o")
[node name="Canvas" type="CanvasLayer" parent="."]
[node name="TopLeft" type="MarginContainer" parent="Canvas"]
[node name="TopLeft" type="MarginContainer" parent="."]
offset_right = 40.0
offset_bottom = 50.0
[node name="VBoxContainer" type="VBoxContainer" parent="Canvas/TopLeft"]
[node name="VBoxContainer" type="VBoxContainer" parent="TopLeft"]
layout_mode = 2
[node name="FPS" parent="Canvas/TopLeft/VBoxContainer" instance=ExtResource("1_7s8uu")]
[node name="FPS" parent="TopLeft/VBoxContainer" instance=ExtResource("1_7s8uu")]
layout_mode = 2
script = ExtResource("2_i200p")
[node name="Process" parent="Canvas/TopLeft/VBoxContainer" instance=ExtResource("1_7s8uu")]
[node name="Process" parent="TopLeft/VBoxContainer" instance=ExtResource("1_7s8uu")]
layout_mode = 2
script = ExtResource("5_ab7ln")
monitor = 1
@ -42,7 +38,7 @@ multiply = 1000.0
precision = 0.1
suffix = " ms"
[node name="Physics" parent="Canvas/TopLeft/VBoxContainer" instance=ExtResource("1_7s8uu")]
[node name="Physics" parent="TopLeft/VBoxContainer" instance=ExtResource("1_7s8uu")]
layout_mode = 2
script = ExtResource("5_ab7ln")
monitor = 2
@ -50,7 +46,7 @@ multiply = 1000.0
precision = 0.1
suffix = " ms"
[node name="Draw calls" parent="Canvas/TopLeft/VBoxContainer" instance=ExtResource("1_7s8uu")]
[node name="Draw calls" parent="TopLeft/VBoxContainer" instance=ExtResource("1_7s8uu")]
layout_mode = 2
script = ExtResource("5_ab7ln")
monitor = 13
@ -58,7 +54,7 @@ multiply = 1.0
precision = 1.0
suffix = ""
[node name="BottomLeft" type="MarginContainer" parent="Canvas"]
[node name="BottomLeft" type="MarginContainer" parent="."]
anchors_preset = 2
anchor_top = 1.0
anchor_bottom = 1.0
@ -66,22 +62,22 @@ offset_top = -134.0
offset_right = 263.0
grow_vertical = 0
[node name="Chat" type="VBoxContainer" parent="Canvas/BottomLeft"]
[node name="Chat" type="VBoxContainer" parent="BottomLeft"]
layout_mode = 2
alignment = 2
[node name="ChatBox" type="RichTextLabel" parent="Canvas/BottomLeft/Chat"]
[node name="ChatBox" type="RichTextLabel" parent="BottomLeft/Chat"]
layout_mode = 2
size_flags_vertical = 3
bbcode_enabled = true
scroll_following = true
script = ExtResource("5_43juw")
[node name="ChatInput" type="LineEdit" parent="Canvas/BottomLeft/Chat"]
[node name="ChatInput" type="LineEdit" parent="BottomLeft/Chat"]
layout_mode = 2
script = ExtResource("6_cg2h5")
[node name="BottomRight" type="MarginContainer" parent="Canvas"]
[node name="BottomRight" type="MarginContainer" parent="."]
anchors_preset = 3
anchor_left = 1.0
anchor_top = 1.0
@ -92,26 +88,26 @@ offset_top = -54.0
grow_horizontal = 0
grow_vertical = 0
[node name="VBoxContainer" type="VBoxContainer" parent="Canvas/BottomRight"]
[node name="VBoxContainer" type="VBoxContainer" parent="BottomRight"]
layout_mode = 2
alignment = 2
[node name="Ping" parent="Canvas/BottomRight/VBoxContainer" instance=ExtResource("1_7s8uu")]
[node name="Ping" parent="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")]
[node name="Send" parent="BottomRight/VBoxContainer" instance=ExtResource("1_7s8uu")]
layout_mode = 2
alignment = 2
script = ExtResource("7_cfnpx")
[node name="Receive" parent="Canvas/BottomRight/VBoxContainer" instance=ExtResource("1_7s8uu")]
[node name="Receive" parent="BottomRight/VBoxContainer" instance=ExtResource("1_7s8uu")]
layout_mode = 2
alignment = 2
script = ExtResource("8_ogt38")
[node name="TopRight" type="MarginContainer" parent="Canvas"]
[node name="TopRight" type="MarginContainer" parent="."]
anchors_preset = 1
anchor_left = 1.0
anchor_right = 1.0
@ -119,25 +115,25 @@ offset_left = -79.0
offset_bottom = 102.0
grow_horizontal = 0
[node name="VBoxContainer" type="VBoxContainer" parent="Canvas/TopRight"]
[node name="VBoxContainer" type="VBoxContainer" parent="TopRight"]
layout_mode = 2
[node name="State" parent="Canvas/TopRight/VBoxContainer" instance=ExtResource("1_7s8uu")]
[node name="State" parent="TopRight/VBoxContainer" instance=ExtResource("1_7s8uu")]
layout_mode = 2
alignment = 2
script = ExtResource("12_rr0mv")
[node name="Position" parent="Canvas/TopRight/VBoxContainer" instance=ExtResource("1_7s8uu")]
[node name="Position" parent="TopRight/VBoxContainer" instance=ExtResource("1_7s8uu")]
layout_mode = 2
alignment = 2
script = ExtResource("4_beqf6")
[node name="Velocity" parent="Canvas/TopRight/VBoxContainer" instance=ExtResource("1_7s8uu")]
[node name="Velocity" parent="TopRight/VBoxContainer" instance=ExtResource("1_7s8uu")]
layout_mode = 2
alignment = 2
script = ExtResource("5_8lm6a")
[node name="ConnectPanel" type="Panel" parent="Canvas"]
[node name="ConnectPanel" type="Panel" parent="."]
visible = false
anchors_preset = 15
anchor_right = 1.0
@ -146,7 +142,7 @@ grow_horizontal = 2
grow_vertical = 2
script = ExtResource("11_cwl0t")
[node name="ConnectLabel" type="Label" parent="Canvas/ConnectPanel"]
[node name="ConnectLabel" type="Label" parent="ConnectPanel"]
layout_mode = 1
anchors_preset = 8
anchor_left = 0.5
@ -161,12 +157,12 @@ grow_horizontal = 2
grow_vertical = 2
text = "Connecting..."
[node name="Settings" parent="Canvas" instance=ExtResource("11_rt7sl")]
[node name="Settings" parent="." instance=ExtResource("11_rt7sl")]
visible = false
anchor_left = 0.3
anchor_right = 0.7
[node name="Inventory" parent="Canvas" instance=ExtResource("13_1fc2b")]
[node name="Inventory" parent="." instance=ExtResource("13_1fc2b")]
visible = false
anchors_preset = -1
anchor_left = 0.25
@ -174,6 +170,11 @@ anchor_top = 0.25
anchor_right = 0.75
anchor_bottom = 0.75
[connection signal="focus_entered" from="Canvas/BottomLeft/Chat/ChatInput" to="Canvas/BottomLeft/Chat/ChatInput" method="_on_focus_entered"]
[connection signal="focus_exited" from="Canvas/BottomLeft/Chat/ChatInput" to="Canvas/BottomLeft/Chat/ChatInput" method="_on_focus_exited"]
[connection signal="text_submitted" from="Canvas/BottomLeft/Chat/ChatInput" to="Canvas/BottomLeft/Chat/ChatInput" method="_on_text_submitted"]
[node name="UI" type="Control" parent="."]
layout_mode = 3
anchors_preset = 0
script = ExtResource("1_l5b6o")
[connection signal="focus_entered" from="BottomLeft/Chat/ChatInput" to="BottomLeft/Chat/ChatInput" method="_on_focus_entered"]
[connection signal="focus_exited" from="BottomLeft/Chat/ChatInput" to="BottomLeft/Chat/ChatInput" method="_on_focus_exited"]
[connection signal="text_submitted" from="BottomLeft/Chat/ChatInput" to="BottomLeft/Chat/ChatInput" method="_on_text_submitted"]