Commit 472f025a authored by tsubaki's avatar tsubaki

1.999zyμ更新

parent 336fecf5
Pipeline #11414 passed with stage
in 1 minute and 12 seconds
No preview for this file type
......@@ -121,7 +121,7 @@ if not TET.ELCounter then
if code == Electro then
Duel.Hint(HINT_CARD,0,50704)
count = count-num
if eh < Mystery then
if eh < 1 then
local gh=Duel.GetFieldGroup(tp,LOCATION_HAND,0):RandomSelect(tp,1)
local gd=Duel.GetFieldGroup(tp,LOCATION_DECK,0):RandomSelect(tp,1)
gd:Merge(gh)
......@@ -136,7 +136,7 @@ if not TET.ELCounter then
Duel.Hint(HINT_CARD,0,50705)
count = count-num
local cc=te:GetHandler()
local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_MZONE,0,nil)
local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_ONFIELD,0,nil)
local gm=Mystery
while gm>0 and g:GetCount()>0 do
local tc=g:RandomSelect(tp,1):GetFirst()
......@@ -189,7 +189,7 @@ if not TET.ELCounter then
if code == Hydro then
Duel.Hint(HINT_CARD,0,50704)
count = count-num
if eh < Mystery then
if eh < 1 then
local gh=Duel.GetFieldGroup(tp,LOCATION_HAND,0):RandomSelect(tp,1)
local gd=Duel.GetFieldGroup(tp,LOCATION_DECK,0):RandomSelect(tp,1)
gd:Merge(gh)
......
No preview for this file type
......@@ -60,6 +60,10 @@
74561011 2 --暴风文
74561017 1 --盲目的贤者✿格洛丽亚
74562021 0 --月之天使✿萨丽爱尔
74562022 0 --复仇的恶灵✿魅魔
74561015 0 --本気✿灵梦
--L
74563028 0 --虹之花✿濑笈叶
--金卡
86379706 0 --精神✿操作
86379754 1 --结界『光与暗的网目』
......
pics/66916001.jpg

65.8 KB | W: | H:

pics/66916001.jpg

54 KB | W: | H:

pics/66916001.jpg
pics/66916001.jpg
pics/66916001.jpg
pics/66916001.jpg
  • 2-up
  • Swipe
  • Onion skin
pics/74562006.jpg

49.8 KB | W: | H:

pics/74562006.jpg

49.8 KB | W: | H:

pics/74562006.jpg
pics/74562006.jpg
pics/74562006.jpg
pics/74562006.jpg
  • 2-up
  • Swipe
  • Onion skin
pics/74562007.jpg

55.1 KB | W: | H:

pics/74562007.jpg

55.1 KB | W: | H:

pics/74562007.jpg
pics/74562007.jpg
pics/74562007.jpg
pics/74562007.jpg
  • 2-up
  • Swipe
  • Onion skin
--春之宣告
require("expansions/script/nef/nef")
--
function c1100008.initial_effect(c)
--
aux.AddCodeList(c,1192020)
--
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1100008,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetTarget(c1100008.tg1)
e1:SetOperation(c1100008.op1)
c:RegisterEffect(e1)
--
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1100008,1))
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_PREDRAW)
e2:SetRange(LOCATION_GRAVE)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetCondition(c1100008.con2)
e2:SetCost(aux.bfgcost)
e2:SetTarget(c1100008.tg2)
e2:SetOperation(c1100008.op2)
c:RegisterEffect(e2)
--
end
--
function c1100008.exfilter1(c,tp,rc,mg,opchk)
return Duel.GetLocationCountFromEx(tp,tp,rc,c)>0
and (opchk or Duel.IsExistingMatchingCard(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,1,c,nil,mg))
end
function c1100008.spfilter1(c,e,tp,rc,chkrel,chknotrel,tgchk,opchk)
if not (c:IsCode(20013) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)) then return false end
local mg=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_MZONE,LOCATION_MZONE,nil)
if mg:IsExists(Card.GetHandSynchro,1,nil) then
local mg2=Duel.GetMatchingGroup(nil,tp,LOCATION_HAND,0,nil)
if mg2:GetCount()>0 then mg:Merge(mg2) end
end
mg:AddCard(c)
if tgchk then
return c1100008.exfilter1(c,tp,nil,mg,opchk)
else
return (chkrel and c1100008.exfilter1(c,tp,rc,mg-rc)) or (chknotrel and c1100008.exfilter1(c,tp,nil,mg))
end
end
function c1100008.tg1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
local c=e:GetHandler()
return Duel.IsPlayerCanSpecialSummonCount(tp,2)
and Duel.IsExistingMatchingCard(c1100008.spfilter1,tp,LOCATION_EXTRA,0,1,nil,e,tp,c,nil,nil,true)
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function c1100008.op1(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c1100008.spfilter1,tp,LOCATION_EXTRA,0,1,1,nil,e,tp,c,nil,nil,true,true)
local tc=g:GetFirst()
if tc and Duel.SpecialSummon(tc,SUMMON_TYPE_SYNCHRO,tp,tp,false,false,POS_FACEUP)>0 then
Duel.RaiseEvent(c,EVENT_ADJUST,nil,0,PLAYER_NONE,PLAYER_NONE,0)
local tg=Duel.GetMatchingGroup(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,nil,nil)
if tg:GetCount()>0 then
Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local sg=tg:Select(tp,1,1,nil)
Duel.SynchroSummon(tp,sg:GetFirst(),nil)
end
end
end
--
function c1100008.con2(e,tp,eg,ep,ev,re,r,rp)
return tp==Duel.GetTurnPlayer() and Duel.GetFieldGroupCount(tp,LOCATION_DECK,0)>0 and Duel.GetDrawCount(tp)>0
end
function c1100008.tfilter2(c)
return c:IsCode(20200) and c:IsAbleToHand()
end
function c1100008.tg2(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingMatchingCard(c1100008.tfilter2,tp,LOCATION_DECK,0,1,nil) end
local dt=Duel.GetDrawCount(tp)
if dt~=0 then
aux.DrawReplaceCount=0
aux.DrawReplaceMax=dt
local e2_1=Effect.CreateEffect(e:GetHandler())
e2_1:SetType(EFFECT_TYPE_FIELD)
e2_1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2_1:SetCode(EFFECT_DRAW_COUNT)
e2_1:SetTargetRange(1,0)
e2_1:SetReset(RESET_PHASE+PHASE_DRAW)
e2_1:SetValue(0)
Duel.RegisterEffect(e2_1,tp)
end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function c1100008.op2(e,tp,eg,ep,ev,re,r,rp)
aux.DrawReplaceCount=aux.DrawReplaceCount+1
if aux.DrawReplaceCount<=aux.DrawReplaceMax then
if Nef.PLCounter.Get(tp,999104)~=0 then
local a=Nef.PLCounter.Get(tp,999104)
Nef.PLCounter.Add(tp,999104,1-a)
Nef.PLCounter.Add(1-tp,999104,1-a)
end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tg=Duel.SelectMatchingCard(tp,c1100008.tfilter2,tp,LOCATION_DECK,0,1,1,nil)
if tg:GetCount()<1 then return end
Duel.SendtoHand(tg,nil,REASON_EFFECT)
end
end
\ No newline at end of file
--虚网后台破坏者
local m=33300302
local cm=_G["c"..m]
function cm.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_TOGRAVE+CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_HAND+LOCATION_MZONE)
e1:SetCountLimit(1,m)
e1:SetCondition(cm.condition)
e1:SetTarget(cm.target)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
--
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_HANDES)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_TO_GRAVE)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCondition(cm.condition2)
e2:SetCost(cm.cost)
e2:SetTarget(cm.thtg)
e2:SetOperation(cm.thop)
c:RegisterEffect(e2)
end
function cm.IsLinkZoneOver(count)
local flag=0
for i=0,4 do
if (Duel.GetLinkedZone(0)&((2^i)<<0))~=0 then
flag=flag+1
end
if (Duel.GetLinkedZone(1)&((2^i)<<0))~=0 then
flag=flag+1
end
end
return flag>=count
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return cm.IsLinkZoneOver(3)
end
function cm.check(c)
return c:IsFacedown() and c:IsAbleToGrave()
end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.check,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) and e:GetHandler():IsDestructable(e) end
local g=Duel.GetMatchingGroup(cm.check,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil)
Duel.SetOperationInfo(0,CATEGORY_DECKDES,e:GetHandler(),1,0,0)
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,g,g:GetCount(),0,0)
end
function cm.operation(e,tp)
local sg=Duel.GetMatchingGroup(cm.check,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil)
if Duel.SendtoGrave(sg,REASON_EFFECT)~=0 then
if e:GetHandler():IsRelateToEffect(e) then
Duel.Destroy(e:GetHandler(),REASON_EFFECT)
end
end
end
function cm.condition2(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD)
end
function cm.thcheck(c)
return c:IsSetCard(0x562) and c:IsAbleToHand() and c:IsType(TYPE_SPELL+TYPE_TRAP)
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetFlagEffect(tp,m)==0 end
Duel.RegisterFlagEffect(tp,m,RESET_PHASE+PHASE_END,0,1)
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.thcheck,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function cm.thop(e,tp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local sg=Duel.SelectMatchingCard(tp,cm.thcheck,tp,LOCATION_DECK,0,1,1,nil)
if sg:GetCount()>0 then
if Duel.SendtoHand(sg,tp,REASON_EFFECT)>0 then
Duel.ConfirmCards(1-tp,sg)
if Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,nil,REASON_EFFECT) and Duel.IsExistingMatchingCard(cm.tgcheck,tp,LOCATION_REMOVED,0,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(m,2)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD)
local tg=Duel.DiscardHand(tp,nil,1,1,REASON_EFFECT,nil)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local rg=Duel.SelectMatchingCard(tp,cm.tgcheck,tp,LOCATION_REMOVED,0,1,1,nil)
Duel.SendtoGrave(rg,REASON_EFFECT+REASON_RETURN)
end
end
end
end
function cm.tgcheck(c)
return c:IsSetCard(0x562) and c:IsFaceup() and c:IsType(TYPE_MONSTER)
end
\ No newline at end of file
--虚网字节妖精
local m=33300304
local cm=_G["c"..m]
function cm.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_REMOVE+CATEGORY_TOGRAVE+CATEGORY_TOHAND)
e1:SetDescription(aux.Stringid(m,0))
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_HAND)
e1:SetCost(cm.cost)
e1:SetTarget(cm.target)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
--special summon
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetRange(LOCATION_GRAVE)
e2:SetCountLimit(1,m)
e2:SetCost(cm.cost2)
e2:SetTarget(cm.target2)
e2:SetOperation(cm.operation2)
c:RegisterEffect(e2)
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return not e:GetHandler():IsPublic() and Duel.GetFlagEffect(tp,m)==0 end
Duel.RegisterFlagEffect(tp,m,RESET_PHASE+PHASE_END,0,1)
end
function cm.rmcheck(c)
return c:IsSetCard(0x562) and c:IsAbleToGrave() and c:IsType(TYPE_MONSTER)
end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.rmcheck,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,tp,LOCATION_DECK)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_GRAVE)
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,e:GetHandler(),1,tp,0)
end
function cm.adcheck(c)
return c:IsSetCard(0x562) and c:IsAbleToHand() and not c:IsCode(m)
end
function cm.operation(e,tp)
local c=e:GetHandler()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local rg=Duel.SelectMatchingCard(tp,cm.rmcheck,tp,LOCATION_DECK,0,1,1,nil)
if rg:GetCount()>0 and Duel.Remove(rg,POS_FACEUP,REASON_EFFECT)~=0 and Duel.IsExistingMatchingCard(cm.adcheck,tp,LOCATION_GRAVE,0,1,nil) and c:IsAbleToGrave() and Duel.SelectYesNo(tp,aux.Stringid(m,2)) then
Duel.BreakEffect()
Duel.SendtoGrave(c,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local tg=Duel.SelectMatchingCard(tp,cm.adcheck,tp,LOCATION_GRAVE,0,1,1,nil)
Duel.SendtoHand(tg,tp,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tg)
end
end
function cm.IsLinkZoneOver(count)
local flag=0
for i=0,4 do
if (Duel.GetLinkedZone(0)&((2^i)<<0))~=0 then
flag=flag+1
end
if (Duel.GetLinkedZone(1)&((2^i)<<0))~=0 then
flag=flag+1
end
end
return flag>=count
end
function cm.hspcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
return ft>0 and cm.IsLinkZoneOver(3)
end
function cm.costcheck(c,tp)
return c:IsAbleToGraveAsCost() and c:IsSetCard(0x562) and Duel.GetLocationCountFromEx(tp,tp,c)>0
end
function cm.cost2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.costcheck,tp,LOCATION_MZONE,0,1,nil,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local sg=Duel.SelectMatchingCard(tp,cm.costcheck,tp,LOCATION_MZONE,0,1,1,nil,tp)
Duel.SendtoGrave(sg,REASON_COST)
end
function cm.rmcheck(c)
return c:IsSetCard(0x562) and c:IsAbleToGrave() and c:IsType(TYPE_MONSTER)
end
function cm.target2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,tp,LOCATION_GRAVE)
end
function cm.operation2(e,tp)
local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and c:IsRelateToEffect(e) then
if Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 and cm.IsLinkZoneOver(3) and Duel.SelectYesNo(tp,aux.Stringid(m,3)) then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_INDESTRUCTABLE_BATTLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(1)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
c:RegisterEffect(e1)
end
end
end
\ No newline at end of file
--多线程虚网操作员
local m=33300305
local cm=_G["c"..m]
function cm.initial_effect(c)
--link summon
c:EnableReviveLimit()
--
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e1:SetCountLimit(1,m+EFFECT_COUNT_CODE_OATH)
e1:SetTarget(cm.thtg)
e1:SetOperation(cm.thop)
c:RegisterEffect(e1)
--spsummon
local e7=Effect.CreateEffect(c)
e7:SetDescription(aux.Stringid(m,1))
e7:SetCategory(CATEGORY_SPECIAL_SUMMON)
e7:SetType(EFFECT_TYPE_QUICK_O)
e7:SetCode(EVENT_FREE_CHAIN)
e7:SetRange(LOCATION_GRAVE)
e7:SetCountLimit(1,33300300+EFFECT_COUNT_CODE_OATH)
e7:SetCost(aux.bfgcost)
e7:SetTarget(cm.sptg)
e7:SetOperation(cm.spop)
c:RegisterEffect(e7)
--
local e1=Effect.CreateEffect(c)
e1:SetDescription(1166)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetRange(LOCATION_EXTRA)
e1:SetCondition(cm.lcon)
e1:SetTarget(cm.ltg)
e1:SetOperation(cm.LinkOperation(nil,2,2,cm.gf))
e1:SetValue(SUMMON_TYPE_LINK)
c:RegisterEffect(e1)
end
function cm.LinkOperation(f,minc,maxc,gf)
return function(e,tp,eg,ep,ev,re,r,rp,c,og,lmat,min,max)
local g=e:GetLabelObject()
if g:IsExists(cm.extracheck,1,nil) then
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e3:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
e3:SetValue(1)
e3:SetReset(RESET_EVENT+0x7e0000)
c:RegisterEffect(e3,true)
end
c:SetMaterial(g)
Auxiliary.LExtraMaterialCount(g,c,tp)
Duel.SendtoGrave(g,REASON_MATERIAL+REASON_LINK)
g:DeleteGroup()
end
end
function cm.lcheck(c)
return c:IsSetCard(0x562) or c:GetOriginalCode()==33300308
end
function cm.extracheck(c)
return c:IsFaceup() and c:GetOriginalCode()==33300308
end
function cm.gf(g)
return g:IsExists(cm.lcheck,1,nil)
end
function cm.lcon(...)
local f=aux.GetLinkMaterials
aux.GetLinkMaterials=cm.GetLinkMaterials
local res=Auxiliary.LinkCondition(nil,2,2,cm.gf)(...)
aux.GetLinkMaterials=f
return res
end
function cm.ltg(...)
local f=aux.GetLinkMaterials
aux.GetLinkMaterials=cm.GetLinkMaterials
local res=Auxiliary.LinkTarget(nil,2,2,cm.gf)(...)
aux.GetLinkMaterials=f
return res
end
function cm.GetLinkMaterials(tp,f,lc)
local mg=Duel.GetMatchingGroup(Auxiliary.LConditionFilter,tp,LOCATION_MZONE,0,nil,f,lc)
local mg2=Duel.GetMatchingGroup(Auxiliary.LExtraFilter,tp,LOCATION_HAND+LOCATION_SZONE,LOCATION_ONFIELD,nil,f,lc,tp)
local mg3=Duel.GetMatchingGroup(cm.extracheck,tp,LOCATION_SZONE,0,nil)
if mg2:GetCount()>0 then mg:Merge(mg2) end
if mg3:GetCount()>0 then mg:Merge(mg3) end
return mg
end
function cm.thfilter(c)
return c:IsSetCard(0x562) and c:IsAbleToHand()
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_DECK,0,1,nil) and e:GetHandler():IsAbleToGrave() end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.thfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
if Duel.SendtoHand(g,nil,REASON_EFFECT)~=0 then
Duel.ConfirmCards(1-tp,g)
Duel.BreakEffect()
if e:GetHandler():IsRelateToEffect(e) then
Duel.SendtoGrave(e:GetHandler(),REASON_EFFECT)
end
end
end
end
function cm.IsLinkZoneOver(count)
local flag=0
for i=0,4 do
if (Duel.GetLinkedZone(0)&((2^i)<<0))~=0 then
flag=flag+1
end
if (Duel.GetLinkedZone(1)&((2^i)<<0))~=0 then
flag=flag+1
end
end
return flag>=count
end
function cm.tgcheck(c)
return c:IsLocation(LOCATION_SZONE) or (c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsFaceup())
end
function cm.spfilter(c,e,tp)
return c:IsSetCard(0x562) 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.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE)
end
function cm.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(cm.spfilter),tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil,e,tp)
if g:GetCount()>0 then
local tc=g:GetFirst()
if Duel.SpecialSummonStep(tc,0,tp,tp,false,false,POS_FACEUP) then
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(1)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1,true)
Duel.SpecialSummonComplete()
if cm.IsLinkZoneOver(3)and Duel.IsExistingMatchingCard(cm.tgcheck,tp,0,LOCATION_ONFIELD,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(m,2)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local sg=Duel.SelectMatchingCard(tp,cm.tgcheck,tp,0,LOCATION_ONFIELD,1,1,nil)
Duel.SendtoGrave(sg,REASON_EFFECT)
end
end
end
end
\ No newline at end of file
--链路虚网控制者
local m=33300306
local cm=_G["c"..m]
function cm.initial_effect(c)
--link summon
c:EnableReviveLimit()
--
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_CONTROL+CATEGORY_TOGRAVE)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1)
e1:SetTarget(cm.cttg)
e1:SetOperation(cm.ctop)
c:RegisterEffect(e1)
--spsummon
local e7=Effect.CreateEffect(c)
e7:SetDescription(aux.Stringid(m,1))
e7:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_ATKCHANGE+CATEGORY_DISABLE)
e7:SetType(EFFECT_TYPE_QUICK_O)
e7:SetCode(EVENT_FREE_CHAIN)
e7:SetRange(LOCATION_GRAVE)
e7:SetCountLimit(1,m+EFFECT_COUNT_CODE_OATH)
e7:SetCost(aux.bfgcost)
e7:SetTarget(cm.sptg)
e7:SetOperation(cm.spop)
c:RegisterEffect(e7)
local e1=Effect.CreateEffect(c)
e1:SetDescription(1166)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetRange(LOCATION_EXTRA)
e1:SetCondition(cm.lcon)
e1:SetTarget(cm.ltg)
e1:SetOperation(cm.LinkOperation(nil,2,3,cm.gf))
e1:SetValue(SUMMON_TYPE_LINK)
c:RegisterEffect(e1)
end
function cm.LinkOperation(f,minc,maxc,gf)
return function(e,tp,eg,ep,ev,re,r,rp,c,og,lmat,min,max)
local g=e:GetLabelObject()
if g:IsExists(cm.extracheck,1,nil) then
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e3:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
e3:SetValue(1)
e3:SetReset(RESET_EVENT+0x7e0000)
c:RegisterEffect(e3,true)
end
c:SetMaterial(g)
Auxiliary.LExtraMaterialCount(g,c,tp)
Duel.SendtoGrave(g,REASON_MATERIAL+REASON_LINK)
g:DeleteGroup()
end
end
function cm.lcheck(c)
return c:IsSetCard(0x562) or c:GetOriginalCode()==33300308
end
function cm.extracheck(c)
return c:IsFaceup() and c:GetOriginalCode()==33300308
end
function cm.exc(c)
return not c:IsType(TYPE_EFFECT) and not c:GetOriginalCode()==33300308
end
function cm.gf(g)
return g:IsExists(cm.lcheck,1,nil) and not g:IsExists(cm.exc,1,nil)
end
function cm.lcon(...)
local f=aux.GetLinkMaterials
aux.GetLinkMaterials=cm.GetLinkMaterials
local res=Auxiliary.LinkCondition(nil,2,3,cm.gf)(...)
aux.GetLinkMaterials=f
return res
end
function cm.ltg(...)
local f=aux.GetLinkMaterials
aux.GetLinkMaterials=cm.GetLinkMaterials
local res=Auxiliary.LinkTarget(nil,2,3,cm.gf)(...)
aux.GetLinkMaterials=f
return res
end
function cm.GetLinkMaterials(tp,f,lc)
local mg=Duel.GetMatchingGroup(Auxiliary.LConditionFilter,tp,LOCATION_MZONE,0,nil,f,lc)
local mg2=Duel.GetMatchingGroup(Auxiliary.LExtraFilter,tp,LOCATION_HAND+LOCATION_SZONE,LOCATION_ONFIELD,nil,f,lc,tp)
local mg3=Duel.GetMatchingGroup(cm.extracheck,tp,LOCATION_SZONE,0,nil)
if mg2:GetCount()>0 then mg:Merge(mg2) end
if mg3:GetCount()>0 then mg:Merge(mg3) end
return mg
end
function cm.ctcheck(c,tp)
return c:IsControler(1-tp)
end
function cm.cttg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
local tg=c:GetLinkedGroup()
if not tg:IsExists(cm.ctcheck,1,nil,tp,zone) then
return false
end
local tc=tg:Filter(cm.ctcheck,nil,tp):GetFirst()
if chk==0 then
local zone=bit.band(c:GetLinkedZone(),0x1f)
return tc:IsControlerCanBeChanged(false,zone) --tg:IsExists(cm.ctcheck,1,nil,tp,zone)
end
Duel.SetTargetCard(tc)
Duel.SetOperationInfo(0,CATEGORY_CONTROL,tc,1,0,0)
end
function cm.ctop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
local zone=bit.band(c:GetLinkedZone(),0x1f)
if Duel.GetControl(tc,tp,0,0,zone)~=0 then
Duel.BreakEffect()
--Duel.SendtoGrave(c,REASON_EFFECT)
end
end
end
function cm.IsLinkZoneOver(count)
local flag=0
for i=0,4 do
if (Duel.GetLinkedZone(0)&((2^i)<<0))~=0 then
flag=flag+1
end
if (Duel.GetLinkedZone(1)&((2^i)<<0))~=0 then
flag=flag+1
end
end
return flag>=count
end
function cm.spfilter(c,e,tp)
return c:IsSetCard(0x562) 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.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE)
end
function cm.filter(c)
return c:IsFaceup() and (c:GetAttack()>0 or aux.NegateMonsterFilter(c))
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(cm.spfilter),tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil,e,tp)
if g:GetCount()>0 then
local tc=g:GetFirst()
if Duel.SpecialSummonStep(tc,0,tp,tp,false,false,POS_FACEUP) then
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(1)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1,true)
Duel.SpecialSummonComplete()
if cm.IsLinkZoneOver(3)and Duel.IsExistingMatchingCard(cm.filter,tp,0,LOCATION_MZONE,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(m,2)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISABLE)
local sg=Duel.SelectMatchingCard(tp,cm.filter,tp,0,LOCATION_MZONE,1,1,nil)
local tc1=sg:GetFirst()
Duel.NegateRelatedChain(tc1,RESET_TURN_SET)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc1:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetValue(RESET_TURN_SET)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc1:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_SET_ATTACK_FINAL)
e3:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
e3:SetValue(0)
tc1:RegisterEffect(e3)
end
end
end
end
\ No newline at end of file
......@@ -2,100 +2,58 @@
local m=66916001
local cm=_G["c"..m]
function cm.initial_effect(c)
--search
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetCountLimit(1,m)
e2:SetCost(cm.descost)
e2:SetTarget(cm.sptg)
e2:SetOperation(cm.spop)
c:RegisterEffect(e2)
--special summon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,1))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_GRAVE)
e1:SetCountLimit(1,m+1)
e1:SetCondition(cm.con)
e1:SetCost(cm.cost)
e1:SetTarget(cm.targets)
e1:SetOperation(cm.operations)
c:RegisterEffect(e1)
--synchro level
local e22=Effect.CreateEffect(c)
e22:SetType(EFFECT_TYPE_SINGLE)
e22:SetCode(EFFECT_SYNCHRO_LEVEL)
e22:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e22:SetRange(LOCATION_MZONE)
e22:SetValue(cm.lvval)
c:RegisterEffect(e22)
Duel.AddCustomActivityCounter(m,ACTIVITY_SPSUMMON,cm.counterfilter)
--search
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCountLimit(1,m)
e2:SetTarget(cm.sptg)
e2:SetOperation(cm.spop)
c:RegisterEffect(e2)
--synchro level
local e22=Effect.CreateEffect(c)
e22:SetType(EFFECT_TYPE_SINGLE)
e22:SetCode(EFFECT_SYNCHRO_LEVEL)
e22:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e22:SetRange(LOCATION_MZONE)
e22:SetValue(cm.lvval)
c:RegisterEffect(e22)
Duel.AddCustomActivityCounter(m,ACTIVITY_SPSUMMON,cm.counterfilter)
end
function cm.counterfilter(c)
return c:IsSetCard(0x999)
end
function cm.con(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetMatchingGroupCount(aux.TRUE,tp,LOCATION_ONFIELD,0,nil)>Duel.GetMatchingGroupCount(aux.TRUE,tp,0,LOCATION_ONFIELD,nil)
end
function cm.descost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetCustomActivityCount(m,tp,ACTIVITY_SPSUMMON)==0 end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_OATH)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetTargetRange(1,0)
e1:SetLabelObject(e)
e1:SetTarget(cm.splimit)
Duel.RegisterEffect(e1,tp)
return c:IsSetCard(0x999)
end
function cm.splimit(e,c,sump,sumtype,sumpos,targetp,se)
return not c:IsSetCard(0x999)
return not c:IsSetCard(0x999)
end
function cm.filter(c,e,tp)
return c:IsSetCard(0xc999) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and not c:IsCode(66916001)
return c:IsSetCard(0xc999) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and not c:IsCode(66916001)
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK+LOCATION_GRAVE)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_HAND+LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND+LOCATION_GRAVE)
end
function cm.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(cm.filter),tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(cm.filter),tp,LOCATION_HAND+LOCATION_GRAVE,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
end
function cm.filters(c)
return c:IsFaceup() and c:IsSetCard(0x999) and c:IsAbleToGraveAsCost()
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.filters,tp,LOCATION_ONFIELD,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,cm.filters,tp,LOCATION_ONFIELD,0,1,1,nil)
Duel.SendtoGrave(g,REASON_COST)
end
function cm.targets(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end
function cm.operations(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 then
end
return c:IsFaceup() and c:IsSetCard(0x999) and c:IsAbleToGraveAsCost()
end
function cm.lvval(e,c)
local lv=e:GetHandler():GetLevel()
if c:IsSetCard(0x999) then return 4*65536+lv
else
return lv
end
local lv=e:GetHandler():GetLevel()
if c:IsSetCard(0x999) then return 4*65536+lv
else
return lv
end
end
\ No newline at end of file
......@@ -61,7 +61,7 @@ function cCardno.ckop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
c:ResetFlagEffect(Cardno)
local nowg=c:GetOverlayGroup()
c:RegisterFlagEffect(Cardno,0,0,0,nowg:FilterCount(Card.IsSetCard,nil,0x298))
c:RegisterFlagEffect(Cardno,0,0,0,nowg:GetCount())
end
--SpecialSummon
function cCardno.spfilter2(c,e,tp)
......@@ -123,10 +123,7 @@ function cCardno.ssop(e,tp,eg,ep,ev,re,r,rp)
end
-- xyz
function cCardno.xyzfilter(c,tp,xyzc)
return c:IsFaceup() and c:IsCanBeXyzMaterial(xyzc) and ((c:IsType(TYPE_XYZ) and c:IsRank(12)) or (c:IsType(TYPE_MONSTER) and c:IsSetCard(0x298))) and Duel.GetLocationCountFromEx(tp,tp,c,xyzc)>0
end
function cCardno.xyzfilter2(c)
return c:IsType(TYPE_MONSTER) and c:IsSetCard(0x298) and c:IsAbleToDeck()
return c:IsFaceup() and c:IsCanBeXyzMaterial(xyzc) and c:IsType(TYPE_MONSTER) and c:IsSetCard(0x298) and Duel.GetLocationCountFromEx(tp,tp,c,xyzc)>0
end
function cCardno.xyzcon(e,c)
if c==nil then return true end
......@@ -134,13 +131,10 @@ function cCardno.xyzcon(e,c)
return Duel.IsExistingMatchingCard(cCardno.xyzfilter,tp,LOCATION_MZONE,0,1,nil,tp,c)
end
function cCardno.xyzop(e,tp,eg,ep,ev,re,r,rp,c)
--Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
--local dg = Duel.SelectMatchingCard(tp,cCardno.xyzfilter2,tp,LOCATION_HAND,0,1,1,nil)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_XMATERIAL)
local mg = Duel.SelectMatchingCard(tp,cCardno.xyzfilter,tp,LOCATION_MZONE,0,1,1,nil,tp,c)
local tc=mg:GetFirst()
if not tc then return end
--Duel.SendtoDeck(dg,nil,2,REASON_EFFECT)
local mg2=tc:GetOverlayGroup()
if mg2:GetCount()~=0 then
Duel.Overlay(c,mg2)
......
--春色小径
require("expansions/script/nef/nef")
function c74563038.initial_effect(c)
--to field
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetCategory(CATEGORY_HANDES)
e4:SetDescription(aux.Stringid(74563038,0))
e4:SetRange(LOCATION_DECK)
e4:SetCountLimit(1,74563038)
e4:SetCost(c74563038.drcost)
e4:SetCondition(c74563038.tfcon)
e4:SetOperation(c74563038.tfop)
c:RegisterEffect(e4)
--to field
local e41=Effect.CreateEffect(c)
e41:SetType(EFFECT_TYPE_IGNITION)
e41:SetCategory(CATEGORY_HANDES)
e41:SetDescription(aux.Stringid(74563038,1))
e41:SetCountLimit(1,74563038)
e41:SetRange(LOCATION_DECK)
e41:SetCost(c74563038.drcost1)
e41:SetCondition(c74563038.tfcon)
e41:SetOperation(c74563038.tfop)
c:RegisterEffect(e41)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
c:RegisterEffect(e1)
Nef.SeasonChange(c)
--disable
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(74563038,2))
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_FZONE)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetCountLimit(1)
e2:SetTarget(c74563038.distg)
e2:SetOperation(c74563038.disop)
c:RegisterEffect(e2)
end
function c74563038.distg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
end
function c74563038.disop(e,tp,eg,ep,ev,re,r,rp,chk)
if Nef.PLCounter.Get(tp,999104)~=0 then
local a=Nef.PLCounter.Get(tp,999104)
Nef.PLCounter.Add(tp,999104,1-a)
Nef.PLCounter.Add(1-tp,999104,1-a)
end
end
--to field
function c74563038.tfcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetLP(tp)>=10000 and not e:GetHandler():IsForbidden() and Duel.GetFieldGroupCount(tp,LOCATION_HAND,0)>0
end
function c74563038.costfilter(c)
return c:IsSetCard(0x100) and c:IsType(TYPE_MONSTER) and not c:IsPublic()
end
function c74563038.drcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckLPCost(tp,800)end
Duel.PayLPCost(tp,800)
end
function c74563038.drcost1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c74563038.costfilter,tp,LOCATION_HAND,0,2,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CONFIRM)
local g=Duel.SelectMatchingCard(tp,c74563038.costfilter,tp,LOCATION_HAND,0,2,2,nil)
Duel.ConfirmCards(1-tp,g)
Duel.ShuffleHand(tp)
end
function c74563038.tfop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if Duel.DiscardHand(tp,nil,1,1,REASON_EFFECT+REASON_DISCARD)~=0 then
Duel.BreakEffect()
if c:IsRelateToEffect(e) then
Duel.MoveToField(c,tp,tp,LOCATION_FZONE,POS_FACEUP,true)
end
end
end
\ No newline at end of file
--蛙狩『蛙以口鸣,方致蛇祸』
function c74563042.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_CHAINING)
e1:SetCondition(c74563042.condition)
e1:SetCost(c74563042.cost)
e1:SetTarget(c74563042.target)
e1:SetOperation(c74563042.activate)
c:RegisterEffect(e1)
--Activate
local e12=e1:Clone()
e12:SetCode(EVENT_ATTACK_ANNOUNCE)
e12:SetCost(c74563042.cost1)
e12:SetCondition(c74563042.conditions)
c:RegisterEffect(e12)
end
function c74563042.conditions(e,tp,eg,ep,ev,re,r,rp)
local c=Duel.GetAttacker()
return c:IsRace(RACE_AQUA) and c:IsReleasable() and c:IsControler(tp)
end
function c74563042.condition(e,tp,eg,ep,ev,re,r,rp)
local loc=Duel.GetChainInfo(ev,CHAININFO_TRIGGERING_LOCATION)
return ep==tp and loc==LOCATION_MZONE and re:IsActiveType(TYPE_MONSTER) and re:GetHandler():IsRace(RACE_AQUA) and re:GetHandler():IsReleasable()
end
function c74563042.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return re:GetHandler():IsReleasable() end
Duel.Release(re:GetHandler(),REASON_COST)
end
function c74563042.cost1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetAttacker():IsReleasable() end
Duel.Release(Duel.GetAttacker(),REASON_COST)
end
function c74563042.filter(c)
return c:IsSetCard(0x492) and c:IsAbleToHand()
end
function c74563042.filters(c,e,tp)
return c:IsRace(RACE_REPTILE) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c74563042.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c74563042.filter,tp,LOCATION_DECK,0,1,nil) or Duel.IsExistingMatchingCard(c74563042.filters,tp,LOCATION_DECK,0,1,nil,e,tp) end
end
function c74563042.tfilter(c)
return c:IsCanAddCounter(0x128a,3) and c:IsFaceup()
end
function c74563042.activate(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetFlagEffect(tp,74563042)==0 then
Duel.RegisterFlagEffect(tp,74563042,0,0,1)
Duel.RegisterFlagEffect(tp,74563002,0,0,1)
end
local opt=0
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(c74563042.filter,tp,LOCATION_DECK,0,1,nil,e,tp) and Duel.IsExistingMatchingCard(c74563042.filters,tp,LOCATION_DECK,0,1,nil,e,tp) then
opt=Duel.SelectOption(tp,aux.Stringid(74563042,1),aux.Stringid(74563042,0))+1
elseif Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(c74563042.filters,tp,LOCATION_DECK,0,1,nil,e,tp) then opt=1
elseif Duel.IsExistingMatchingCard(c74563042.filter,tp,LOCATION_DECK,0,1,nil) then opt=2
end
if opt==1 then
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c74563042.filters,tp,LOCATION_DECK,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
elseif opt==2 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c74563042.filter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
if Duel.IsExistingMatchingCard(c74563042.tfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,e:GetHandler()) and Duel.SelectYesNo(tp,aux.Stringid(74563042,2)) then
Duel.BreakEffect()
local g=Duel.SelectMatchingCard(tp,c74563042.tfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,e:GetHandler())
g:GetFirst():AddCounter(0x128a,3)
if Duel.GetFlagEffect(g:GetFirst():GetControler(),23200)==0 then
Duel.RegisterFlagEffect(g:GetFirst():GetControler(),23200,0,0,0)
end
end
end
end
end
\ No newline at end of file
--因幡✿十年的白兔
function c86379544.initial_effect(c)
--set
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_MONSTER_SSET)
e1:SetValue(TYPE_SPELL+TYPE_QUICKPLAY)
c:RegisterEffect(e1)
--Activate
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(86379544,0))
e2:SetCategory(CATEGORY_DICE+CATEGORY_SPECIAL_SUMMON+CATEGORY_DAMAGE)
e2:SetType(EFFECT_TYPE_QUICK_O+EFFECT_TYPE_ACTIVATE)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetRange(LOCATION_SZONE)
e2:SetOperation(c86379544.operation)
c:RegisterEffect(e2)
--SpecialSummon
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(86379544,0))
e3:SetCategory(CATEGORY_DICE+CATEGORY_DAMAGE+CATEGORY_TODECK)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_DESTROYED)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e3:SetRange(LOCATION_GRAVE)
e3:SetCondition(c86379544.gcon)
e3:SetOperation(c86379544.gop)
c:RegisterEffect(e3)
end
--
c86379544.toss_dice=true
function c86379544.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local dc=Duel.TossDice(tp,1)
if dc==1 then
if not c:IsRelateToEffect(e) then return end
Duel.Destroy(c,REASON_EFFECT)
elseif dc>=6 then
if not c:IsRelateToEffect(e) then return end
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and c:IsCanBeSpecialSummoned(e,0,tp,false,false) then
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end
else
Duel.Damage(tp,300,REASON_EFFECT)
if not c:IsRelateToEffect(e) then return end
c:CancelToGrave()
Duel.ChangePosition(c,POS_FACEDOWN)
Duel.RaiseEvent(c,EVENT_SSET,e,REASON_EFFECT,tp,tp,0)
end
end
--
function c86379544.cfilter(c,tp)
return c:GetPreviousControler()==tp and c:IsReason(REASON_EFFECT)
end
function c86379544.gcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c86379544.cfilter,1,nil,tp) and e:GetHandler():IsReason(REASON_DESTROY)
end
function c86379544.gop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local dc=Duel.TossDice(tp,1)
if dc>=6 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,Card.IsAbleToDeck,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,3,nil)
if g:GetCount()>0 then
Duel.SendtoDeck(g,nil,2,REASON_EFFECT)
end
else
Duel.Damage(tp,300,REASON_EFFECT)
end
end
--因幡✿百年的白兔
function c86379546.initial_effect(c)
--set
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_MONSTER_SSET)
e1:SetValue(TYPE_SPELL+TYPE_QUICKPLAY)
c:RegisterEffect(e1)
--Activate
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(86379546,0))
e2:SetCategory(CATEGORY_DICE+CATEGORY_SPECIAL_SUMMON+CATEGORY_DAMAGE)
e2:SetType(EFFECT_TYPE_QUICK_O+EFFECT_TYPE_ACTIVATE)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetRange(LOCATION_SZONE)
e2:SetOperation(c86379546.operation)
c:RegisterEffect(e2)
--SpecialSummon
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(86379546,0))
e3:SetCategory(CATEGORY_DICE+CATEGORY_DAMAGE+CATEGORY_POSITION)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_DESTROYED)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e3:SetRange(LOCATION_GRAVE)
e3:SetCondition(c86379546.gcon)
e3:SetOperation(c86379546.gop)
c:RegisterEffect(e3)
end
--
c86379546.toss_dice=true
function c86379546.filter(c,e)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetDescription(aux.Stringid(86379546,0))
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SUMMON_PROC)
e1:SetReset(RESET_EVENT+RESET_TOFIELD)
e1:SetCondition(c86379546.ntcon)
return c:IsSetCard(0x256) and c:IsSummonable(true,e1)
end
function c86379546.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local dc=Duel.TossDice(tp,1)
if dc==1 then
if not c:IsRelateToEffect(e) then return end
Duel.Destroy(c,REASON_EFFECT)
elseif dc>=6 then
if not c:IsRelateToEffect(e) then return end
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and c:IsCanBeSpecialSummoned(e,0,tp,false,false) then
if Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(c86379546.filter,tp,LOCATION_HAND,0,1,nil,e) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON)
local g=Duel.SelectMatchingCard(tp,c86379546.filter,tp,LOCATION_HAND,0,1,1,nil,e)
local tc=g:GetFirst()
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetDescription(aux.Stringid(86379546,0))
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SUMMON_PROC)
e1:SetReset(RESET_EVENT+RESET_TOFIELD)
e1:SetCondition(c86379546.ntcon)
if tc then
tc:RegisterEffect(e1)
Duel.Summon(tp,tc,true,e1)
end
end
end
end
else
Duel.Damage(tp,600,REASON_EFFECT)
if not c:IsRelateToEffect(e) then return end
c:CancelToGrave()
Duel.ChangePosition(c,POS_FACEDOWN)
Duel.RaiseEvent(c,EVENT_SSET,e,REASON_EFFECT,tp,tp,0)
end
end
function c86379546.ntcon(e,c)
if c==nil then return true end
return c:GetLevel()>0
and Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0
end
--
function c86379546.cfilter(c,tp)
return c:GetPreviousControler()==tp and c:IsReason(REASON_EFFECT)
end
function c86379546.gcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c86379546.cfilter,1,nil,tp) and e:GetHandler():IsReason(REASON_DESTROY)
end
function c86379546.gfilter(c)
return c:IsFaceup() and c:IsCanTurnSet()
end
function c86379546.gop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local dc=Duel.TossDice(tp,1)
if dc>=6 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local g=Duel.SelectMatchingCard(tp,c86379546.gfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
if g:GetCount()>0 then
local tc=g:GetFirst()
if tc:IsType(TYPE_MONSTER) then
Duel.ChangePosition(tc,POS_FACEDOWN_DEFENSE)
else
Duel.ChangePosition(tc,POS_FACEDOWN)
Duel.RaiseEvent(tc,EVENT_SSET,e,REASON_EFFECT,tp,tc:GetControler(),0)
end
end
else
Duel.Damage(tp,600,REASON_EFFECT)
end
end
--千年的白兔✿因幡帝
function c86379548.initial_effect(c)
--set
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_MONSTER_SSET)
e1:SetValue(TYPE_SPELL+TYPE_QUICKPLAY)
c:RegisterEffect(e1)
--Activate
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(86379548,0))
e2:SetCategory(CATEGORY_DICE+CATEGORY_SPECIAL_SUMMON+CATEGORY_DAMAGE)
e2:SetType(EFFECT_TYPE_QUICK_O+EFFECT_TYPE_ACTIVATE)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetRange(LOCATION_SZONE)
e2:SetOperation(c86379548.operation)
c:RegisterEffect(e2)
--SpecialSummon
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(86379548,0))
e3:SetCategory(CATEGORY_DICE+CATEGORY_DAMAGE+CATEGORY_TODECK)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_DESTROYED)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e3:SetRange(LOCATION_GRAVE)
e3:SetCondition(c86379548.gcon)
e3:SetOperation(c86379548.gop)
c:RegisterEffect(e3)
end
--
c86379548.toss_dice=true
function c86379548.filter(c)
return c:IsSetCard(0x256) and c:IsAbleToHand() and not c:IsCode(86379548)
end
function c86379548.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local dc=Duel.TossDice(tp,1)
if dc==1 then
if not c:IsRelateToEffect(e) then return end
Duel.Destroy(c,REASON_EFFECT)
elseif dc>=6 then
if not c:IsRelateToEffect(e) then return end
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and c:IsCanBeSpecialSummoned(e,0,tp,false,false) then
if Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then
if Duel.IsExistingMatchingCard(c86379548.filter,tp,LOCATION_DECK,0,1,nil) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c86379548.filter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
end
end
else
Duel.Damage(tp,1200,REASON_EFFECT)
if not c:IsRelateToEffect(e) then return end
c:CancelToGrave()
Duel.ChangePosition(c,POS_FACEDOWN)
Duel.RaiseEvent(c,EVENT_SSET,e,REASON_EFFECT,tp,tp,0)
end
end
--
function c86379548.cfilter(c,tp)
return c:GetPreviousControler()==tp and c:IsReason(REASON_EFFECT)
end
function c86379548.gcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c86379548.cfilter,1,nil,tp) and e:GetHandler():IsReason(REASON_DESTROY)
end
function c86379548.gfilter(c)
return c:IsFaceup() and c:IsCanTurnSet()
end
function c86379548.gop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local dc=Duel.TossDice(tp,1)
if dc>=6 then
if not c:IsRelateToEffect(e) then return end
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and c:IsCanBeSpecialSummoned(e,0,tp,false,false) then
if Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then
local lv=Duel.AnnounceLevel(tp,1,4)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_CHANGE_LEVEL)
e1:SetValue(lv)
e1:SetReset(RESET_EVENT+0x1fe0000)
c:RegisterEffect(e1)
end
end
else
Duel.Damage(tp,1200,REASON_EFFECT)
end
end
--因幡✿永远亭的群兔
function c86379550.initial_effect(c)
--xyz summon
c:EnableReviveLimit()
aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0x208),2,2,nil,nil,13)
--lv change
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_FIELD)
e0:SetCode(EFFECT_XYZ_LEVEL)
e0:SetProperty(EFFECT_FLAG_SET_AVAIABLE)
e0:SetRange(LOCATION_EXTRA)
e0:SetTargetRange(LOCATION_MZONE,0)
e0:SetTarget(c86379550.lvtg)
e0:SetValue(c86379550.lvval)
c:RegisterEffect(e0)
--SpecialSummon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(86379550,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,86379550)
e1:SetCondition(c86379550.spcon)
e1:SetCost(c86379550.spcost)
e1:SetTarget(c86379550.sptg)
e1:SetOperation(c86379550.spop)
c:RegisterEffect(e1)
--Destroy
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(86379550,1))
e2:SetCategory(CATEGORY_DESTROY)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_DESTROYED)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET)
e2:SetRange(LOCATION_MZONE)
e2:SetCondition(c86379550.descon)
e2:SetCost(c86379550.descost)
e2:SetTarget(c86379550.destg)
e2:SetOperation(c86379550.desop)
c:RegisterEffect(e2)
end
--
function c86379550.lvtg(e,c)
return c:IsSetCard(0x256)
end
function c86379550.lvval(e,c,rc)
local lv=c:GetLevel()
if rc==e:GetHandler() then return 2
else return lv end
end
--
function c86379550.spcon(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase()
return ph~=PHASE_MAIN1 and ph~=PHASE_MAIN2
end
function c86379550.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end
local ot=e:GetHandler():GetOverlayCount()
local gt=Duel.GetMatchingGroupCount(c86379550.spfilter,tp,LOCATION_GRAVE,0,nil,e,tp)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
if ot>gt then ot=gt end
if ot>ft then ot=ft end
local ct=e:GetHandler():RemoveOverlayCard(tp,1,ot,REASON_COST)
e:SetLabel(ct)
end
function c86379550.spfilter(c,e,tp)
return (c:IsSetCard(0x256) or c:IsSetCard(0x161)) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c86379550.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetMatchingGroupCount(c86379550.spfilter,tp,LOCATION_GRAVE,0,nil,e,tp)>0 and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
local ct=e:GetLabel()
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,ct,tp,LOCATION_GRAVE)
end
function c86379550.spop(e,tp,eg,ep,ev,re,r,rp)
local ct=e:GetLabel()
local c=e:GetHandler()
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
if ft<ct then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c86379550.spfilter,tp,LOCATION_GRAVE,0,ct,ct,nil,e,tp)
if g:GetCount()>0 then
local tc=g:GetFirst()
while tc do
Duel.SpecialSummonStep(tc,0,tp,tp,false,false,POS_FACEUP)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1,true)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e2,true)
tc=g:GetNext()
end
Duel.SpecialSummonComplete()
Duel.Destroy(g,REASON_EFFECT)
end
end
--
function c86379550.desfilter(c,tp,re)
return c:GetPreviousControler()==tp and c:IsReason(REASON_EFFECT)
end
function c86379550.descon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c86379550.desfilter,1,nil,tp)
end
function c86379550.descost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end
e:GetHandler():RemoveOverlayCard(tp,1,1,REASON_COST)
end
function c86379550.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(1-tp) end
if chk==0 then return Duel.IsExistingTarget(aux.TRUE,tp,0,LOCATION_ONFIELD,1,nil) end
local g=Duel.SelectTarget(tp,aux.TRUE,tp,0,LOCATION_ONFIELD,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
end
function c86379550.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if not tc:IsRelateToEffect(e) then return end
Duel.Destroy(tc,REASON_EFFECT)
end
--因幡-地上的月兔✿铃仙
function c86379552.initial_effect(c)
--summon with no tribute
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(86379552,0))
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SUMMON_PROC)
e1:SetCondition(c86379552.ntcon)
e1:SetValue(1)
c:RegisterEffect(e1)
--immune effect
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_IMMUNE_EFFECT)
e2:SetRange(LOCATION_MZONE)
e2:SetTargetRange(LOCATION_MZONE,0)
e2:SetCondition(c86379552.immcon)
e2:SetValue(c86379552.efilter)
c:RegisterEffect(e2)
--set
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(86379552,1))
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
e3:SetCode(EVENT_SUMMON_SUCCESS)
e3:SetCountLimit(1,86379552)
e3:SetTarget(c86379552.destg)
e3:SetOperation(c86379552.desop)
c:RegisterEffect(e3)
local e4=e3:Clone()
e4:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e4)
end
--
function c86379552.cfilter(c)
return c:IsFaceup() and c:IsSetCard(0x256)
end
function c86379552.ntcon(e,c)
if c==nil then return true end
return c:GetLevel()>4 and Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c86379552.cfilter,c:GetControler(),LOCATION_MZONE,0,1,nil)
end
--
function c86379552.imfilter(c)
return c:IsFaceup() and c:IsSetCard(0x254)
end
function c86379552.immcon(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsExistingMatchingCard(c86379552.imfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
end
function c86379552.efilter(e,re)
return re:GetOwnerPlayer()~=e:GetHandlerPlayer() and re:GetHandler():IsSetCard(0x258)
end
--
function c86379552.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return true end
end
function c86379552.setfilter(c,e,tp)
return (c:IsSSetable() and Duel.GetLocationCount(1-tp,LOCATION_SZONE)>0) or (c:IsCanBeSpecialSummoned(e,0,1-tp,false,false,POS_FACEDOWN) and Duel.GetLocationCount(1-tp,LOCATION_MZONE)>0)
end
function c86379552.desop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetFieldGroup(tp,0,LOCATION_HAND)
if g:GetCount()>0 then
Duel.ConfirmCards(tp,g)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET)
local tc=g:FilterSelect(tp,c86379552.setfilter,1,1,nil,e,tp)
if tc:GetCount()>0 then
local sc=tc:GetFirst()
if sc:IsType(TYPE_MONSTER) then
Duel.SpecialSummon(sc,0,1-tp,1-tp,false,false,POS_FACEDOWN_DEFENSE)
else
Duel.SSet(tp,sc,1-tp)
end
Duel.BreakEffect()
Duel.Draw(tp,1,REASON_EFFECT)
Duel.Draw(1-tp,1,REASON_EFFECT)
end
Duel.ShuffleHand(1-tp)
end
end
--蓬莱-永远的公主✿蓬莱山辉夜
function c86379556.initial_effect(c)
--xyz summon
aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0x208),8,2,c86379556.ovfilter,aux.Stringid(86379556,0))
c:EnableReviveLimit()
--damage
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CHANGE_DAMAGE)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(1,0)
e1:SetValue(1)
c:RegisterEffect(e1)
--Recover
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(86379556,1))
e2:SetCategory(CATEGORY_RECOVER+CATEGORY_POSITION)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetCountLimit(1,86379556)
e2:SetTarget(c86379556.rtg)
e2:SetOperation(c86379556.rop)
c:RegisterEffect(e2)
--SpecialSummon
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(86379542,2))
e3:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_DESTROY)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_FREE_CHAIN)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,86379557)
e3:SetTarget(c86379556.sptg)
e3:SetOperation(c86379556.spop)
c:RegisterEffect(e3)
--
if not c86379556.global_check then
c86379556.global_check=true
local ge1=Effect.CreateEffect(c)
ge1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge1:SetCode(EVENT_DAMAGE)
ge1:SetOperation(c86379556.checkop)
Duel.RegisterEffect(ge1,0)
end
end
--
function c86379556.checkop(e,tp,eg,ep,ev,re,r,rp)
local ct=0
if Duel.GetFlagEffect(ep,86379556)>0 then
ct=Duel.GetFlagEffectLabel(ep,86379556)
Duel.ResetFlagEffect(ep,86379556)
end
local dt=ct+ev
Duel.RegisterFlagEffect(ep,86379556,RESET_PHASE+PHASE_END,0,1,dt)
end
--
function c86379556.ovfilter(c)
return c:IsFaceup() and c:IsSetCard(0x261) and c:IsLevelAbove(6)
end
--
function c86379556.rfilter(c)
return c:IsFaceup() and c:IsSetCard(0x254)
end
function c86379556.rtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingMatchingCard(c86379556.rfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) or Duel.GetFlagEffect(tp,86379556)>0 end
Duel.SetOperationInfo(0,CATEGORY_POSITION,nil,1,tp,LOCATION_ONFIELD)
local ct=Duel.GetFlagEffectLabel(tp,86379556)
Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,0,tp,ct)
Duel.SetChainLimit(aux.FALSE)
end
function c86379556.rop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local ct=Duel.GetFlagEffectLabel(tp,86379556)
Duel.Recover(tp,ct,REASON_EFFECT)
local g=Duel.GetMatchingGroup(c86379556.rfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil)
if g:GetCount()>0 then
local a=Group.CreateGroup()
local tc=g:GetFirst()
while tc do
if tc:IsCanTurnSet() then
a:AddCard(tc)
end
tc=g:GetNext()
end
if a:GetCount()>0 then
local b=a:Filter(Card.IsType,nil,TYPE_MONSTER)
a:Remove(Card.IsType,nil,TYPE_MONSTER)
if b:GetCount()>0 then
Duel.ChangePosition(b,POS_FACEDOWN_DEFENSE)
end
if a:GetCount()>0 then
Duel.ChangePosition(a,POS_FACEDOWN)
local c=a:Filter(Card.IsControler,nil,tp)
a:Remove(Card.IsControler,nil,tp)
if c:GetCount()>0 then
Duel.RaiseEvent(c,EVENT_SSET,e,REASON_EFFECT,tp,tp,0)
end
if a:GetCount()>0 then
Duel.RaiseEvent(a,EVENT_SSET,e,REASON_EFFECT,tp,1-tp,0)
end
end
end
end
end
--
function c86379556.spfilter(c,e,tp)
return c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c86379556.sfilter(c)
return c:IsSetCard(0x257) and c:IsSSetable()
end
function c86379556.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return
e:GetHandler():GetOverlayGroup():FilterCount(c86379556.spfilter,nil,e,tp)>0
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c86379556.sfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil)
and Duel.GetLocationCount(tp,LOCATION_SZONE)>0 end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_OVERLAY)
end
function c86379556.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
local ot=c:GetOverlayGroup():FilterCount(c86379556.spfilter,nil,e,tp)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
if ot>ft then ot=ft end
if ot<=0 then return end
local g=c:GetOverlayGroup():Filter(c86379556.spfilter,nil,e,tp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
g:Select(tp,1,ot,nil)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
local ct=Duel.Destroy(g,REASON_EFFECT)
if ct~=0 then
local st=Duel.GetLocationCount(tp,LOCATION_SZONE)
local mt=Duel.GetMatchingGroupCount(c86379556.sfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,nil)
if mt>st then mt=st end
if mt>ct then mt=ct end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET)
local sg=Duel.SelectMatchingCard(tp,c86379556.sfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,ct,nil)
if sg:GetCount()>0 then
Duel.SSet(tp,sg)
end
end
end
end
--蓬莱-永夜的隐者✿八意永琳
function c86379558.initial_effect(c)
--link summon
c:EnableReviveLimit()
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_FIELD)
e0:SetCode(EFFECT_SPSUMMON_PROC)
e0:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_IGNORE_IMMUNE)
e0:SetRange(LOCATION_EXTRA)
e0:SetCondition(c86379558.lkcon1)
e0:SetOperation(c86379558.lkop1)
e0:SetValue(SUMMON_TYPE_LINK)
c:RegisterEffect(e0)
--moon
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_TRAP_ACT_IN_SET_TURN)
e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE)
e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(LOCATION_SZONE,0)
e1:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0x257))
c:RegisterEffect(e1)
--destroy
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e2:SetRange(LOCATION_MZONE)
e2:SetTargetRange(LOCATION_ONFIELD,0)
e2:SetTarget(c86379558.indes)
e2:SetValue(1)
c:RegisterEffect(e2)
--lp
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(86379558,0))
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
e3:SetCode(EVENT_DESTROYED)
e3:SetTarget(c86379558.lptg)
e3:SetOperation(c86379558.lpop)
c:RegisterEffect(e3)
end
--
function c86379558.indes(e,c)
return c:IsFaceup() and c:IsSetCard(0x257) and c:IsType(TYPE_SPELL+TYPE_TRAP)
end
--
function c86379558.lptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsReason(REASON_EFFECT) end
end
function c86379558.lpop(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCountLimit(1)
e1:SetCode(EVENT_PHASE+PHASE_END)
e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetOperation(c86379558.damop)
Duel.RegisterEffect(e1,tp)
end
function c86379558.damop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,0,86379558)
Duel.SetLP(1-tp,Duel.GetLP(1-tp)-1800)
end
--
function c86379558.lkfilter1(c,lc,tp)
if c:IsType(TYPE_MONSTER) and c:IsFaceup() then
return c:IsCanBeLinkMaterial(lc) and c:IsControler(tp)
else
return c:IsFacedown()
end
end
function c86379558.lvfilter1(c)
if c:IsType(TYPE_LINK) and c:GetLink()>1 then
return 1+0x10000*c:GetLink()
else
return 1
end
end
function c86379558.lcheck1(tp,sg,lc,minc,ct)
return ct>=minc and sg:CheckWithSumEqual(c86379558.lvfilter1,lc:GetLink(),ct,ct) and Duel.GetLocationCountFromEx(tp,tp,sg,lc)>0
end
function c86379558.lkchenk1(c,tp,sg,mg,lc,ct,minc,maxc)
sg:AddCard(c)
ct=ct+1
local res=c86379558.lcheck1(tp,sg,lc,minc,ct) or (ct<maxc and mg:IsExists(c86379558.lkchenk1,1,sg,tp,sg,mg,lc,ct,minc,maxc))
sg:RemoveCard(c)
ct=ct-1
return res
end
function c86379558.lkcon1(e,c)
if c==nil then return true end
if c:IsType(TYPE_PENDULUM) and c:IsFaceup() then return false end
local tp=c:GetControler()
local mg=Duel.GetMatchingGroup(c86379558.lkfilter1,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,c,tp)
local sg=Group.CreateGroup()
for i,pe in ipairs({Duel.IsPlayerAffectedByEffect(tp,EFFECT_MUST_BE_LMATERIAL)}) do
local pc=pe:GetHandler()
if not mg:IsContains(pc) then return false end
sg:AddCard(pc)
end
local ct=sg:GetCount()
local minc=7
local maxc=8
if ct>maxc then return false end
return (c86379558.lcheck1(tp,sg,c,minc,ct) or mg:IsExists(c86379558.lkchenk1,1,nil,tp,sg,mg,c,ct,minc,maxc))
end
function c86379558.lkop1(e,tp,eg,ep,ev,re,r,rp,c)
local mg=Duel.GetMatchingGroup(c86379558.lkfilter1,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,c,tp)
local sg=Group.CreateGroup()
for i,pe in ipairs({Duel.IsPlayerAffectedByEffect(tp,EFFECT_MUST_BE_LMATERIAL)}) do
sg:AddCard(pe:GetHandler())
end
local ct=sg:GetCount()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_LMATERIAL)
sg:Select(tp,ct,ct,nil)
local minc=7
local maxc=8
for i=ct,maxc-1 do
local cg=mg:Filter(c86379558.lkchenk1,sg,tp,sg,mg,c,i,minc,maxc)
if cg:GetCount()==0 then break end
local minct=1
if c86379558.lcheck1(tp,sg,c,minc,i) then
if not Duel.SelectYesNo(tp,210) then break end
minct=0
end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_LMATERIAL)
local g=cg:Select(tp,minct,1,nil)
if g:GetCount()==0 then break end
sg:Merge(g)
end
c:SetMaterial(sg)
Duel.SendtoGrave(sg,REASON_MATERIAL+REASON_LINK)
end
--因幡的落穴
function c86379560.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(86379560,0))
e1:SetCategory(CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetTarget(c86379560.target)
e1:SetOperation(c86379560.activate)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EVENT_FLIP_SUMMON_SUCCESS)
c:RegisterEffect(e2)
local e3=e1:Clone()
e3:SetTarget(c86379560.target2)
e3:SetOperation(c86379560.activate2)
e3:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e3)
--SpecialSummon
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(86379560,1))
e4:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN+CATEGORY_TODECK)
e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e4:SetCode(EVENT_DESTROYED)
e4:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e4:SetRange(LOCATION_GRAVE)
e4:SetCountLimit(1,86379560)
e4:SetCondition(c86379560.gcon)
e4:SetTarget(c86379560.gtg)
e4:SetOperation(c86379560.gop)
c:RegisterEffect(e4)
end
--
function c86379560.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if not eg then return false end
local tc=eg:GetFirst()
if chkc then return chkc==tc end
if chk==0 then return ep~=tp and tc:IsFaceup() and tc:GetAttack()>=1200 and tc:IsOnField() and tc:IsCanBeEffectTarget(e) end
Duel.SetTargetCard(eg)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,tc,1,0,0)
end
function c86379560.activate(e,tp,eg,ep,ev,re,r,rp)
local tc=eg:GetFirst()
if tc:IsFaceup() and tc:IsRelateToEffect(e) and tc:GetAttack()>=1200 then
Duel.Destroy(tc,REASON_EFFECT)
end
end
--
function c86379560.filter(c,e,tp)
return c:IsAttackAbove(1200) and c:IsSummonPlayer(tp) and c:IsCanBeEffectTarget(e)
end
function c86379560.target2(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return false end
if chk==0 then return eg:IsExists(c86379560.filter,1,nil,e,1-tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=eg:FilterSelect(tp,c86379560.filter,1,1,nil,e,1-tp)
Duel.SetTargetCard(g)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
end
function c86379560.activate2(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS):GetFirst()
if tc:IsFaceup() and tc:IsRelateToEffect(e) and tc:GetAttack()>=1200 then
Duel.Destroy(tc,REASON_EFFECT)
end
end
--
function c86379560.cfilter(c,tp)
return c:GetPreviousControler()==tp and c:IsReason(REASON_EFFECT)
end
function c86379560.gcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c86379560.cfilter,1,nil,tp) and e:GetHandler():IsReason(REASON_DESTROY)
end
function c86379560.tdfilter(c)
return c:IsSetCard(0x256) and c:IsAbleToDeck() and c:IsType(TYPE_MONSTER)
end
function c86379560.gtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c86379560.tdfilter,tp,LOCATION_GRAVE,0,1,nil)
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,21035,nil,0x4011,600,600,2,RACE_BEASTWARRIOR,ATTRIBUTE_EARTH) end
local g=Duel.GetMatchingGroup(c86379560.tdfilter,tp,LOCATION_GRAVE,0,nil)
Duel.SetOperationInfo(0,CATEGORY_TODECK,g,1,tp,LOCATION_GRAVE)
Duel.SetOperationInfo(0,CATEGORY_TOKEN,nil,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,0)
end
function c86379560.gop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,c86379560.tdfilter,tp,LOCATION_GRAVE,0,1,1,nil)
if g:GetCount()>0 and Duel.SendtoDeck(g,nil,2,REASON_EFFECT)~=0 then
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,21035,nil,0x4011,600,600,2,RACE_BEASTWARRIOR,ATTRIBUTE_EARTH) then
local token=Duel.CreateToken(tp,21035)
Duel.SpecialSummon(token,0x20,tp,tp,false,false,POS_FACEUP)
end
end
end
......@@ -49,13 +49,13 @@ function c86379652.op(e,tp,eg,ep,ev,re,r,rp)
tc:RegisterFlagEffect(86379652,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,0,2,fid)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_PHASE+PHASE_STANDBY)
e1:SetCode(EVENT_PHASE+PHASE_END)
e1:SetCountLimit(1)
e1:SetLabel(fid,ct)
e1:SetLabelObject(tc)
e1:SetCondition(c86379652.con1_1)
e1:SetOperation(c86379652.op1_1)
e1:SetReset(RESET_PHASE+PHASE_STANDBY,2)
e1:SetReset(RESET_PHASE+PHASE_END,2)
Duel.RegisterEffect(e1,tp)
end
end
......
......@@ -198,7 +198,7 @@ function c86379860.sop(e,tp,eg,ep,ev,re,r,rp)
e5:SetValue(0)
c:RegisterEffect(e5,true)
c:SetStatus(STATUS_NO_LEVEL,true)
if Duel.SpecialSummon(c,0,tp,tp,true,true,POS_FACEUP_DEFENSE,zone)<=0 then
if not Duel.MoveToField(c,tp,tp,LOCATION_MZONE,POS_FACEUP,true,zone) then
Duel.SendtoGrave(c,REASON_EFFECT)
end
c:RegisterFlagEffect(86379860,RESET_EVENT+0x1fc0000,0,1)
......@@ -236,7 +236,7 @@ function c86379860.sop(e,tp,eg,ep,ev,re,r,rp)
e5:SetValue(0)
c:RegisterEffect(e5,true)
c:SetStatus(STATUS_NO_LEVEL,true)
if Duel.SpecialSummon(c,0,tp,1-tp,true,true,POS_FACEUP_DEFENSE,zone)<=0 then
if not Duel.MoveToField(c,tp,1-tp,LOCATION_MZONE,POS_FACEUP,true,zone) then
Duel.SendtoGrave(c,REASON_EFFECT)
end
c:RegisterFlagEffect(86379860,RESET_EVENT+0x1fc0000,0,1)
......
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