面板美化

This commit is contained in:
2025-08-28 22:09:43 +08:00
parent ee5d99b4f7
commit f7c6296954
9 changed files with 1020 additions and 574 deletions

View File

@@ -1,74 +1,70 @@
[gd_scene load_steps=8 format=3 uid="uid://j4ft87o7jk14"]
[gd_scene load_steps=7 format=3 uid="uid://j4ft87o7jk14"]
[ext_resource type="Script" uid="uid://bruqwi63myl1m" path="res://Script/BigPanel/ItemStorePanel.gd" id="1_vx1qn"]
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_n03md"]
bg_color = Color(0.85, 0.95, 0.88, 0.85)
border_width_left = 2
border_width_top = 2
border_width_right = 2
border_width_bottom = 2
border_color = Color(0.6, 0.8, 0.65, 0.9)
corner_radius_top_left = 35
corner_radius_top_right = 35
corner_radius_bottom_right = 35
corner_radius_bottom_left = 35
corner_detail = 20
shadow_color = Color(0, 0, 0, 0.3)
shadow_size = 12
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_8kysg"]
bg_color = Color(0.9, 0.85, 0.75, 0.95)
border_width_left = 8
border_width_top = 8
border_width_right = 8
border_width_bottom = 8
border_color = Color(0.5, 0.3, 0.1, 1)
corner_radius_top_left = 25
corner_radius_top_right = 25
corner_radius_bottom_right = 25
corner_radius_bottom_left = 25
shadow_color = Color(0.3, 0.2, 0.1, 0.4)
shadow_size = 15
shadow_offset = Vector2(3, 3)
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_Button"]
bg_color = Color(0.75, 0.9, 0.8, 0.8)
border_width_left = 1
border_width_top = 1
border_width_right = 1
border_width_bottom = 1
border_color = Color(0.5, 0.75, 0.6, 0.8)
corner_radius_top_left = 20
corner_radius_top_right = 20
corner_radius_bottom_right = 20
corner_radius_bottom_left = 20
shadow_color = Color(0, 0, 0, 0.2)
shadow_size = 6
shadow_offset = Vector2(2, 2)
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_ButtonHover"]
bg_color = Color(0.8, 0.95, 0.85, 0.9)
border_width_left = 1
border_width_top = 1
border_width_right = 1
border_width_bottom = 1
border_color = Color(0.4, 0.7, 0.5, 1)
corner_radius_top_left = 20
corner_radius_top_right = 20
corner_radius_bottom_right = 20
corner_radius_bottom_left = 20
shadow_color = Color(0, 0, 0, 0.25)
shadow_size = 8
shadow_offset = Vector2(2, 2)
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_ButtonPressed"]
bg_color = Color(0.65, 0.8, 0.7, 0.9)
border_width_left = 1
border_width_top = 1
border_width_right = 1
border_width_bottom = 1
border_color = Color(0.3, 0.6, 0.4, 1)
corner_radius_top_left = 20
corner_radius_top_right = 20
corner_radius_bottom_right = 20
corner_radius_bottom_left = 20
shadow_color = Color(0, 0, 0, 0.15)
shadow_size = 4
shadow_offset = Vector2(1, 1)
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_ScrollBar"]
bg_color = Color(0.8, 0.9, 0.85, 0.7)
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_uc6q1"]
bg_color = Color(0.95, 0.92, 0.85, 0.9)
border_width_left = 3
border_width_top = 3
border_width_right = 3
border_width_bottom = 3
border_color = Color(0.6, 0.4, 0.2, 0.8)
corner_radius_top_left = 15
corner_radius_top_right = 15
corner_radius_bottom_right = 15
corner_radius_bottom_left = 15
corner_detail = 20
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_button_hover"]
bg_color = Color(0.85, 0.7, 0.5, 1)
border_width_left = 2
border_width_top = 2
border_width_right = 2
border_width_bottom = 2
border_color = Color(0.5, 0.4, 0.2, 1)
corner_radius_top_left = 12
corner_radius_top_right = 12
corner_radius_bottom_right = 12
corner_radius_bottom_left = 12
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_button_pressed"]
bg_color = Color(0.65, 0.5, 0.3, 1)
border_width_left = 2
border_width_top = 2
border_width_right = 2
border_width_bottom = 2
border_color = Color(0.3, 0.2, 0.05, 1)
corner_radius_top_left = 12
corner_radius_top_right = 12
corner_radius_bottom_right = 12
corner_radius_bottom_left = 12
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_button"]
bg_color = Color(0.75, 0.6, 0.4, 1)
border_width_left = 2
border_width_top = 2
border_width_right = 2
border_width_bottom = 2
border_color = Color(0.4, 0.3, 0.1, 1)
corner_radius_top_left = 12
corner_radius_top_right = 12
corner_radius_bottom_right = 12
corner_radius_bottom_left = 12
[node name="ItemStorePanel" type="Panel"]
offset_left = 58.0
@@ -78,7 +74,7 @@ offset_bottom = 799.0
scale = Vector2(0.8, 0.8)
size_flags_horizontal = 3
size_flags_vertical = 3
theme_override_styles/panel = SubResource("StyleBoxFlat_n03md")
theme_override_styles/panel = SubResource("StyleBoxFlat_8kysg")
script = ExtResource("1_vx1qn")
[node name="TMBackGround" type="ColorRect" parent="."]
@@ -87,18 +83,18 @@ offset_left = -184.0
offset_top = -100.0
offset_right = 1571.0
offset_bottom = 804.0
color = Color(0.9, 0.98, 0.92, 0.2)
color = Color(0.9, 0.8, 0.6, 0.3)
[node name="ScrollContainer" type="ScrollContainer" parent="."]
layout_mode = 2
offset_left = 15.0
offset_left = 51.0
offset_top = 88.0
offset_right = 3799.0
offset_bottom = 1626.0
offset_right = 3663.0
offset_bottom = 1571.0
scale = Vector2(0.4, 0.4)
size_flags_vertical = 3
theme_override_styles/panel = SubResource("StyleBoxFlat_uc6q1")
horizontal_scroll_mode = 0
theme_override_styles/panel = SubResource("StyleBoxFlat_ScrollBar")
[node name="Store_Grid" type="GridContainer" parent="ScrollContainer"]
layout_mode = 2
@@ -111,15 +107,15 @@ layout_mode = 2
offset_right = 1540.0
offset_bottom = 75.0
size_flags_horizontal = 3
theme_override_colors/font_color = Color(0.2, 0.6, 0.3, 1)
theme_override_colors/font_shadow_color = Color(0, 0, 0, 0.4)
theme_override_colors/font_outline_color = Color(0.8, 0.95, 0.85, 0.8)
theme_override_colors/font_color = Color(0.4, 0.2, 0.1, 1)
theme_override_colors/font_shadow_color = Color(1, 0.9, 0.7, 0.8)
theme_override_colors/font_outline_color = Color(0.7, 0.5, 0.3, 1)
theme_override_constants/shadow_offset_x = 2
theme_override_constants/shadow_offset_y = 2
theme_override_constants/outline_size = 8
theme_override_constants/outline_size = 3
theme_override_constants/shadow_outline_size = 8
theme_override_font_sizes/font_size = 42
text = "道具商店"
theme_override_font_sizes/font_size = 45
text = "🏪 道具商店 🏪"
horizontal_alignment = 1
vertical_alignment = 1
@@ -130,15 +126,12 @@ offset_left = 1457.5
offset_top = 13.75
offset_right = 1517.5
offset_bottom = 76.75
theme_override_colors/font_color = Color(0.3, 0.5, 0.35, 1)
theme_override_colors/font_shadow_color = Color(0, 0, 0, 0.3)
theme_override_constants/shadow_offset_x = 1
theme_override_constants/shadow_offset_y = 1
theme_override_font_sizes/font_size = 40
theme_override_styles/normal = SubResource("StyleBoxFlat_Button")
theme_override_styles/hover = SubResource("StyleBoxFlat_ButtonHover")
theme_override_styles/pressed = SubResource("StyleBoxFlat_ButtonPressed")
text = "X"
theme_override_colors/font_color = Color(0.8, 0.2, 0.2, 1)
theme_override_font_sizes/font_size = 35
theme_override_styles/hover = SubResource("StyleBoxFlat_button_hover")
theme_override_styles/pressed = SubResource("StyleBoxFlat_button_pressed")
theme_override_styles/normal = SubResource("StyleBoxFlat_button")
text = "❌"
[node name="RefreshButton" type="Button" parent="."]
custom_minimum_size = Vector2(60, 60)
@@ -147,83 +140,68 @@ offset_left = 12.5
offset_top = 12.5
offset_right = 100.5
offset_bottom = 75.5
theme_override_colors/font_color = Color(0.2, 0.5, 0.3, 1)
theme_override_colors/font_shadow_color = Color(0, 0, 0, 0.3)
theme_override_constants/shadow_offset_x = 1
theme_override_constants/shadow_offset_y = 1
theme_override_font_sizes/font_size = 32
theme_override_styles/normal = SubResource("StyleBoxFlat_Button")
theme_override_styles/hover = SubResource("StyleBoxFlat_ButtonHover")
theme_override_styles/pressed = SubResource("StyleBoxFlat_ButtonPressed")
text = "刷新"
theme_override_colors/font_color = Color(0.3, 0.2, 0.1, 1)
theme_override_font_sizes/font_size = 28
theme_override_styles/hover = SubResource("StyleBoxFlat_button_hover")
theme_override_styles/pressed = SubResource("StyleBoxFlat_button_pressed")
theme_override_styles/normal = SubResource("StyleBoxFlat_button")
text = "🔄刷新"
[node name="All_Filter" type="Button" parent="."]
custom_minimum_size = Vector2(60, 60)
layout_mode = 2
offset_left = 217.5
offset_top = 12.5
offset_right = 305.5
offset_bottom = 75.5
theme_override_colors/font_color = Color(0.25, 0.5, 0.3, 1)
theme_override_colors/font_shadow_color = Color(0, 0, 0, 0.3)
theme_override_constants/shadow_offset_x = 1
theme_override_constants/shadow_offset_y = 1
theme_override_font_sizes/font_size = 32
theme_override_styles/normal = SubResource("StyleBoxFlat_Button")
theme_override_styles/hover = SubResource("StyleBoxFlat_ButtonHover")
theme_override_styles/pressed = SubResource("StyleBoxFlat_ButtonPressed")
text = "全部"
offset_left = 161.25
offset_top = 13.75
offset_right = 259.25
offset_bottom = 76.75
theme_override_colors/font_color = Color(0.3, 0.2, 0.1, 1)
theme_override_font_sizes/font_size = 28
theme_override_styles/hover = SubResource("StyleBoxFlat_button_hover")
theme_override_styles/pressed = SubResource("StyleBoxFlat_button_pressed")
theme_override_styles/normal = SubResource("StyleBoxFlat_button")
text = "🏪全部"
[node name="Pet_Filter" type="Button" parent="."]
custom_minimum_size = Vector2(60, 60)
layout_mode = 2
offset_left = 310.0
offset_left = 277.5
offset_top = 13.75
offset_right = 398.0
offset_right = 375.5
offset_bottom = 76.75
theme_override_colors/font_color = Color(0.25, 0.5, 0.35, 1)
theme_override_colors/font_shadow_color = Color(0, 0, 0, 0.3)
theme_override_constants/shadow_offset_x = 1
theme_override_constants/shadow_offset_y = 1
theme_override_font_sizes/font_size = 32
theme_override_styles/normal = SubResource("StyleBoxFlat_Button")
theme_override_styles/hover = SubResource("StyleBoxFlat_ButtonHover")
theme_override_styles/pressed = SubResource("StyleBoxFlat_ButtonPressed")
text = "宠物"
theme_override_colors/font_color = Color(0.3, 0.2, 0.1, 1)
theme_override_font_sizes/font_size = 28
theme_override_styles/hover = SubResource("StyleBoxFlat_button_hover")
theme_override_styles/pressed = SubResource("StyleBoxFlat_button_pressed")
theme_override_styles/normal = SubResource("StyleBoxFlat_button")
text = "🐾宠物"
[node name="Crop_Filter" type="Button" parent="."]
custom_minimum_size = Vector2(60, 60)
layout_mode = 2
offset_left = 397.5
offset_top = 13.75
offset_right = 485.5
offset_bottom = 76.75
theme_override_colors/font_color = Color(0.2, 0.5, 0.25, 1)
theme_override_colors/font_shadow_color = Color(0, 0, 0, 0.3)
theme_override_constants/shadow_offset_x = 1
theme_override_constants/shadow_offset_y = 1
theme_override_font_sizes/font_size = 32
theme_override_styles/normal = SubResource("StyleBoxFlat_Button")
theme_override_styles/hover = SubResource("StyleBoxFlat_ButtonHover")
theme_override_styles/pressed = SubResource("StyleBoxFlat_ButtonPressed")
text = "作物"
offset_left = 391.25
offset_top = 12.5
offset_right = 489.25
offset_bottom = 75.5
theme_override_colors/font_color = Color(0.3, 0.2, 0.1, 1)
theme_override_font_sizes/font_size = 28
theme_override_styles/hover = SubResource("StyleBoxFlat_button_hover")
theme_override_styles/pressed = SubResource("StyleBoxFlat_button_pressed")
theme_override_styles/normal = SubResource("StyleBoxFlat_button")
text = "🌾作物"
[node name="Farm_Filter" type="Button" parent="."]
custom_minimum_size = Vector2(60, 60)
layout_mode = 2
offset_left = 485.0
offset_top = 13.75
offset_right = 573.0
offset_bottom = 76.75
theme_override_colors/font_color = Color(0.25, 0.5, 0.3, 1)
theme_override_colors/font_shadow_color = Color(0, 0, 0, 0.3)
theme_override_constants/shadow_offset_x = 1
theme_override_constants/shadow_offset_y = 1
theme_override_font_sizes/font_size = 32
theme_override_styles/normal = SubResource("StyleBoxFlat_Button")
theme_override_styles/hover = SubResource("StyleBoxFlat_ButtonHover")
theme_override_styles/pressed = SubResource("StyleBoxFlat_ButtonPressed")
text = "农场"
offset_left = 507.5
offset_top = 12.5
offset_right = 605.5
offset_bottom = 75.5
theme_override_colors/font_color = Color(0.3, 0.2, 0.1, 1)
theme_override_font_sizes/font_size = 28
theme_override_styles/hover = SubResource("StyleBoxFlat_button_hover")
theme_override_styles/pressed = SubResource("StyleBoxFlat_button_pressed")
theme_override_styles/normal = SubResource("StyleBoxFlat_button")
text = "🏡农场"
[connection signal="pressed" from="RefreshButton" to="." method="_on_refresh_button_pressed"]
[connection signal="pressed" from="All_Filter" to="." method="_on_all_filter_pressed"]