Commit 3d32db18 authored by TanakaKotoha's avatar TanakaKotoha

Suit

parent cf1e4831
...@@ -43,10 +43,9 @@ function cm.sstg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -43,10 +43,9 @@ function cm.sstg(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,#g,0,0) Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,#g,0,0)
end end
function cm.ssop(e,tp,eg,ep,ev,re,r,rp) function cm.ssop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() if e:GetHandler():IsRelateToEffect(e) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then
if c:IsRelateToEffect(e) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then if Duel.SpecialSummon(e:GetHandler(),0,tp,tp,false,false,POS_FACEUP)~=0 then
if Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then local g=Duel.GetMatchingGroup(aux.TRUE,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,e:GetHandler())
local g=Duel.GetMatchingGroup(aux.TRUE,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,c)
if #g>0 then if #g>0 then
Duel.Destroy(g,REASON_EFFECT) Duel.Destroy(g,REASON_EFFECT)
end end
...@@ -56,22 +55,22 @@ end ...@@ -56,22 +55,22 @@ end
function cm.spcon(e) function cm.spcon(e)
return Duel.GetFieldGroupCount(e:GetHandlerPlayer(),LOCATION_ONFIELD,0)==1 return Duel.GetFieldGroupCount(e:GetHandlerPlayer(),LOCATION_ONFIELD,0)==1
end end
function cm.xyzfilter(c,e,tp,mat) function cm.xyzfilter(c,e,tp)
return c:IsType(TYPE_XYZ) and c:IsCode(14000656) and e:GetHandler():IsCanBeXyzMaterial(c) return c:IsType(TYPE_XYZ) and c:IsCode(14000656) and e:GetHandler():IsCanBeXyzMaterial(c)
and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_XYZ,tp,false,false) and Duel.GetLocationCountFromEx(tp,tp,mat,c)>0 and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_XYZ,tp,false,false)
end end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() if chk==0 then return Duel.GetLocationCountFromEx(tp,tp,e:GetHandler())>0
if chk==0 then return aux.MustMaterialCheck(c,tp,EFFECT_MUST_BE_XMATERIAL) and aux.MustMaterialCheck(e:GetHandler(),tp,EFFECT_MUST_BE_XMATERIAL)
and Duel.IsExistingMatchingCard(cm.xyzfilter,tp,LOCATION_EXTRA,0,1,nil,e,tp,c) end and Duel.IsExistingMatchingCard(cm.xyzfilter,tp,LOCATION_EXTRA,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end end
function cm.spop(e,tp,eg,ep,ev,re,r,rp) function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if not aux.MustMaterialCheck(c,tp,EFFECT_MUST_BE_XMATERIAL) then return end if Duel.GetLocationCountFromEx(tp,tp,c)<=0 or not aux.MustMaterialCheck(c,tp,EFFECT_MUST_BE_XMATERIAL) then return end
if c:IsFacedown() or not c:IsRelateToEffect(e) or c:IsImmuneToEffect(e) then return end if c:IsFacedown() or not c:IsRelateToEffect(e) or c:IsImmuneToEffect(e) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,cm.xyzfilter,tp,LOCATION_EXTRA,0,1,1,nil,e,tp,c) local g=Duel.SelectMatchingCard(tp,cm.xyzfilter,tp,LOCATION_EXTRA,0,1,1,nil,e,tp)
local sc=g:GetFirst() local sc=g:GetFirst()
if sc then if sc then
local mg=c:GetOverlayGroup() local mg=c:GetOverlayGroup()
......
...@@ -4,7 +4,6 @@ function c33310159.initial_effect(c) ...@@ -4,7 +4,6 @@ function c33310159.initial_effect(c)
aux.AddXyzProcedure(c,aux.TRUE,5,2) aux.AddXyzProcedure(c,aux.TRUE,5,2)
--linmo --linmo
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TODECK)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP) e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP)
...@@ -24,14 +23,16 @@ function c33310159.initial_effect(c) ...@@ -24,14 +23,16 @@ function c33310159.initial_effect(c)
c33310159[c]=e1 c33310159[c]=e1
end end
function c33310159.ltg(e,tp,eg,ep,ev,re,r,rp,chk) function c33310159.ltg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToDeck,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(Card.IsSetCard,tp,LOCATION_GRAVE+LOCATION_HAND,0,1,nil,0x55b) end
Duel.SetOperationInfo(0,CATEGORY_TODECK,nil,1,0,LOCATION_GRAVE)
end end
function c33310159.lop(e,tp,eg,ep,ev,re,r,rp) function c33310159.lop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.SelectMatchingCard(tp,Card.IsAbleToDeck,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,2,nil) local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
local g=Duel.SelectMatchingCard(tp,Card.IsSetCard,tp,LOCATION_GRAVE+LOCATION_HAND,0,1,1,nil,0x55b)
if g then if g then
Duel.HintSelection(g) Duel.HintSelection(g)
Duel.SendtoDeck(g,nil,2,REASON_EFFECT) Duel.Overlay(c,g)
end
end end
end end
......
...@@ -62,15 +62,20 @@ end ...@@ -62,15 +62,20 @@ end
function c33400220.cfilter(c) function c33400220.cfilter(c)
return c:IsSetCard(0x341) and c:IsType(TYPE_XYZ) and c:IsAbleToRemoveAsCost() and c:IsRankAbove(6) return c:IsSetCard(0x341) and c:IsType(TYPE_XYZ) and c:IsAbleToRemoveAsCost() and c:IsRankAbove(6)
end end
function c33400220.cfilter3(c)
return c:IsSetCard(0x6342) and c:IsType(TYPE_XYZ) and c:IsAbleToRemoveAsCost() and c:IsRankAbove(6)
end
function c33400220.ovfilter(c) function c33400220.ovfilter(c)
return c:IsFaceup() and c:IsSetCard(0x341) return c:IsFaceup() and c:IsSetCard(0x341)
end end
function c33400220.xyzop(e,tp,chk) function c33400220.xyzop(e,tp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c33400220.cfilter,tp,LOCATION_GRAVE,0,2,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c33400220.cfilter,tp,LOCATION_GRAVE,0,2,nil) and Duel.IsExistingMatchingCard(c33400220.cfilter3,tp,LOCATION_GRAVE,0,1,nil)end
local g1=Duel.GetMatchingGroup(c33400220.cfilter,tp,LOCATION_GRAVE,0,nil) local g1=Duel.GetMatchingGroup(c33400220.cfilter,tp,LOCATION_GRAVE,0,nil)
if g1 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=g1:SelectSubGroup(tp,c33400220.xyzcheck,false,2,99) local g=g1:SelectSubGroup(tp,c33400220.xyzcheck,false,2,99)
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.Remove(g,POS_FACEUP,REASON_COST)
end
end end
function c33400220.macon(e,tp,eg,ep,ev,re,r,rp) function c33400220.macon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_XYZ) return e:GetHandler():IsSummonType(SUMMON_TYPE_XYZ)
......
...@@ -92,7 +92,7 @@ function c60151016.immcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -92,7 +92,7 @@ function c60151016.immcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetCurrentChain()<2 and e:GetHandler():GetMaterial():FilterCount(c60151016.ccfilter,nil)>0 return Duel.GetCurrentChain()<2 and e:GetHandler():GetMaterial():FilterCount(c60151016.ccfilter,nil)>0
end end
function c60151016.efilter(e,te) function c60151016.efilter(e,te)
if te:IsActiveType(TYPE_SPELL+TYPE_TRAP) and te:IsHasType(EFFECT_TYPE_ACTIVATE) then return true end if te:IsActiveType(TYPE_SPELL+TYPE_TRAP) then return true end
if te:IsActiveType(TYPE_MONSTER) and te:IsActivated() then return true end if te:IsActiveType(TYPE_MONSTER) and te:IsActivated() then return true end
end end
function c60151016.regcon(e,tp,eg,ep,ev,re,r,rp) function c60151016.regcon(e,tp,eg,ep,ev,re,r,rp)
......
...@@ -27,7 +27,7 @@ function c75646065.lkfilter(c) ...@@ -27,7 +27,7 @@ function c75646065.lkfilter(c)
return c:IsLinkSetCard(0x2c0) or c:IsLinkSetCard(0xa2c2) return c:IsLinkSetCard(0x2c0) or c:IsLinkSetCard(0xa2c2)
end end
function c75646065.lcheck(g,lc) function c75646065.lcheck(g,lc)
return g:IsExists(c75646065.lkfilter,1) return g:IsExists(c75646065.lkfilter,1,nil)
end end
function c75646065.filter(c) function c75646065.filter(c)
return (c:IsSetCard(0x2c0) or c:IsSetCard(0xa2c2)) and (c:IsLocation(LOCATION_GRAVE) or c:IsFaceup()) and c:IsAbleToDeck() return (c:IsSetCard(0x2c0) or c:IsSetCard(0xa2c2)) and (c:IsLocation(LOCATION_GRAVE) or c:IsFaceup()) and c:IsAbleToDeck()
......
...@@ -11,7 +11,7 @@ function c81010059.initial_effect(c) ...@@ -11,7 +11,7 @@ function c81010059.initial_effect(c)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
function c81010059.condition(e,tp,eg,ep,ev,re,r,rp) function c81010059.condition(e,tp,eg,ep,ev,re,r,rp)
return rp==tp return rp==tp and (re:IsActiveType(TYPE_MONSTER) or re:IsHasType(EFFECT_TYPE_ACTIVATE))
end end
function c81010059.target(e,tp,eg,ep,ev,re,r,rp,chk) function c81010059.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(aux.TRUE,tp,LOCATION_MZONE,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(aux.TRUE,tp,LOCATION_MZONE,0,1,nil) 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