Commit 3c95ccab authored by nanahira's avatar nanahira Committed by mercury233

fix (#1134)

parent 5ead05c1
......@@ -18,7 +18,7 @@ function c16494704.filter(c,e,tp,m,ft)
or not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true) then return false end
local mg=m:Filter(Card.IsCanBeRitualMaterial,c,c)
if c.mat_filter then
mg=mg:Filter(c.mat_filter,nil)
mg=mg:Filter(c.mat_filter,nil,tp)
end
if ft>0 then
return mg:CheckWithSumGreater(Card.GetRitualLevel,c:GetLevel(),c)
......@@ -57,7 +57,7 @@ function c16494704.operation(e,tp,eg,ep,ev,re,r,rp)
if tc then
mg=mg:Filter(Card.IsCanBeRitualMaterial,tc,tc)
if tc.mat_filter then
mg=mg:Filter(tc.mat_filter,nil)
mg=mg:Filter(tc.mat_filter,nil,tp)
end
local mat=nil
if ft>0 then
......
......@@ -13,7 +13,7 @@ function c2266498.cfilter(c,e,tp,m,ft)
if bit.band(c:GetType(),0x81)~=0x81 or not c:IsSetCard(0x106) or c:IsPublic()
or not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true) then return false end
if c.mat_filter then
m=m:Filter(c.mat_filter,nil)
m=m:Filter(c.mat_filter,nil,tp)
end
local sg=Group.CreateGroup()
return m:IsExists(c2266498.spselect,1,nil,c,0,ft,m,sg)
......@@ -53,7 +53,7 @@ function c2266498.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.ConfirmCards(1-tp,tg)
local tc=tg:GetFirst()
if tc.mat_filter then
mg=mg:Filter(tc.mat_filter,nil)
mg=mg:Filter(tc.mat_filter,nil,tp)
end
local sg=Group.CreateGroup()
for i=0,98 do
......
......@@ -13,7 +13,7 @@ function c46052429.filter(c,e,tp,m)
if bit.band(c:GetType(),0x81)~=0x81
or not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true) then return false end
if c.mat_filter then
m=m:Filter(c.mat_filter,nil)
m=m:Filter(c.mat_filter,nil,tp)
end
return m:CheckWithSumEqual(Card.GetRitualLevel,c:GetLevel(),1,99,c)
end
......@@ -36,7 +36,7 @@ function c46052429.activate(e,tp,eg,ep,ev,re,r,rp)
if tg:GetCount()>0 then
local tc=tg:GetFirst()
if tc.mat_filter then
mg=mg:Filter(tc.mat_filter,nil)
mg=mg:Filter(tc.mat_filter,nil,tp)
end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local mat=mg:SelectWithSumEqual(tp,Card.GetRitualLevel,tc:GetLevel(),1,99,tc)
......
......@@ -21,7 +21,7 @@ function c51124303.initial_effect(c)
c:RegisterEffect(e2)
end
function c51124303.spfilter(c,e,tp,mc)
return c:IsSetCard(0xb4) and bit.band(c:GetType(),0x81)==0x81 and (not c.mat_filter or c.mat_filter(mc))
return c:IsSetCard(0xb4) and bit.band(c:GetType(),0x81)==0x81 and (not c.mat_filter or c.mat_filter(mc,tp))
and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true)
and mc:IsCanBeRitualMaterial(c)
end
......
......@@ -73,7 +73,7 @@ function c81306186.target(e,tp,eg,ep,ev,re,r,rp,chk)
end
function c81306186.relfilter(c,e,tp,tc,ft)
if not c:IsLevelAbove(tc:GetLevel()) then return false end
if tc.mat_filter and not tc.mat_filter(c) then return false end
if tc.mat_filter and not tc.mat_filter(c,tp) then return false end
if c:IsLocation(LOCATION_GRAVE) then
return c:IsType(TYPE_RITUAL) and ft>0 and c:IsAbleToDeck()
else
......
......@@ -1408,7 +1408,7 @@ function Auxiliary.RitualUltimateFilter(c,filter,e,tp,m1,m2,level_function,great
mg:Merge(m2)
end
if c.mat_filter then
mg=mg:Filter(c.mat_filter,c)
mg=mg:Filter(c.mat_filter,c,tp)
else
mg:RemoveCard(c)
end
......@@ -1448,7 +1448,7 @@ function Auxiliary.RitualUltimateOperation(filter,level_function,greater_or_equa
mg:Merge(exg)
end
if tc.mat_filter then
mg=mg:Filter(tc.mat_filter,tc)
mg=mg:Filter(tc.mat_filter,tc,tp)
else
mg:RemoveCard(tc)
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment