Commit eef56673 authored by VanillaSalt's avatar VanillaSalt

fix

parent 9bf3d963
...@@ -22,11 +22,7 @@ function c15155568.initial_effect(c) ...@@ -22,11 +22,7 @@ function c15155568.initial_effect(c)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function c15155568.cfilter(c) function c15155568.cfilter(c)
if c:IsFacedown() or not c.material then return false end return c:IsFaceup() and aux.IsMaterialListCode(c,78193831)
for i,mcode in ipairs(c.material) do
if mcode==78193831 then return true end
end
return false
end end
function c15155568.condition(e,tp,eg,ep,ev,re,r,rp) function c15155568.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c15155568.cfilter,tp,LOCATION_MZONE,0,1,nil) return Duel.IsExistingMatchingCard(c15155568.cfilter,tp,LOCATION_MZONE,0,1,nil)
......
...@@ -28,11 +28,7 @@ function c1784686.tgfilter(c,e,tp) ...@@ -28,11 +28,7 @@ function c1784686.tgfilter(c,e,tp)
and Duel.IsExistingMatchingCard(c1784686.spfilter,tp,LOCATION_EXTRA,0,1,nil,e,tp,c:GetCode()) and Duel.IsExistingMatchingCard(c1784686.spfilter,tp,LOCATION_EXTRA,0,1,nil,e,tp,c:GetCode())
end end
function c1784686.spfilter(c,e,tp,code) function c1784686.spfilter(c,e,tp,code)
if not c.material or not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_FUSION,tp,false,false) then return false end return aux.IsMaterialListCode(c,code) and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_FUSION,tp,false,false)
for i,mcode in ipairs(c.material) do
if code==mcode then return true end
end
return false
end end
function c1784686.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c1784686.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc==0 then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c1784686.tgfilter(chkc,e,tp) end if chkc==0 then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c1784686.tgfilter(chkc,e,tp) end
......
...@@ -17,18 +17,14 @@ function c1801154.initial_effect(c) ...@@ -17,18 +17,14 @@ function c1801154.initial_effect(c)
e2:SetOperation(c1801154.spop) e2:SetOperation(c1801154.spop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function c1801154.filter2(c,code)
if not c.material or not c:IsReason(REASON_DESTROY) or not c:IsReason(REASON_EFFECT) then return false end
for i,mcode in ipairs(c.material) do
if code==mcode then return true end
end
return false
end
function c1801154.filter1(c,e,tp,eg) function c1801154.filter1(c,e,tp,eg)
if not c:IsCanBeSpecialSummoned(e,0,tp,false,false) then return false end return eg:IsExists(c1801154.filter2,1,nil,c:GetCode()) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
return eg:IsExists(c1801154.filter2,1,nil,c:GetCode()) end
function c1801154.filter2(c,code)
return c:IsReason(REASON_DESTROY) and c:IsReason(REASON_EFFECT) and aux.IsMaterialListCode(c,code)
end end
function c1801154.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function c1801154.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c1801154.filter1(chkc,e,tp,eg) end
if chk==0 then return e:GetHandler():IsRelateToEffect(e) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return e:GetHandler():IsRelateToEffect(e) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingTarget(c1801154.filter1,tp,LOCATION_GRAVE,0,1,nil,e,tp,eg) end and Duel.IsExistingTarget(c1801154.filter1,tp,LOCATION_GRAVE,0,1,nil,e,tp,eg) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
......
...@@ -21,6 +21,7 @@ function c27383110.initial_effect(c) ...@@ -21,6 +21,7 @@ function c27383110.initial_effect(c)
e2:SetLabelObject(e1) e2:SetLabelObject(e1)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
c27383110.fit_monster={44665365}
function c27383110.filter(c,e,tp,m) function c27383110.filter(c,e,tp,m)
if not c:IsCode(44665365) or not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true) then return false end if not c:IsCode(44665365) 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)
......
...@@ -33,11 +33,7 @@ function c41940225.filter2(c,e,tp,m,f,chkf) ...@@ -33,11 +33,7 @@ function c41940225.filter2(c,e,tp,m,f,chkf)
and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_FUSION,tp,false,false) and c:CheckFusionMaterial(m,nil,chkf) and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_FUSION,tp,false,false) and c:CheckFusionMaterial(m,nil,chkf)
end end
function c41940225.spfilter(c) function c41940225.spfilter(c)
if not c.material then return false end return aux.IsMaterialListCode(c,78193831)
for i,mcode in ipairs(c.material) do
if mcode==78193831 then return true end
end
return false
end end
function c41940225.target(e,tp,eg,ep,ev,re,r,rp,chk) function c41940225.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then if chk==0 then
......
...@@ -9,6 +9,7 @@ function c45410988.initial_effect(c) ...@@ -9,6 +9,7 @@ function c45410988.initial_effect(c)
e1:SetOperation(c45410988.activate) e1:SetOperation(c45410988.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
c45410988.fit_monster={19025379}
function c45410988.filter(c,e,tp,m1,m2) function c45410988.filter(c,e,tp,m1,m2)
if not c:IsCode(19025379) or not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true) then return false end if not c:IsCode(19025379) or not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true) then return false end
local mg=m1:Filter(Card.IsCanBeRitualMaterial,c,c) local mg=m1:Filter(Card.IsCanBeRitualMaterial,c,c)
......
...@@ -34,8 +34,8 @@ function c68319538.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -34,8 +34,8 @@ function c68319538.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsOnField() and c68319538.filter(chkc) end if chkc then return chkc:IsOnField() and c68319538.filter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c68319538.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end if chk==0 then return Duel.IsExistingTarget(c68319538.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local eg=Duel.SelectTarget(tp,c68319538.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,11,nil) local g=Duel.SelectTarget(tp,c68319538.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,16,nil)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,eg,eg:GetCount(),0,0) Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,g:GetCount(),0,0)
end end
function c68319538.operation(e,tp,eg,ep,ev,re,r,rp) function c68319538.operation(e,tp,eg,ep,ev,re,r,rp)
local tg=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS) local tg=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS)
......
...@@ -9,6 +9,7 @@ function c79306385.initial_effect(c) ...@@ -9,6 +9,7 @@ function c79306385.initial_effect(c)
e1:SetOperation(c79306385.activate) e1:SetOperation(c79306385.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
c79306385.fit_monster={48546368}
function c79306385.filter(c,e,tp,m) function c79306385.filter(c,e,tp,m)
if not c:IsCode(48546368) or not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true) then return false end if not c:IsCode(48546368) 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)
......
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