bayuMIR/client/dev/GUIExport/game/B/SelfTianGuanUI.lua
2026-06-12 02:32:15 +08:00

117 lines
4.2 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/public/1900000600.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", 449, 138, "res/public/1900000510.png")
GUI:Button_loadTexturePressed(btn_close, "res/public/1900000511.png")
GUI:setContentSize(btn_close, 26, 42)
GUI:setIgnoreContentAdaptWithSize(btn_close, false)
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 Text_1
local Text_1 = GUI:Text_Create(img_bg, "Text_1", 144, 139, 16, "#ffff00", [[进入下一关需击杀本关卡所有怪物]])
GUI:Text_enableOutline(Text_1, "#000000", 2)
GUI:setAnchorPoint(Text_1, 0.00, 0.00)
GUI:setTouchEnabled(Text_1, false)
GUI:setTag(Text_1, 0)
-- Create Button_1
local Button_1 = GUI:Button_Create(img_bg, "Button_1", 33, 43, "res/public/1900000663_1.png")
GUI:Button_loadTexturePressed(Button_1, "res/public/1900000663_2.png")
GUI:setContentSize(Button_1, 174, 38)
GUI:setIgnoreContentAdaptWithSize(Button_1, false)
GUI:Button_setTitleText(Button_1, [[直接进入下一层]])
GUI:Button_setTitleColor(Button_1, "#ffffff")
GUI:Button_setTitleFontSize(Button_1, 16)
GUI:Button_titleEnableOutline(Button_1, "#000000", 2)
GUI:setAnchorPoint(Button_1, 0.00, 0.00)
GUI:setTouchEnabled(Button_1, true)
GUI:setTag(Button_1, 0)
-- Create Button_2
local Button_2 = GUI:Button_Create(img_bg, "Button_2", 243, 43, "res/public/1900000663_1.png")
GUI:Button_loadTexturePressed(Button_2, "res/public/1900000663_2.png")
GUI:setContentSize(Button_2, 174, 38)
GUI:setIgnoreContentAdaptWithSize(Button_2, false)
GUI:Button_setTitleText(Button_2, [[随机进入]])
GUI:Button_setTitleColor(Button_2, "#ffffff")
GUI:Button_setTitleFontSize(Button_2, 16)
GUI:Button_titleEnableOutline(Button_2, "#000000", 2)
GUI:setAnchorPoint(Button_2, 0.00, 0.00)
GUI:setTouchEnabled(Button_2, true)
GUI:setTag(Button_2, 0)
-- Create Text_3
local Text_3 = GUI:Text_Create(img_bg, "Text_3", 233, 90, 16, "#00ff00", [[消耗:30元宝随机传送2-3层]])
GUI:Text_enableOutline(Text_3, "#000000", 2)
GUI:setAnchorPoint(Text_3, 0.00, 0.00)
GUI:setTouchEnabled(Text_3, false)
GUI:setTag(Text_3, 0)
-- Create Text_4
local Text_4 = GUI:Text_Create(img_bg, "Text_4", 63, 89, 16, "#ff0000", [[免费进入下一层]])
GUI:Text_enableOutline(Text_4, "#000000", 2)
GUI:setAnchorPoint(Text_4, 0.00, 0.00)
GUI:setTouchEnabled(Text_4, false)
GUI:setTag(Text_4, 0)
-- Create Text_2
local Text_2 = GUI:Text_Create(img_bg, "Text_2", 97, 16, 14, "#ffffff", [[击杀怪物1分钟后未选择将自动进入下一层]])
GUI:Text_enableOutline(Text_2, "#000000", 1)
GUI:setAnchorPoint(Text_2, 0.00, 0.00)
GUI:setTouchEnabled(Text_2, false)
GUI:setTag(Text_2, 0)
-- Create Text_5
local Text_5 = GUI:Text_Create(img_bg, "Text_5", 19, 138, 16, "#ffffff", [[当前关卡:第1层]])
GUI:Text_enableOutline(Text_5, "#000000", 1)
GUI:setAnchorPoint(Text_5, 0.00, 0.00)
GUI:setTouchEnabled(Text_5, false)
GUI:setTag(Text_5, 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