Commit 447e8ffc authored by Tachibana's avatar Tachibana

E

parent 3f2cb8bf
Pipeline #16115 passed with stages
in 31 minutes and 2 seconds
expansions/pics/12300025.jpg

50.6 KB | W: | H:

expansions/pics/12300025.jpg

39 KB | W: | H:

expansions/pics/12300025.jpg
expansions/pics/12300025.jpg
expansions/pics/12300025.jpg
expansions/pics/12300025.jpg
  • 2-up
  • Swipe
  • Onion skin
......@@ -11,13 +11,13 @@ function c92900004.initial_effect(c)
--spsummon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,3))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_SEARCH)
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_FZONE)
e1:SetCountLimit(1,m)
e1:SetCost(cm.spcost)
e1:SetTarget(cm.sptg)
e1:SetOperation(cm.spop)
e1:SetCost(cm.thcost)
e1:SetTarget(cm.thtg)
e1:SetOperation(cm.thop)
c:RegisterEffect(e1)
--counter
local e2=Effect.CreateEffect(c)
......@@ -39,43 +39,41 @@ function c92900004.initial_effect(c)
e3:SetOperation(cm.drop)
c:RegisterEffect(e3)
end
function cm.rfilter(c,tp)
return Duel.GetMZoneCount(tp,c)>0 and c:IsSetCard(0x9a0)
return c:IsSetCard(0x9a0) and (c:IsControler(tp) or c:IsFaceup())
end
function cm.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckReleaseGroup(tp,cm.rfilter,1,nil,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local g=Duel.SelectReleaseGroup(tp,cm.rfilter,1,1,nil,tp)
Duel.Release(g,REASON_COST)
function cm.costfilter(c,e,tp)
local check=Duel.GetMZoneCount(tp,c)>0
return Duel.IsExistingMatchingCard(cm.tgfilter,tp,LOCATION_DECK,0,1,c,e,tp,check)
end
function cm.spfilter(c,e,tp)
return (c:IsSetCard(0x9a0) and c:IsLevelBelow(4)) and (c:IsCanBeSpecialSummoned(e,0,tp,false,false) or c:IsAbleToHand())
function cm.tgfilter(c,e,tp,check)
return c:IsSetCard(0x9a0) and c:IsLevelBelow(4)
and (c:IsAbleToHand() or check and c:IsCanBeSpecialSummoned(e,0,tp,false,false))
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK)
Duel.SetOperationInfo(0,CATEGORY_SEARCH,nil,1,tp,LOCATION_DECK)
function cm.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
local g=Duel.GetReleaseGroup(tp):Filter(cm.rfilter,nil,tp)
if chk==0 then return g:IsExists(cm.costfilter,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local rg=g:FilterSelect(tp,cm.costfilter,1,1,nil,e,tp):GetFirst()
Duel.Release(rg,REASON_COST)
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(m,2))
local g=Duel.SelectMatchingCard(tp,cm.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp)
local tc=g:GetFirst()
local op=0
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and tc:IsCanBeSpecialSummoned(e,0,tp,false,false) then
op=Duel.SelectOption(tp,aux.Stringid(m,0),aux.Stringid(m,1))
else
op=Duel.SelectOption(tp,aux.Stringid(m,1))
end
if op==0 then
Duel.SendtoHand(tc,tp,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc)
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.tgfilter,tp,LOCATION_DECK,0,1,nil,e,tp,true) end
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
local check=Duel.GetLocationCount(tp,LOCATION_MZONE)>0
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_OPERATECARD)
local g=Duel.SelectMatchingCard(tp,cm.tgfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,check)
local tc=g:GetFirst()
if tc then
if tc:IsAbleToHand() and (not tc:IsCanBeSpecialSummoned(e,0,tp,false,false) or not check
or Duel.SelectOption(tp,1190,1152)==0) then
Duel.SendtoHand(tc,nil,REASON_EFFECT)
else
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
end
end
end
function cm.ctfilter(c)
return c:IsType(TYPE_SPELL) and c:IsPreviousLocation(LOCATION_ONFIELD)
end
......@@ -102,4 +100,4 @@ end
function cm.drop(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Draw(p,d,REASON_EFFECT)
end
\ No newline at end of file
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