模块:ItemInfo:修订间差异

跳转到导航 跳转到搜索
添加106字节 、​ 2024年6月8日 (星期六)
修复bug
(修正bug)
(修复bug)
第3行: 第3行:
function p.loadItemInfoByIndex(game, category, index)
function p.loadItemInfoByIndex(game, category, index)
     -- 获取索引(综合数据)
     -- 获取索引(综合数据)
     local matIdx = mw.loadJsonData(game .. '/' .. category .. '/索引')
     local matIdx = mw.loadJsonData('数据:' .. game .. '/' .. category .. '/索引')
     local itemBase = matIdx[index]
     local itemBase = matIdx[index]
     local itemAux = mw.loadJsonData(game .. '/' .. category .. '/' .. index)
     local status, data = pcall(mw.loadJsonData, '数据:' .. game .. '/' .. category .. '/' .. index)
     table.append(itemBase, itemAux)
     if status then
        return table.append(itemBase, data)
    else
        return itemBase
    end
end
end


1,075

个编辑

导航菜单