Skip to content

Commit 3fad442

Browse files
committed
HUD: Reduce its size
Set a minimum size of 32x32 to items (which are TextureRects). This is the same size as the actual PNG asset. Adjust the stylebox texture override. Set texture margins to 64 (it was 65 which is wrong). Use expand margins and content margins to reduce the transparent zone at the top and right of the texture. Fix #1143
1 parent dca8bff commit 3fad442

1 file changed

Lines changed: 18 additions & 6 deletions

File tree

scenes/ui_elements/story_quest_progress/story_quest_progress.tscn

Lines changed: 18 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,33 +5,45 @@
55
[ext_resource type="PackedScene" uid="uid://1mjm4atk2j6e" path="res://scenes/ui_elements/story_quest_progress/components/item_slot/item_slot.tscn" id="3_mwl7j"]
66

77
[sub_resource type="StyleBoxTexture" id="StyleBoxTexture_hqnrr"]
8+
content_margin_top = 32.0
9+
content_margin_right = 48.0
810
texture = ExtResource("1_cikk2")
9-
texture_margin_left = 65.0
10-
texture_margin_top = 65.0
11-
texture_margin_right = 65.0
12-
texture_margin_bottom = 65.0
11+
texture_margin_left = 64.0
12+
texture_margin_top = 64.0
13+
texture_margin_right = 64.0
14+
texture_margin_bottom = 64.0
15+
expand_margin_top = 32.0
16+
expand_margin_right = 16.0
1317
axis_stretch_horizontal = 1
1418
axis_stretch_vertical = 1
1519

1620
[node name="StoryQuestProgress" type="PanelContainer"]
1721
anchors_preset = 1
1822
anchor_left = 1.0
1923
anchor_right = 1.0
20-
offset_left = -372.0
21-
offset_bottom = 208.0
24+
offset_left = -216.0
25+
offset_bottom = 128.0
2226
grow_horizontal = 0
2327
theme_override_styles/panel = SubResource("StyleBoxTexture_hqnrr")
2428
script = ExtResource("2_hvmtc")
2529

2630
[node name="ItemsContainer" type="HBoxContainer" parent="."]
2731
unique_name_in_owner = true
2832
layout_mode = 2
33+
size_flags_horizontal = 4
34+
size_flags_vertical = 4
2935

3036
[node name="ItemSlot" parent="ItemsContainer" instance=ExtResource("3_mwl7j")]
37+
custom_minimum_size = Vector2(32, 32)
3138
layout_mode = 2
39+
expand_mode = 2
3240

3341
[node name="ItemSlot2" parent="ItemsContainer" instance=ExtResource("3_mwl7j")]
42+
custom_minimum_size = Vector2(32, 32)
3443
layout_mode = 2
44+
expand_mode = 2
3545

3646
[node name="ItemSlot3" parent="ItemsContainer" instance=ExtResource("3_mwl7j")]
47+
custom_minimum_size = Vector2(32, 32)
3748
layout_mode = 2
49+
expand_mode = 2

0 commit comments

Comments
 (0)