Files
Main/Assets/GameAssets/Resources/Lua/Config/Data/DataPetEquipSynthesis.lua

228 lines
10 KiB
Lua
Raw Permalink Normal View History

2025-01-25 04:38:09 +08:00
--文件是自动生成,请勿手动修改.来自数据文件:pet_equip_synthesis
local L_CompressMaxColumn = 4
local L_CompressData = {
398915915141077,2814963135725461847,96053337165832836,1,
--7000021,7000025,1,201,0,6_7,10000_15000,5000,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,,,,
398915931918294,2814963135725461848,96053337165832836,1,
--7000022,7000026,1,202,0,6_7,10000_15000,5000,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,,,,
398915948695511,2814963135725461849,96053337165832836,1,
--7000023,7000027,1,203,0,6_7,10000_15000,5000,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,,,,
398915965472728,2814963135725461850,96053337165832836,1,
--7000024,7000028,1,204,0,6_7,10000_15000,5000,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,,,,
398915982249945,1407588252172181847,96053337165832836,1,
--7000025,7000029,1,201,0,6_7,10000_15000,2500,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,,,,
398915999027162,1407588252172181848,96053337165832836,1,
--7000026,7000030,1,202,0,6_7,10000_15000,2500,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,,,,
398916015804379,1407588252172181849,96053337165832836,1,
--7000027,7000031,1,203,0,6_7,10000_15000,2500,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,,,,
398916032581596,1407588252172181850,96053337165832836,1,
--7000028,7000032,1,204,0,6_7,10000_15000,2500,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,,,,
398916116467681,2814963135725461847,2978357098682950276,31689,
--7000033,7000037,1,201,0,6_7,10000_15000,5000,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916133244898,2814963135725461848,2978357098682950276,31689,
--7000034,7000038,1,202,0,6_7,10000_15000,5000,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916150022115,2814963135725461849,2978357098682950276,31689,
--7000035,7000039,1,203,0,6_7,10000_15000,5000,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916166799332,2814963135725461850,2978357098682950276,31689,
--7000036,7000040,1,204,0,6_7,10000_15000,5000,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916183576549,1407588252172181847,2978357098682950276,31689,
--7000037,7000041,1,201,0,6_7,10000_15000,2500,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916200353766,1407588252172181848,2978357098682950276,31689,
--7000038,7000042,1,202,0,6_7,10000_15000,2500,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916217130983,1407588252172181849,2978357098682950276,31689,
--7000039,7000043,1,203,0,6_7,10000_15000,2500,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916233908200,1407588252172181850,2978357098682950276,31689,
--7000040,7000044,1,204,0,6_7,10000_15000,2500,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916250685417,703900810395541847,2978357098682950276,31689,
--7000041,7000045,1,201,0,6_7,10000_15000,1250,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916267462634,703900810395541848,2978357098682950276,31689,
--7000042,7000046,1,202,0,6_7,10000_15000,1250,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916284239851,703900810395541849,2978357098682950276,31689,
--7000043,7000047,1,203,0,6_7,10000_15000,1250,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916301017068,703900810395541850,2978357098682950276,31689,
--7000044,7000048,1,204,0,6_7,10000_15000,1250,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916317794285,563163322040213847,2978357098682950276,31689,
--7000045,7000049,1,201,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916334571502,563163322040213848,2978357098682950276,31689,
--7000046,7000050,1,202,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916351348719,563163322040213849,2978357098682950276,31689,
--7000047,7000051,1,203,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916368125936,563163322040213850,2978357098682950276,31689,
--7000048,7000052,1,204,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,,,,,,,,10,14,,
398916384903153,563163322040213847,2978383858476688004,31689,
--7000049,7000053,1,201,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,1103_2,,,,,,,10,14,,
398916401680370,563163322040213848,2978383858476688004,31689,
--7000050,7000054,1,202,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,1103_2,,,,,,,10,14,,
398916418457587,563163322040213849,2978383858476688004,31689,
--7000051,7000055,1,203,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,1103_2,,,,,,,10,14,,
398916435234804,563163322040213850,2978383858476688004,31689,
--7000052,7000056,1,204,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,1103_2,,,,,,,10,14,,
398916452012021,563163322040213847,2978383859550429828,31689,
--7000053,7000057,1,201,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,1104_4,,,,,,,10,14,,
398916468789238,563163322040213848,2978383859550429828,31689,
--7000054,7000058,1,202,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,1104_4,,,,,,,10,14,,
398916485566455,563163322040213849,2978383859550429828,31689,
--7000055,7000059,1,203,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,1104_4,,,,,,,10,14,,
398916502343672,563163322040213850,2978383859550429828,31689,
--7000056,7000060,1,204,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,1104_4,,,,,,,10,14,,
398916519120889,563163322040213847,2978383860624171652,31689,
--7000057,7000061,1,201,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,1105_4,,,,,,,10,14,,
398916535898106,563163322040213848,2978383860624171652,31689,
--7000058,7000062,1,202,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,1105_4,,,,,,,10,14,,
398916552675323,563163322040213849,2978383860624171652,31689,
--7000059,7000063,1,203,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,1105_4,,,,,,,10,14,,
398916569452540,563163322040213850,2978383860624171652,31689,
--7000060,7000064,1,204,0,6_7,10000_15000,1000,1_2_3_4_5,10000_20000_60000_60000_60000,1105_4,,,,,,,10,14,,
}
local L_MainKeyDic = {
[7000021]=1,[7000022]=2,[7000023]=3,[7000024]=4,[7000025]=5,[7000026]=6,[7000027]=7,[7000028]=8,[7000033]=9,[7000034]=10,[7000035]=11,[7000036]=12,[7000037]=13,[7000038]=14,[7000039]=15,
[7000040]=16,[7000041]=17,[7000042]=18,[7000043]=19,[7000044]=20,[7000045]=21,[7000046]=22,[7000047]=23,[7000048]=24,[7000049]=25,[7000050]=26,[7000051]=27,[7000052]=28,[7000053]=29,[7000054]=30,
[7000055]=31,[7000056]=32,[7000057]=33,[7000058]=34,[7000059]=35,[7000060]=36,}
local L_NamesByNum = {
Id = 1,
EquipID = 2,
SynthesisLevel = 3,
Professional = 5,
JoinNumProbability = 8,
Notice = 18,
}
local L_NamesByString = {
JoinPart = 4,
Quality = 6,
QualityNumber = 7,
Diamond = 9,
DiamondNumber = 10,
JoinItem = 11,
ItemPrice = 12,
JoinEquipID1 = 13,
JoinNum1 = 14,
JoinEquipID2 = 15,
JoinNum2 = 16,
FailureType = 17,
Chatchannel = 19,
}
local L_ColNameIndexs = {
Id = 0,
EquipID = 1,
SynthesisLevel = 2,
JoinPart = 3,
Professional = 4,
Quality = 5,
QualityNumber = 6,
JoinNumProbability = 7,
Diamond = 8,
DiamondNumber = 9,
JoinItem = 10,
ItemPrice = 11,
JoinEquipID1 = 12,
JoinNum1 = 13,
JoinEquipID2 = 14,
JoinNum2 = 15,
FailureType = 16,
Notice = 17,
Chatchannel = 18,
}
--local L_ColumnUseBitCount = {24,24,2,16,2,15,16,14,15,15,16,2,2,2,2,2,2,5,16,}
--local L_ColumnList = {1,1,1,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3,4,}
--local L_ShiftDataList = {0,24,48,0,16,18,33,49,0,15,30,46,48,50,52,54,56,58,0,}
--local L_AndDataList = {8388607,8388607,1,32767,1,16383,32767,8191,16383,16383,32767,1,1,1,1,1,1,15,32767,}
local L_ColumnShiftAndList = {1,0,8388607,1,24,8388607,1,48,1,2,0,32767,2,16,1,2,18,16383,2,33,32767,2,49,8191,3,0,16383,3,15,16383,3,30,32767,3,46,1,3,48,1,3,50,1,3,52,1,3,54,1,3,56,1,3,58,15,4,0,32767,}
local L_ColNum = 19;
local L_UseDataK = setmetatable({ },{ __mode = 'k'});
local L_UseDataV = setmetatable({ },{ __mode = 'v'});
local L_UseDataRow = setmetatable({ },{ __mode = 'v'});
local L_IsCache = false;
local mt = {}
local function GetData(row, column)
local startIndex = (column - 1) * 3
local _compressData = L_CompressData[(row - 1)*L_CompressMaxColumn+L_ColumnShiftAndList[startIndex + 1]]
local _tempData = _compressData >> L_ColumnShiftAndList[startIndex + 2]
local _data = _tempData & L_ColumnShiftAndList[startIndex + 3]
local _andSign = L_ColumnShiftAndList[startIndex + 3] + 1
local _isMinus = (_andSign & _tempData) == _andSign
return _isMinus and -_data or _data;
end
mt.__index = function (t,key)
local _key = L_UseDataK[t];
local _row = L_MainKeyDic[_key];
local _column = L_NamesByNum[key];
if _column ~= nil then
if L_IsCache then
local _data = L_UseDataRow[_row * L_ColNum + _column]
if not _data then
_data = GetData(_row, _column)
L_UseDataRow[_row * L_ColNum + _column] = _data
end
return _data
else
return GetData(_row, _column)
end
end
_column = L_NamesByString[key]
if _column ~= nil then
return StringDefines[GetData(_row, _column)]
end
if string.find(key, '_') then
local _newKey = string.gsub(key, '_', '')
_column = L_NamesByString[_newKey]
if _column ~= nil then
return GetData(_row, _column)
end
end
if key ~= '_OnCopyAfter_' then
return
end
end
local M = {
_CompressData_ = L_CompressData,
_ColumnShiftAndList_ = L_ColumnShiftAndList,
_CompressMaxColumn_ = L_CompressMaxColumn,
_ColumnNameIndexs_ = L_ColNameIndexs,
Count = 36
}
function M:Foreach(func)
for i=1,M.Count do
local _key = GetData(i, 1)
func(_key, M[_key])
end
end
function M:ForeachCanBreak(func)
for i = 1,M.Count do
local _key = GetData(i, 1)
if func(_key, M[_key]) then
break
end
end
end
function M:GetByIndex(index)
return M[GetData(index, 1)];
end
function M:IsContainKey(key)
return not(not L_MainKeyDic[key]);
end
function M:SetIsCache(isCh)
L_IsCache = isCh;
end
setmetatable(M, {__index = function(t, key)
if not L_MainKeyDic[key] then
return;
end
local _t = L_UseDataV[key];
if not _t then
_t = setmetatable({}, mt);
L_UseDataV[key] = _t;
L_UseDataK[_t] = key;
end
return _t
end})
return M