Commit bf69daad authored by Tachibana's avatar Tachibana 🐟

md

parent 36d2b889
Pipeline #26287 passed with stages
in 18 minutes and 41 seconds
No preview for this file type
......@@ -105,7 +105,6 @@ function s.set(c)
e1:SetCode(EVENT_TO_GRAVE)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1)
e1:SetCondition(s.setcon)
e1:SetTarget(s.settg)
e1:SetOperation(s.setop)
......@@ -121,7 +120,7 @@ function s.confilter(c,tp)
return true
end
function s.setcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(s.confilter,1,nil,tp)
return eg:IsExists(s.confilter,1,nil,tp) and e:GetHandler():GetFlagEffect(id)==0
end
function s.tgfilter1(c,e,tp)
return s.confilter(c,tp) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEDOWN_DEFENSE)
......@@ -132,6 +131,7 @@ end
function s.settg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return (eg:IsExists(s.tgfilter1,1,nil,e,tp) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0)
or (eg:IsExists(s.tgfilter2,1,nil,tp) and Duel.GetLocationCount(tp,LOCATION_SZONE)>0) end
e:GetHandler():RegisterFlagEffect(id,RESET_PHASE+PHASE_END,0,1)
end
function s.setop(e,tp,eg,ep,ev,re,r,rp)
local sg=Group.CreateGroup()
......@@ -148,7 +148,7 @@ function s.setop(e,tp,eg,ep,ev,re,r,rp)
local flag=0
if sc:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEDOWN_DEFENSE) then
flag=1
if sc:IsSSetable() and not Duel.SelectEffectYesNo(tp,c,aux.Stringid(id,1)) then
if sc:IsSSetable() and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and not Duel.SelectEffectYesNo(tp,c,aux.Stringid(id,1)) then
flag=2
end
else
......@@ -159,7 +159,6 @@ function s.setop(e,tp,eg,ep,ev,re,r,rp)
Duel.ConfirmCards(1-tp,sc)
else
Duel.SSet(tp,sc)
Duel.ConfirmCards(1-tp,sc)
end
end
end
......
......@@ -71,7 +71,6 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,47364499,0,TYPES_TOKEN_MONSTER,0,0,1,RACE_INSECT,ATTRIBUTE_LIGHT) then
local token=Duel.CreateToken(tp,47364499)
Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP)
if Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP)>0 and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
......
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