Commit bfcd1caa authored by Satty's avatar Satty

fix

parent 59926522
Pipeline #35423 passed with stages
in 46 minutes and 20 seconds
...@@ -41,7 +41,8 @@ function s.filter(c,tp) ...@@ -41,7 +41,8 @@ function s.filter(c,tp)
return c:IsFaceup() and c:IsSetCard(0x9a7b) and g:GetClassCount(Card.GetCode)>=7 return c:IsFaceup() and c:IsSetCard(0x9a7b) and g:GetClassCount(Card.GetCode)>=7
end end
function s.tgfilter(c,code) function s.tgfilter(c,code)
return c:IsFaceupEx() and c:IsSetCard(0x9a7b) and not c:IsCode(code) and c:IsAbleToRemove() return c:IsFaceupEx() and c:IsSetCard(0x9a7b) and not c:IsCode(code) and c:IsAbleToRemove() and
c:IsType(TYPE_MONSTER)
end end
function s.skitg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function s.skitg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler() local c=e:GetHandler()
......
...@@ -82,14 +82,15 @@ function cm.tfilter2(c,e,tp) ...@@ -82,14 +82,15 @@ function cm.tfilter2(c,e,tp)
end end
function cm.tg1(e,tp,eg,ep,ev,re,r,rp,chk) function cm.tg1(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return Duel.GetMZoneCount(tp)>0 and Duel.IsExistingMatchingCard(cm.tfilter2,tp,LOCATION_GRAVE+LOCATION_HAND,0,1,nil,e,tp) end if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(cm.tfilter2,tp,LOCATION_GRAVE+LOCATION_HAND,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE+LOCATION_HAND) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE+LOCATION_HAND)
end end
function cm.op1(e,tp,eg,ep,ev,re,r,rp) function cm.op1(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetMZoneCount(tp)<1 then return end if Duel.GetLocationCount(tp,LOCATION_MZONE)<1 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local sg=Duel.SelectMatchingCard(tp,cm.tfilter2,tp,LOCATION_GRAVE+LOCATION_HAND,0,1,2,nil,e,tp) local ct=math.min(2,Duel.GetLocationCount(tp,LOCATION_MZONE))
local sg=Duel.SelectMatchingCard(tp,cm.tfilter2,tp,LOCATION_GRAVE+LOCATION_HAND,0,1,ct,nil,e,tp)
if sg:GetCount()>0 then if sg:GetCount()>0 then
for tc in aux.Next(sg) do for tc in aux.Next(sg) do
tc:AddMonsterAttribute(TYPE_NORMAL,ATTRIBUTE_WATER,RACE_SPELLCASTER,3,1000,1000) tc:AddMonsterAttribute(TYPE_NORMAL,ATTRIBUTE_WATER,RACE_SPELLCASTER,3,1000,1000)
......
...@@ -13,6 +13,7 @@ function s.initial_effect(c) ...@@ -13,6 +13,7 @@ function s.initial_effect(c)
e1:SetType(EFFECT_TYPE_QUICK_O) e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_CHAINING) e1:SetCode(EVENT_CHAINING)
e1:SetRange(LOCATION_SZONE) e1:SetRange(LOCATION_SZONE)
e1:SetCountLimit(1,id)
e1:SetCondition(s.discon) e1:SetCondition(s.discon)
e1:SetCost(s.cost) e1:SetCost(s.cost)
e1:SetTarget(s.distg) e1:SetTarget(s.distg)
......
...@@ -46,7 +46,7 @@ function s.operation1(e,tp,eg,ep,ev,re,r,rp) ...@@ -46,7 +46,7 @@ function s.operation1(e,tp,eg,ep,ev,re,r,rp)
e4:SetTargetRange(0,LOCATION_MZONE) e4:SetTargetRange(0,LOCATION_MZONE)
e4:SetCode(EFFECT_DISABLE) e4:SetCode(EFFECT_DISABLE)
e4:SetReset(RESET_PHASE+PHASE_END) e4:SetReset(RESET_PHASE+PHASE_END)
c:RegisterEffect(e4) Duel.RegisterEffect(e4,tp)
end end
function s.cost2(e,tp,eg,ep,ev,re,r,rp,chk) function s.cost2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckReleaseGroup(tp,nil,1,nil,tp) end if chk==0 then return Duel.CheckReleaseGroup(tp,nil,1,nil,tp) end
......
...@@ -19,7 +19,7 @@ function cm.initial_effect(c) ...@@ -19,7 +19,7 @@ function cm.initial_effect(c)
e2:SetDescription(aux.Stringid(m,1)) e2:SetDescription(aux.Stringid(m,1))
e2:SetCategory(CATEGORY_REMOVE) e2:SetCategory(CATEGORY_REMOVE)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_CHAINING) e2:SetCode(EVENT_CUSTOM+53757098)
e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCondition(cm.trcon) e2:SetCondition(cm.trcon)
...@@ -102,8 +102,7 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -102,8 +102,7 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp)
if c:IsRelateToEffect(e) then Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) end if c:IsRelateToEffect(e) then Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) end
end end
function cm.trcon(e,tp,eg,ep,ev,re,r,rp) function cm.trcon(e,tp,eg,ep,ev,re,r,rp)
local tc=eg:GetFirst() return eg:IsExists(Card.IsCode,1,nil,m-1) or eg:IsContains(e:GetHandler())
return tc:IsCode(m-1) or tc==e:GetHandler()
end end
function cm.trtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function cm.trtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE+LOCATION_ONFIELD) and chkc:IsControler(1-tp) and chkc:IsAbleToRemove() end if chkc then return chkc:IsLocation(LOCATION_GRAVE+LOCATION_ONFIELD) and chkc:IsControler(1-tp) and chkc:IsAbleToRemove() end
......
...@@ -18,7 +18,7 @@ function cm.initial_effect(c) ...@@ -18,7 +18,7 @@ function cm.initial_effect(c)
e2:SetDescription(aux.Stringid(m,1)) e2:SetDescription(aux.Stringid(m,1))
e2:SetCategory(CATEGORY_REMOVE) e2:SetCategory(CATEGORY_REMOVE)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_CHAINING) e2:SetCode(EVENT_CUSTOM+53757098)
e2:SetProperty(EFFECT_FLAG_DELAY) e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCondition(cm.trcon) e2:SetCondition(cm.trcon)
...@@ -49,8 +49,7 @@ function cm.pop(e,tp,eg,ep,ev,re,r,rp) ...@@ -49,8 +49,7 @@ function cm.pop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function cm.trcon(e,tp,eg,ep,ev,re,r,rp) function cm.trcon(e,tp,eg,ep,ev,re,r,rp)
local tc=eg:GetFirst() return eg:IsExists(Card.IsCode,1,nil,m-1) or eg:IsContains(e:GetHandler())
return tc:IsCode(m-1) or tc==e:GetHandler()
end end
function cm.cfilter(c,s) function cm.cfilter(c,s)
if not c:IsRace(RACE_DRAGON) or not c:GetType()&0x20002~=0x20002 then return false end if not c:IsRace(RACE_DRAGON) or not c:GetType()&0x20002~=0x20002 then return false end
......
...@@ -21,7 +21,7 @@ function cm.initial_effect(c) ...@@ -21,7 +21,7 @@ function cm.initial_effect(c)
e2:SetDescription(aux.Stringid(m,1)) e2:SetDescription(aux.Stringid(m,1))
e2:SetCategory(CATEGORY_REMOVE) e2:SetCategory(CATEGORY_REMOVE)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_CHAINING) e2:SetCode(EVENT_CUSTOM+53757098)
e2:SetProperty(EFFECT_FLAG_DELAY) e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCondition(cm.trcon) e2:SetCondition(cm.trcon)
...@@ -45,8 +45,7 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -45,8 +45,7 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp)
if c:IsRelateToEffect(e) then Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) end if c:IsRelateToEffect(e) then Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) end
end end
function cm.trcon(e,tp,eg,ep,ev,re,r,rp) function cm.trcon(e,tp,eg,ep,ev,re,r,rp)
local tc=eg:GetFirst() return eg:IsExists(Card.IsCode,1,nil,m-1) or eg:IsContains(e:GetHandler())
return tc:IsCode(m-1) or tc==e:GetHandler()
end end
function cm.trtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function cm.trtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,0,LOCATION_HAND,1,nil,tp,POS_FACEDOWN) end if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,0,LOCATION_HAND,1,nil,tp,POS_FACEDOWN) end
......
...@@ -19,7 +19,7 @@ function cm.initial_effect(c) ...@@ -19,7 +19,7 @@ function cm.initial_effect(c)
e2:SetDescription(aux.Stringid(m,1)) e2:SetDescription(aux.Stringid(m,1))
e2:SetCategory(CATEGORY_ATKCHANGE) e2:SetCategory(CATEGORY_ATKCHANGE)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_CHAINING) e2:SetCode(EVENT_CUSTOM+53757098)
e2:SetProperty(EFFECT_FLAG_DELAY) e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCondition(cm.trcon) e2:SetCondition(cm.trcon)
...@@ -65,8 +65,7 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -65,8 +65,7 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp)
if c:IsRelateToEffect(e) then Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) end if c:IsRelateToEffect(e) then Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) end
end end
function cm.trcon(e,tp,eg,ep,ev,re,r,rp) function cm.trcon(e,tp,eg,ep,ev,re,r,rp)
local tc=eg:GetFirst() return eg:IsExists(Card.IsCode,1,nil,m-1) or eg:IsContains(e:GetHandler())
return tc:IsCode(m-1) or tc==e:GetHandler()
end end
function cm.atkfilter(c) function cm.atkfilter(c)
return c:IsFaceup() and c:IsLevel(3) return c:IsFaceup() and c:IsLevel(3)
......
...@@ -59,8 +59,7 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -59,8 +59,7 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function cm.trcon(e,tp,eg,ep,ev,re,r,rp) function cm.trcon(e,tp,eg,ep,ev,re,r,rp)
local tc=eg:GetFirst() return eg:IsExists(Card.IsCode,1,nil,m-1) or eg:IsContains(e:GetHandler())
return tc:IsCode(m-1) or tc==e:GetHandler()
end end
function cm.trtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function cm.trtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return true end if chk==0 then return true 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