Commit ba9f34fb authored by 聖園ミカ's avatar 聖園ミカ 🐟

byd

parent 4e7db7f7
......@@ -32,6 +32,14 @@ function s.initial_effect(c)
e3:SetCode(EVENT_TO_GRAVE)
e3:SetOperation(s.regop)
c:RegisterEffect(e3)
--spsummon condition
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_SINGLE_RANGE)
e4:SetCode(EFFECT_SPSUMMON_CONDITION)
e4:SetRange(LOCATION_EXTRA)
e4:SetValue(aux.fuslimit)
c:RegisterEffect(e4)
end
function s.cfilter(c)
return c:IsType(TYPE_MONSTER) and c:IsFusionSetCard(0xa77) and c:IsAbleToRemoveAsCost()
......
......@@ -79,7 +79,7 @@ function s.teop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(7984540,1))
local sc=sg:Select(tp,1,3,nil)
if #sc~=0 then
Duel.SendtoDeck(sg,nil,SEQ_DECKSHUFFLE,REASON_EFFECT)
Duel.SendtoDeck(sc,nil,SEQ_DECKSHUFFLE,REASON_EFFECT)
end
end
......@@ -38,24 +38,28 @@ function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
return true
end
local g=aux.SelectSimultaneousEventGroup(eg,id+100,1,e,id+200)
Duel.SetTargetCard(g)
local opinfochk=false
local g=Duel.GetDecktopGroup(1-tp,1)
if g and #g>0 then
local tc=g:GetFirst()
if tc:IsPublic() or Duel.IsPlayerAffectedByEffect(tp,EFFECT_REVERSE_DECK) then
opinfochk=true
if tc:IsSetCard(ARCHE_SEPIALIFE) then
Duel.SetOperationInfo(0,CATEGORY_TODECK,g,#g,0,0)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,1-tp,2)
else
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK)
local g=aux.SelectSimultaneousEventGroup(eg,id+100,1,e,id+200)
if not g or #g==0 then
Duel.SetOperationInfo(0,CATEGORY_TODECK,nil,0,0,LOCATION_MZONE)
else
Duel.SetTargetCard(g)
local g=Duel.GetDecktopGroup(1-tp,1)
if g and #g>0 then
local tc=g:GetFirst()
if tc:IsPublic() or Duel.IsPlayerAffectedByEffect(tp,EFFECT_REVERSE_DECK) then
opinfochk=true
if tc:IsSetCard(ARCHE_SEPIALIFE) then
Duel.SetOperationInfo(0,CATEGORY_TODECK,g,#g,0,0)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,1-tp,2)
else
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK)
end
end
end
end
if opinfochk then return end
Duel.SetPossibleOperationInfo(0,CATEGORY_TODECK,g,#g,0,0)
Duel.SetPossibleOperationInfo(0,CATEGORY_TODECK,g and g or nil,g and #g or 0,0,0)
Duel.SetPossibleOperationInfo(0,CATEGORY_DRAW,nil,0,1-tp,2)
Duel.SetPossibleOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK)
end
......@@ -67,7 +71,9 @@ function s.operation(e,tp,eg,ep,ev,re,r,rp)
local tc=top:GetFirst()
if tc:IsSetCard(ARCHE_SEPIALIFE) then
local og=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS)
if not og or #og==0 then return end
local g=og:Filter(Card.IsRelateToChain,nil)
if #g==0 then return end
g:AddCard(tc)
local tg=g:Filter(Card.IsAbleToDeck,nil)
if #tg==#og+1 and Duel.ShuffleIntoDeck(tg,tp,nil,SEQ_DECKTOP)>0 then
......
......@@ -68,7 +68,7 @@ function c50224525.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
end
function c50224525.spop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c50224525.spfilter,tp,0x32,0,1,1,nil,e,tp)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c50224525.spfilter),tp,0x32,0,1,1,nil,e,tp)
if #g>0 then
Duel.HintSelection(g)
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
......
......@@ -75,7 +75,7 @@ function c50224530.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
end
function c50224530.spop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c50224530.spfilter,tp,0x32,0,1,1,nil,e,tp)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c50224530.spfilter),tp,0x32,0,1,1,nil,e,tp)
if #g>0 then
Duel.HintSelection(g)
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
......
......@@ -78,7 +78,7 @@ function c50224535.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
end
function c50224535.spop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c50224535.spfilter,tp,0x32,0,1,1,nil,e,tp)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c50224535.spfilter),tp,0x32,0,1,1,nil,e,tp)
if #g>0 then
Duel.HintSelection(g)
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
......
......@@ -86,7 +86,7 @@ function c50224540.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
end
function c50224540.spop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c50224540.spfilter,tp,0x32,0,1,1,nil,e,tp)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c50224540.spfilter),tp,0x32,0,1,1,nil,e,tp)
if #g>0 then
Duel.HintSelection(g)
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
......
......@@ -80,7 +80,7 @@ function c50224545.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
end
function c50224545.spop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c50224545.spfilter,tp,0x32,0,1,1,nil,e,tp)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c50224545.spfilter),tp,0x32,0,1,1,nil,e,tp)
if #g>0 then
Duel.HintSelection(g)
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
......
......@@ -91,7 +91,7 @@ function c50224550.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
end
function c50224550.spop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c50224550.spfilter,tp,0x32,0,1,1,nil,e,tp)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c50224550.spfilter),tp,0x32,0,1,1,nil,e,tp)
if #g>0 then
Duel.HintSelection(g)
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
......
......@@ -83,13 +83,13 @@ function c50224610.spfilter(c,e,tp)
and not c:IsCode(50224610)
end
function c50224610.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(c50224610.spfilter,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_REMOVED,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_REMOVED)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(c50224610.spfilter,tp,0x32,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,0x32)
end
function c50224610.spop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c50224610.spfilter),tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil,e,tp)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c50224610.spfilter),tp,0x32,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP_DEFENSE)
end
......
......@@ -4004,7 +4004,14 @@ function Auxiliary.SelectSimultaneousEventGroup(g,flag,ct,e,excflag)
if excflag then
g=g:Filter(aux.NOT(Card.HasFlagEffectLabel),nil,excflag,fid)
end
if #g>1 then
if #g==0 then return end
if #g==1 then
Duel.HintSelection(g)
if excflag then
g:GetFirst():RegisterFlagEffect(excflag,RESET_CHAIN,0,1,fid)
end
return g
else
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_OPERATECARD)
local tg=g:SelectSubGroup(tp,aux.SimultaneousEventGroupCheck,false,ct,#g,flag,g)
Duel.HintSelection(tg)
......@@ -4014,12 +4021,6 @@ function Auxiliary.SelectSimultaneousEventGroup(g,flag,ct,e,excflag)
end
end
return tg
else
Duel.HintSelection(g)
if excflag then
g:GetFirst():RegisterFlagEffect(excflag,RESET_CHAIN,0,1,fid)
end
return g
end
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