bayuMIR/client/dev/GUIExport/game/A/StrategyUI.lua
2026-06-17 18:29:12 +08:00

66 lines
2.1 KiB
Lua

local ui = {}
local _V = function(...) return SL:GetMetaValue(...) end
local FUNCQUEUE = {}
local TAGOBJ = {}
function ui.init(parent, __data__, __update__)
if __update__ then return ui.update(__data__) end
-- Create Layer
local Layer = GUI:Node_Create(parent, "Layer", 0, 0)
GUI:setTag(Layer, -1)
-- Create bg_close
local bg_close = GUI:Layout_Create(Layer, "bg_close", 0, 0, 1136, 640, false)
GUI:Layout_setBackGroundColorType(bg_close, 1)
GUI:Layout_setBackGroundColor(bg_close, "#000000")
GUI:Layout_setBackGroundColorOpacity(bg_close, 0)
GUI:setAnchorPoint(bg_close, 0.00, 0.00)
GUI:setTouchEnabled(bg_close, true)
GUI:setTag(bg_close, -1)
-- Create nd_root
local nd_root = GUI:Node_Create(Layer, "nd_root", 568, 320)
GUI:setTag(nd_root, 670)
TAGOBJ["670"] = nd_root
-- Create img_bg
local img_bg = GUI:Image_Create(nd_root, "img_bg", 0, 0, "res/custom/42/youxigl.png")
GUI:setChineseName(img_bg, "攻略背景")
GUI:setAnchorPoint(img_bg, 0.50, 0.50)
GUI:setTouchEnabled(img_bg, true)
GUI:setTag(img_bg, -1)
-- Create btn_close
local btn_close = GUI:Button_Create(img_bg, "btn_close", 769, 447, "res/public/1900000510.png")
GUI:Button_loadTexturePressed(btn_close, "res/public/1900000511.png")
GUI:Button_setTitleText(btn_close, [[]])
GUI:Button_setTitleColor(btn_close, "#ffffff")
GUI:Button_setTitleFontSize(btn_close, 14)
GUI:Button_titleDisableOutLine(btn_close)
GUI:setAnchorPoint(btn_close, 0.00, 0.00)
GUI:setTouchEnabled(btn_close, true)
GUI:setTag(btn_close, -1)
-- Create content_list
local content_list = GUI:ListView_Create(img_bg, "content_list", 54, 31, 695, 414, 1)
GUI:setAnchorPoint(content_list, 0.00, 0.00)
GUI:setTouchEnabled(content_list, true)
GUI:setTag(content_list, 0)
-- Create img_content
local img_content = GUI:Image_Create(content_list, "img_content", 0, -74, "res/custom/42/wenzi.png")
GUI:setAnchorPoint(img_content, 0.00, 0.00)
GUI:setTouchEnabled(img_content, false)
GUI:setTag(img_content, 0)
ui.update(__data__)
return Layer
end
function ui.update(data)
for _, func in pairs(FUNCQUEUE) do
if func then func(data) end
end
end
return ui