mirror of
https://github.com/Steffo99/swear-jar.git
synced 2024-11-21 23:34:18 +00:00
Improve shop ui a bit
This commit is contained in:
parent
ac22a77215
commit
b7b1030037
3 changed files with 48 additions and 3 deletions
|
@ -1,8 +1,47 @@
|
||||||
[gd_resource type="Theme" load_steps=3 format=3 uid="uid://ba5utvfhnxa5i"]
|
[gd_resource type="Theme" load_steps=7 format=3 uid="uid://ba5utvfhnxa5i"]
|
||||||
|
|
||||||
[ext_resource type="FontFile" uid="uid://cs8tiwyb76gig" path="res://interface/font/press-start/prstart.ttf" id="1_mtdor"]
|
[ext_resource type="FontFile" uid="uid://cs8tiwyb76gig" path="res://interface/font/press-start/prstart.ttf" id="1_mtdor"]
|
||||||
|
|
||||||
|
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_7jecc"]
|
||||||
|
content_margin_left = 4.0
|
||||||
|
content_margin_top = 4.0
|
||||||
|
content_margin_right = 4.0
|
||||||
|
content_margin_bottom = 4.0
|
||||||
|
bg_color = Color(0.0627451, 0, 0.411765, 0.709804)
|
||||||
|
corner_radius_top_left = 4
|
||||||
|
corner_radius_top_right = 4
|
||||||
|
corner_radius_bottom_right = 4
|
||||||
|
corner_radius_bottom_left = 4
|
||||||
|
|
||||||
|
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_nln5d"]
|
||||||
|
|
||||||
|
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_81iux"]
|
||||||
|
content_margin_left = 4.0
|
||||||
|
content_margin_top = 4.0
|
||||||
|
content_margin_right = 4.0
|
||||||
|
content_margin_bottom = 4.0
|
||||||
|
bg_color = Color(0.0313726, 0.478431, 0.694118, 0.529412)
|
||||||
|
corner_radius_top_left = 4
|
||||||
|
corner_radius_top_right = 4
|
||||||
|
corner_radius_bottom_right = 4
|
||||||
|
corner_radius_bottom_left = 4
|
||||||
|
|
||||||
|
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_yuycx"]
|
||||||
|
content_margin_left = 4.0
|
||||||
|
content_margin_top = 4.0
|
||||||
|
content_margin_right = 4.0
|
||||||
|
content_margin_bottom = 4.0
|
||||||
|
bg_color = Color(0.262745, 0.717647, 0.984314, 0.709804)
|
||||||
|
corner_radius_top_left = 4
|
||||||
|
corner_radius_top_right = 4
|
||||||
|
corner_radius_bottom_right = 4
|
||||||
|
corner_radius_bottom_left = 4
|
||||||
|
|
||||||
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_knce4"]
|
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_knce4"]
|
||||||
|
content_margin_left = 2.0
|
||||||
|
content_margin_top = 2.0
|
||||||
|
content_margin_right = 2.0
|
||||||
|
content_margin_bottom = 2.0
|
||||||
bg_color = Color(0.0901961, 0.227451, 0.290196, 0.686275)
|
bg_color = Color(0.0901961, 0.227451, 0.290196, 0.686275)
|
||||||
border_width_left = 2
|
border_width_left = 2
|
||||||
border_width_top = 2
|
border_width_top = 2
|
||||||
|
@ -16,4 +55,9 @@ corner_radius_bottom_left = 8
|
||||||
|
|
||||||
[resource]
|
[resource]
|
||||||
default_font = ExtResource("1_mtdor")
|
default_font = ExtResource("1_mtdor")
|
||||||
|
Button/styles/disabled = SubResource("StyleBoxFlat_7jecc")
|
||||||
|
Button/styles/focus = SubResource("StyleBoxEmpty_nln5d")
|
||||||
|
Button/styles/hover = SubResource("StyleBoxFlat_81iux")
|
||||||
|
Button/styles/normal = SubResource("StyleBoxFlat_81iux")
|
||||||
|
Button/styles/pressed = SubResource("StyleBoxFlat_yuycx")
|
||||||
Panel/styles/panel = SubResource("StyleBoxFlat_knce4")
|
Panel/styles/panel = SubResource("StyleBoxFlat_knce4")
|
||||||
|
|
|
@ -72,6 +72,7 @@ var is_buying: bool = false:
|
||||||
set(value):
|
set(value):
|
||||||
is_buying = value
|
is_buying = value
|
||||||
$Contents/Action/BuyButton.text = "Undo" if value else "Buy"
|
$Contents/Action/BuyButton.text = "Undo" if value else "Buy"
|
||||||
|
$Contents/Action/BuyButton.modulate = Color.RED if value else Color.WHITE
|
||||||
|
|
||||||
## Whether this item can be bought one or infinite times.
|
## Whether this item can be bought one or infinite times.
|
||||||
@export var one_shot: bool
|
@export var one_shot: bool
|
||||||
|
|
|
@ -53,7 +53,7 @@ size_flags_horizontal = 3
|
||||||
theme_override_font_sizes/font_size = 16
|
theme_override_font_sizes/font_size = 16
|
||||||
text = "ITEMNAME"
|
text = "ITEMNAME"
|
||||||
vertical_alignment = 1
|
vertical_alignment = 1
|
||||||
autowrap_mode = 2
|
autowrap_mode = 3
|
||||||
uppercase = true
|
uppercase = true
|
||||||
|
|
||||||
[node name="NamePaddingRight" type="Control" parent="Contents/Header"]
|
[node name="NamePaddingRight" type="Control" parent="Contents/Header"]
|
||||||
|
@ -82,7 +82,7 @@ size_flags_horizontal = 3
|
||||||
mouse_filter = 1
|
mouse_filter = 1
|
||||||
theme_override_font_sizes/font_size = 8
|
theme_override_font_sizes/font_size = 8
|
||||||
text = "What does this item do? Nobody knows."
|
text = "What does this item do? Nobody knows."
|
||||||
autowrap_mode = 2
|
autowrap_mode = 3
|
||||||
|
|
||||||
[node name="DescriptionPaddingRight" type="Control" parent="Contents/Description"]
|
[node name="DescriptionPaddingRight" type="Control" parent="Contents/Description"]
|
||||||
custom_minimum_size = Vector2(8, 0)
|
custom_minimum_size = Vector2(8, 0)
|
||||||
|
|
Loading…
Reference in a new issue