Open main menu
Home
Random
Nearby
Log in
Settings
About Kancolle Wiki
Disclaimers
Kancolle Wiki
Search
Changes
← Older edit
Newer edit →
Module:Calc
(view source)
Revision as of 13:19, 2 November 2021
7 bytes removed
,
3 years ago
no edit summary
Line 362:
Line 362:
if prefix == "~" then
if prefix == "~" then
local kv = mw.text.split(string.sub(arg, 2), "%s*~%s*")
local kv = mw.text.split(string.sub(arg, 2), "%s*~%s*")
−
table.insert(filterArgs, kv)
+
local xs = mw.text.split(kv[2], "%s*,%s*")
+
table.insert(filterArgs,
{
kv
[1], xs}
)
end
end
end
end
Line 378:
Line 379:
local test = true
local test = true
for _, kv in ipairs(filterArgs) do
for _, kv in ipairs(filterArgs) do
−
--local xs = mw.text.split(kv[2], "%s*,%s*")
+
local test2 = false
−
--
local test2 = false
+
for _, e2 in ipairs(
kv[2]
) do
−
--
for _, e2 in ipairs(
xs
) do
+
if tostring(ship[kv[1]](ship)) =
= e2
then
−
if tostring(ship[kv[1]](ship))
~
=
kv[2]
then
+
test2 = true
−
--
test2 = true
+
break
−
--
break
+
end
−
--
end
+
end
−
--
end
+
if not test2 then
−
--
if not test2 then
test = false
test = false
break
break
がか
cssedit, gkautomate
7,064
edits