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

98 lines
3.4 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/25/0.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", 897, 452, "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 item_listview
local item_listview = GUI:ListView_Create(img_bg, "item_listview", 552, 58, 320, 366, 1)
GUI:setAnchorPoint(item_listview, 0.00, 0.00)
GUI:setTouchEnabled(item_listview, true)
GUI:setTag(item_listview, 0)
-- Create list_Layout
local list_Layout = GUI:Layout_Create(item_listview, "list_Layout", 0, 296, 320, 70, false)
GUI:setAnchorPoint(list_Layout, 0.00, 0.00)
GUI:setTouchEnabled(list_Layout, false)
GUI:setTag(list_Layout, 0)
-- Create Selected_ItemShow
local Selected_ItemShow = GUI:ItemShow_Create(img_bg, "Selected_ItemShow", 357, 281, {index = 1, count = 1, look = true, bgVisible = false, color = 0})
GUI:setChineseName(Selected_ItemShow, "选中物品框")
GUI:setAnchorPoint(Selected_ItemShow, 0.50, 0.50)
GUI:setTag(Selected_ItemShow, 0)
-- Create give_Layout
local give_Layout = GUI:Layout_Create(img_bg, "give_Layout", 356, 182, 328, 70, false)
GUI:setAnchorPoint(give_Layout, 0.50, 0.50)
GUI:setTouchEnabled(give_Layout, false)
GUI:setTag(give_Layout, 0)
-- Create Up_btn
local Up_btn = GUI:Button_Create(img_bg, "Up_btn", 283, 58, "res/private/ZhiBaoLaoRenUI/5.png")
GUI:Button_loadTexturePressed(Up_btn, "res/private/ZhiBaoLaoRenUI/3.png")
GUI:Button_setTitleText(Up_btn, [[]])
GUI:Button_setTitleColor(Up_btn, "#ffffff")
GUI:Button_setTitleFontSize(Up_btn, 16)
GUI:Button_titleEnableOutline(Up_btn, "#000000", 1)
GUI:setAnchorPoint(Up_btn, 0.00, 0.00)
GUI:setTouchEnabled(Up_btn, true)
GUI:setTag(Up_btn, 0)
-- Create Text_1
local Text_1 = GUI:Text_Create(img_bg, "Text_1", 641, 28, 16, "#00ff00", [[双击至宝可进行分解]])
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)
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