模块:舰娘:修订间差异
舰R百科,玩家自由编辑的战舰少女R百科
更多操作
标签:回退 |
无编辑摘要 |
||
| 第30行: | 第30行: | ||
local normal = 0; local mod = 0; local skin = 0 | local normal = 0; local mod = 0; local skin = 0 | ||
local total = 0 | local total = 0 | ||
local typeCount = { | |||
CV = 0, CVL = 0, AV = 0, | |||
BB = 0, BBV = 0, BC = 1, | |||
CA = 0, CAV = 0, CLT = 0, CF = 0, | |||
CL = 0, BM = 0, DD = 0, | |||
SSG = 0, SS = 0, SC = 0, | |||
AP = 0, DDG = 0, DDGAA = 0, | |||
CG = 0, CGAA = 0, CBG = 0, | |||
BBG = 0, BBGAA = 0, | |||
} | |||
local typeCountMod = { | |||
CV = 0, CVL = 0, AV = 0, | |||
BB = 0, BBV = 0, BC = 0, | |||
CA = 0, CAV = 1, CLT = 0, CF = 0, | |||
CL = 0, BM = 0, DD = 0, | |||
SSG = 0, SS = 0, SC = 0, | |||
AP = 0, DDG = 0, DDGAA = 0, | |||
CG = 0, CGAA = 0, CBG = 0, | |||
BBG = 0, BBGAA = 0, | |||
} | |||
for index, name in pairs(byIndex) do | for index, name in pairs(byIndex) do | ||
if type(index) == 'string' then | if type(index) == 'string' then | ||
| 第38行: | 第58行: | ||
if num and num > 0 then total = total + num end | if num and num > 0 then total = total + num end | ||
end | end | ||
elseif index < 1000 then normal = normal + 1 | elseif index < 1000 then | ||
elseif index < 2000 then mod = mod + 1 end | normal = normal + 1 | ||
typeCount[ships[name].type] = typeCount[ships[name].type] + 1 | |||
elseif index < 2000 then | |||
mod = mod + 1 | |||
typeCountMod[ships[name].type] = typeCountMod[ships[name].type] + 1 | |||
end | |||
end | end | ||
local arg = frame.args[1] | local arg = frame.args[1] | ||
| 第46行: | 第71行: | ||
if arg == '换装' then return skin end | if arg == '换装' then return skin end | ||
if arg == '换装总价' then return total end | if arg == '换装总价' then return total end | ||
if arg == '未改舰种' then return typeCount[frame.args[2]] end | |||
if arg == '改造舰种' then return typeCountMod[frame.args[2]] end | |||
end | end | ||
| 第99行: | 第126行: | ||
CV='航空母舰', CVL='轻型航母', AV='装甲航母', BB='战列舰', BBV='航空战列舰', BC='战列巡洋舰', | CV='航空母舰', CVL='轻型航母', AV='装甲航母', BB='战列舰', BBV='航空战列舰', BC='战列巡洋舰', | ||
CA='重巡洋舰', CAV='航空巡洋舰', CLT='重雷装巡洋舰', CL='轻巡洋舰', BM='浅水重炮舰', DD='驱逐舰', SC='重炮潜艇', SS='潜水艇', AP='补给舰', | CA='重巡洋舰', CAV='航空巡洋舰', CLT='重雷装巡洋舰', CL='轻巡洋舰', BM='浅水重炮舰', DD='驱逐舰', SC='重炮潜艇', SS='潜水艇', AP='补给舰', | ||
DDG='反舰导弹驱逐舰', DDGAA='防空导弹驱逐舰', CBG='导弹大型巡洋舰', BBG='导弹战列舰', CF='航空巡洋舰', CG='反舰导弹巡洋舰', CGAA='防空导弹巡洋舰', SSG='导弹潜艇', | DDG='反舰导弹驱逐舰', DDGAA='防空导弹驱逐舰', CBG='导弹大型巡洋舰', BBG='导弹战列舰', CF='航空巡洋舰', CG='反舰导弹巡洋舰', CGAA='防空导弹巡洋舰', SSG='导弹潜艇', BBGAA='防空导弹战列舰', | ||
} | } | ||