diff --git a/lua_probject/base_project/Game/View/Common/BaseView.lua b/lua_probject/base_project/Game/View/Common/BaseView.lua index d27066c0..3a84e41c 100644 --- a/lua_probject/base_project/Game/View/Common/BaseView.lua +++ b/lua_probject/base_project/Game/View/Common/BaseView.lua @@ -31,8 +31,6 @@ local view_url = { --@param self --@param #string url function M:InitView(url) - print("什么鬼地址"..url) - print(InnerFunction()) self._root_view = UIPackage.CreateObjectFromURL(self._full and view_url[2] or view_url[1]) local contentPane = self._root_view:GetChild("contentPane") self._view = UIPackage.CreateObjectFromURL(url) diff --git a/lua_probject/base_project/Main.lua b/lua_probject/base_project/Main.lua index 323d4e4b..883fc922 100644 --- a/lua_probject/base_project/Main.lua +++ b/lua_probject/base_project/Main.lua @@ -388,360 +388,4 @@ function printlog(...) if debug_print then print(...) end -end - -function PrintStackTrace(ignoreCount, options) - -- 默认参数 - ignoreCount = ignoreCount or 3 - options = options or {} - - -- 合并配置选项 - local config = { - maxDepth = options.maxDepth or 20, - indentSize = options.indentSize or 2, - showVariables = options.showVariables ~= false, -- 默认true - maxVariableLength = options.maxVariableLength or 50, - showLineNumbers = options.showLineNumbers ~= false, - showFunctionType = options.showFunctionType ~= false, - showFullPath = options.showFullPath or false, - colorOutput = options.colorOutput or false, - skipDebuggerFrames = options.skipDebuggerFrames ~= false, - debuggerFiles = options.debuggerFiles or { - "debugger.lua", - "LuaDebugger.lua", - "=[C]" - }, - includeTimestamp = options.includeTimestamp or false, - maxStackDepth = options.maxStackDepth or 100 - } - - -- ANSI颜色代码(用于彩色输出) - local colors = { - reset = "\27[0m", - red = "\27[31m", - green = "\27[32m", - yellow = "\27[33m", - blue = "\27[34m", - magenta = "\27[35m", - cyan = "\27[36m", - white = "\27[37m", - gray = "\27[90m" - } - - -- 如果不支持彩色输出,使用空字符串 - if not config.colorOutput then - for k, _ in pairs(colors) do - colors[k] = "" - end - end - - -- 辅助函数:判断是否为调试器自身的帧 - local function isDebuggerFrame(frameInfo) - if not config.skipDebuggerFrames then - return false - end - - for _, pattern in ipairs(config.debuggerFiles) do - if frameInfo.src and frameInfo.src:find(pattern, 1, true) then - return true - end - if frameInfo.source and frameInfo.source:find(pattern, 1, true) then - return true - end - end - return false - end - - -- 辅助函数:格式化变量值(限制长度) - local function formatValue(value, maxLength) - if value == nil then - return colors.gray .. "nil" .. colors.reset - end - - local valueType = type(value) - local str - - if valueType == "string" then - str = colors.green .. string.format("%q", value) .. colors.reset - elseif valueType == "number" then - str = colors.yellow .. tostring(value) .. colors.reset - elseif valueType == "boolean" then - str = colors.cyan .. tostring(value) .. colors.reset - elseif valueType == "table" then - local mt = getmetatable(value) - if mt and mt.__tostring then - str = tostring(value) - else - str = colors.magenta .. string.format("table: %p", value) .. colors.reset - end - elseif valueType == "function" then - str = colors.blue .. string.format("function: %p", value) .. colors.reset - elseif valueType == "userdata" or valueType == "thread" then - str = colors.white .. string.format("%s: %p", valueType, value) .. colors.reset - else - str = colors.gray .. tostring(value) .. colors.reset - end - - -- 限制长度 - if #str > maxLength * 2 then -- 乘以2因为ANSI代码也占长度 - str = str:sub(1, maxLength * 2) .. "..." - end - - return str - end - - -- 辅助函数:格式化变量信息 - local function formatVariables(vars, indent) - if not vars or not config.showVariables then - return "" - end - - local lines = {} - local prefix = string.rep(" ", indent) - - -- 处理局部变量 - if vars.locals then - local hasLocals = false - local localNames = {} - for name, _ in pairs(vars.locals) do - table.insert(localNames, name) - end - table.sort(localNames) -- 按字母顺序排序 - - for _, name in ipairs(localNames) do - local info = vars.locals[name] - if not hasLocals then - table.insert(lines, prefix .. colors.cyan .. "Local Variables:" .. colors.reset) - hasLocals = true - end - local valueStr = formatValue(info.value, config.maxVariableLength) - table.insert(lines, string.format("%s %s%s%s = %s", - prefix, colors.yellow, name, colors.reset, valueStr)) - end - end - - -- 处理上值(upvalues) - if vars.upvalues then - local hasUpvalues = false - local upvalueNames = {} - for name, _ in pairs(vars.upvalues) do - table.insert(upvalueNames, name) - end - table.sort(upvalueNames) - - for _, name in ipairs(upvalueNames) do - local info = vars.upvalues[name] - if not hasUpvalues then - table.insert(lines, prefix .. colors.cyan .. "Upvalues:" .. colors.reset) - hasUpvalues = true - end - local valueStr = formatValue(info.value, config.maxVariableLength) - table.insert(lines, string.format("%s %s%s%s = %s", - prefix, colors.yellow, name, colors.reset, valueStr)) - end - end - - if #lines > 0 then - return table.concat(lines, "\n") .. "\n" - end - return "" - end - - -- 获取堆栈信息 - local stackInfo = {} - local outputLines = {} - - -- 添加标题 - if config.includeTimestamp then - table.insert(outputLines, colors.white .. "=== Stack Trace @" .. os.date("%H:%M:%S") .. " ===" .. colors.reset) - else - table.insert(outputLines, colors.white .. "=== Stack Trace ===" .. colors.reset) - end - - -- 收集堆栈信息 - local frameCount = 0 - local skippedDebuggerFrames = 0 - - for level = ignoreCount, config.maxStackDepth do - local source = debug.getinfo(level, "Snlf") - if not source then - break - end - - -- 构建栈帧信息 - local frameInfo = { - level = level - ignoreCount + 1, - src = source.source, - funcName = source.name or "", - currentline = source.currentline, - linedefined = source.linedefined, - lastlinedefined = source.lastlinedefined, - what = source.what, - namewhat = source.namewhat or "", - source = source.source - } - - -- 跳过调试器自身的帧 - if isDebuggerFrame(frameInfo) then - skippedDebuggerFrames = skippedDebuggerFrames + 1 - goto continue - end - - -- 达到最大显示深度时停止 - if frameCount >= config.maxDepth then - table.insert(outputLines, colors.gray .. string.format("... (%d more frames hidden)", - (config.maxStackDepth - level + 1)) .. colors.reset) - break - end - - -- 格式化文件路径 - local filePath - if config.showFullPath then - filePath = source.source - else - -- 提取文件名 - if source.source:sub(1, 1) == "@" then - local path = source.source:sub(2) - local _, filename = path:match("^.*[/\\](.+)$") - filePath = filename or path - elseif source.source:sub(1, 1) == "=" then - filePath = source.source:sub(2) - else - filePath = "[string]" - end - end - - -- 构建帧描述 - local indent = string.rep(" ", config.indentSize) - local framePrefix = string.format("#%d ", frameCount + 1) - - local frameLine - if config.showLineNumbers then - if source.currentline > 0 then - frameLine = string.format("%s%s in %s%s%s at %s%s%s:%s%d%s", - colors.white, framePrefix, - colors.yellow, frameInfo.funcName, colors.reset, - colors.blue, filePath, colors.reset, - colors.green, source.currentline, colors.reset) - else - frameLine = string.format("%s%s in %s%s%s at %s%s%s", - colors.white, framePrefix, - colors.yellow, frameInfo.funcName, colors.reset, - colors.blue, filePath, colors.reset) - end - else - frameLine = string.format("%s%s in %s%s%s", - colors.white, framePrefix, - colors.yellow, frameInfo.funcName, colors.reset) - end - - -- 添加函数类型信息 - if config.showFunctionType then - local typeColor = colors.gray - if source.what == "Lua" then - typeColor = colors.green - elseif source.what == "C" then - typeColor = colors.red - elseif source.what == "main" then - typeColor = colors.cyan - end - - frameLine = frameLine .. string.format(" [%s%s%s]", - typeColor, source.what, colors.reset) - end - - table.insert(outputLines, frameLine) - - -- 获取并格式化变量 - if config.showVariables then - local success, vars = pcall(function() - local varInfo = {} - - -- 获取局部变量 - varInfo.locals = {} - local idx = 1 - while true do - local name, value = debug.getlocal(level + 1, idx) - if not name then break end - - -- 过滤掉调试器内部变量 - if not name:find("^_debugger_") then - varInfo.locals[name] = { - value = value, - type = type(value) - } - end - idx = idx + 1 - end - - -- 获取上值 - varInfo.upvalues = {} - local func = debug.getinfo(level + 1, "f").func - if func then - idx = 1 - while true do - local name, value = debug.getupvalue(func, idx) - if not name then break end - - varInfo.upvalues[name] = { - value = value, - type = type(value) - } - idx = idx + 1 - end - end - - return varInfo - end) - - if success then - local varsStr = formatVariables(vars, config.indentSize * 2) - if varsStr ~= "" then - table.insert(outputLines, varsStr) - end - end - end - - frameCount = frameCount + 1 - - -- 到达主程序层时停止 - if source.what == "main" then - break - end - - ::continue:: - end - - -- 添加统计信息 - table.insert(outputLines, "") - table.insert(outputLines, colors.gray .. string.format( - "Total frames: %d (skipped %d debugger frames)", - frameCount, skippedDebuggerFrames) .. colors.reset) - - -- 如果没有找到任何帧 - if frameCount == 0 then - table.insert(outputLines, - colors.yellow .. "No stack frames found (possibly all frames were skipped)" .. colors.reset) - end - - -- 添加分隔线 - table.insert(outputLines, colors.white .. "====================" .. colors.reset) - - return table.concat(outputLines, "\n") -end - -function InnerFunction() - local x = 42 - local name = "Test" - local data = { a = 1, b = 2 } - - -- 打印堆栈信息 - local trace = PrintStackTrace(2, { - showVariables = false, - colorOutput = false, - maxDepth = 20 - }) - - return trace -end - +end \ No newline at end of file diff --git a/lua_probject/extend_project/extend/zipai/fanpaofa/main/ZPMainView.lua b/lua_probject/extend_project/extend/zipai/fanpaofa/main/ZPMainView.lua index 6605a1ee..d605fdaf 100644 --- a/lua_probject/extend_project/extend/zipai/fanpaofa/main/ZPMainView.lua +++ b/lua_probject/extend_project/extend/zipai/fanpaofa/main/ZPMainView.lua @@ -90,11 +90,11 @@ function M:InitView(url, isdisplay, open_social, change_card_size, qihu) local typeface = _data['game_cardsize'] local _gamectr = self._gamectr if typeface == 0 then - self._room.change_card_size = 1.3 + self._room.change_card_size = 2 elseif typeface == 1 then - self._room.change_card_size = 1.2 + self._room.change_card_size = 1.5 elseif typeface == 2 then - self._room.change_card_size = 1.2 + self._room.change_card_size = 1.5 end else self._room.change_card_size = change_card_size @@ -337,11 +337,11 @@ end function M:UpdateCardSize(index) -- print("lingmeng UpdateCardSize") if index == 0 then - self._room.change_card_size = 1.3 + self._room.change_card_size = 2 elseif index == 1 then - self._room.change_card_size = 1.2 + self._room.change_card_size = 1.5 elseif index == 2 then - self._room.change_card_size = 1.2 + self._room.change_card_size = 1.5 end local info = self._player_card_info[1] info:UpdateCardSize() diff --git a/wb_new_ui/.objs/metas/1utjt0r2/ufu92i.info b/wb_new_ui/.objs/metas/1utjt0r2/ufu92i.info index d04551a1..3fd2f2d1 100644 --- a/wb_new_ui/.objs/metas/1utjt0r2/ufu92i.info +++ b/wb_new_ui/.objs/metas/1utjt0r2/ufu92i.info @@ -1,11 +1,23 @@ { "objectStatus": { + "n19_pt1r": { + "collapsed": true + }, "n85_rbpg": { "hidden": true }, + "n51_fmkv": { + "collapsed": true + }, "n84_rbpg": { "hidden": true }, + "n44_n1ry": { + "collapsed": true + }, + "n55_rx2e": { + "collapsed": true + }, "n4_fux2": { "hidden": true } diff --git a/wb_new_ui/.objs/metas/lkq9ne9s/peuq8b.info b/wb_new_ui/.objs/metas/lkq9ne9s/peuq8b.info index 4439c5c2..9e26dfee 100644 --- a/wb_new_ui/.objs/metas/lkq9ne9s/peuq8b.info +++ b/wb_new_ui/.objs/metas/lkq9ne9s/peuq8b.info @@ -1,7 +1 @@ -{ - "objectStatus": { - "n154_r1mo": { - "collapsed": true - } - } -} \ No newline at end of file +{} \ No newline at end of file diff --git a/wb_new_ui/.objs/metas/lkq9ne9s/peuqao.info b/wb_new_ui/.objs/metas/lkq9ne9s/peuqao.info new file mode 100644 index 00000000..18662af8 --- /dev/null +++ b/wb_new_ui/.objs/metas/lkq9ne9s/peuqao.info @@ -0,0 +1,10 @@ +{ + "objectStatus": { + "n76_ra9v": { + "collapsed": true + }, + "n77_ra9v": { + "collapsed": true + } + } +} \ No newline at end of file diff --git a/wb_new_ui/assets/Common/buttons/Frame 1153.png b/wb_new_ui/assets/Common/buttons/Frame 1153.png deleted file mode 100644 index 7ca88a03..00000000 Binary files a/wb_new_ui/assets/Common/buttons/Frame 1153.png and /dev/null differ diff --git a/wb_new_ui/assets/Common/package.xml b/wb_new_ui/assets/Common/package.xml index db529854..343f3877 100644 --- a/wb_new_ui/assets/Common/package.xml +++ b/wb_new_ui/assets/Common/package.xml @@ -1355,7 +1355,6 @@ - diff --git a/wb_new_ui/assets/Extend_Poker_FanPaoFa/component/clearing/btn_xp.xml b/wb_new_ui/assets/Extend_Poker_FanPaoFa/component/clearing/btn_xp.xml index 3a4c3642..ea63411a 100644 --- a/wb_new_ui/assets/Extend_Poker_FanPaoFa/component/clearing/btn_xp.xml +++ b/wb_new_ui/assets/Extend_Poker_FanPaoFa/component/clearing/btn_xp.xml @@ -1,8 +1,8 @@ - + - +