local propertyTable = { ID = 1,GodBeastName = 2,GodBeastDes = 3,SortId = 4,GodBeastQuality = 5,TalentCount = 6,PictorialID = 7,GodBeastTalent = 8,LevelUpID = 9,PieceItem = 10,GodBeastColorEffect = 11,GodBeastSkill = 12,GodBeastSkillGS = 13,SkillIcon = 14,SkillName = 15,SkillDesc = 16,GodBeastIcon = 17,GodBeastModelID = 18,GodBeastPicture = 19,GodBeastParadiseCoordinate = 20,GodBeastPosition = 21,GodBeastParadiseLiveImage = 22,GodBeastParadiseStillImage = 23,GodBeastTalentPicture = 24,GodBeastPreviewModelLight = 25,ModelIdleAnim = 26,ModelIdleShowAnim = 27,GodBeastIdleShowAudio = 28,GodBeastShowEffect = 29,GodBeastShowEffect2 = 30,FormationModelPosOffset1 = 31,FormationModelPosOffset2 = 32,FormationModelPosOffset3 = 33,FormationModelRot1 = 34,FormationModelRot2 = 35,FormationModelRot3 = 36,FormationModelScale = 37,ModelXYZ = 38,ModelScale = 39,GroundScale = 40,ModelRot = 41,ActivationModelRot = 42,CameraRenderId = 43,Item_Table = 44,Attr_Table = 45,CanRebirthStarLevel = 46,RebirthStarLevel = 47, } local mainPropertyTable = { ID = 1,PageIndex = 2,LineIndex = 3, } local primaryTable = { "ID", } local DataPageEntry = {} local rawget = rawget local base = { __index = function(t, k) local propertyIndex = propertyTable[k] if propertyIndex then local mainPropertyIndex = mainPropertyTable[k] if mainPropertyIndex then return t[mainPropertyIndex] end local pageIndex = t[2] local pageData = DataPageEntry[pageIndex] if pageData == nil then pageData = require('Data/GodBeastData-page'..pageIndex) if DataSheetUtil then --skip fixedpoint process for data sheet checker DataSheetUtil.ProcessFixedPoint('GodBeastData', pageData) end DataPageEntry[pageIndex] = pageData end local lineIndex = t[3] local resultData = pageData[lineIndex] return resultData[propertyIndex] end end, __newindex = function() error('Attempt to modify read-only table') end } local dataTable = { setmetatable({8,1,1},base), setmetatable({9,1,2},base), setmetatable({1,1,3},base), setmetatable({2,1,4},base), setmetatable({3,1,5},base), setmetatable({4,1,6},base), setmetatable({5,1,7},base), setmetatable({6,1,8},base), setmetatable({7,1,9},base), } return { dataTable = dataTable, propertyTable = propertyTable, primaryTable = primaryTable, }