From 0a5bb248d74c7ba27c90e4575372cd2b5b91dc80 Mon Sep 17 00:00:00 2001 From: Insality Date: Sat, 19 Oct 2024 10:58:46 +0300 Subject: [PATCH] Remove checkbox, checkbox group, radio group and old default templates --- druid/extended/checkbox.lua | 97 ---------------- druid/extended/checkbox_group.lua | 73 ------------ druid/extended/radio_group.lua | 81 ------------- druid/styles/default/style.lua | 14 --- templates/druid_button_blue.gui | 137 ---------------------- templates/druid_button_green.gui | 137 ---------------------- templates/druid_button_red.gui | 137 ---------------------- templates/druid_button_yellow.gui | 137 ---------------------- templates/druid_checkbox.gui | 181 ------------------------------ templates/druid_input.gui | 137 ---------------------- templates/druid_slider.gui | 181 ------------------------------ 11 files changed, 1312 deletions(-) delete mode 100755 druid/extended/checkbox.lua delete mode 100644 druid/extended/checkbox_group.lua delete mode 100644 druid/extended/radio_group.lua delete mode 100644 templates/druid_button_blue.gui delete mode 100644 templates/druid_button_green.gui delete mode 100644 templates/druid_button_red.gui delete mode 100644 templates/druid_button_yellow.gui delete mode 100644 templates/druid_checkbox.gui delete mode 100644 templates/druid_input.gui delete mode 100644 templates/druid_slider.gui diff --git a/druid/extended/checkbox.lua b/druid/extended/checkbox.lua deleted file mode 100755 index dd13921..0000000 --- a/druid/extended/checkbox.lua +++ /dev/null @@ -1,97 +0,0 @@ --- Copyright (c) 2021 Maksim Tuprikov . This code is licensed under MIT license - ---- Druid checkbox component --- --- Example Link --- @module Checkbox --- @within BaseComponent --- @alias druid.checkbox - ---- On change state callback(self, state) --- @tfield DruidEvent on_change_state @{DruidEvent} - ---- Visual node --- @tfield node node - ---- Button trigger node --- @tfield node|nil click_node - ---- Button component from click_node --- @tfield Button button @{Button} - ---- - -local Event = require("druid.event") -local component = require("druid.component") - -local Checkbox = component.create("checkbox") - - -local function on_click(self) - self:set_state(not self.state) -end - - ---- Component style params. --- You can override this component styles params in druid styles table --- or create your own style --- @table style --- @tfield function on_change_state (self, node, state) -function Checkbox.on_style_change(self, style) - self.style = {} - - self.style.on_change_state = style.on_change_state or function(_, node, state) - gui.set_enabled(node, state) - end -end - - ---- The @{Checkbox} constructor --- @tparam Checkbox self @{Checkbox} --- @tparam node node Gui node --- @tparam function callback Checkbox callback --- @tparam node|nil click_node Trigger node, by default equals to node. Default: node --- @tparam boolean|nil initial_state The initial state of checkbox, default - false -function Checkbox.init(self, node, callback, click_node, initial_state) - self.druid = self:get_druid() - self.node = self:get_node(node) - self.click_node = self:get_node(click_node or node) - - self.button = self.druid:new_button(self.click_node or self.node, on_click) - self:set_state(initial_state, true, true) - - self.on_change_state = Event(callback) -end - - -function Checkbox.on_layout_change(self) - self:set_state(self.state, true) -end - - ---- Set checkbox state --- @tparam Checkbox self @{Checkbox} --- @tparam boolean|nil state Checkbox state --- @tparam boolean|nil is_silent Don't trigger on_change_state if true --- @tparam boolean|nil is_instant If instant checkbox change -function Checkbox.set_state(self, state, is_silent, is_instant) - self.state = state - self.style.on_change_state(self, self.node, state, is_instant) - - if not is_silent then - self.on_change_state:trigger(self:get_context(), state) - end - - return self -end - - ---- Return checkbox state --- @tparam Checkbox self @{Checkbox} --- @treturn boolean Checkbox state -function Checkbox.get_state(self) - return self.state -end - - -return Checkbox diff --git a/druid/extended/checkbox_group.lua b/druid/extended/checkbox_group.lua deleted file mode 100644 index d59adc3..0000000 --- a/druid/extended/checkbox_group.lua +++ /dev/null @@ -1,73 +0,0 @@ --- Copyright (c) 2021 Maksim Tuprikov . This code is licensed under MIT license - ---- Checkbox group module --- --- Example Link --- @module CheckboxGroup --- @within BaseComponent --- @alias druid.checkbox_group - ---- On any checkbox click callback(self, index) --- @tfield DruidEvent on_checkbox_click @{DruidEvent} - ---- Array of checkbox components --- @tfield table checkboxes @{Checkbox} - ---- - -local Event = require("druid.event") -local component = require("druid.component") - -local CheckboxGroup = component.create("checkbox_group") - - ---- The @{CheckboxGroup} constructor --- @tparam CheckboxGroup self @{CheckboxGroup} --- @tparam node[] nodes Array of gui node --- @tparam function callback Checkbox callback --- @tparam node[]|nil click_nodes Array of trigger nodes, by default equals to nodes -function CheckboxGroup.init(self, nodes, callback, click_nodes) - self.druid = self:get_druid() - self.checkboxes = {} - - self.on_checkbox_click = Event(callback) - - for i = 1, #nodes do - local click_node = click_nodes and click_nodes[i] or nil - local checkbox = self.druid:new_checkbox(nodes[i], function() - self.on_checkbox_click:trigger(self:get_context(), i) - end, click_node) - - table.insert(self.checkboxes, checkbox) - end -end - - ---- Set checkbox group state --- @tparam CheckboxGroup self @{CheckboxGroup} --- @tparam boolean[] indexes Array of checkbox state --- @tparam boolean|nil is_instant If instant state change -function CheckboxGroup.set_state(self, indexes, is_instant) - for i = 1, #indexes do - if self.checkboxes[i] then - self.checkboxes[i]:set_state(indexes[i], true, is_instant) - end - end -end - - ---- Return checkbox group state --- @tparam CheckboxGroup self @{CheckboxGroup} --- @treturn boolean[] Array if checkboxes state -function CheckboxGroup.get_state(self) - local result = {} - - for i = 1, #self.checkboxes do - table.insert(result, self.checkboxes[i]:get_state()) - end - - return result -end - - -return CheckboxGroup diff --git a/druid/extended/radio_group.lua b/druid/extended/radio_group.lua deleted file mode 100644 index 51dbe6b..0000000 --- a/druid/extended/radio_group.lua +++ /dev/null @@ -1,81 +0,0 @@ --- Copyright (c) 2021 Maksim Tuprikov . This code is licensed under MIT license - ---- Radio group module --- --- Example Link --- @module RadioGroup --- @within BaseComponent --- @alias druid.radio_group - ---- On any checkbox click --- @tfield DruidEvent on_radio_click @{DruidEvent} - ---- Array of checkbox components --- @tfield Checkbox[] checkboxes - ---- - -local Event = require("druid.event") -local component = require("druid.component") - -local RadioGroup = component.create("radio_group") - - -local function on_checkbox_click(self, index, is_instant) - for i = 1, #self.checkboxes do - self.checkboxes[i]:set_state(i == index, true, is_instant) - end - - self.on_radio_click:trigger(self:get_context(), index) -end - - ---- The @{RadioGroup} constructor --- @tparam RadioGroup self @{RadioGroup} --- @tparam node[] nodes Array of gui node --- @tparam function callback Radio callback --- @tparam node[]|nil click_nodes Array of trigger nodes, by default equals to nodes. Default - nodes -function RadioGroup.init(self, nodes, callback, click_nodes) - self.druid = self:get_druid() - self.checkboxes = {} - - self.on_radio_click = Event(callback) - - for i = 1, #nodes do - local click_node = click_nodes and click_nodes[i] or nil - local checkbox = self.druid:new_checkbox(nodes[i], function() - on_checkbox_click(self, i) - end, click_node) - - table.insert(self.checkboxes, checkbox) - end -end - - ---- Set radio group state --- @tparam RadioGroup self @{RadioGroup} --- @tparam number index Index in radio group --- @tparam boolean|nil is_instant If is instant state change -function RadioGroup.set_state(self, index, is_instant) - on_checkbox_click(self, index, is_instant) -end - - ---- Return radio group state --- @tparam RadioGroup self @{RadioGroup} --- @treturn number Index in radio group -function RadioGroup.get_state(self) - local result = -1 - - for i = 1, #self.checkboxes do - if self.checkboxes[i]:get_state() then - result = i - break - end - end - - return result -end - - -return RadioGroup diff --git a/druid/styles/default/style.lua b/druid/styles/default/style.lua index ca9121c..03c722d 100644 --- a/druid/styles/default/style.lua +++ b/druid/styles/default/style.lua @@ -96,20 +96,6 @@ M["progress"] = { } -M["checkbox"] = { - on_change_state = function(self, node, state, is_instant) - local target = state and 1 or 0 - if not is_instant then - gui.animate(node, "color.w", target, gui.EASING_OUTSINE, 0.1) - else - local color = gui.get_color(node) - color.w = target - gui.set_color(node, color) - end - end -} - - M["swipe"] = { SWIPE_THRESHOLD = 50, SWIPE_TIME = 0.4, diff --git a/templates/druid_button_blue.gui b/templates/druid_button_blue.gui deleted file mode 100644 index ee5a4d8..0000000 --- a/templates/druid_button_blue.gui +++ /dev/null @@ -1,137 +0,0 @@ -script: "" -fonts { - name: "game" - font: "/example/assets/fonts/game.font" -} -textures { - name: "kenney" - texture: "/example/assets/images/kenney.atlas" -} -background_color { - x: 0.0 - y: 0.0 - z: 0.0 - w: 0.0 -} -nodes { - position { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - size { - x: 147.0 - y: 49.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_BOX - blend_mode: BLEND_MODE_ALPHA - texture: "kenney/button_blue" - id: "root" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - adjust_mode: ADJUST_MODE_FIT - layer: "" - inherit_alpha: true - slice9 { - x: 15.0 - y: 10.0 - z: 15.0 - w: 10.0 - } - clipping_mode: CLIPPING_MODE_NONE - clipping_visible: true - clipping_inverted: false - alpha: 1.0 - template_node_child: false - size_mode: SIZE_MODE_MANUAL - custom_type: 0 -} -nodes { - position { - x: 0.0 - y: 5.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 0.75 - y: 0.75 - z: 1.0 - w: 1.0 - } - size { - x: 175.0 - y: 40.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_TEXT - blend_mode: BLEND_MODE_ALPHA - text: "Button" - font: "game" - id: "text" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - outline { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - shadow { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - adjust_mode: ADJUST_MODE_FIT - line_break: false - parent: "root" - layer: "" - inherit_alpha: true - alpha: 1.0 - outline_alpha: 0.5 - shadow_alpha: 0.0 - template_node_child: false - text_leading: 1.0 - text_tracking: 0.0 - custom_type: 0 -} -material: "/builtins/materials/gui.material" -adjust_reference: ADJUST_REFERENCE_PARENT -max_nodes: 512 diff --git a/templates/druid_button_green.gui b/templates/druid_button_green.gui deleted file mode 100644 index c47e8f0..0000000 --- a/templates/druid_button_green.gui +++ /dev/null @@ -1,137 +0,0 @@ -script: "" -fonts { - name: "game" - font: "/example/assets/fonts/game.font" -} -textures { - name: "kenney" - texture: "/example/assets/images/kenney.atlas" -} -background_color { - x: 0.0 - y: 0.0 - z: 0.0 - w: 0.0 -} -nodes { - position { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - size { - x: 147.0 - y: 49.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_BOX - blend_mode: BLEND_MODE_ALPHA - texture: "kenney/button_green" - id: "root" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - adjust_mode: ADJUST_MODE_FIT - layer: "" - inherit_alpha: true - slice9 { - x: 15.0 - y: 10.0 - z: 15.0 - w: 10.0 - } - clipping_mode: CLIPPING_MODE_NONE - clipping_visible: true - clipping_inverted: false - alpha: 1.0 - template_node_child: false - size_mode: SIZE_MODE_MANUAL - custom_type: 0 -} -nodes { - position { - x: 0.0 - y: 5.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 0.75 - y: 0.75 - z: 1.0 - w: 1.0 - } - size { - x: 175.0 - y: 40.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_TEXT - blend_mode: BLEND_MODE_ALPHA - text: "Button" - font: "game" - id: "text" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - outline { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - shadow { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - adjust_mode: ADJUST_MODE_FIT - line_break: false - parent: "root" - layer: "" - inherit_alpha: true - alpha: 1.0 - outline_alpha: 0.5 - shadow_alpha: 0.0 - template_node_child: false - text_leading: 1.0 - text_tracking: 0.0 - custom_type: 0 -} -material: "/builtins/materials/gui.material" -adjust_reference: ADJUST_REFERENCE_PARENT -max_nodes: 512 diff --git a/templates/druid_button_red.gui b/templates/druid_button_red.gui deleted file mode 100644 index 31bd89b..0000000 --- a/templates/druid_button_red.gui +++ /dev/null @@ -1,137 +0,0 @@ -script: "" -fonts { - name: "game" - font: "/example/assets/fonts/game.font" -} -textures { - name: "kenney" - texture: "/example/assets/images/kenney.atlas" -} -background_color { - x: 0.0 - y: 0.0 - z: 0.0 - w: 0.0 -} -nodes { - position { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - size { - x: 147.0 - y: 49.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_BOX - blend_mode: BLEND_MODE_ALPHA - texture: "kenney/button_red" - id: "root" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - adjust_mode: ADJUST_MODE_FIT - layer: "" - inherit_alpha: true - slice9 { - x: 15.0 - y: 10.0 - z: 15.0 - w: 10.0 - } - clipping_mode: CLIPPING_MODE_NONE - clipping_visible: true - clipping_inverted: false - alpha: 1.0 - template_node_child: false - size_mode: SIZE_MODE_MANUAL - custom_type: 0 -} -nodes { - position { - x: 0.0 - y: 5.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 0.75 - y: 0.75 - z: 1.0 - w: 1.0 - } - size { - x: 175.0 - y: 40.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_TEXT - blend_mode: BLEND_MODE_ALPHA - text: "Button" - font: "game" - id: "text" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - outline { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - shadow { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - adjust_mode: ADJUST_MODE_FIT - line_break: false - parent: "root" - layer: "" - inherit_alpha: true - alpha: 1.0 - outline_alpha: 0.5 - shadow_alpha: 0.0 - template_node_child: false - text_leading: 1.0 - text_tracking: 0.0 - custom_type: 0 -} -material: "/builtins/materials/gui.material" -adjust_reference: ADJUST_REFERENCE_PARENT -max_nodes: 512 diff --git a/templates/druid_button_yellow.gui b/templates/druid_button_yellow.gui deleted file mode 100644 index 6d1ca81..0000000 --- a/templates/druid_button_yellow.gui +++ /dev/null @@ -1,137 +0,0 @@ -script: "" -fonts { - name: "game" - font: "/example/assets/fonts/game.font" -} -textures { - name: "kenney" - texture: "/example/assets/images/kenney.atlas" -} -background_color { - x: 0.0 - y: 0.0 - z: 0.0 - w: 0.0 -} -nodes { - position { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - size { - x: 147.0 - y: 49.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_BOX - blend_mode: BLEND_MODE_ALPHA - texture: "kenney/button_yellow" - id: "root" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - adjust_mode: ADJUST_MODE_FIT - layer: "" - inherit_alpha: true - slice9 { - x: 15.0 - y: 10.0 - z: 15.0 - w: 10.0 - } - clipping_mode: CLIPPING_MODE_NONE - clipping_visible: true - clipping_inverted: false - alpha: 1.0 - template_node_child: false - size_mode: SIZE_MODE_MANUAL - custom_type: 0 -} -nodes { - position { - x: 0.0 - y: 5.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 0.75 - y: 0.75 - z: 1.0 - w: 1.0 - } - size { - x: 175.0 - y: 40.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_TEXT - blend_mode: BLEND_MODE_ALPHA - text: "Button" - font: "game" - id: "text" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - outline { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - shadow { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - adjust_mode: ADJUST_MODE_FIT - line_break: false - parent: "root" - layer: "" - inherit_alpha: true - alpha: 1.0 - outline_alpha: 0.5 - shadow_alpha: 0.0 - template_node_child: false - text_leading: 1.0 - text_tracking: 0.0 - custom_type: 0 -} -material: "/builtins/materials/gui.material" -adjust_reference: ADJUST_REFERENCE_PARENT -max_nodes: 512 diff --git a/templates/druid_checkbox.gui b/templates/druid_checkbox.gui deleted file mode 100644 index a78ed62..0000000 --- a/templates/druid_checkbox.gui +++ /dev/null @@ -1,181 +0,0 @@ -script: "" -textures { - name: "kenney" - texture: "/example/assets/images/kenney.atlas" -} -background_color { - x: 0.0 - y: 0.0 - z: 0.0 - w: 0.0 -} -nodes { - position { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - size { - x: 50.0 - y: 50.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_BOX - blend_mode: BLEND_MODE_ALPHA - texture: "kenney/empty" - id: "root" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - adjust_mode: ADJUST_MODE_FIT - layer: "" - inherit_alpha: true - slice9 { - x: 0.0 - y: 0.0 - z: 0.0 - w: 0.0 - } - clipping_mode: CLIPPING_MODE_NONE - clipping_visible: true - clipping_inverted: false - alpha: 1.0 - template_node_child: false - size_mode: SIZE_MODE_MANUAL - custom_type: 0 -} -nodes { - position { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - size { - x: 38.0 - y: 36.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_BOX - blend_mode: BLEND_MODE_ALPHA - texture: "kenney/check_back_square" - id: "back" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - adjust_mode: ADJUST_MODE_FIT - parent: "root" - layer: "" - inherit_alpha: true - slice9 { - x: 0.0 - y: 0.0 - z: 0.0 - w: 0.0 - } - clipping_mode: CLIPPING_MODE_NONE - clipping_visible: true - clipping_inverted: false - alpha: 1.0 - template_node_child: false - size_mode: SIZE_MODE_AUTO - custom_type: 0 -} -nodes { - position { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - size { - x: 21.0 - y: 20.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_BOX - blend_mode: BLEND_MODE_ALPHA - texture: "kenney/checkmark" - id: "checkmark" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - adjust_mode: ADJUST_MODE_FIT - parent: "root" - layer: "" - inherit_alpha: true - slice9 { - x: 0.0 - y: 0.0 - z: 0.0 - w: 0.0 - } - clipping_mode: CLIPPING_MODE_NONE - clipping_visible: true - clipping_inverted: false - alpha: 1.0 - template_node_child: false - size_mode: SIZE_MODE_AUTO - custom_type: 0 -} -material: "/builtins/materials/gui.material" -adjust_reference: ADJUST_REFERENCE_PARENT -max_nodes: 512 diff --git a/templates/druid_input.gui b/templates/druid_input.gui deleted file mode 100644 index 71dbf6b..0000000 --- a/templates/druid_input.gui +++ /dev/null @@ -1,137 +0,0 @@ -script: "" -fonts { - name: "game" - font: "/example/assets/fonts/game.font" -} -textures { - name: "kenney" - texture: "/example/assets/images/kenney.atlas" -} -background_color { - x: 0.0 - y: 0.0 - z: 0.0 - w: 0.0 -} -nodes { - position { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - size { - x: 180.0 - y: 45.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_BOX - blend_mode: BLEND_MODE_ALPHA - texture: "kenney/progress_back" - id: "root" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - adjust_mode: ADJUST_MODE_FIT - layer: "" - inherit_alpha: true - slice9 { - x: 20.0 - y: 10.0 - z: 20.0 - w: 10.0 - } - clipping_mode: CLIPPING_MODE_NONE - clipping_visible: true - clipping_inverted: false - alpha: 1.0 - template_node_child: false - size_mode: SIZE_MODE_MANUAL - custom_type: 0 -} -nodes { - position { - x: 0.0 - y: 3.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 0.75 - y: 0.75 - z: 1.0 - w: 1.0 - } - size { - x: 220.0 - y: 45.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_TEXT - blend_mode: BLEND_MODE_ALPHA - text: "Input" - font: "game" - id: "text" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - outline { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - shadow { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - adjust_mode: ADJUST_MODE_FIT - line_break: false - parent: "root" - layer: "" - inherit_alpha: true - alpha: 1.0 - outline_alpha: 0.75 - shadow_alpha: 0.0 - template_node_child: false - text_leading: 1.0 - text_tracking: 0.0 - custom_type: 0 -} -material: "/builtins/materials/gui.material" -adjust_reference: ADJUST_REFERENCE_PARENT -max_nodes: 512 diff --git a/templates/druid_slider.gui b/templates/druid_slider.gui deleted file mode 100644 index f6b9c41..0000000 --- a/templates/druid_slider.gui +++ /dev/null @@ -1,181 +0,0 @@ -script: "" -textures { - name: "kenney" - texture: "/example/assets/images/kenney.atlas" -} -background_color { - x: 0.0 - y: 0.0 - z: 0.0 - w: 0.0 -} -nodes { - position { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - size { - x: 200.0 - y: 4.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_BOX - blend_mode: BLEND_MODE_ALPHA - texture: "kenney/slider_back" - id: "root" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - adjust_mode: ADJUST_MODE_FIT - layer: "" - inherit_alpha: true - slice9 { - x: 10.0 - y: 0.0 - z: 10.0 - w: 0.0 - } - clipping_mode: CLIPPING_MODE_NONE - clipping_visible: true - clipping_inverted: false - alpha: 1.0 - template_node_child: false - size_mode: SIZE_MODE_MANUAL - custom_type: 0 -} -nodes { - position { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - size { - x: 240.0 - y: 45.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_BOX - blend_mode: BLEND_MODE_ALPHA - texture: "kenney/empty" - id: "input_zone" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - adjust_mode: ADJUST_MODE_FIT - parent: "root" - layer: "" - inherit_alpha: true - slice9 { - x: 0.0 - y: 0.0 - z: 0.0 - w: 0.0 - } - clipping_mode: CLIPPING_MODE_NONE - clipping_visible: true - clipping_inverted: false - alpha: 1.0 - template_node_child: false - size_mode: SIZE_MODE_MANUAL - custom_type: 0 -} -nodes { - position { - x: -100.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - rotation { - x: 0.0 - y: 0.0 - z: 0.0 - w: 1.0 - } - scale { - x: 0.7 - y: 0.7 - z: 1.0 - w: 1.0 - } - size { - x: 36.0 - y: 36.0 - z: 0.0 - w: 1.0 - } - color { - x: 1.0 - y: 1.0 - z: 1.0 - w: 1.0 - } - type: TYPE_BOX - blend_mode: BLEND_MODE_ALPHA - texture: "kenney/slider_move" - id: "pin" - xanchor: XANCHOR_NONE - yanchor: YANCHOR_NONE - pivot: PIVOT_CENTER - adjust_mode: ADJUST_MODE_FIT - parent: "root" - layer: "" - inherit_alpha: true - slice9 { - x: 0.0 - y: 0.0 - z: 0.0 - w: 0.0 - } - clipping_mode: CLIPPING_MODE_NONE - clipping_visible: true - clipping_inverted: false - alpha: 1.0 - template_node_child: false - size_mode: SIZE_MODE_AUTO - custom_type: 0 -} -material: "/builtins/materials/gui.material" -adjust_reference: ADJUST_REFERENCE_PARENT -max_nodes: 512