Commit 4da3104e authored by Tachibana's avatar Tachibana 🐟

pic

parent faab491b
Pipeline #26466 passed with stages
in 28 minutes and 2 seconds
No preview for this file type
......@@ -13,6 +13,7 @@ function cm.initial_effect(c)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,m)
e1:SetCondition(cm.thcon)
e1:SetCost(cm.thcost)
e1:SetTarget(cm.thtg)
......
......@@ -12,6 +12,7 @@ function cm.initial_effect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCountLimit(1,m)
e1:SetTarget(cm.dftg)
e1:SetOperation(cm.dfop)
c:RegisterEffect(e1)
......
......@@ -31,8 +31,11 @@ end
function s.splimit(e,se,sp,st)
return se:IsHasType(EFFECT_TYPE_ACTIONS)
end
function s.tcfilter(c)
return c:IsReleasable() and c:GetBaseAttack()==35
end
function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
local rg=Duel.GetReleaseGroup(tp):Filter(Card.IsReleasable,nil)
local rg=Duel.GetReleaseGroup(tp):Filter(s.tcfilter,nil)
if chk==0 then return rg:CheckSubGroup(aux.mzctcheckrel,1,1,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local g=rg:SelectSubGroup(tp,aux.mzctcheckrel,false,1,1,tp)
......@@ -55,17 +58,17 @@ function s.tdfilter(c)
end
function s.effop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local b1=Duel.GetMatchingGroup(s.tdfilter,tp,LOCATION_REMOVED,0,nil)
local b2=Duel.GetMatchingGroup(Card.IsAbleToDeck,tp,LOCATION_GRAVE,LOCATION_GRAVE,nil)
local b1=Duel.IsExistingMatchingCard(s.tdfilter,tp,LOCATION_REMOVED,0,5,nil)
local b2=Duel.IsExistingMatchingCard(Card.IsAbleToDeck,tp,LOCATION_GRAVE,LOCATION_GRAVE,3,nil)
local off=1
local ops={}
local opval={}
if #b1>5 then
if b1 then
ops[off]=1110
opval[off-1]=1
off=off+1
end
if #b2>3 then
if b2 then
ops[off]=1193
opval[off-1]=2
off=off+1
......@@ -74,11 +77,15 @@ function s.effop(e,tp,eg,ep,ev,re,r,rp)
local sel=opval[op]
if sel==1 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local sc=b1:Select(tp,5,5,nil)
Duel.SendtoDeck(sc,nil,SEQ_DECKSHUFFLE,REASON_EFFECT)
elseif sel==2 then
local sg=Duel.SelectMatchingCard(tp,s.tdfilter,tp,LOCATION_REMOVED,0,5,5,nil)
if sg:GetCount()>0 then
Duel.SendtoDeck(sg,nil,SEQ_DECKSHUFFLE,REASON_EFFECT)
end
else
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local sc=b2:Select(tp,3,3,nil)
Duel.SendtoDeck(sc,tp,SEQ_DECKSHUFFLE,REASON_EFFECT)
local sg=Duel.SelectMatchingCard(tp,Card.IsAbleToDeck,tp,LOCATION_GRAVE,LOCATION_GRAVE,3,3,nil)
if sg:GetCount()>0 then
Duel.SendtoDeck(sg,tp,SEQ_DECKSHUFFLE,REASON_EFFECT)
end
end
end
\ No newline at end of file
......@@ -14,6 +14,7 @@ function s.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetHintTiming(0,TIMING_END_PHASE)
e2:SetCountLimit(1)
e2:SetRange(LOCATION_MZONE)
e2:SetTarget(s.sptg)
e2:SetOperation(s.spop)
......@@ -91,7 +92,7 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp)
tc:SetMaterial(mat1)
Duel.SendtoGrave(mat1,REASON_EFFECT+REASON_MATERIAL+REASON_FUSION)
Duel.BreakEffect()
Duel.SpecialSummon(tc,SUMMON_TYPE_FUSION,tp,tp,false,false,POS_FACEUP)
Duel.SpecialSummon(tc,SUMMON_TYPE_FUSION,tp,tp,false,false,POS_FACEUP,0x60)
else
local mat2=Duel.SelectFusionMaterial(tp,tc,mg2,nil,chkf)
local fop=ce:GetOperation()
......
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