fuzzyworld

godot-shooter / commit

Proper death screen positioning.

1e610e5d8511602755c28d0a48b87bdd60f3f73c · Pavel Safronov · 2023-11-01 21:52:13 -0700 · parents 682d509883ab

Proper death screen positioning.
 HUD.tscn    | 24 ++++++++++++------------
 Player.tscn | 14 ++++----------
 2 files changed, 16 insertions(+), 22 deletions(-)

diff --git a/HUD.tscn b/HUD.tscn
index 04098df..c44d76c 100644
--- a/HUD.tscn
+++ b/HUD.tscn
@@ -58,29 +58,29 @@ margin_right = 40.0
 margin_bottom = 40.0
 
 [node name="HBoxContainer" type="HBoxContainer" parent="VBoxContainer"]
-margin_right = 956.0
-margin_bottom = 115.0
+margin_right = 617.0
+margin_bottom = 74.0
 
 [node name="ScoreText" type="Label" parent="VBoxContainer/HBoxContainer"]
-margin_right = 296.0
-margin_bottom = 115.0
+margin_right = 192.0
+margin_bottom = 74.0
 text = "Score: "
 
 [node name="Score" type="Label" parent="VBoxContainer/HBoxContainer"]
-margin_left = 300.0
-margin_right = 426.0
-margin_bottom = 115.0
+margin_left = 196.0
+margin_right = 278.0
+margin_bottom = 74.0
 text = "100"
 uppercase = true
 
 [node name="CenterContainer" type="CenterContainer" parent="VBoxContainer"]
-margin_top = 119.0
-margin_right = 956.0
-margin_bottom = 234.0
+margin_top = 78.0
+margin_right = 617.0
+margin_bottom = 152.0
 
 [node name="Label" type="Label" parent="VBoxContainer/CenterContainer"]
-margin_right = 956.0
-margin_bottom = 115.0
+margin_right = 617.0
+margin_bottom = 74.0
 theme = ExtResource( 1 )
 text = "Tap anywhere to travel"
 align = 1
diff --git a/Player.tscn b/Player.tscn
index 4d9f78a..7f1f864 100644
--- a/Player.tscn
+++ b/Player.tscn
@@ -37,22 +37,16 @@ visible = false
 
 [node name="CanvasLayer" type="CanvasLayer" parent="."]
 layer = 100
-follow_viewport_enable = true
 
 [node name="CenterContainer" type="CenterContainer" parent="CanvasLayer"]
-anchor_right = 1.0
-anchor_bottom = 1.0
-margin_left = -1.0
-margin_right = -201.0
-margin_bottom = -200.0
+margin_left = 109.0
+margin_top = 84.0
+margin_right = 109.0
+margin_bottom = 84.0
 mouse_filter = 2
 
 [node name="DeathScreen" type="Control" parent="CanvasLayer/CenterContainer"]
 visible = false
-margin_left = 412.0
-margin_top = 200.0
-margin_right = 412.0
-margin_bottom = 200.0
 mouse_filter = 2
 size_flags_horizontal = 5
 size_flags_vertical = 5