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) ...@@ -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 or not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true) then return false end
local mg=m:Filter(Card.IsCanBeRitualMaterial,c,c) local mg=m:Filter(Card.IsCanBeRitualMaterial,c,c)
if c.mat_filter then if c.mat_filter then
mg=mg:Filter(c.mat_filter,nil) mg=mg:Filter(c.mat_filter,nil,tp)
end end
if ft>0 then if ft>0 then
return mg:CheckWithSumGreater(Card.GetRitualLevel,c:GetLevel(),c) return mg:CheckWithSumGreater(Card.GetRitualLevel,c:GetLevel(),c)
...@@ -57,7 +57,7 @@ function c16494704.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -57,7 +57,7 @@ function c16494704.operation(e,tp,eg,ep,ev,re,r,rp)
if tc then if tc then
mg=mg:Filter(Card.IsCanBeRitualMaterial,tc,tc) mg=mg:Filter(Card.IsCanBeRitualMaterial,tc,tc)
if tc.mat_filter then if tc.mat_filter then
mg=mg:Filter(tc.mat_filter,nil) mg=mg:Filter(tc.mat_filter,nil,tp)
end end
local mat=nil local mat=nil
if ft>0 then if ft>0 then
......
...@@ -13,7 +13,7 @@ function c2266498.cfilter(c,e,tp,m,ft) ...@@ -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() 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 or not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true) then return false end
if c.mat_filter then if c.mat_filter then
m=m:Filter(c.mat_filter,nil) m=m:Filter(c.mat_filter,nil,tp)
end end
local sg=Group.CreateGroup() local sg=Group.CreateGroup()
return m:IsExists(c2266498.spselect,1,nil,c,0,ft,m,sg) 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) ...@@ -53,7 +53,7 @@ function c2266498.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.ConfirmCards(1-tp,tg) Duel.ConfirmCards(1-tp,tg)
local tc=tg:GetFirst() local tc=tg:GetFirst()
if tc.mat_filter then if tc.mat_filter then
mg=mg:Filter(tc.mat_filter,nil) mg=mg:Filter(tc.mat_filter,nil,tp)
end end
local sg=Group.CreateGroup() local sg=Group.CreateGroup()
for i=0,98 do for i=0,98 do
......
...@@ -13,7 +13,7 @@ function c46052429.filter(c,e,tp,m) ...@@ -13,7 +13,7 @@ function c46052429.filter(c,e,tp,m)
if bit.band(c:GetType(),0x81)~=0x81 if bit.band(c:GetType(),0x81)~=0x81
or not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true) then return false end or not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true) then return false end
if c.mat_filter then if c.mat_filter then
m=m:Filter(c.mat_filter,nil) m=m:Filter(c.mat_filter,nil,tp)
end end
return m:CheckWithSumEqual(Card.GetRitualLevel,c:GetLevel(),1,99,c) return m:CheckWithSumEqual(Card.GetRitualLevel,c:GetLevel(),1,99,c)
end end
...@@ -36,7 +36,7 @@ function c46052429.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -36,7 +36,7 @@ function c46052429.activate(e,tp,eg,ep,ev,re,r,rp)
if tg:GetCount()>0 then if tg:GetCount()>0 then
local tc=tg:GetFirst() local tc=tg:GetFirst()
if tc.mat_filter then if tc.mat_filter then
mg=mg:Filter(tc.mat_filter,nil) mg=mg:Filter(tc.mat_filter,nil,tp)
end end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local mat=mg:SelectWithSumEqual(tp,Card.GetRitualLevel,tc:GetLevel(),1,99,tc) local mat=mg:SelectWithSumEqual(tp,Card.GetRitualLevel,tc:GetLevel(),1,99,tc)
......
...@@ -21,7 +21,7 @@ function c51124303.initial_effect(c) ...@@ -21,7 +21,7 @@ function c51124303.initial_effect(c)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function c51124303.spfilter(c,e,tp,mc) 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 c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true)
and mc:IsCanBeRitualMaterial(c) and mc:IsCanBeRitualMaterial(c)
end end
......
...@@ -73,7 +73,7 @@ function c81306186.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -73,7 +73,7 @@ function c81306186.target(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function c81306186.relfilter(c,e,tp,tc,ft) function c81306186.relfilter(c,e,tp,tc,ft)
if not c:IsLevelAbove(tc:GetLevel()) then return false end 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 if c:IsLocation(LOCATION_GRAVE) then
return c:IsType(TYPE_RITUAL) and ft>0 and c:IsAbleToDeck() return c:IsType(TYPE_RITUAL) and ft>0 and c:IsAbleToDeck()
else else
......
...@@ -1408,7 +1408,7 @@ function Auxiliary.RitualUltimateFilter(c,filter,e,tp,m1,m2,level_function,great ...@@ -1408,7 +1408,7 @@ function Auxiliary.RitualUltimateFilter(c,filter,e,tp,m1,m2,level_function,great
mg:Merge(m2) mg:Merge(m2)
end end
if c.mat_filter then if c.mat_filter then
mg=mg:Filter(c.mat_filter,c) mg=mg:Filter(c.mat_filter,c,tp)
else else
mg:RemoveCard(c) mg:RemoveCard(c)
end end
...@@ -1448,7 +1448,7 @@ function Auxiliary.RitualUltimateOperation(filter,level_function,greater_or_equa ...@@ -1448,7 +1448,7 @@ function Auxiliary.RitualUltimateOperation(filter,level_function,greater_or_equa
mg:Merge(exg) mg:Merge(exg)
end end
if tc.mat_filter then if tc.mat_filter then
mg=mg:Filter(tc.mat_filter,tc) mg=mg:Filter(tc.mat_filter,tc,tp)
else else
mg:RemoveCard(tc) mg:RemoveCard(tc)
end 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