mirror of
https://github.com/Insality/druid
synced 2025-09-27 10:02:19 +02:00
Solve #114 Add default component templates for fast usage
This commit is contained in:
@@ -2,10 +2,6 @@ images {
|
||||
image: "/example/assets/images/back/back_blue.png"
|
||||
sprite_trim_mode: SPRITE_TRIM_MODE_OFF
|
||||
}
|
||||
images {
|
||||
image: "/example/assets/images/back/back_gray.png"
|
||||
sprite_trim_mode: SPRITE_TRIM_MODE_OFF
|
||||
}
|
||||
images {
|
||||
image: "/example/assets/images/back/back_green.png"
|
||||
sprite_trim_mode: SPRITE_TRIM_MODE_OFF
|
||||
@@ -34,14 +30,6 @@ images {
|
||||
image: "/example/assets/images/progress/progress_back.png"
|
||||
sprite_trim_mode: SPRITE_TRIM_MODE_OFF
|
||||
}
|
||||
images {
|
||||
image: "/example/assets/images/progress/progress_fill_green.png"
|
||||
sprite_trim_mode: SPRITE_TRIM_MODE_OFF
|
||||
}
|
||||
images {
|
||||
image: "/example/assets/images/progress/progress_fill_red.png"
|
||||
sprite_trim_mode: SPRITE_TRIM_MODE_OFF
|
||||
}
|
||||
images {
|
||||
image: "/example/assets/images/progress/progress_fill_yellow.png"
|
||||
sprite_trim_mode: SPRITE_TRIM_MODE_OFF
|
||||
|
@@ -66,6 +66,7 @@ nodes {
|
||||
alpha: 1.0
|
||||
template_node_child: false
|
||||
size_mode: SIZE_MODE_MANUAL
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -121,6 +122,7 @@ nodes {
|
||||
alpha: 1.0
|
||||
template_node_child: false
|
||||
size_mode: SIZE_MODE_AUTO
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -176,6 +178,7 @@ nodes {
|
||||
alpha: 1.0
|
||||
template_node_child: false
|
||||
size_mode: SIZE_MODE_AUTO
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -231,6 +234,7 @@ nodes {
|
||||
alpha: 1.0
|
||||
template_node_child: false
|
||||
size_mode: SIZE_MODE_MANUAL
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -286,6 +290,7 @@ nodes {
|
||||
alpha: 1.0
|
||||
template_node_child: false
|
||||
size_mode: SIZE_MODE_MANUAL
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -341,6 +346,7 @@ nodes {
|
||||
alpha: 1.0
|
||||
template_node_child: false
|
||||
size_mode: SIZE_MODE_AUTO
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -396,6 +402,7 @@ nodes {
|
||||
alpha: 1.0
|
||||
template_node_child: false
|
||||
size_mode: SIZE_MODE_MANUAL
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -459,6 +466,7 @@ nodes {
|
||||
template_node_child: false
|
||||
text_leading: 1.0
|
||||
text_tracking: 0.0
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -514,6 +522,7 @@ nodes {
|
||||
alpha: 1.0
|
||||
template_node_child: false
|
||||
size_mode: SIZE_MODE_MANUAL
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -569,6 +578,7 @@ nodes {
|
||||
alpha: 1.0
|
||||
template_node_child: false
|
||||
size_mode: SIZE_MODE_MANUAL
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -632,6 +642,7 @@ nodes {
|
||||
template_node_child: false
|
||||
text_leading: 1.0
|
||||
text_tracking: 0.0
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -687,6 +698,7 @@ nodes {
|
||||
alpha: 1.0
|
||||
template_node_child: false
|
||||
size_mode: SIZE_MODE_AUTO
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -721,7 +733,7 @@ nodes {
|
||||
}
|
||||
type: TYPE_BOX
|
||||
blend_mode: BLEND_MODE_ALPHA
|
||||
texture: "kenney/back_gray"
|
||||
texture: "kenney/progress_back"
|
||||
id: "panel_top"
|
||||
xanchor: XANCHOR_NONE
|
||||
yanchor: YANCHOR_NONE
|
||||
@@ -742,6 +754,7 @@ nodes {
|
||||
alpha: 1.0
|
||||
template_node_child: false
|
||||
size_mode: SIZE_MODE_MANUAL
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -782,6 +795,7 @@ nodes {
|
||||
alpha: 1.0
|
||||
template: "/example/templates/button.gui"
|
||||
template_node_child: false
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -839,6 +853,7 @@ nodes {
|
||||
overridden_fields: 20
|
||||
template_node_child: true
|
||||
size_mode: SIZE_MODE_MANUAL
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -907,6 +922,7 @@ nodes {
|
||||
template_node_child: true
|
||||
text_leading: 1.0
|
||||
text_tracking: 0.0
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -947,6 +963,7 @@ nodes {
|
||||
alpha: 1.0
|
||||
template: "/example/templates/button.gui"
|
||||
template_node_child: false
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -1004,6 +1021,7 @@ nodes {
|
||||
overridden_fields: 20
|
||||
template_node_child: true
|
||||
size_mode: SIZE_MODE_MANUAL
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -1072,6 +1090,7 @@ nodes {
|
||||
template_node_child: true
|
||||
text_leading: 1.0
|
||||
text_tracking: 0.0
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -1112,6 +1131,7 @@ nodes {
|
||||
alpha: 1.0
|
||||
template: "/example/templates/button.gui"
|
||||
template_node_child: false
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -1169,6 +1189,7 @@ nodes {
|
||||
overridden_fields: 20
|
||||
template_node_child: true
|
||||
size_mode: SIZE_MODE_MANUAL
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -1237,6 +1258,7 @@ nodes {
|
||||
template_node_child: true
|
||||
text_leading: 1.0
|
||||
text_tracking: 0.0
|
||||
custom_type: 0
|
||||
}
|
||||
nodes {
|
||||
position {
|
||||
@@ -1300,6 +1322,7 @@ nodes {
|
||||
template_node_child: false
|
||||
text_leading: 1.0
|
||||
text_tracking: 0.0
|
||||
custom_type: 0
|
||||
}
|
||||
layers {
|
||||
name: "image"
|
||||
|
@@ -104,7 +104,7 @@ local function get_button_disabled(self, text)
|
||||
local prefab = gui.get_node("prefab_button")
|
||||
local nodes = gui.clone_tree(prefab)
|
||||
local root = nodes["prefab_button"]
|
||||
gui.play_flipbook(nodes["icon_button"], "back_gray")
|
||||
gui.play_flipbook(nodes["icon_button"], "progress_back")
|
||||
gui.set_enabled(root, true)
|
||||
gui.set_text(nodes["text_button_lobby"], text)
|
||||
|
||||
|
Reference in New Issue
Block a user