Commit ae0a427e authored by Momobako's avatar Momobako

Push by Appveyor

parent ce1bb7ff
No preview for this file type
No preview for this file type
--圆环的使徒 晓美焰
function c1000600.initial_effect(c)
--spsummon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000600,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e1:SetCountLimit(1,1000600)
e1:SetTarget(c1000600.sptg2)
e1:SetOperation(c1000600.spop2)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e2)
--atk/lv up
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000600,1))
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCategory(CATEGORY_ATKCHANGE)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1,10006000)
e2:SetCondition(c1000600.con2)
e2:SetOperation(c1000600.operation)
c:RegisterEffect(e2)
--direct atk
local e6=Effect.CreateEffect(c)
e6:SetType(EFFECT_TYPE_SINGLE)
e6:SetCode(EFFECT_DIRECT_ATTACK)
e6:SetCondition(c1000600.con3)
c:RegisterEffect(e6)
--tohand
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000600,2))
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_HAND)
e2:SetCountLimit(1,10006000)
e2:SetCondition(c1000600.con)
e2:SetCost(c1000600.thcost)
e2:SetTarget(c1000600.thtg)
e2:SetOperation(c1000600.thop)
c:RegisterEffect(e2)
end
function c1000600.filter(c,e,tp)
return ((c:IsType(TYPE_TUNER) and c:IsSetCard(0xc204)) or c:IsSetCard(0x5b23)) and not c:IsType(TYPE_PENDULUM) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c1000600.sptg2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c1000600.filter,tp,LOCATION_HAND,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND)
end
function c1000600.spop2(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,c1000600.filter,tp,LOCATION_HAND,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
end
function c1000600.filter9(c,e,tp)
return (c:IsSetCard(0xc204) or c:IsSetCard(0x5b23)) and c:IsControler(tp) and not c:IsType(TYPE_PENDULUM)
end
function c1000600.con(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000600.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=6
end
function c1000600.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsDiscardable() end
Duel.SendtoGrave(e:GetHandler(),REASON_COST+REASON_DISCARD)
end
function c1000600.thfilter(c)
return c:IsSetCard(0x5b23) and c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsAbleToHand()
end
function c1000600.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c1000600.thfilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function c1000600.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c1000600.thfilter,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
function c1000600.con2(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000600.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=3
end
function c1000600.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsFaceup() and c:IsRelateToEffect(e) then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetReset(RESET_EVENT+0x1ff0000)
e1:SetValue(800)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_UPDATE_LEVEL)
e2:SetReset(RESET_EVENT+0x1ff0000)
e2:SetValue(2)
c:RegisterEffect(e2)
end
end
function c1000600.con3(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000600.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=9
end
\ No newline at end of file
--苏生的福音 鹿目圆香
function c1000601.initial_effect(c)
--special summon1
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(c1000601.spcon)
c:RegisterEffect(e1)
--summon success
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000601,2))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCountLimit(1,1000601)
e1:SetCondition(c1000601.con)
e1:SetTarget(c1000601.sptg)
e1:SetOperation(c1000601.spop)
c:RegisterEffect(e1)
--special summon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000601,3))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,1000601)
e1:SetCondition(c1000601.con2)
e1:SetCost(c1000601.spcost)
e1:SetTarget(c1000601.sptg1)
e1:SetOperation(c1000601.spop1)
c:RegisterEffect(e1)
--atk/lv up
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000609,1))
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCategory(CATEGORY_ATKCHANGE)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1)
e2:SetCondition(c1000601.con3)
e2:SetOperation(c1000601.operation)
c:RegisterEffect(e2)
end
function c1000601.filter1(c)
return c:IsFaceup() and c:IsSetCard(0xc204) and c:IsType(TYPE_TUNER) and not c:IsType(TYPE_PENDULUM)
end
function c1000601.spcon(e,c)
if c==nil then return true end
return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0 and
Duel.IsExistingMatchingCard(c1000601.filter1,c:GetControler(),LOCATION_MZONE,0,1,nil)
end
function c1000601.filter9(c)
return c:IsSetCard(0xc204) and not c:IsType(TYPE_PENDULUM)
end
function c1000601.con(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000601.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=6
end
function c1000601.filter(c,e,tp)
return c:IsSetCard(0xc204) and c:IsType(TYPE_TUNER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and not c:IsType(TYPE_PENDULUM)
end
function c1000601.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c1000601.filter(chkc,e,tp) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingTarget(c1000601.filter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c1000601.filter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end
function c1000601.spop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
end
end
function c1000601.con3(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000601.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=3
end
function c1000601.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsFaceup() and c:IsRelateToEffect(e) then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetReset(RESET_EVENT+0x1ff0000)
e1:SetValue(700)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_UPDATE_LEVEL)
e2:SetReset(RESET_EVENT+0x1ff0000)
e2:SetValue(1)
c:RegisterEffect(e2)
end
end
function c1000601.con2(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000601.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=9
end
function c1000601.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToGraveAsCost() end
Duel.SendtoGrave(e:GetHandler(),REASON_COST)
end
function c1000601.filter2(c,e,tp)
return c:IsSetCard(0xc204) and c:IsType(TYPE_TUNER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and not c:IsType(TYPE_PENDULUM)
end
function c1000601.sptg1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c1000601.filter2,tp,LOCATION_DECK+LOCATION_GRAVE,0,2,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,2,tp,LOCATION_DECK+LOCATION_GRAVE)
end
function c1000601.spop1(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<2 then return end
local g=Duel.GetMatchingGroup(c1000601.filter2,tp,LOCATION_DECK+LOCATION_GRAVE,0,nil,e,tp)
if g:GetCount()>=2 then
local fid=e:GetHandler():GetFieldID()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local sg=g:Select(tp,2,2,nil)
Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP)
local tc=sg:GetFirst()
tc:RegisterFlagEffect(1000601,RESET_EVENT+0x1fe0000,0,1,fid)
tc=sg:GetNext()
tc:RegisterFlagEffect(1000601,RESET_EVENT+0x1fe0000,0,1,fid)
sg:KeepAlive()
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_PHASE+PHASE_END)
e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetCountLimit(1)
e1:SetLabel(fid)
e1:SetLabelObject(sg)
e1:SetCondition(c1000601.descon)
e1:SetOperation(c1000601.desop)
Duel.RegisterEffect(e1,tp)
end
end
function c1000601.desfilter(c,fid)
return c:GetFlagEffectLabel(1000601)==fid
end
function c1000601.descon(e,tp,eg,ep,ev,re,r,rp)
local g=e:GetLabelObject()
if not g:IsExists(c1000601.desfilter,1,nil,e:GetLabel()) then
g:DeleteGroup()
e:Reset()
return false
else return true end
end
function c1000601.desop(e,tp,eg,ep,ev,re,r,rp)
local g=e:GetLabelObject()
local tg=g:Filter(c1000601.desfilter,nil,e:GetLabel())
Duel.Destroy(tg,REASON_EFFECT)
end
--平凡的学生 鹿目圆香
function c1000602.initial_effect(c)
--special summon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000602,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetCountLimit(1,1000621)
e1:SetRange(LOCATION_MZONE)
e1:SetCost(c1000602.spcost)
e1:SetTarget(c1000602.sptg)
e1:SetOperation(c1000602.spop)
c:RegisterEffect(e1)
Duel.AddCustomActivityCounter(1000602,ACTIVITY_SPSUMMON,c1000602.counterfilter)
--
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_TOGRAVE)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_GRAVE)
e2:SetCountLimit(1,1000602)
e2:SetCondition(c1000602.con)
e2:SetCost(c1000602.cost)
e2:SetTarget(c1000602.tg)
e2:SetOperation(c1000602.op)
c:RegisterEffect(e2)
if not NitoriGlobal then
NitoriGlobal={}
NitoriGlobal["Effects"]={}
end
NitoriGlobal["Effects"]["c1000602"]=e2
Duel.AddCustomActivityCounter(1000602,ACTIVITY_SPSUMMON,c1000602.counterfilter)
end
function c1000602.counterfilter(c)
return c:IsSetCard(0xc204) and not c:IsType(TYPE_PENDULUM)
end
function c1000602.costfilter(c)
return c:IsSetCard(0xc204) and c:IsType(TYPE_MONSTER) and not c:IsType(TYPE_PENDULUM) and c:IsDiscardable()
end
function c1000602.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c1000602.costfilter,tp,LOCATION_HAND,0,1,e:GetHandler())
and Duel.GetCustomActivityCount(1000602,tp,ACTIVITY_SPSUMMON)==0 end
Duel.DiscardHand(tp,c1000602.costfilter,1,1,REASON_COST+REASON_DISCARD)
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:SetTarget(c1000602.splimit)
Duel.RegisterEffect(e1,tp)
end
function c1000602.splimit(e,c,sump,sumtype,sumpos,targetp,se)
return not c:IsSetCard(0xc204)
end
function c1000602.filter(c,e,tp)
return c:IsSetCard(0xc204) and not (c:IsType(TYPE_TUNER) and c:IsType(TYPE_PENDULUM)) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c1000602.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c1000602.filter,tp,LOCATION_DECK,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK)
end
function c1000602.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,c1000602.filter,tp,LOCATION_DECK,0,1,1,nil,e,tp)
local tc=g:GetFirst()
if tc then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_CANNOT_ATTACK)
e1:SetReset(RESET_EVENT+0x1fe0000)
tc:RegisterEffect(e1)
end
end
function c1000602.con(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetFlagEffect(1000602)==0 and e:GetHandler():GetTurnID()~=Duel.GetTurnCount()
end
function c1000602.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetCustomActivityCount(1000602,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:SetTarget(c1000602.splimit)
Duel.RegisterEffect(e1,tp)
end
function c1000602.tgfilter(c)
return c:IsSetCard(0xc204) and not (c:IsType(TYPE_TUNER) and c:IsType(TYPE_PENDULUM)) and c:IsType(TYPE_MONSTER) and c:IsAbleToGrave()
end
function c1000602.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c1000602.tgfilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK)
e:GetHandler():RegisterFlagEffect(1000602,RESET_EVENT+0x1680000,EFFECT_FLAG_COPY_INHERIT,1)
end
function c1000602.op(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,c1000602.tgfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoGrave(g,REASON_EFFECT)
end
end
--梦中的倩影 鹿目圆香
function c1000603.initial_effect(c)
--search
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000603,0))
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,1000603)
e1:SetCondition(c1000603.con)
e1:SetCost(c1000603.cost)
e1:SetTarget(c1000603.setg)
e1:SetOperation(c1000603.seop)
c:RegisterEffect(e1)
--spsummon
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000603,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1,10006030)
e2:SetCondition(c1000603.con2)
e2:SetCost(c1000603.cost)
e2:SetTarget(c1000603.sptg)
e2:SetOperation(c1000603.spop)
c:RegisterEffect(e2)
--atk up
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_SET_ATTACK)
e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e3:SetRange(LOCATION_MZONE)
e3:SetCondition(c1000603.con3)
e3:SetValue(3000)
c:RegisterEffect(e3)
--immune
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_SINGLE)
e5:SetCode(EFFECT_IMMUNE_EFFECT)
e5:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e5:SetRange(LOCATION_MZONE)
e5:SetCondition(c1000603.con3)
e5:SetValue(c1000603.efilter)
c:RegisterEffect(e5)
--spsummon
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000603,3))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_TO_GRAVE)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP)
e2:SetRange(LOCATION_GRAVE)
e2:SetCondition(c1000603.spcon1)
e2:SetTarget(c1000603.sptg1)
e2:SetOperation(c1000603.spop1)
c:RegisterEffect(e2)
end
function c1000603.filter9(c,e,tp)
return c:IsSetCard(0xc204) and c:IsControler(tp) and not c:IsType(TYPE_PENDULUM)
end
function c1000603.con(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000603.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=3
end
function c1000603.costfilter(c)
return c:IsDiscardable() and c:IsSetCard(0xc204) and not c:IsType(TYPE_PENDULUM)
end
function c1000603.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c1000603.costfilter,tp,LOCATION_HAND,0,1,nil) end
Duel.DiscardHand(tp,c1000603.costfilter,1,1,REASON_COST+REASON_DISCARD)
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
end
function c1000603.sefilter(c)
return c:IsSetCard(0xc204) and c:IsAbleToHand() and c:IsType(TYPE_MONSTER) and not c:IsType(TYPE_PENDULUM)
end
function c1000603.setg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c1000603.sefilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function c1000603.seop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c1000603.sefilter,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
function c1000603.con2(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000603.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=6
end
function c1000603.spfilter(c,e,tp)
return c:IsSetCard(0xc204) and c:IsType(TYPE_TUNER) and not c:IsType(TYPE_PENDULUM) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c1000603.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc==0 then return false end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingTarget(c1000603.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c1000603.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,LOCATION_GRAVE)
end
function c1000603.spop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
local g=Duel.GetFirstTarget()
if g and g:IsRelateToEffect(e) then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
end
function c1000603.con3(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000603.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=9
end
function c1000603.efilter(e,re)
return e:GetHandlerPlayer()~=re:GetOwnerPlayer() and re:IsActiveType(TYPE_MONSTER)
end
function c1000603.cfilter(c,tp)
return c:IsSetCard(0xc204) and not c:IsType(TYPE_PENDULUM) and c:IsReason(REASON_DESTROY)
and c:IsPreviousLocation(LOCATION_MZONE) and c:GetPreviousControler()==tp
end
function c1000603.spcon1(e,tp,eg,ep,ev,re,r,rp)
return not eg:IsContains(e:GetHandler()) and eg:IsExists(c1000603.cfilter,1,nil,tp)
end
function c1000603.sptg1(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 c1000603.spop1(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) then
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_LEAVE_FIELD_REDIRECT)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+0x47e0000)
e1:SetValue(LOCATION_REMOVED)
c:RegisterEffect(e1,true)
end
end
\ No newline at end of file
--废怯的女孩 鹿目圆香
function c1000604.initial_effect(c)
--spsummon
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_TRIGGER_O+EFFECT_TYPE_SINGLE)
e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCountLimit(1,1000604)
e1:SetCondition(c1000604.spcon)
e1:SetTarget(c1000604.sptg)
e1:SetOperation(c1000604.spop)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e2)
--atk up
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetCode(EFFECT_SET_ATTACK)
e4:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e4:SetRange(LOCATION_MZONE)
e4:SetCondition(c1000604.con3)
e4:SetValue(2800)
c:RegisterEffect(e4)
--negate
local e7=Effect.CreateEffect(c)
e7:SetDescription(aux.Stringid(1000604,1))
e7:SetCategory(CATEGORY_NEGATE+CATEGORY_DESTROY)
e7:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
e7:SetType(EFFECT_TYPE_QUICK_O)
e7:SetRange(LOCATION_MZONE)
e7:SetCountLimit(1,1000604)
e7:SetCode(EVENT_CHAINING)
e7:SetCondition(c1000604.discon)
e7:SetTarget(c1000604.distg)
e7:SetOperation(c1000604.disop)
c:RegisterEffect(e7)
--indes
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_INDESTRUCTABLE_BATTLE)
e2:SetCondition(c1000604.con1)
e2:SetValue(1)
c:RegisterEffect(e2)
end
function c1000604.filter1(c,e,tp)
return c:IsSetCard(0xc204) and not (c:IsType(TYPE_TUNER) and c:IsType(TYPE_PENDULUM)) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c1000604.cfilter(c)
return c:GetSummonLocation()==LOCATION_EXTRA
end
function c1000604.spcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c1000604.cfilter,tp,0,LOCATION_MZONE,1,nil)
end
function c1000604.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c1000604.filter1,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK+LOCATION_GRAVE)
end
function c1000604.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,c1000604.filter1,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
end
function c1000604.filter9(c,e,tp)
return c:IsSetCard(0xc204) and c:IsControler(tp) and not c:IsType(TYPE_PENDULUM)
end
function c1000604.con3(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000604.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=6
end
function c1000604.con1(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000604.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=3
end
function c1000604.discon(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000604.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return not e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED) and ct>=9 and ep~=tp and re:IsHasType(EFFECT_TYPE_ACTIVATE) and Duel.IsChainNegatable(ev)
end
function c1000604.distg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
if re:GetHandler():IsDestructable() and re:GetHandler():IsRelateToEffect(re) then
Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,1,0,0)
end
end
function c1000604.disop(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateActivation(ev)
if re:GetHandler():IsRelateToEffect(re) then
Duel.Destroy(eg,REASON_EFFECT)
end
end
\ No newline at end of file
--绘本的涂鸦 鹿目圆香
function c1000605.initial_effect(c)
--DEFENSE attack
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DEFENSE_ATTACK)
e1:SetValue(1)
c:RegisterEffect(e1)
--destroy
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000605,0))
e2:SetCategory(CATEGORY_DESTROY)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_MZONE)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetCountLimit(1,1000605)
e2:SetCondition(c1000605.con)
e2:SetCost(c1000605.cost)
e2:SetTarget(c1000605.destg)
e2:SetOperation(c1000605.desop)
c:RegisterEffect(e2)
--spsummon
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(1000605,1))
e3:SetCategory(CATEGORY_SPECIAL_SUMMON)
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,1000605)
e3:SetCondition(c1000605.con2)
e3:SetCost(c1000605.defcost)
e3:SetTarget(c1000605.sptg)
e3:SetOperation(c1000605.spop)
c:RegisterEffect(e3)
--def up
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetCode(EFFECT_SET_DEFENSE)
e4:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e4:SetRange(LOCATION_MZONE)
e4:SetCondition(c1000605.con3)
e4:SetValue(3500)
c:RegisterEffect(e4)
--immune
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_SINGLE)
e5:SetCode(EFFECT_IMMUNE_EFFECT)
e5:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e5:SetRange(LOCATION_MZONE)
e5:SetCondition(c1000605.con3)
e5:SetValue(c1000605.efilter)
c:RegisterEffect(e5)
end
function c1000605.filter9(c,e,tp)
return c:IsSetCard(0xc204) and c:IsControler(tp) and not c:IsType(TYPE_PENDULUM)
end
function c1000605.con(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000605.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=3
end
function c1000605.cfilter(c)
return c:IsSetCard(0xc204) and not c:IsType(TYPE_PENDULUM) and c:IsAbleToGraveAsCost()
end
function c1000605.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c1000605.cfilter,tp,LOCATION_DECK,0,1,nil) end
local g=Duel.SelectMatchingCard(tp,c1000605.cfilter,tp,LOCATION_DECK,0,1,1,nil)
Duel.SendtoGrave(g,REASON_COST)
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
end
function c1000605.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_ONFIELD) and chkc:IsDestructable() end
if chk==0 then return Duel.IsExistingTarget(Card.IsDestructable,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectTarget(tp,Card.IsDestructable,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
end
function c1000605.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.Destroy(tc,REASON_EFFECT)
end
end
function c1000605.con2(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000605.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=6
end
function c1000605.spfilter(c,e,tp)
return c:IsSetCard(0xc204) and c:IsType(TYPE_TUNER) and not c:IsType(TYPE_PENDULUM) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c1000605.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c1000605.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK)
end
function c1000605.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,c1000605.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_CANNOT_ATTACK)
e1:SetReset(RESET_EVENT+0x1fe0000)
g:GetFirst():RegisterEffect(e1)
local e2=Effect.CreateEffect(e:GetHandler())
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1)
e2:SetOperation(c1000605.des)
e2:SetReset(RESET_EVENT+0x1fe0000)
g:GetFirst():RegisterEffect(e2)
end
end
function c1000605.des(e,tp,eg,ep,ev,re,r,rp)
Duel.Destroy(e:GetHandler(),REASON_EFFECT)
end
function c1000605.con3(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000605.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=9
end
function c1000605.defcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
end
function c1000605.efilter(e,re)
return e:GetHandlerPlayer()~=re:GetOwnerPlayer() and re:IsActiveType(TYPE_SPELL+TYPE_TRAP)
end
\ No newline at end of file
--最终的决心 鹿目圆香
function c1000606.initial_effect(c)
--fusion
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_REMOVE)
e1:SetDescription(aux.Stringid(1000606,0))
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetCountLimit(1,1000624+EFFECT_COUNT_CODE_DUEL)
e1:SetRange(LOCATION_MZONE)
e1:SetCondition(c1000606.condition)
e1:SetCost(c1000606.cost)
e1:SetTarget(c1000606.sptg)
e1:SetOperation(c1000606.spop)
c:RegisterEffect(e1)
--special summon
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_REMOVE)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetCountLimit(1,1000606)
e2:SetRange(LOCATION_GRAVE)
e2:SetCondition(aux.exccon)
e2:SetCost(c1000606.syncost)
e2:SetTarget(c1000606.tg)
e2:SetOperation(c1000606.op)
c:RegisterEffect(e2)
--special summon1
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_HAND)
e1:SetCountLimit(1,10006060)
e1:SetCondition(c1000606.spcon)
c:RegisterEffect(e1)
end
function c1000606.condition(e,tp,eg,ep,ev,re,r,rp)
local ct1=Duel.GetFieldGroupCount(tp,LOCATION_ONFIELD,0)
local ct2=Duel.GetFieldGroupCount(tp,0,LOCATION_ONFIELD)
local ct3=Duel.GetFieldGroupCount(tp,LOCATION_HAND,0)
return not Duel.IsExistingMatchingCard(nil,tp,LOCATION_ONFIELD,0,1,e:GetHandler())
and ct3==0 and ct2>ct1
end
function c1000606.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLP(tp)>1 and e:GetHandler():IsAbleToRemoveAsCost() end
Duel.PayLPCost(tp,Duel.GetLP(tp)-1)
Duel.Remove(e:GetHandler(),POS_FACEUP,REASON_COST)
end
function c1000606.spfilter(c,e,tp)
return c:IsSetCard(0xc204) and c:IsType(TYPE_FUSION+TYPE_SYNCHRO) and not c:IsType(TYPE_PENDULUM) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
end
function c1000606.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c1000606.spfilter,tp,LOCATION_EXTRA,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
Duel.SetChainLimit(c1000606.chlimit)
end
function c1000606.chlimit(e,ep,tp)
return tp==ep
end
function c1000606.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,c1000606.spfilter,tp,LOCATION_EXTRA,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,true,false,POS_FACEUP)
end
end
function c1000606.filter(c,e,tp)
local lv=c:GetLevel()
return lv>0 and c:IsSetCard(0xc204) and not c:IsType(TYPE_TUNER) and c:IsAbleToRemoveAsCost()
and Duel.IsExistingMatchingCard(c1000606.exfilter,tp,LOCATION_EXTRA,0,1,nil,lv+3,e,tp)
end
function c1000606.exfilter(c,lv,e,tp)
return c:IsSetCard(0xc204) and c:GetLevel()==lv
and c:IsType(TYPE_SYNCHRO) and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_SYNCHRO,tp,false,false)
end
function c1000606.syncost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c1000606.filter,tp,LOCATION_GRAVE,0,1,e:GetHandler(),e,tp)
and e:GetHandler():IsAbleToRemoveAsCost() end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c1000606.filter,tp,LOCATION_GRAVE,0,1,1,e:GetHandler(),e,tp)
e:SetLabel(g:GetFirst():GetLevel())
g:AddCard(e:GetHandler())
Duel.Remove(g,POS_FACEUP,REASON_COST)
end
function c1000606.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function c1000606.op(e,tp,eg,ep,ev,re,r,rp)
local lv=e:GetLabel()
local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local sg=Duel.SelectMatchingCard(tp,c1000606.exfilter,tp,LOCATION_EXTRA,0,1,1,nil,lv+3,e,tp)
local sc=sg:GetFirst()
if sc then
Duel.SpecialSummon(sg,SUMMON_TYPE_SYNCHRO,tp,tp,false,false,POS_FACEUP)
end
end
end
function c1000606.filter1(c)
return c:IsFaceup() and c:IsSetCard(0xc204) and c:GetCode()~=1000606 and not c:IsType(TYPE_PENDULUM)
end
function c1000606.spcon(e,c)
if c==nil then return true end
return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0 and
Duel.IsExistingMatchingCard(c1000606.filter1,c:GetControler(),LOCATION_MZONE,0,1,nil)
end
\ No newline at end of file
--虚空的泡沫 鹿目圆香
function c1000607.initial_effect(c)
c:SetUniqueOnField(1,1,1000607)
c:SetUniqueOnField(1,1,1000614)
c:SetUniqueOnField(1,1,1000613)
--fusion summon
aux.AddFusionProcFun2(c,c1000607.ffilter,c1000607.ffilter2,true)
c:EnableReviveLimit()
--destroy
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000607,0))
e1:SetCategory(CATEGORY_DESTROY+CATEGORY_DAMAGE)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCountLimit(1)
e1:SetCondition(c1000607.con)
e1:SetCost(c1000607.cost)
e1:SetTarget(c1000607.destg)
e1:SetOperation(c1000607.desop)
c:RegisterEffect(e1)
--atk up
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000607,1))
e2:SetCategory(CATEGORY_ATKCHANGE)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1)
e2:SetCondition(c1000607.con2)
e2:SetCost(c1000607.cost)
e2:SetOperation(c1000607.atkop)
c:RegisterEffect(e2)
--buff
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(1000607,2))
e3:SetCategory(CATEGORY_ATKCHANGE)
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1)
e3:SetCondition(c1000607.con3)
e3:SetCost(c1000607.cost)
e3:SetTarget(c1000607.bftg)
e3:SetOperation(c1000607.bfop)
c:RegisterEffect(e3)
end
function c1000607.ffilter(c)
return c:IsType(TYPE_TUNER) and c:IsSetCard(0xc204) and not c:IsType(TYPE_PENDULUM)
end
function c1000607.ffilter2(c)
return not (c:IsType(TYPE_TUNER) and c:IsType(TYPE_PENDULUM)) and c:IsSetCard(0xc204)
end
function c1000607.filter9(c,e,tp)
return c:IsSetCard(0xc204) and c:IsControler(tp) and not c:IsType(TYPE_PENDULUM)
end
function c1000607.con(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000607.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=3
end
function c1000607.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
end
function c1000607.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_ONFIELD) and chkc:IsDestructable() end
if chk==0 then return Duel.IsExistingTarget(Card.IsDestructable,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectTarget(tp,Card.IsDestructable,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
if g:GetFirst():IsType(TYPE_MONSTER) then
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,1000)
end
end
function c1000607.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.Destroy(tc,REASON_EFFECT)>0 and tc:IsType(TYPE_MONSTER) then
Duel.Damage(1-tp,1000,REASON_EFFECT)
end
end
function c1000607.con2(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000607.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=6
end
function c1000607.atkop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetReset(RESET_EVENT+0x1fe0000)
e1:SetValue(1000)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EFFECT_CANNOT_BE_BATTLE_TARGET)
e2:SetValue(1)
e2:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_STANDBY+RESET_SELF_TURN)
c:RegisterEffect(e2)
local e3=e2:Clone()
e3:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET)
e3:SetValue(c1000607.effval)
c:RegisterEffect(e3)
end
end
function c1000607.effval(e,te,tp)
return tp~=e:GetHandlerPlayer()
end
function c1000607.con3(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000607.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=9
end
function c1000607.bftg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsFaceup,tp,LOCATION_MZONE,0,1,e:GetHandler()) end
local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_MZONE,0,e:GetHandler())
Duel.SetOperationInfo(0,CATEGORY_ATKCHANGE,g,g:GetCount(),tp,1000)
end
function c1000607.bfop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_MZONE,0,e:GetHandler())
local tc=g:GetFirst()
while tc do
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetReset(RESET_EVENT+0x1fe0000)
e1:SetValue(1000)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(e:GetHandler())
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_PIERCE)
e2:SetReset(RESET_EVENT+0x1ff0000+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e2)
tc=g:GetNext()
end
end
\ No newline at end of file
--圆香的守望者 晓美焰
function c1000608.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SPECIAL_SUMMON+CATEGORY_TOGRAVE)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,1000608+EFFECT_COUNT_CODE_OATH)
e1:SetOperation(c1000608.activate)
c:RegisterEffect(e1)
--
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetRange(LOCATION_SZONE)
e2:SetCountLimit(1)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetHintTiming(0,0x1e0)
e2:SetCost(c1000608.cost)
e2:SetOperation(c1000608.op)
c:RegisterEffect(e2)
end
function c1000608.tdfilter(c)
return c:IsSetCard(0xc204) and not c:IsType(TYPE_PENDULUM) and c:IsAbleToHand()
end
function c1000608.tgfilter(c)
return c:IsSetCard(0xc204) and not c:IsType(TYPE_PENDULUM) and c:IsAbleToGrave()
end
function c1000608.spfilter(c,e,tp)
return c:IsSetCard(0xc204) and not c:IsType(TYPE_PENDULUM) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c1000608.activate(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
local g1=Duel.GetMatchingGroup(c1000608.tdfilter,tp,LOCATION_GRAVE,0,nil)
local g2=Duel.GetMatchingGroup(c1000608.tgfilter,tp,LOCATION_DECK,0,nil)
local g3=Duel.GetMatchingGroup(c1000608.spfilter,tp,LOCATION_HAND,0,nil,e,tp)
if g1:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(1000608,0)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local sg1=g1:Select(tp,1,1,nil)
Duel.SendtoHand(sg1,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,sg1)
elseif g2:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(1000608,1)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local sg2=g2:Select(tp,1,1,nil)
Duel.SendtoGrave(sg2,REASON_EFFECT)
elseif g3:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(1000608,2)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local sg3=g3:Select(tp,1,1,nil)
Duel.SpecialSummon(sg3,0,tp,tp,false,false,POS_FACEUP)
end
end
function c1000608.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToGraveAsCost() end
Duel.SendtoGrave(e:GetHandler(),REASON_COST)
end
function c1000608.op(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CHANGE_DAMAGE)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(1,0)
e1:SetValue(c1000608.rdval)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
function c1000608.rdval(e,re,dam,r,rp,rc)
if bit.band(r,REASON_BATTLE)~=0 then
return dam/2
else return dam end
end
\ No newline at end of file
--轮回的溯回者 晓美焰
function c1000609.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000609,0))
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMING_END_PHASE)
e1:SetCountLimit(1,1000609)
e1:SetCost(c1000609.cost)
e1:SetTarget(c1000609.setg)
e1:SetOperation(c1000609.seop)
c:RegisterEffect(e1)
--spsummon
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000609,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_ACTIVATE)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetHintTiming(0,TIMING_END_PHASE)
e2:SetCountLimit(1,1000609)
e2:SetCost(c1000609.cost)
e2:SetTarget(c1000609.sptg)
e2:SetOperation(c1000609.spop)
c:RegisterEffect(e2)
end
function c1000609.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
end
function c1000609.sefilter(c)
return c:IsSetCard(0xc204) and c:IsType(TYPE_MONSTER) and c:IsAbleToHand() and not c:IsType(TYPE_PENDULUM)
end
function c1000609.setg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c1000609.sefilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function c1000609.seop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c1000609.sefilter,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
function c1000609.filter(c,e,tp)
return c:IsSetCard(0xc204) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and not c:IsType(TYPE_PENDULUM)
end
function c1000609.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c1000609.filter,tp,LOCATION_GRAVE,0,1,nil,e,tp)
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,0)
end
function c1000609.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c1000609.filter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
local tc=g:GetFirst()
if tc then
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+0x1fe0000)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetReset(RESET_EVENT+0x1fe0000)
tc:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_UPDATE_ATTACK)
e3:SetValue(1000)
e3:SetReset(RESET_EVENT+0x1fe0000)
tc:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e4:SetCode(EVENT_PHASE+PHASE_END)
e4:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e4:SetRange(LOCATION_MZONE)
e4:SetCountLimit(1)
e4:SetOperation(c1000609.desop)
e4:SetReset(RESET_EVENT+0x1fe0000)
tc:RegisterEffect(e4)
Duel.SpecialSummonComplete()
end
end
function c1000609.desop(e,tp,eg,ep,ev,re,r,rp)
Duel.Destroy(e:GetHandler(),REASON_EFFECT)
end
--魔法的少女 鹿目圆香
function c1000610.initial_effect(c)
--synchro summon
aux.AddSynchroProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xc204),aux.NonTuner(nil),1)
c:EnableReviveLimit()
--search
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCondition(c1000610.recon)
e1:SetOperation(c1000610.regop)
c:RegisterEffect(e1)
--remove
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_REMOVE)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_BATTLE_START)
e2:SetCondition(c1000610.con)
e2:SetCondition(c1000610.remcon)
e2:SetTarget(c1000610.remtg)
e2:SetOperation(c1000610.remop)
c:RegisterEffect(e2)
--disable
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e3:SetCode(EVENT_ATTACK_ANNOUNCE)
e3:SetCondition(c1000610.con2)
e3:SetOperation(c1000610.disop)
c:RegisterEffect(e3)
local e4=e3:Clone()
e4:SetCode(EVENT_BE_BATTLE_TARGET)
c:RegisterEffect(e4)
--immune
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_SINGLE)
e5:SetCode(EFFECT_IMMUNE_EFFECT)
e5:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e5:SetRange(LOCATION_MZONE)
e5:SetCondition(c1000610.con3)
e5:SetValue(c1000610.efilter)
c:RegisterEffect(e5)
end
function c1000610.recon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_SYNCHRO
end
function c1000610.regop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_REMOVE)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1)
e1:SetCode(EVENT_PHASE+PHASE_END)
e1:SetTarget(c1000610.tg)
e1:SetOperation(c1000610.op)
e1:SetReset(RESET_EVENT+0x1ee0000+RESET_PHASE+PHASE_END)
c:RegisterEffect(e1)
end
function c1000610.tgfilter(c)
return c:IsSetCard(0xc204) and c:IsType(TYPE_MONSTER) and c:IsAbleToHand() and not c:IsType(TYPE_PENDULUM)
end
function c1000610.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c1000610.tgfilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND+CATEGORY_SEARCH,nil,1,tp,LOCATION_DECK)
end
function c1000610.op(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c1000610.tgfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,POS_FACEUP,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
function c1000610.filter9(c,e,tp)
return c:IsSetCard(0xc204) and c:IsControler(tp) and not c:IsType(TYPE_PENDULUM)
end
function c1000610.con(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000610.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=3
end
function c1000610.remcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local bc=c:GetBattleTarget()
return bc and bit.band(bc:GetSummonType(),SUMMON_TYPE_SPECIAL)==SUMMON_TYPE_SPECIAL
end
function c1000610.remtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_REMOVE,e:GetHandler():GetBattleTarget(),1,0,0)
end
function c1000610.remop(e,tp,eg,ep,ev,re,r,rp)
local bc=e:GetHandler():GetBattleTarget()
if bc:IsRelateToBattle() then
Duel.Remove(bc,POS_FACEUP,REASON_EFFECT)
end
end
function c1000610.con2(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000610.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=6
end
function c1000610.disop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsFaceup() then return end
local bc=c:GetBattleTarget()
if bc then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_BATTLE)
bc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_BATTLE)
bc:RegisterEffect(e2)
end
end
function c1000610.con3(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000610.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=9
end
function c1000610.efilter(e,re)
return e:GetHandlerPlayer()~=re:GetOwnerPlayer() and re:IsActiveType(TYPE_SPELL+TYPE_TRAP)
end
\ No newline at end of file
--救济的少女 鹿目圆香
function c1000611.initial_effect(c)
--synchro summon
aux.AddSynchroProcedure(c,nil,aux.NonTuner(Card.IsSetCard,0xc204),1)
c:EnableReviveLimit()
--draw
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000611,1))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_DRAW)
e1:SetType(EFFECT_TYPE_TRIGGER_O+EFFECT_TYPE_SINGLE)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCondition(c1000611.con)
e1:SetTarget(c1000611.drtg)
e1:SetOperation(c1000611.drop)
c:RegisterEffect(e1)
--to hand
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000611,3))
e2:SetCategory(CATEGORY_TOHAND)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetHintTiming(0,0x1e0)
e2:SetCondition(c1000611.con2)
e2:SetTarget(c1000611.thtg)
e2:SetOperation(c1000611.thop)
c:RegisterEffect(e2)
--atk
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(1000611,2))
e3:SetCategory(CATEGORY_ATKCHANGE+CATEGORY_DISABLE)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_SPSUMMON_SUCCESS)
e3:SetCondition(c1000611.con3)
e3:SetOperation(c1000611.atkop)
c:RegisterEffect(e3)
end
function c1000611.filter9(c,e,tp)
return c:IsSetCard(0xc204) and not c:IsType(TYPE_PENDULUM)
end
function c1000611.con(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000611.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_SYNCHRO and ct>=3
end
function c1000611.drtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
end
function c1000611.drop(e,tp,eg,ep,ev,re,r,rp)
if Duel.Draw(tp,1,REASON_EFFECT)>0 then
local tc=Duel.GetOperatedGroup():GetFirst()
Duel.ConfirmCards(1-tp,tc)
if tc:IsSetCard(0xc204) and tc:IsCanBeSpecialSummoned(e,0,tp,false,false) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.SelectYesNo(tp,aux.Stringid(1000611,0)) then
Duel.BreakEffect()
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
else
Duel.ShuffleHand(tp)
end
end
end
function c1000611.con2(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000611.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_SYNCHRO and ct>=6
end
function c1000611.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsOnField() and chkc:IsAbleToHand() end
if chk==0 then return Duel.IsExistingTarget(Card.IsAbleToHand,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local g=Duel.SelectTarget(tp,Card.IsAbleToHand,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end
function c1000611.thop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.SendtoHand(tc,nil,REASON_EFFECT)
end
end
function c1000611.con3(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000611.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_SYNCHRO and ct>=9
end
function c1000611.atktg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(nil,tp,0,LOCATION_MZONE,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_DISABLE,nil,1,0,0)
end
function c1000611.atkop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,0,LOCATION_MZONE,nil)
local tc=g:GetFirst()
while tc do
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SET_ATTACK_FINAL)
e1:SetValue(0)
e1:SetReset(RESET_EVENT+0x1fe0000)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(e:GetHandler())
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE)
e2:SetReset(RESET_EVENT+0x1fe0000)
tc:RegisterEffect(e2)
local e3=Effect.CreateEffect(e:GetHandler())
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_DISABLE_EFFECT)
e3:SetReset(RESET_EVENT+0x1fe0000)
tc:RegisterEffect(e3)
local e4=Effect.CreateEffect(e:GetHandler())
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetProperty(EFFECT_FLAG_SET_AVAILABLE+EFFECT_FLAG_IGNORE_RANGE)
e4:SetCode(EFFECT_TO_GRAVE_REDIRECT)
e4:SetValue(LOCATION_REMOVED)
e4:SetReset(RESET_EVENT+0x1fe0000)
tc:RegisterEffect(e2)
tc=g:GetNext()
end
end
\ No newline at end of file
--少女的祈愿 鹿目圆香
function c1000612.initial_effect(c)
--synchro summon
aux.AddSynchroProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xc204),aux.NonTuner(Card.IsSetCard,0xc204),1)
c:EnableReviveLimit()
--todeck
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000612,0))
e1:SetCategory(CATEGORY_TODECK)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetCountLimit(1)
e1:SetRange(LOCATION_MZONE)
e1:SetCondition(c1000612.con1)
e1:SetTarget(c1000612.tg)
e1:SetOperation(c1000612.op)
c:RegisterEffect(e1)
--buff
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_UPDATE_ATTACK)
e2:SetRange(LOCATION_MZONE)
e2:SetCondition(c1000612.con2)
e2:SetTargetRange(LOCATION_MZONE,0)
e2:SetValue(c1000612.val)
c:RegisterEffect(e2)
local e3=e2:Clone()
e3:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e3)
--lock
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD)
e4:SetRange(LOCATION_MZONE)
e4:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e4:SetTargetRange(0,LOCATION_EXTRA)
e4:SetCondition(c1000612.con3)
e4:SetTarget(c1000612.filter)
c:RegisterEffect(e4)
--special summon
local e5=Effect.CreateEffect(c)
e5:SetCategory(CATEGORY_SPECIAL_SUMMON)
e5:SetType(EFFECT_TYPE_IGNITION)
e5:SetRange(LOCATION_GRAVE)
e5:SetCountLimit(1,1000612+EFFECT_COUNT_CODE_DUEL)
e5:SetCost(c1000612.spcost)
e5:SetTarget(c1000612.sptg)
e5:SetOperation(c1000612.spop)
c:RegisterEffect(e5)
end
function c1000612.filter9(c,e,tp)
return c:IsSetCard(0xc204) and c:IsControler(tp) and not c:IsType(TYPE_PENDULUM)
end
function c1000612.con1(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000612.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=6
end
function c1000612.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToDeck,tp,0,LOCATION_ONFIELD+LOCATION_GRAVE,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_TODECK,nil,1,0,0)
end
function c1000612.op(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,Card.IsAbleToDeck,tp,0,LOCATION_ONFIELD+LOCATION_GRAVE,1,2,nil)
Duel.SendtoDeck(g,nil,2,REASON_EFFECT)
end
function c1000612.con2(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000612.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=3
end
function c1000612.val(e,c)
local g=Duel.GetMatchingGroup(c1000612.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct*100
end
function c1000612.con3(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000612.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=9
end
function c1000612.filter(e,c)
return c:IsLevelAbove(4) or c:IsRankAbove(4)
end
function c1000612.refilter(c)
return c:IsSetCard(0xc204) and c:IsAbleToRemoveAsCost() and not c:IsType(TYPE_PENDULUM)
end
function c1000612.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
local g=Duel.GetMatchingGroup(c1000612.refilter,tp,LOCATION_GRAVE,0,nil)
local ct=g:GetClassCount(Card.GetCode)
if chk==0 then return e:GetHandler():IsAbleToRemoveAsCost() and ct>=4 end
local tg=Duel.SelectMatchingCard(tp,c1000612.refilter,tp,LOCATION_GRAVE,0,3,3,e:GetHandler())
tg:AddCard(e:GetHandler())
Duel.Remove(tg,POS_FACEUP,REASON_COST)
end
function c1000612.spfilter(c,e,tp)
return c:IsCode(1000623) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
end
function c1000612.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c1000612.spfilter,tp,LOCATION_EXTRA,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function c1000612.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,c1000612.spfilter,tp,LOCATION_EXTRA,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,true,false,POS_FACEUP)
end
end
--圆环之理 鹿目圆香
function c1000613.initial_effect(c)
c:SetUniqueOnField(1,1,1000607)
c:SetUniqueOnField(1,1,1000614)
c:SetUniqueOnField(1,1,1000613)
--fusion material
c:EnableReviveLimit()
aux.AddFusionProcCodeFun(c,1000611,aux.FilterBoolFunction(Card.IsSetCard,0xc204),4,true,true)
--immune
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_MZONE)
e1:SetCode(EFFECT_IMMUNE_EFFECT)
e1:SetCondition(c1000613.con)
e1:SetValue(c1000613.efilter)
c:RegisterEffect(e1)
--atk/def down
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_UPDATE_ATTACK)
e2:SetRange(LOCATION_MZONE)
e2:SetTargetRange(0,LOCATION_MZONE)
e2:SetValue(c1000613.val)
c:RegisterEffect(e2)
local e3=e2:Clone()
e3:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e3)
--atk/def up
local e4=e2:Clone()
e4:SetTargetRange(LOCATION_MZONE,0)
e4:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0xc204))
e4:SetValue(c1000613.val2)
c:RegisterEffect(e4)
local e5=e2:Clone()
e5:SetTargetRange(LOCATION_MZONE,0)
e5:SetCode(EFFECT_UPDATE_DEFENSE)
e5:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0xc204))
e5:SetValue(c1000613.val2)
c:RegisterEffect(e5)
--level/rank down
local e6=e2:Clone()
e6:SetCode(EFFECT_UPDATE_LEVEL)
e6:SetValue(c1000613.val3)
c:RegisterEffect(e6)
local e7=e2:Clone()
e7:SetCode(EFFECT_UPDATE_RANK)
e7:SetValue(c1000613.val3)
c:RegisterEffect(e7)
--spsummon condition
local e9=Effect.CreateEffect(c)
e9:SetType(EFFECT_TYPE_SINGLE)
e9:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e9:SetCode(EFFECT_SPSUMMON_CONDITION)
e9:SetValue(c1000613.splimit)
c:RegisterEffect(e9)
--destroy
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000613,0))
e1:SetCategory(CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetRange(LOCATION_MZONE)
e1:SetCondition(c1000613.condition)
e1:SetTarget(c1000613.target)
e1:SetOperation(c1000613.operation)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e2)
end
function c1000613.splimit(e,se,sp,st)
if e:GetHandler():IsLocation(LOCATION_EXTRA) then
return bit.band(st,SUMMON_TYPE_FUSION)==SUMMON_TYPE_FUSION
end
return true
end
function c1000613.con(e)
return Duel.GetTurnPlayer()==e:GetHandlerPlayer()
end
function c1000613.efilter(e,te)
return te:GetOwner()~=e:GetOwner()
end
function c1000613.filter9(c,e,tp)
return c:IsSetCard(0xc204) and c:IsControler(tp) and not c:IsType(TYPE_PENDULUM)
end
function c1000613.val(e,c)
local g=Duel.GetMatchingGroup(c1000613.filter9,LOCATION_REMOVED,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct*-300
end
function c1000613.val2(e,c)
local g=Duel.GetMatchingGroup(c1000613.filter9,LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct*300
end
function c1000613.val3(e,c)
local g=Duel.GetMatchingGroup(c1000613.filter9,LOCATION_REMOVED,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return -ct
end
function c1000613.cfilter(c)
return c:IsFaceup() and (c:GetAttack()==0 or c:GetDefense()==0)
end
function c1000613.condition(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c1000613.cfilter,1,nil) and not eg:IsContains(e:GetHandler())
end
function c1000613.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
local g=eg:Filter(c1000613.cfilter,nil)
Duel.SetTargetCard(eg)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0)
end
function c1000613.filter(c,e)
return c:IsFaceup() and (c:GetAttack()==0 or c:GetDefense()==0) and c:IsRelateToEffect(e)
end
function c1000613.operation(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
local g=eg:Filter(c1000613.filter,nil,e)
if g:GetCount()>0 then
Duel.Destroy(g,REASON_EFFECT)
end
end
\ No newline at end of file
--救赎的圣母 鹿目圆香
function c1000614.initial_effect(c)
c:SetUniqueOnField(1,1,1000607)
c:SetUniqueOnField(1,1,1000614)
c:SetUniqueOnField(1,1,1000613)
--fusion material
c:EnableReviveLimit()
aux.AddFusionProcFun2(c,c1000614.ffilter,aux.FilterBoolFunction(Card.IsSetCard,0xc204),true)
--immune
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_MZONE)
e1:SetCode(EFFECT_IMMUNE_EFFECT)
e1:SetCondition(c1000614.con)
e1:SetValue(c1000614.efilter)
c:RegisterEffect(e1)
--disable
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_BATTLED)
e2:SetOperation(c1000614.disop1)
c:RegisterEffect(e2)
--destroy
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(1000614,0))
e4:SetProperty(EFFECT_FLAG_CARD_TARGET)
e4:SetCategory(CATEGORY_DESTROY+CATEGORY_DAMAGE+CATEGORY_RECOVER)
e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetCountLimit(1)
e4:SetRange(LOCATION_MZONE)
e4:SetTarget(c1000614.destg)
e4:SetOperation(c1000614.desop)
c:RegisterEffect(e4)
--spsummon condition
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_SINGLE)
e5:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e5:SetCode(EFFECT_SPSUMMON_CONDITION)
e5:SetValue(c1000614.splimit)
c:RegisterEffect(e5)
--indes
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EFFECT_DESTROY_REPLACE)
e2:SetRange(LOCATION_MZONE)
e2:SetTarget(c1000614.reptg)
e2:SetValue(c1000614.repval)
c:RegisterEffect(e2)
local g=Group.CreateGroup()
g:KeepAlive()
e2:SetLabelObject(g)
end
function c1000614.splimit(e,se,sp,st)
if e:GetHandler():IsLocation(LOCATION_EXTRA) then
return bit.band(st,SUMMON_TYPE_FUSION)==SUMMON_TYPE_FUSION
end
return true
end
function c1000614.ffilter(c)
return c:IsType(TYPE_SYNCHRO) and c:IsSetCard(0xc204) and not c:IsType(TYPE_PENDULUM)
end
function c1000614.con(e)
return Duel.GetTurnPlayer()==e:GetHandlerPlayer()
end
function c1000614.efilter(e,te)
return te:GetOwner()~=e:GetOwner()
end
function c1000614.disop1(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local d=Duel.GetAttackTarget()
if d==c then d=Duel.GetAttacker() end
if not d or not not d:IsLocation(LOCATION_GRAVE) or not d:IsStatus(STATUS_BATTLE_DESTROYED) then return end
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+0x17a0000)
d:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetReset(RESET_EVENT+0x17a0000)
d:RegisterEffect(e2)
end
function c1000614.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc==0 then return chkc:IsDestructable() and chkc:IsControler(1-tp) and chkc:IsOnField() end
if chk==0 then return Duel.IsExistingTarget(Card.IsDestructable,tp,0,LOCATION_ONFIELD,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectTarget(tp,Card.IsDestructable,tp,0,LOCATION_ONFIELD,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,0,tp,1000)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,1000)
end
function c1000614.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.Destroy(tc,REASON_EFFECT)>0 then
Duel.Recover(tp,1000,REASON_EFFECT)
Duel.Damage(1-tp,1000,REASON_EFFECT)
if tc:IsLocation(LOCATION_GRAVE) then
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+0x17a0000)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(e:GetHandler())
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetReset(RESET_EVENT+0x17a0000)
tc:RegisterEffect(e2)
end
end
end
function c1000614.repfilter(c,tp)
return c:IsControler(tp) and c:IsOnField() and c:IsReason(REASON_BATTLE+REASON_EFFECT) and c:GetFlagEffect(1000614)==0
end
function c1000614.reptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return eg:IsExists(c1000614.repfilter,1,nil,tp) end
local g=eg:Filter(c1000614.repfilter,nil,tp)
local tc=g:GetFirst()
while tc do
tc:RegisterFlagEffect(1000614,RESET_EVENT+0x1fc0000+RESET_PHASE+PHASE_END,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(1000614,2))
tc=g:GetNext()
end
e:GetLabelObject():Clear()
e:GetLabelObject():Merge(g)
return true
end
function c1000614.repval(e,c)
local g=e:GetLabelObject()
return g:IsContains(c)
end
\ No newline at end of file
--奇迹的少女 鹿目圆香
function c1000615.initial_effect(c)
--synchro summon
aux.AddSynchroProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xc204),aux.NonTuner(nil),1)
c:EnableReviveLimit()
--damage
local e7=Effect.CreateEffect(c)
e7:SetDescription(aux.Stringid(1000615,0))
e7:SetCategory(CATEGORY_DAMAGE)
e7:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
e7:SetCode(EVENT_BATTLE_DESTROYING)
e7:SetCondition(c1000615.con2)
e7:SetTarget(c1000615.damtg)
e7:SetOperation(c1000615.damop)
c:RegisterEffect(e7)
--indes
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_INDESTRUCTABLE_BATTLE)
e2:SetValue(1)
c:RegisterEffect(e2)
--atkup
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e3:SetRange(LOCATION_MZONE)
e3:SetCode(EFFECT_UPDATE_ATTACK)
e2:SetCondition(c1000615.con)
e3:SetValue(c1000615.atkup)
c:RegisterEffect(e3)
local e2=e3:Clone()
e2:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e2)
--pierce
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_PIERCE)
e1:SetCondition(c1000615.con3)
c:RegisterEffect(e1)
end
function c1000615.filter9(c,e,tp)
return c:IsSetCard(0xc204) and c:IsControler(tp) and not c:IsType(TYPE_PENDULUM)
end
function c1000615.con2(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000615.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=6
end
function c1000615.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
local tc=e:GetHandler():GetBattleTarget()
local atk=tc:GetBaseAttack()
if atk<0 then atk=0 end
Duel.SetTargetPlayer(1-tp)
Duel.SetTargetParam(atk)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,atk)
end
function c1000615.damop(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Damage(p,d,REASON_EFFECT)
end
function c1000615.con(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000615.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=3
end
function c1000615.atkup(e,c)
return Duel.GetMatchingGroupCount(c1000615.filter9,LOCATION_GRAVE,0,nil,e,tp)*300
end
function c1000615.con3(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000615.filter9,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=9
end
\ No newline at end of file
--圆环圣母 鹿目圆香
function c1000617.initial_effect(c)
c:SetUniqueOnField(1,0,1000617)
--synchro summon
c:EnableReviveLimit()
local e1=Effect.CreateEffect(c)
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(c1000617.syncon)
e1:SetOperation(c1000617.synop)
e1:SetValue(SUMMON_TYPE_SYNCHRO)
c:RegisterEffect(e1)
--act limit
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000617,1))
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetCondition(c1000617.limcon)
e2:SetTarget(c1000617.limtg)
e2:SetOperation(c1000617.limop)
c:RegisterEffect(e2)
--spsummon
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_CANNOT_DISABLE_SPSUMMON)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e2)
--immune
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e3:SetRange(LOCATION_MZONE)
e3:SetCode(EFFECT_IMMUNE_EFFECT)
e3:SetValue(c1000617.efilter)
c:RegisterEffect(e3)
--cannot release
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_MZONE)
e1:SetCode(EFFECT_UNRELEASABLE_SUM)
e1:SetCondition(c1000617.con)
e1:SetValue(1)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_UNRELEASABLE_NONSUM)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e3:SetCode(EFFECT_CANNOT_BE_FUSION_MATERIAL)
e3:SetValue(1)
c:RegisterEffect(e3)
local e4=e3:Clone()
e4:SetCode(EFFECT_CANNOT_BE_SYNCHRO_MATERIAL)
c:RegisterEffect(e4)
local e5=e3:Clone()
e5:SetCode(EFFECT_CANNOT_BE_XYZ_MATERIAL)
c:RegisterEffect(e5)
--control
local e99=Effect.CreateEffect(c)
e99:SetType(EFFECT_TYPE_SINGLE)
e99:SetProperty(EFFECT_FLAG_SINGLE_RANGE+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e99:SetRange(LOCATION_MZONE)
e99:SetCode(EFFECT_CANNOT_CHANGE_CONTROL)
c:RegisterEffect(e99)
--act limit
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_ACTIVATE)
e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(0,1)
e1:SetValue(c1000617.aclimit)
e1:SetCondition(c1000617.con1)
c:RegisterEffect(e1)
--
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetCode(EFFECT_CANNOT_TO_HAND)
e3:SetRange(LOCATION_MZONE)
e3:SetTargetRange(0,LOCATION_DECK+LOCATION_GRAVE)
e3:SetCondition(c1000617.con2)
c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD)
e4:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e4:SetRange(LOCATION_MZONE)
e4:SetCode(EFFECT_CANNOT_DRAW)
e4:SetCondition(c1000617.con2)
e4:SetTargetRange(0,1)
c:RegisterEffect(e4)
--immune
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e3:SetRange(LOCATION_MZONE)
e3:SetCode(EFFECT_IMMUNE_EFFECT)
e3:SetCondition(c1000617.con3)
e3:SetValue(c1000617.efilter2)
c:RegisterEffect(e3)
end
function c1000617.matfilter1(c,syncard)
return c:IsSetCard(0xc204) and c:IsType(TYPE_TUNER) and (c:IsLocation(LOCATION_HAND) or c:IsFaceup()) and c:IsCanBeSynchroMaterial(syncard) and not c:IsType(TYPE_PENDULUM)
end
function c1000617.matfilter2(c,syncard)
return c:IsFaceup() and c:IsSetCard(0xc204) and c:IsType(TYPE_SYNCHRO) and c:IsCanBeSynchroMaterial(syncard) and not c:IsType(TYPE_PENDULUM)
end
function c1000617.synfilter1(c,syncard,lv,g1,g2,g3)
local tlv=c:GetSynchroLevel(syncard)
if lv-tlv<=0 then return false end
local f1=c.tuner_filter
if c:IsHasEffect(EFFECT_HAND_SYNCHRO) then
return g3:IsExists(c1000617.synfilter2,1,c,syncard,lv-tlv,g2,f1,c)
else
return g1:IsExists(c1000617.synfilter2,1,c,syncard,lv-tlv,g2,f1,c)
end
end
function c1000617.synfilter2(c,syncard,lv,g2,f1,tuner1)
local tlv=c:GetSynchroLevel(syncard)
if lv-tlv<=0 then return false end
local f2=c.tuner_filter
if f1 and not f1(c) then return false end
if f2 and not f2(tuner1) then return false end
return g2:IsExists(c1000617.synfilter3,1,nil,syncard,lv-tlv,f1,f2)
end
function c1000617.synfilter3(c,syncard,lv,f1,f2)
local mlv=c:GetSynchroLevel(syncard)
local lv1=bit.band(mlv,0xffff)
local lv2=bit.rshift(mlv,16)
return (lv1==lv or lv2==lv) and (not f1 or f1(c)) and (not f2 or f2(c))
end
function c1000617.syncon(e,c,tuner,mg)
if c==nil then return true end
local tp=c:GetControler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<-2 then return false end
local g1=nil
local g2=nil
local g3=nil
if mg then
g1=mg:Filter(c1000617.matfilter1,nil,c)
g2=mg:Filter(c1000617.matfilter2,nil,c)
g3=mg:Filter(c1000617.matfilter1,nil,c)
else
g1=Duel.GetMatchingGroup(c1000617.matfilter1,tp,LOCATION_MZONE,LOCATION_MZONE,nil,c)
g2=Duel.GetMatchingGroup(c1000617.matfilter2,tp,LOCATION_MZONE,LOCATION_MZONE,nil,c)
g3=Duel.GetMatchingGroup(c1000617.matfilter1,tp,LOCATION_MZONE+LOCATION_HAND,LOCATION_MZONE,nil,c)
end
local pe=Duel.IsPlayerAffectedByEffect(tp,EFFECT_MUST_BE_SMATERIAL)
local lv=c:GetLevel()
if tuner then
local tlv=tuner:GetSynchroLevel(c)
if lv-tlv<=0 then return false end
local f1=tuner.tuner_filter
if not pe then
return g1:IsExists(c1000617.synfilter2,1,tuner,c,lv-tlv,g2,f1,tuner)
else
return c1000617.synfilter2(pe:GetOwner(),c,lv-tlv,g2,f1,tuner)
end
end
if not pe then
return g1:IsExists(c1000617.synfilter1,1,nil,c,lv,g1,g2,g3)
else
return c1000617.synfilter1(pe:GetOwner(),c,lv,g1,g2)
end
end
function c1000617.synop(e,tp,eg,ep,ev,re,r,rp,c,tuner,mg)
local g=Group.CreateGroup()
local g1=nil
local g2=nil
local g3=nil
if mg then
g1=mg:Filter(c1000617.matfilter1,nil,c)
g2=mg:Filter(c1000617.matfilter2,nil,c)
g3=mg:Filter(c1000617.matfilter1,nil,c)
else
g1=Duel.GetMatchingGroup(c1000617.matfilter1,tp,LOCATION_MZONE,LOCATION_MZONE,nil,c)
g2=Duel.GetMatchingGroup(c1000617.matfilter2,tp,LOCATION_MZONE,LOCATION_MZONE,nil,c)
g3=Duel.GetMatchingGroup(c1000617.matfilter1,tp,LOCATION_MZONE+LOCATION_HAND,LOCATION_MZONE,nil,c)
end
local pe=Duel.IsPlayerAffectedByEffect(tp,EFFECT_MUST_BE_SMATERIAL)
local lv=c:GetLevel()
if tuner then
g:AddCard(tuner)
local lv1=tuner:GetSynchroLevel(c)
local f1=tuner.tuner_filter
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SMATERIAL)
local tuner2=nil
if not pe then
local t2=g1:FilterSelect(tp,c1000617.synfilter2,1,1,tuner,c,lv-lv1,g2,f1,tuner)
tuner2=t2:GetFirst()
else
tuner2=pe:GetOwner()
Group.FromCards(tuner2):Select(tp,1,1,nil)
end
g:AddCard(tuner2)
local lv2=tuner2:GetSynchroLevel(c)
local f2=tuner2.tuner_filter
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SMATERIAL)
local m3=g2:FilterSelect(tp,c1000617.synfilter3,1,1,nil,c,lv-lv1-lv2,f1,f2)
g:Merge(m3)
else
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SMATERIAL)
local tuner1=nil
if not pe then
local t1=g1:FilterSelect(tp,c1000617.synfilter1,1,1,nil,c,lv,g1,g2,g3)
tuner1=t1:GetFirst()
else
tuner1=pe:GetOwner()
Group.FromCards(tuner1):Select(tp,1,1,nil)
end
g:AddCard(tuner1)
local lv1=tuner1:GetSynchroLevel(c)
local f1=tuner1.tuner_filter
local t2=nil
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SMATERIAL)
if tuner1:IsHasEffect(EFFECT_HAND_SYNCHRO) then
t2=g3:FilterSelect(tp,c1000617.synfilter2,1,1,tuner1,c,lv-lv1,g2,f1,tuner1)
else
t2=g1:FilterSelect(tp,c1000617.synfilter2,1,1,tuner1,c,lv-lv1,g2,f1,tuner1)
end
local tuner2=t2:GetFirst()
g:AddCard(tuner2)
local lv2=tuner2:GetSynchroLevel(c)
local f2=tuner2.tuner_filter
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SMATERIAL)
local m3=g2:FilterSelect(tp,c1000617.synfilter3,1,1,nil,c,lv-lv1-lv2,f1,f2)
g:Merge(m3)
end
c:SetMaterial(g)
Duel.SendtoGrave(g,REASON_MATERIAL+REASON_SYNCHRO)
end
function c1000617.limcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_SYNCHRO
end
function c1000617.limtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetChainLimit(c1000617.chainlm)
end
function c1000617.chainlm(e,rp,tp)
return tp==rp
end
function c1000617.limop(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_ACTIVATE)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(0,1)
e1:SetValue(c1000617.aclimit)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
function c1000617.aclimit(e,re,tp)
return re:GetHandler():IsOnField()
end
function c1000617.efilter(e,te)
return te:IsActiveType(TYPE_MONSTER) and te:GetOwner()~=e:GetOwner()
end
function c1000617.filter9(c,e,tp)
return c:IsSetCard(0xc204) and c:IsControler(tp) and not c:IsType(TYPE_PENDULUM)
end
function c1000617.con(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000617.filter9,LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=1
end
function c1000617.con1(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000617.filter9,LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=3
end
function c1000617.aclimit(e,re,tp)
return re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsActiveType(TYPE_SPELL+TYPE_NORMAL)
end
function c1000617.con2(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000617.filter9,LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=6
end
function c1000617.con3(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000617.filter9,LOCATION_GRAVE,0,nil,e,tp)
local ct=g:GetClassCount(Card.GetCode)
return ct>=9
end
function c1000617.efilter2(e,te)
return te:IsActiveType(TYPE_MONSTER) and te:GetOwner()~=e:GetOwner()
end
\ No newline at end of file
--圆环真理
function c1000618.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
c:RegisterEffect(e1)
--todeck
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000618,3))
e2:SetCategory(CATEGORY_TODECK)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e2:SetRange(LOCATION_SZONE)
e2:SetLabel(4)
e2:SetCode(EVENT_REMOVE)
e2:SetCondition(c1000618.effcon)
e2:SetTarget(c1000618.tg)
e2:SetOperation(c1000618.op)
c:RegisterEffect(e2)
--Atk up
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetRange(LOCATION_SZONE)
e3:SetTargetRange(LOCATION_MZONE,0)
e3:SetCode(EFFECT_UPDATE_ATTACK)
e3:SetCondition(c1000618.effcon)
e3:SetValue(c1000618.atkval)
e3:SetTarget(c1000618.tg2)
e3:SetLabel(5)
c:RegisterEffect(e3)
--remove
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(1000618,0))
e4:SetProperty(EFFECT_FLAG_CARD_TARGET)
e4:SetType(EFFECT_TYPE_QUICK_O)
e4:SetRange(LOCATION_SZONE)
e4:SetCode(EVENT_FREE_CHAIN)
e4:SetHintTiming(0,TIMING_END_PHASE)
e4:SetLabel(6)
e4:SetCondition(c1000618.effcon)
e4:SetCost(c1000618.cost)
e4:SetTarget(c1000618.target2)
e4:SetOperation(c1000618.operation)
c:RegisterEffect(e4)
--reflect damage
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_FIELD)
e5:SetCode(EFFECT_REFLECT_DAMAGE)
e5:SetRange(LOCATION_SZONE)
e5:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e5:SetTargetRange(1,0)
e5:SetLabel(7)
e5:SetCondition(c1000618.effcon)
e5:SetValue(c1000618.ref)
c:RegisterEffect(e5)
--draw
local e6=Effect.CreateEffect(c)
e6:SetDescription(aux.Stringid(1000618,2))
e6:SetCategory(CATEGORY_DRAW)
e6:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e6:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e6:SetRange(LOCATION_SZONE)
e6:SetCode(EVENT_DAMAGE)
e6:SetLabel(8)
e6:SetCondition(c1000618.drcon)
e6:SetCost(c1000618.cost2)
e6:SetTarget(c1000618.drtg)
e6:SetOperation(c1000618.drop)
c:RegisterEffect(e6)
--spsummon
local e7=Effect.CreateEffect(c)
e7:SetCategory(CATEGORY_SPECIAL_SUMMON)
e7:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
e7:SetCode(EVENT_DESTROYED)
e7:SetLabel(9)
e7:SetCondition(c1000618.effcon)
e7:SetTarget(c1000618.sptg)
e7:SetOperation(c1000618.spop)
c:RegisterEffect(e7)
end
function c1000618.cfilter(c)
return c:IsFaceup() and c:IsSetCard(0xc204) and not c:IsType(TYPE_PENDULUM)
end
function c1000618.effcon(e)
return Duel.GetMatchingGroup(c1000618.cfilter,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil):GetClassCount(Card.GetCode)>=e:GetLabel()
end
function c1000618.tdfilter(c,tp)
return c:IsSetCard(0xc204) and cIsType(TYPE_MONSTER) and c:IsFaceup()
and c:GetReasonPlayer()==1-tp and c:IsAbleToDeck() and not c:IsType(TYPE_PENDULUM)
end
function c1000618.tg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return eg:IsExists(c1000618.tdfilter,1,nil,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
Duel.SetOperationInfo(0,CATEGORY_TODECK,eg,eg:GetCount(),0,0)
end
function c1000618.op(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
if eg:GetCount()>0 then
Duel.SendtoDeck(eg,nil,2,REASON_EFFECT)
end
end
function c1000618.tg2(e,c)
return c:IsSetCard(0xc204) and c:IsFaceup() and not c:IsType(TYPE_PENDULUM)
end
function c1000618.atkval(e,c)
return Duel.GetMatchingGroup(c1000618.cfilter,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil):GetClassCount(Card.GetCode)*100
end
function c1000618.reval(e,re,rp)
return rp~=e:GetHandlerPlayer()
end
function c1000618.ref(e,re,val,r,rp,rc)
return (bit.band(r,REASON_BATTLE)~=0 or bit.band(r,REASON_EFFECT)~=0) and val<=1200
end
function c1000618.refilter(c)
return c:IsSetCard(0xc204) and c:IsAbleToGraveAsCost()
and Duel.IsExistingTarget(Card.IsAbleToRemove,0,0,LOCATION_ONFIELD,1,nil)
end
function c1000618.target1(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return c1000618.target2(e,tp,eg,ep,ev,re,r,rp,chk,chkc) end
if chk==0 then return true end
if c1000618.cost(e,tp,eg,ep,ev,re,r,rp,0) and c1000618.target2(e,tp,eg,ep,ev,re,r,rp,0,chkc)
and Duel.GetMatchingGroup(c1000618.cfilter,tp,LOCATION_GRAVE,0,nil):GetClassCount(Card.GetCode)>=e:GetLabel()
and Duel.SelectYesNo(tp,aux.Stringid(1000618,1)) then
e:SetProperty(EFFECT_FLAG_CARD_TARGET)
e:SetOperation(c1000618.operation)
c1000618.cost(e,tp,eg,ep,ev,re,r,rp,1)
c1000618.target2(e,tp,eg,ep,ev,re,r,rp,1,chkc)
else
e:SetProperty(0)
e:SetOperation(nil)
end
end
function c1000618.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c1000618.refilter,tp,LOCATION_MZONE,0,1,nil) and e:GetHandler():GetFlagEffect(1000618)==0 end
local cg=Duel.SelectMatchingCard(tp,c1000618.cfilter,tp,LOCATION_MZONE,0,1,1,nil)
Duel.SendtoGrave(cg,POS_FACEUP,REASON_COST)
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
e:GetHandler():RegisterFlagEffect(1000618,RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END,0,1)
end
function c1000618.target2(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsOnField() and c:IsControler(1-tp) and chkc:IsAbleToRemove() end
if chk==0 then return true end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectTarget(tp,Card.IsAbleToRemove,tp,0,LOCATION_ONFIELD,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,g,1,0,0)
end
function c1000618.operation(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.Remove(tc,POS_FACEDOWN,REASON_EFFECT)
end
end
function c1000618.drcon(e,tp,eg,ep,ev,re,r,rp)
return ep==tp and ev>=1300 and Duel.GetMatchingGroup(c1000618.cfilter,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil):GetClassCount(Card.GetCode)>=e:GetLabel()
end
function c1000618.cost2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
end
function c1000618.drtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(1)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
end
function c1000618.drop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Draw(p,d,REASON_EFFECT)
end
function c1000618.spfilter(c,e,tp)
return c:IsSetCard(0xc204) and c:IsType(TYPE_SYNCHRO) and c:IsCanBeSpecialSummoned(e,0,tp,true,false) and not c:IsType(TYPE_PENDULUM)
end
function c1000618.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_EXTRA)
end
function c1000618.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,c1000618.spfilter,tp,LOCATION_EXTRA,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,true,false,POS_FACEUP)
end
end
\ No newline at end of file
--超越命运之影
function c1000619.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000619,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,1000619)
e1:SetCost(c1000619.cost)
e1:SetTarget(c1000619.target)
e1:SetOperation(c1000619.activate)
c:RegisterEffect(e1)
--remove
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000619,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_ACTIVATE)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetCountLimit(1,1000619)
e2:SetCost(c1000619.cost)
e2:SetTarget(c1000619.tg)
e2:SetOperation(c1000619.op)
c:RegisterEffect(e2)
end
function c1000619.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
end
function c1000619.filter1(c,e)
return c:IsCanBeFusionMaterial() and not c:IsImmuneToEffect(e)
end
function c1000619.filter2(c,e,tp,m,f,chkf)
return c:IsType(TYPE_FUSION) and c:IsSetCard(0xc204) and (not f or f(c))
and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_FUSION,tp,false,false) and c:CheckFusionMaterial(m,nil,chkf)
end
function c1000619.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
local chkf=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and PLAYER_NONE or tp
local mg1=Duel.GetMatchingGroup(Card.IsCanBeFusionMaterial,tp,LOCATION_HAND+LOCATION_MZONE,0,nil)
local res=Duel.IsExistingMatchingCard(c1000619.filter2,tp,LOCATION_EXTRA,0,1,nil,e,tp,mg1,nil,chkf)
if not res then
local ce=Duel.GetChainMaterial(tp)
if ce~=nil then
local fgroup=ce:GetTarget()
local mg2=fgroup(ce,e,tp)
local mf=ce:GetValue()
res=Duel.IsExistingMatchingCard(c1000619.filter2,tp,LOCATION_EXTRA,0,1,nil,e,tp,mg2,mf,chkf)
end
end
return res
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function c1000619.activate(e,tp,eg,ep,ev,re,r,rp)
local chkf=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and PLAYER_NONE or tp
local mg1=Duel.GetMatchingGroup(c1000619.filter1,tp,LOCATION_HAND+LOCATION_MZONE,0,nil,e)
local sg1=Duel.GetMatchingGroup(c1000619.filter2,tp,LOCATION_EXTRA,0,nil,e,tp,mg1,nil,chkf)
local mg2=nil
local sg2=nil
local ce=Duel.GetChainMaterial(tp)
if ce~=nil then
local fgroup=ce:GetTarget()
mg2=fgroup(ce,e,tp)
local mf=ce:GetValue()
sg2=Duel.GetMatchingGroup(c1000619.filter2,tp,LOCATION_EXTRA,0,nil,e,tp,mg2,mf,chkf)
end
if sg1:GetCount()>0 or (sg2~=nil and sg2:GetCount()>0) then
local sg=sg1:Clone()
if sg2 then sg:Merge(sg2) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tg=sg:Select(tp,1,1,nil)
local tc=tg:GetFirst()
if sg1:IsContains(tc) and (sg2==nil or not sg2:IsContains(tc) or not Duel.SelectYesNo(tp,ce:GetDescription())) then
local mat1=Duel.SelectFusionMaterial(tp,tc,mg1,nil,chkf)
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)
else
local mat2=Duel.SelectFusionMaterial(tp,tc,mg2,nil,chkf)
local fop=ce:GetOperation()
fop(ce,e,tp,tc,mat2)
end
tc:CompleteProcedure()
else
local cg1=Duel.GetFieldGroup(tp,LOCATION_HAND+LOCATION_MZONE,0)
local cg2=Duel.GetFieldGroup(tp,LOCATION_EXTRA,0)
if cg1:GetCount()>1 and cg2:IsExists(Card.IsFacedown,1,nil)
and Duel.IsPlayerCanSpecialSummon(tp) and not Duel.IsPlayerAffectedByEffect(tp,27581098) then
Duel.ConfirmCards(1-tp,cg1)
Duel.ConfirmCards(1-tp,cg2)
Duel.ShuffleHand(tp)
end
end
end
function c1000619.filter3(c)
return c:IsCanBeFusionMaterial() and c:IsAbleToRemove()
end
function c1000619.filter4(c,e)
return c:IsCanBeFusionMaterial() and c:IsAbleToRemove() and not c:IsImmuneToEffect(e)
end
function c1000619.filter5(c,e,tp,m,f,chkf)
return c:IsType(TYPE_FUSION) and c:IsSetCard(0xc204) and (not f or f(c))
and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_FUSION,tp,false,false) and c:CheckFusionMaterial(m,nil,chkf)
end
function c1000619.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
local chkf=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and PLAYER_NONE or tp
local mg1=Duel.GetMatchingGroup(c1000619.filter3,tp,LOCATION_MZONE+LOCATION_GRAVE,0,nil)
local res=Duel.IsExistingMatchingCard(c1000619.filter5,tp,LOCATION_EXTRA,0,1,nil,e,tp,mg1,nil,chkf)
if not res then
local ce=Duel.GetChainMaterial(tp)
if ce~=nil then
local fgroup=ce:GetTarget()
local mg2=fgroup(ce,e,tp)
local mf=ce:GetValue()
res=Duel.IsExistingMatchingCard(c1000619.filter5,tp,LOCATION_EXTRA,0,1,nil,e,tp,mg2,mf,chkf)
end
end
return res
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function c1000619.op(e,tp,eg,ep,ev,re,r,rp)
local chkf=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and PLAYER_NONE or tp
local mg1=Duel.GetMatchingGroup(c1000619.filter4,tp,LOCATION_GRAVE+LOCATION_MZONE,0,nil,e)
local sg1=Duel.GetMatchingGroup(c1000619.filter5,tp,LOCATION_EXTRA,0,nil,e,tp,mg1,nil,chkf)
local mg2=nil
local sg2=nil
local ce=Duel.GetChainMaterial(tp)
if ce~=nil then
local fgroup=ce:GetTarget()
mg2=fgroup(ce,e,tp)
local mf=ce:GetValue()
sg2=Duel.GetMatchingGroup(c1000619.filter5,tp,LOCATION_EXTRA,0,nil,e,tp,mg2,mf,chkf)
end
if sg1:GetCount()>0 or (sg2~=nil and sg2:GetCount()>0) then
local sg=sg1:Clone()
if sg2 then sg:Merge(sg2) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tg=sg:Select(tp,1,1,nil)
local tc=tg:GetFirst()
if sg1:IsContains(tc) and (sg2==nil or not sg2:IsContains(tc) or not Duel.SelectYesNo(tp,ce:GetDescription())) then
local mat1=Duel.SelectFusionMaterial(tp,tc,mg1,nil,chkf)
tc:SetMaterial(mat1)
Duel.Remove(mat1,POS_FACEUP,REASON_EFFECT+REASON_MATERIAL+REASON_FUSION)
Duel.BreakEffect()
Duel.SpecialSummon(tc,SUMMON_TYPE_FUSION,tp,tp,false,false,POS_FACEUP)
else
local mat2=Duel.SelectFusionMaterial(tp,tc,mg2,nil,chkf)
local fop=ce:GetOperation()
fop(ce,e,tp,tc,mat2)
end
tc:CompleteProcedure()
end
end
--纯洁的牲祭·鹿目圆香
function c1000620.initial_effect(c)
--level
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000620,0))
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetCountLimit(1,1000620)
e2:SetRange(LOCATION_MZONE)
e2:SetCost(c1000620.lvcost)
e2:SetOperation(c1000620.lvop)
c:RegisterEffect(e2)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000620,1))
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_NO_TURN_RESET)
e1:SetRange(LOCATION_GRAVE)
e1:SetCountLimit(1,10006200)
e1:SetTarget(c1000620.target)
e1:SetOperation(c1000620.operation)
c:RegisterEffect(e1)
end
function c1000620.costfilter(c,lv)
local clv=c:GetLevel()
return clv>0 and clv~=lv and c:IsSetCard(0xc204) and c:IsType(TYPE_MONSTER) and not c:IsType(TYPE_PENDULUM) and c:IsAbleToGraveAsCost()
end
function c1000620.lvcost(e,tp,eg,ep,ev,re,r,rp,chk)
local lv=e:GetHandler():GetLevel()
if chk==0 then return Duel.IsExistingMatchingCard(c1000620.costfilter,tp,LOCATION_DECK,0,1,nil,lv) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,c1000620.costfilter,tp,LOCATION_DECK,0,1,1,nil,lv)
Duel.SendtoGrave(g,REASON_COST)
e:SetLabel(g:GetFirst():GetLevel())
end
function c1000620.lvop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local lv=e:GetLabel()
if c:IsRelateToEffect(e) and c:IsFaceup() then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_CHANGE_LEVEL)
e1:SetValue(lv)
e1:SetReset(RESET_EVENT+0x1ff0000)
c:RegisterEffect(e1)
end
end
function c1000620.filter(c)
return c:IsFaceup() and c:IsSetCard(0xc204)
end
function c1000620.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c1000620.filter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c1000620.filter,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SelectTarget(tp,c1000620.filter,tp,LOCATION_MZONE,0,1,1,nil)
end
function c1000620.operation(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:IsFaceup() then
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_INDESTRUCTABLE_COUNT)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCountLimit(1)
e1:SetValue(c1000620.valcon)
e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
end
end
function c1000620.valcon(e,re,r,rp)
return bit.band(r,REASON_BATTLE+REASON_EFFECT)~=0
end
\ No newline at end of file
--愿望的诅咒·鹿目圆香
function c1000621.initial_effect(c)
--search
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000621,0))
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_HANDES)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetCountLimit(1,1000621)
e1:SetRange(LOCATION_MZONE)
e1:SetTarget(c1000621.target)
e1:SetOperation(c1000621.operation)
c:RegisterEffect(e1)
--negate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000621,1))
e1:SetCategory(CATEGORY_DISABLE)
e1:SetProperty(EFFECT_FLAG_NO_TURN_RESET)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_CHAINING)
e1:SetRange(LOCATION_GRAVE)
e1:SetCountLimit(1,10006210)
e1:SetCondition(c1000621.negcon)
e1:SetTarget(c1000621.negtg)
e1:SetOperation(c1000621.negop)
c:RegisterEffect(e1)
end
function c1000621.filter(c)
return c:IsSetCard(0xc204) and c:IsType(TYPE_MONSTER) and not c:IsType(TYPE_PENDULUM) and c:IsAbleToHand()
end
function c1000621.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c1000621.filter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
Duel.SetOperationInfo(0,CATEGORY_HANDES,nil,1,tp,1)
end
function c1000621.operation(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c1000621.filter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()==0 then return end
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
Duel.ShuffleHand(tp)
end
function c1000621.tfilter(c,tp)
return c:IsLocation(LOCATION_MZONE) and c:IsControler(tp) and c:IsFaceup() and c:IsSetCard(0xc204)
end
function c1000621.negcon(e,tp,eg,ep,ev,re,r,rp)
if not re:IsHasProperty(EFFECT_FLAG_CARD_TARGET) then return false end
local g=Duel.GetChainInfo(ev,CHAININFO_TARGET_CARDS)
return g and g:IsExists(c1000621.tfilter,1,nil,tp) and Duel.IsChainDisablable(ev)
end
function c1000621.negtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_DISABLE,eg,1,0,0)
end
function c1000621.negop(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateEffect(ev)
end
--圆环的少女·鹿目圆香
function c1000622.initial_effect(c)
--spsummon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000622,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetTarget(c1000622.sptg)
e1:SetOperation(c1000622.spop)
c:RegisterEffect(e1)
--flip
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000622,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_FLIP+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCost(c1000622.cost)
e1:SetTarget(c1000622.sptg)
e1:SetOperation(c1000622.spop)
c:RegisterEffect(e1)
--atkup
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000622,0))
e1:SetCategory(CATEGORY_ATKCHANGE)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_NO_TURN_RESET)
e1:SetHintTiming(TIMING_DAMAGE_STEP)
e1:SetRange(LOCATION_GRAVE)
e1:SetCountLimit(1,1000622)
e1:SetCondition(c1000622.atkcon)
e1:SetOperation(c1000622.atkop)
c:RegisterEffect(e1)
end
function c1000622.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
end
function c1000622.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c1000622.filter,tp,LOCATION_GRAVE+LOCATION_HAND,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE+LOCATION_HAND)
end
function c1000622.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,c1000622.filter,tp,LOCATION_GRAVE+LOCATION_HAND,0,1,1,nil,e,tp)
if g:GetCount()>0 and not g:GetFirst():IsHasEffect(EFFECT_NECRO_VALLEY) then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP_DEFENSE)
end
end
function c1000622.filter(c,e,tp)
return c:IsSetCard(0xc204) and c:IsType(TYPE_MONSTER) and not c:IsType(TYPE_PENDULUM+TYPE_TUNER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c1000622.atkcon(e,tp,eg,ep,ev,re,r,rp)
local phase=Duel.GetCurrentPhase()
if phase~=PHASE_DAMAGE or Duel.IsDamageCalculated() then return false end
local c=Duel.GetAttackTarget()
if not c then return false end
if c:IsControler(1-tp) then c=Duel.GetAttacker() end
return c and c:IsSetCard(0xc204) and c:IsRelateToBattle()
end
function c1000622.atkop(e,tp,eg,ep,ev,re,r,rp,chk)
local a=Duel.GetAttacker()
local d=Duel.GetAttackTarget()
if not a:IsRelateToBattle() or a:IsFacedown() or not d:IsRelateToBattle() or d:IsFacedown() then return end
if a:GetControler()~=tp then a,d=d,a end
if a:IsImmuneToEffect(e) then return end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetOwnerPlayer(tp)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_DAMAGE_CAL)
e1:SetValue(d:GetAttack())
a:RegisterEffect(e1)
end
\ No newline at end of file
--Archer·鹿目圆香
function c1000623.initial_effect(c)
--synchro summon
aux.AddSynchroProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xc204),aux.NonTuner(Card.IsAttribute,ATTRIBUTE_LIGHT),1)
c:EnableReviveLimit()
--search
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP)
e2:SetCountLimit(1,1000623)
e2:SetCondition(c1000623.recon)
e2:SetTarget(c1000623.regtg)
e2:SetOperation(c1000623.regop)
c:RegisterEffect(e2)
--atkup
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e3:SetCode(EFFECT_UPDATE_ATTACK)
e3:SetRange(LOCATION_MZONE)
e3:SetValue(c1000623.value)
c:RegisterEffect(e3)
--pierce
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_PIERCE)
c:RegisterEffect(e2)
--destroy
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_DAMAGE+CATEGORY_DESTROY)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_TO_GRAVE)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY)
e3:SetCondition(c1000623.descon)
e3:SetTarget(c1000623.destg)
e3:SetOperation(c1000623.desop)
c:RegisterEffect(e3)
end
function c1000623.recon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_SYNCHRO
end
function c1000623.thfilter(c)
return c:IsSetCard(0xc204) and c:IsType(TYPE_MONSTER) and not c:IsType(TYPE_PENDULUM) and c:IsAbleToHand()
end
function c1000623.regtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsSetCard,tp,LOCATION_DECK,0,1,nil,0xc204) end
end
function c1000623.regop(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_PHASE+PHASE_END)
e1:SetCountLimit(1)
e1:SetCondition(c1000623.thcon)
e1:SetOperation(c1000623.thop)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
function c1000623.thcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c1000623.thfilter,tp,LOCATION_DECK,0,1,nil)
end
function c1000623.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,0,1000623)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c1000623.thfilter,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
function c1000623.atkfilter(c)
return c:IsType(TYPE_MONSTER) and c:IsSetCard(0xc204)
end
function c1000623.value(e,c)
local g=Duel.GetMatchingGroup(c1000623.atkfilter,c:GetControler(),LOCATION_GRAVE,0,nil)
local ct=g:GetClassCount(Card.GetCode)
return ct*300
end
function c1000623.descon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD)
end
function c1000623.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) end
if chk==0 then return Duel.IsExistingTarget(aux.TRUE,tp,0,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectTarget(tp,aux.TRUE,tp,0,LOCATION_MZONE,1,1,nil)
local d=g:GetFirst()
local atk=0
if d:IsFaceup() then atk=d:GetAttack() end
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,atk)
end
function c1000623.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
local atk=0
if tc:IsFaceup() then atk=tc:GetAttack() end
if Duel.Destroy(tc,REASON_EFFECT)==0 then return end
Duel.Damage(1-tp,atk,REASON_EFFECT)
end
end
\ No newline at end of file
--Caster·鹿目圆香
function c1000624.initial_effect(c)
--synchro summon
aux.AddSynchroProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xc204),aux.NonTuner(Card.IsAttribute,ATTRIBUTE_LIGHT),1)
c:EnableReviveLimit()
--cannot be target
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET)
e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(LOCATION_MZONE,0)
e1:SetTarget(c1000624.sfilter)
e1:SetValue(aux.tgoval)
c:RegisterEffect(e1)
--copy
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000624,0))
e2:SetCategory(CATEGORY_REMOVE)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetCountLimit(1)
e2:SetRange(LOCATION_MZONE)
e2:SetTarget(c1000624.target)
e2:SetOperation(c1000624.operation)
c:RegisterEffect(e2)
--negate attack
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000624,1))
e1:SetCategory(CATEGORY_DAMAGE)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_BE_BATTLE_TARGET)
e1:SetProperty(EFFECT_FLAG_NO_TURN_RESET)
e1:SetRange(LOCATION_GRAVE)
e1:SetCountLimit(1,1000624)
e1:SetCondition(c1000624.nacon)
e1:SetTarget(c1000624.natg)
e1:SetOperation(c1000624.naop)
c:RegisterEffect(e1)
end
function c1000624.sfilter(c)
return c:IsFaceup() and (c:IsSetCard(0x3204) or c:IsSetCard(0xa204) or c:IsSetCard(0x5b23) or c:IsSetCard(0x6b25) or c:IsSetCard(0xc204) or c:IsSetCard(0x3205)) and c:IsType(TYPE_MONSTER)
end
function c1000624.cpfilter(c)
return c:IsSetCard(0xc204) and c:IsType(TYPE_MONSTER) and c:IsAbleToRemove()
end
function c1000624.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:GetLocation()==LOCATION_GRAVE and c1000624.cpfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c1000624.cpfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectTarget(tp,c1000624.cpfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,g,1,0,0)
end
function c1000624.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if c:IsRelateToEffect(e) and c:IsFaceup() and tc:IsRelateToEffect(e) then
if Duel.Remove(tc,POS_FACEUP,REASON_EFFECT)~=1 then return end
local code=tc:GetOriginalCode()
local reset_flag=RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END
c:CopyEffect(code, reset_flag, 1)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(reset_flag)
e1:SetCode(EFFECT_CHANGE_CODE)
e1:SetValue(code)
c:RegisterEffect(e1)
end
end
function c1000624.nacon(e,tp,eg,ep,ev,re,r,rp)
local at=Duel.GetAttackTarget()
return at:IsControler(tp) and at:IsFaceup() and at:IsSetCard(0xc204)
end
function c1000624.natg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetAttacker():IsOnField() end
local dam=Duel.GetAttacker():GetAttack()/2
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,dam)
end
function c1000624.naop(e,tp,eg,ep,ev,re,r,rp)
local a=Duel.GetAttacker()
if Duel.NegateAttack() then
Duel.Damage(1-tp,a:GetAttack()/2,REASON_EFFECT)
end
end
\ No newline at end of file
--Saver·鹿目圆香
function c1000625.initial_effect(c)
--synchro summon
aux.AddSynchroProcedure(c,aux.FilterBoolFunction(Card.IsType,TYPE_SYNCHRO),aux.NonTuner(Card.IsType,TYPE_SYNCHRO),1)
c:EnableReviveLimit()
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(1000625,0))
e1:SetCategory(CATEGORY_CONTROL)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCondition(c1000625.ctcon)
e1:SetOperation(c1000625.ctop)
c:RegisterEffect(e1)
--destroy
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000625,0))
e2:SetCategory(CATEGORY_DESTROY)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
e2:SetCode(EVENT_LEAVE_FIELD)
e2:SetCondition(c1000625.descon)
e2:SetTarget(c1000625.destg)
e2:SetOperation(c1000625.desop)
c:RegisterEffect(e2)
--control
local e99=Effect.CreateEffect(c)
e99:SetType(EFFECT_TYPE_SINGLE)
e99:SetProperty(EFFECT_FLAG_SINGLE_RANGE+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e99:SetRange(LOCATION_MZONE)
e99:SetCode(EFFECT_CANNOT_CHANGE_CONTROL)
c:RegisterEffect(e99)
end
function c1000625.ctcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_SYNCHRO
end
function c1000625.filter(c)
return c:IsFaceup()
end
function c1000625.ctop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c1000625.filter,tp,0,LOCATION_MZONE,nil)
if g:GetCount()==0 then return end
local sg=g:GetMaxGroup(Card.GetAttack)
if sg:GetCount()>1 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CONTROL)
sg=sg:Select(tp,1,1,nil)
end
local tc=sg:GetFirst()
Duel.GetControl(tc,tp)
end
function c1000625.descon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsPreviousPosition(POS_FACEUP) and e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD)
end
function c1000625.destg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
local g=Duel.GetMatchingGroup(aux.TRUE,tp,0,LOCATION_ONFIELD,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0)
end
function c1000625.desop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(aux.TRUE,tp,0,LOCATION_ONFIELD,nil)
Duel.Destroy(g,REASON_EFFECT)
end
\ No newline at end of file
--期望的未来·鹿目圆香
function c1000626.initial_effect(c)
--synchro summon
aux.AddSynchroProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xc204),aux.NonTuner(Card.IsAttribute,ATTRIBUTE_LIGHT),1)
c:EnableReviveLimit()
--lv
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000626,0))
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1)
e2:SetCost(c1000626.tgcost)
e2:SetTarget(c1000626.tgtg)
e2:SetOperation(c1000626.tgop)
c:RegisterEffect(e2)
--synchro effect
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1000626,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetRange(LOCATION_MZONE)
e2:SetHintTiming(0,TIMING_BATTLE_START+TIMING_BATTLE_END)
e2:SetCountLimit(1)
e2:SetCondition(c1000626.sccon)
e2:SetTarget(c1000626.sctg)
e2:SetOperation(c1000626.scop)
c:RegisterEffect(e2)
--spsummon
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_GRAVE)
e1:SetCountLimit(1,1000626)
e1:SetTarget(c1000626.target)
e1:SetOperation(c1000626.operation)
c:RegisterEffect(e1)
end
function c1000626.filter(c)
return c:GetLevel()>0 and c:IsSetCard(0xc204) and c:IsType(TYPE_MONSTER) and not c:IsType(TYPE_PENDULUM) and c:IsAbleToGraveAsCost()
end
function c1000626.tgcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c1000626.filter,tp,LOCATION_DECK,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,c1000626.filter,tp,LOCATION_DECK,0,1,1,nil)
Duel.SendtoGrave(g,REASON_COST)
e:SetLabelObject(g:GetFirst())
end
function c1000626.tgtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
local opt=Duel.SelectOption(tp,aux.Stringid(1000626,2),aux.Stringid(1000626,3))
e:SetLabel(opt)
end
function c1000626.tgop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local lv=e:GetLabelObject():GetLevel()
if c:IsRelateToEffect(e) and c:IsFaceup() then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_LEVEL)
if e:GetLabel()==0 then
e1:SetValue(lv)
else
e1:SetValue(-lv)
end
e1:SetReset(RESET_EVENT+0x1ff0000)
c:RegisterEffect(e1)
end
end
function c1000626.mfilter(c)
return c:IsSetCard(0xc204)
end
function c1000626.sccon(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase()
return not e:GetHandler():IsStatus(STATUS_CHAINING) and Duel.GetTurnPlayer()~=tp
and (ph==PHASE_MAIN1 or (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE) or ph==PHASE_MAIN2)
end
function c1000626.sctg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
local mg=Duel.GetMatchingGroup(c1000626.mfilter,tp,LOCATION_MZONE,0,nil)
return Duel.IsExistingMatchingCard(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,1,nil,nil,mg)
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function c1000626.scop(e,tp,eg,ep,ev,re,r,rp)
local mg=Duel.GetMatchingGroup(c1000626.mfilter,tp,LOCATION_MZONE,0,nil)
local g=Duel.GetMatchingGroup(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,nil,nil,mg)
if g:GetCount()>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local sg=g:Select(tp,1,1,nil)
Duel.SynchroSummon(tp,sg:GetFirst(),nil,mg)
end
end
function c1000626.filter0(c)
return c:IsCanBeFusionMaterial() and c:IsAbleToRemove()
end
function c1000626.filter1(c,e)
return c:IsCanBeFusionMaterial() and c:IsAbleToRemove() and not c:IsImmuneToEffect(e)
end
function c1000626.filter2(c,e,tp,m,f,gc)
return c:IsType(TYPE_FUSION) and c:IsSetCard(0xc204) and (not f or f(c))
and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_FUSION,tp,false,false) and c:CheckFusionMaterial(m,gc)
end
function c1000626.target(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then
local mg1=Duel.GetMatchingGroup(c1000626.filter0,tp,LOCATION_GRAVE,0,c)
local res=Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c1000626.filter2,tp,LOCATION_EXTRA,0,1,nil,e,tp,mg1,nil,c)
if not res then
local ce=Duel.GetChainMaterial(tp)
if ce~=nil then
local fgroup=ce:GetTarget()
local mg2=fgroup(ce,e,tp)
local mf=ce:GetValue()
res=Duel.IsExistingMatchingCard(c1000626.filter2,tp,LOCATION_EXTRA,0,1,nil,e,tp,mg2,mf,c)
end
end
return res
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function c1000626.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) or c:IsImmuneToEffect(e) then return end
local mg1=Duel.GetMatchingGroup(c1000626.filter1,tp,LOCATION_GRAVE,0,c,e)
local sg1=Duel.GetMatchingGroup(c1000626.filter2,tp,LOCATION_EXTRA,0,nil,e,tp,mg1,nil,c)
local mg2=nil
local sg2=nil
local ce=Duel.GetChainMaterial(tp)
if ce~=nil then
local fgroup=ce:GetTarget()
mg2=fgroup(ce,e,tp)
local mf=ce:GetValue()
sg2=Duel.GetMatchingGroup(c1000626.filter2,tp,LOCATION_EXTRA,0,nil,e,tp,mg2,mf,c)
end
if (Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and sg1:GetCount()>0) or (sg2~=nil and sg2:GetCount()>0) then
local sg=sg1:Clone()
if sg2 then sg:Merge(sg2) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tg=sg:Select(tp,1,1,nil)
local tc=tg:GetFirst()
if sg1:IsContains(tc) and (sg2==nil or not sg2:IsContains(tc) or not Duel.SelectYesNo(tp,ce:GetDescription())) then
local mat1=Duel.SelectFusionMaterial(tp,tc,mg1,c)
tc:SetMaterial(mat1)
Duel.Remove(mat1,POS_FACEUP,REASON_EFFECT+REASON_MATERIAL+REASON_FUSION)
Duel.BreakEffect()
Duel.SpecialSummon(tc,SUMMON_TYPE_FUSION,tp,tp,false,false,POS_FACEUP)
else
local mat2=Duel.SelectFusionMaterial(tp,tc,mg2,c)
local fop=ce:GetOperation()
fop(ce,e,tp,tc,mat2)
end
tc:CompleteProcedure()
end
end
\ No newline at end of file
--LA SY 先負的菲斯特菲
function c12001000.initial_effect(c)
--pendulum summon
aux.EnablePendulumAttribute(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(12001000,0))
e1:SetCategory(CATEGORY_DECKDES)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DAMAGE_STEP)
e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetCountLimit(1,12001000)
e1:SetTarget(c12001000.target)
e1:SetOperation(c12001000.operation)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(12001000,1))
e3:SetCategory(CATEGORY_SPECIAL_SUMMON)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_TO_GRAVE)
e3:SetCountLimit(1,12001100)
e3:SetCondition(c12001000.spcon)
e3:SetTarget(c12001000.sptg)
e3:SetOperation(c12001000.spop)
c:RegisterEffect(e3)
end
function c12001000.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDiscardDeck(tp,1) end
end
function c12001000.operation(e,tp,eg,ep,ev,re,r,rp)
if not Duel.IsPlayerCanDiscardDeck(tp,1) then return end
Duel.ConfirmDecktop(tp,1)
local g=Duel.GetDecktopGroup(tp,1)
local tc=g:GetFirst()
if tc:IsSetCard(0xfb0) then
Duel.DisableShuffleCheck()
Duel.SendtoGrave(g,REASON_EFFECT+REASON_REVEAL)
else
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ShuffleDeck(tp)
Duel.SendtoDeck(e:GetHandler(),nil,0,REASON_EFFECT)
end
end
function c12001000.spcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_DECK) and c:IsReason(REASON_REVEAL)
end
function c12001000.filter(c,e,tp)
return c:IsSetCard(0xfb0) and c:IsType(TYPE_PENDULUM) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and c:IsLevelBelow(4)
end
function c12001000.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c12001000.filter(chkc,e,tp) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingTarget(c12001000.filter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c12001000.filter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end
function c12001000.spop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
end
end
--六曜 大安的卡莲特尔
function c12001001.initial_effect(c)
--pendulum summon
aux.EnablePendulumAttribute(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(12001001,0))
e1:SetCategory(CATEGORY_TOGRAVE+CATEGORY_DRAW)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetCountLimit(1,12001001)
e1:SetRange(LOCATION_HAND)
e1:SetTarget(c12001001.target)
e1:SetOperation(c12001001.operation)
c:RegisterEffect(e1)
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(12001001,1))
e3:SetCategory(CATEGORY_SPECIAL_SUMMON)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_TO_GRAVE)
e3:SetCountLimit(1,12001101)
e3:SetCondition(c12001001.dscon)
e3:SetTarget(c12001001.dstg)
e3:SetOperation(c12001001.dsop)
c:RegisterEffect(e3)
end
function c12001001.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDiscardDeck(tp,1) end
end
function c12001001.operation(e,tp,eg,ep,ev,re,r,rp)
if not Duel.IsPlayerCanDiscardDeck(tp,1) then return end
Duel.ConfirmDecktop(tp,1)
local g=Duel.GetDecktopGroup(tp,1)
local tc=g:GetFirst()
if tc:IsSetCard(0xfb0) then
Duel.DisableShuffleCheck()
Duel.SendtoGrave(g,REASON_EFFECT+REASON_REVEAL)
Duel.SpecialSummon(e:GetHandler(),0,tp,tp,false,false,POS_FACEUP)
else
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ShuffleDeck(tp)
Duel.SendtoDeck(e:GetHandler(),nil,0,REASON_EFFECT)
end
end
function c12001001.dscon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_DECK) and c:IsReason(REASON_REVEAL)
end
function c12001001.filter(c)
return c:IsPosition(POS_FACEUP_ATTACK)
end
function c12001001.dstg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c12001001.filter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end
local g=Duel.GetMatchingGroup(c12001001.filter,tp,LOCATION_MZONE,LOCATION_MZONE,nil)
local tg=g:GetMaxGroup(Card.GetAttack)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,tg,1,0,0)
end
function c12001001.dsop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c12001001.filter,tp,LOCATION_MZONE,LOCATION_MZONE,nil)
if g:GetCount()>0 then
local tg=g:GetMaxGroup(Card.GetAttack)
if tg:GetCount()>1 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local sg=tg:Select(tp,1,1,nil)
Duel.HintSelection(sg)
local tc=sg:GetFirst()
local atk=tc:IsFaceup() and tc:GetAttack() or 0
if Duel.Destroy(sg,REASON_EFFECT)==1 and atk~=0
then Duel.Recover(tp,atk,REASON_EFFECT)
Duel.Recover(1-tp,atk,REASON_EFFECT)
end
else
local tc=tg:GetFirst()
local atk=tc:IsFaceup() and tc:GetAttack() or 0
if Duel.Destroy(tg,REASON_EFFECT)==1 and atk~=0
then Duel.Recover(tp,atk,REASON_EFFECT)
Duel.Recover(1-tp,atk,REASON_EFFECT)
end
end
end
end
--六曜 友引的夕碧姬
function c12001002.initial_effect(c)
--pendulum summon
aux.EnablePendulumAttribute(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(12001002,0))
e1:SetCategory(CATEGORY_SEARCH+CATEGORY_DECKDES)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,12001002)
e1:SetTarget(c12001002.target)
e1:SetTarget(c12001002.target1)
e1:SetOperation(c12001002.operation)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(12001002,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_TO_GRAVE)
e2:SetCountLimit(1,12001102)
e2:SetCondition(c12001002.spcon)
e2:SetTarget(c12001002.sptg)
e2:SetOperation(c12001002.spop)
c:RegisterEffect(e2)
end
function c12001002.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDiscardDeck(tp,1) end
end
function c12001002.filter(c)
return c:IsSetCard(0xfb0) and c:IsAbleToHand() and c:IsType(TYPE_TRAP)
end
function c12001002.target1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c12001002.filter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function c12001002.operation(e,tp,eg,ep,ev,re,r,rp)
if not Duel.IsPlayerCanDiscardDeck(tp,1) then return end
Duel.ConfirmDecktop(tp,1)
local g=Duel.GetDecktopGroup(tp,1)
local tc=g:GetFirst()
if tc:IsSetCard(0xfb0) then
Duel.DisableShuffleCheck()
Duel.SendtoGrave(g,REASON_EFFECT+REASON_REVEAL)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c12001002.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
else
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ShuffleDeck(tp)
Duel.SendtoDeck(e:GetHandler(),nil,0,REASON_EFFECT)
end
end
function c12001002.spcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_DECK) and c:IsReason(REASON_REVEAL)
end
function c12001002.filter1(c,e,tp)
return c:IsSetCard(0xfb0) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c12001002.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c12001002.filter1,tp,LOCATION_DECK,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK)
end
function c12001002.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,c12001002.filter1,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
end
--六曜 佛灭的波达蝶斯
function c12001003.initial_effect(c)
--pendulum summon
aux.EnablePendulumAttribute(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(12001003,0))
e1:SetCategory(CATEGORY_SEARCH+CATEGORY_DECKDES)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,12001003)
e1:SetTarget(c12001003.target)
e1:SetOperation(c12001003.operation)
c:RegisterEffect(e1)
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(12001003,1))
e3:SetCategory(CATEGORY_TOGRAVE)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_TO_GRAVE)
e3:SetCountLimit(1,12001103)
e3:SetCondition(c12001003.dscon)
e3:SetTarget(c12001003.dstg)
e3:SetOperation(c12001003.dsop)
c:RegisterEffect(e3)
end
function c12001003.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDiscardDeck(tp,1) end
end
function c12001003.operation(e,tp,eg,ep,ev,re,r,rp)
if not Duel.IsPlayerCanDiscardDeck(tp,1) then return end
Duel.ConfirmDecktop(tp,1)
local g=Duel.GetDecktopGroup(tp,1)
local tc=g:GetFirst()
if tc:IsSetCard(0xfb0) then
Duel.DisableShuffleCheck()
Duel.SendtoGrave(g,REASON_EFFECT+REASON_REVEAL)
Duel.ConfirmDecktop(tp,3)
else
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ShuffleDeck(tp)
Duel.SendtoDeck(e:GetHandler(),nil,0,REASON_EFFECT)
end
end
function c12001003.dscon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_DECK) and c:IsReason(REASON_REVEAL)
end
function c12001003.dstg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and c12001003.filter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c12001003.filter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SelectTarget(tp,c12001003.filter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
end
function c12001003.dsop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:IsFaceup() then
Duel.NegateRelatedChain(tc,RESET_TURN_SET)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+0x1fe0000)
tc:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetValue(RESET_TURN_SET)
tc:RegisterEffect(e2)
local e3=e1:Clone()
e3:SetCode(EFFECT_SET_BASE_ATTACK)
e3:SetValue(tc:GetBaseAttack()/2)
tc:RegisterEffect(e3)
end
end
\ No newline at end of file
--六曜 赤口的斯卡雷特
function c12001004.initial_effect(c)
--pendulum summon
aux.EnablePendulumAttribute(c)
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_MZONE+LOCATION_HAND)
e1:SetCountLimit(1,12001004)
e1:SetCost(c12001004.cost)
e1:SetTarget(c12001004.target)
e1:SetOperation(c12001004.operation)
c:RegisterEffect(e1)
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(12001004,1))
e3:SetCategory(CATEGORY_TOGRAVE)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_TO_GRAVE)
e3:SetCountLimit(1,12001104)
e3:SetCondition(c12001004.dscon)
e3:SetTarget(c12001004.dstg)
e3:SetOperation(c12001004.dsop)
c:RegisterEffect(e3)
end
function c12001004.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToGraveAsCost() end
Duel.SendtoGrave(e:GetHandler(),REASON_COST)
end
function c12001004.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDiscardDeck(tp,1) end
end
function c12001004.operation(e,tp,eg,ep,ev,re,r,rp)
if not Duel.IsPlayerCanDiscardDeck(tp,1) then return end
Duel.ConfirmDecktop(tp,1)
local g=Duel.GetDecktopGroup(tp,1)
local tc=g:GetFirst()
if tc:IsSetCard(0xfb0) then
Duel.DisableShuffleCheck()
Duel.SendtoGrave(g,REASON_EFFECT+REASON_REVEAL)
else
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ShuffleDeck(tp)
Duel.SendtoDeck(e:GetHandler(),nil,0,REASON_EFFECT)
end
end
function c12001004.dscon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_DECK) and c:IsReason(REASON_REVEAL)
end
function c12001004.dstg(e,tp,eg,ep,ev,re,r,rp,chk)
if chkc then return chkc:IsLocation(LOCATION_ONFIELD) and chkc:IsControler(1-tp) end
if chk==0 then return Duel.IsExistingTarget(aux.TRUE,tp,0,LOCATION_ONFIELD,1,nil) end
Duel.Hint(HINT_SELECTMSG,1-tp,HINTMSG_DESTROY)
local g=Duel.SelectTarget(1-tp,aux.TRUE,tp,0,LOCATION_ONFIELD,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,g,1,0,0)
end
function c12001004.dsop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.Remove(tc,POS_FACEUP,REASON_RULE)
end
end
\ No newline at end of file
--六曜 先胜的菲斯特文
function c12001005.initial_effect(c)
--pendulum summon
aux.EnablePendulumAttribute(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(12001005,0))
e1:SetCategory(CATEGORY_DECKDES+CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DAMAGE_STEP)
e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetCountLimit(1,12001005)
e1:SetTarget(c12001005.target)
e1:SetTarget(c12001005.target1)
e1:SetOperation(c12001005.operation)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(12001005,2))
e2:SetCategory(CATEGORY_DRAW+CATEGORY_DECKDES)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_TO_GRAVE)
e2:SetCountLimit(1,12001105)
e2:SetCondition(c12001005.drcon)
e2:SetTarget(c12001005.drtg)
e2:SetOperation(c12001005.drop)
c:RegisterEffect(e2)
end
function c12001005.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDiscardDeck(tp,1) end
end
function c12001005.filter1(c,e,tp)
return c:IsCode(12001000) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c12001005.target1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c12001005.filter,tp,LOCATION_DECK,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK)
end
function c12001005.operation(e,tp,eg,ep,ev,re,r,rp)
if not Duel.IsPlayerCanDiscardDeck(tp,1) then return end
Duel.ConfirmDecktop(tp,1)
local g=Duel.GetDecktopGroup(tp,1)
local tc=g:GetFirst()
if tc:IsSetCard(0xfb0) then
Duel.DisableShuffleCheck()
Duel.SendtoGrave(g,REASON_EFFECT+REASON_REVEAL)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c12001005.filter1,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
else
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ShuffleDeck(tp)
Duel.SendtoDeck(e:GetHandler(),nil,0,REASON_EFFECT)
end
end
function c12001005.drcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_DECK) and c:IsReason(REASON_REVEAL)
end
function c12001005.drtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,2) end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(2)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,2)
Duel.SetOperationInfo(0,CATEGORY_HANDES,nil,0,tp,1)
end
function c12001005.drop(e,tp,eg,ep,ev,re,r,rp)
local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER)
if Duel.Draw(p,2,REASON_EFFECT)==2 then
Duel.ShuffleHand(tp)
Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(p,aux.TRUE,p,LOCATION_HAND,0,1,1,nil)
Duel.SendtoDeck(g,nil,1,REASON_EFFECT)
end
end
\ No newline at end of file
--六曜的卜时
function c12001006.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
c:RegisterEffect(e1)
--announce
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(12001006,0))
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_DECKDES)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_SZONE)
e2:SetCountLimit(1)
e2:SetTarget(c12001006.target)
e2:SetOperation(c12001006.operation)
c:RegisterEffect(e2)
local e4=Effect.CreateEffect(c)
e4:SetCategory(CATEGORY_LEAVE_GRAVE)
e4:SetType(EFFECT_TYPE_QUICK_O)
e4:SetCode(EVENT_FREE_CHAIN)
e4:SetRange(LOCATION_GRAVE)
e4:SetCost(aux.bfgcost)
e4:SetTarget(c12001006.actg)
e4:SetOperation(c12001006.acop)
c:RegisterEffect(e4)
end
function c12001006.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDiscardDeck(tp,1) end
end
function c12001006.operation(e,tp,eg,ep,ev,re,r,rp)
if not Duel.IsPlayerCanDiscardDeck(tp,1) then return end
Duel.ConfirmDecktop(tp,1)
local g=Duel.GetDecktopGroup(tp,1)
local tc=g:GetFirst()
if tc:IsSetCard(0xfb0) then
Duel.DisableShuffleCheck()
Duel.SendtoGrave(g,REASON_EFFECT+REASON_REVEAL)
Duel.Draw(tp,1,REASON_EFFECT)
else
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ShuffleDeck(tp)
end
local tg=Duel.GetMatchingGroup(Card.IsAbleToDeck,p,LOCATION_HAND,0,nil)
if tg:GetCount()>1 and tg:IsExists(Card.IsSetCard,1,nil,0xfb0) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local sg1=tg:Select(tp,Card.IsSetCard,1,1,nil,0xfb0)
Duel.ConfirmCards(1-tp,sg1)
Duel.SendtoDeck(sg1,nil,1,REASON_EFFECT)
else
local hg=Duel.GetFieldGroup(tp,LOCATION_HAND,0)
Duel.ConfirmCards(1-tp,hg)
local ct=Duel.SendtoDeck(hg,nil,0,REASON_EFFECT)
Duel.SortDecktop(tp,tp,ct)
end
end
function c12001006.acfilter(c)
return c:IsSetCard(0xfb0) and c:IsAbleToDeck()
end
function c12001006.actg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and c12001006.acfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c12001006.filter1,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
Duel.SelectTarget(tp,c12001006.acfilter,tp,LOCATION_GRAVE,0,1,1,nil)
end
function c12001006.acop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS)
local sg=g:Filter(Card.IsRelateToEffect,nil,e)
Duel.SendtoDeck(sg,nil,0,REASON_EFFECT)
end
\ No newline at end of file
--六曜的读时
function c12001007.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_NEGATE+CATEGORY_DESTROY+CATEGORY_DRAW)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
e1:SetCode(EVENT_CHAINING)
e1:SetCondition(c12001007.condition)
e1:SetTarget(c12001007.target)
e1:SetOperation(c12001007.activate)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetRange(LOCATION_GRAVE)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetCondition(c12001007.damcon)
e2:SetCost(aux.bfgcost)
e2:SetOperation(c12001007.damop)
c:RegisterEffect(e2)
end
function c12001007.indtg(e,c)
return c:IsSetCard(0xfb0)
end
function c12001007.cfilter(c)
return c:IsSetCard(0xfb0) and c:IsType(TYPE_MONSTER)
end
function c12001007.damcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c12001007.cfilter,tp,LOCATION_GRAVE,0,1,nil)
end
function c12001007.damop(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CHANGE_DAMAGE)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(1,0)
e1:SetValue(0)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
Duel.Draw(1-tp,1,REASON_EFFECT)
end
function c12001007.filter(c)
return c:IsFaceup() and c:IsSetCard(0xfb0)
end
function c12001007.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c12001007.filter,tp,LOCATION_MZONE,0,1,nil)
and re:IsActiveType(TYPE_MONSTER) and Duel.IsChainNegatable(ev)
end
function c12001007.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
if re:GetHandler():IsDestructable() and re:GetHandler():IsRelateToEffect(re) then
Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,1,0,0)
end
end
function c12001007.activate(e,tp,eg,ep,ev,re,r,rp)
if Duel.NegateActivation(ev) and re:GetHandler():IsRelateToEffect(re) then
Duel.Destroy(eg,REASON_EFFECT)
Duel.Draw(1-tp,1,REASON_EFFECT)
end
end
--六曜的梦回
function c12001008.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_ATKCHANGE)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetHintTiming(TIMING_DAMAGE_STEP)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DAMAGE_STEP)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCondition(c12001008.condition)
e1:SetTarget(c12001008.target)
e1:SetOperation(c12001008.activate)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(12001008,1))
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetRange(LOCATION_GRAVE)
e2:SetCondition(c12001008.setcon)
e2:SetTarget(c12001008.settg)
e2:SetOperation(c12001008.setop)
c:RegisterEffect(e2)
end
function c12001008.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetCurrentPhase()~=PHASE_DAMAGE or not Duel.IsDamageCalculated()
end
function c12001008.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsFaceup() and chkc:IsSetCard(0xfb0) end
if chk==0 then return Duel.IsExistingTarget(c,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SelectTarget(tp,Card.IsFaceup,tp,LOCATION_MZONE,0,1,1,nil)
end
function c12001008.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:IsFaceup() then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END)
e1:SetValue(100)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EFFECT_IMMUNE_EFFECT)
e2:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END)
e2:SetValue(c12001008.efilter)
tc:RegisterEffect(e2)
end
end
function c12001008.efilter(e,te)
return te:GetOwner()~=e:GetOwner()
end
function c12001008.cfilter(c,tp)
return c:GetSummonLocation()==LOCATION_EXTRA and c:GetPreviousControler()==1-tp
end
function c12001008.setcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c12001008.cfilter,1,nil,tp)
end
function c12001008.settg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsSSetable() end
Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,e:GetHandler(),1,0,0)
end
function c12001008.setop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsSSetable() then
Duel.SSet(tp,c)
Duel.ConfirmCards(1-tp,c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_LEAVE_FIELD_REDIRECT)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+0x47e0000)
e1:SetValue(LOCATION_REMOVED)
c:RegisterEffect(e1)
end
end
\ No newline at end of file
--六曜的先负
function c12001009.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetTarget(c12001009.target)
e1:SetOperation(c12001009.activate)
c:RegisterEffect(e1)
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(12001009,1))
e3:SetCategory(CATEGORY_SPECIAL_SUMMON)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_TO_GRAVE)
e3:SetCountLimit(1,12001100)
e3:SetCondition(c12001009.spcon)
e3:SetTarget(c12001009.sptg)
e3:SetOperation(c12001009.spop)
c:RegisterEffect(e3)
end
function c12001009.filter(c)
return c:IsSetCard(0xfb0) and c:IsType(TYPE_MONSTER) and c:IsAbleToHand()
end
function c12001009.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c12001009.filter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function c12001009.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c12001009.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
function c12001009.spcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_DECK) and c:IsReason(REASON_REVEAL)
end
function c12001009.filter1(c,e,tp)
return c:IsSetCard(0xfb0) and c:IsType(TYPE_PENDULUM) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c12001009.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c12001009.filter1(chkc,e,tp) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingTarget(c12001009.filter1,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c12001009.filter1,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end
function c12001009.spop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
end
end
\ No newline at end of file
--六曜的先胜
function c12001010.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DRAW+CATEGORY_TODECK)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,12001010+EFFECT_COUNT_CODE_OATH)
e1:SetTarget(c12001010.target)
e1:SetOperation(c12001010.activate)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(12001010,2))
e2:SetCategory(CATEGORY_DRAW+CATEGORY_DECKDES)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_TO_GRAVE)
e2:SetCountLimit(1,12001105)
e2:SetCondition(c12001010.drcon)
e2:SetTarget(c12001010.drtg)
e2:SetOperation(c12001010.drop)
c:RegisterEffect(e2)
end
function c12001010.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,3) end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(3)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,3)
Duel.SetOperationInfo(0,CATEGORY_TODECK,nil,0,tp,2)
end
function c12001010.activate(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
if Duel.Draw(p,d,REASON_EFFECT)==3 then
Duel.ShuffleHand(p)
Duel.BreakEffect()
local g=Duel.GetMatchingGroup(Card.IsAbleToDeck,p,LOCATION_HAND,0,nil)
if g:GetCount()>1 and g:IsExists(Card.IsSetCard,1,nil,0xfb0) then
Duel.Hint(HINT_SELECTMSG,p,HINTMSG_TODECK)
local sg1=g:FilterSelect(p,Card.IsSetCard,1,1,nil,0xfb0)
Duel.Hint(HINT_SELECTMSG,p,HINTMSG_TODECK)
local sg2=g:Select(p,1,1,sg1:GetFirst())
sg1:Merge(sg2)
Duel.ConfirmCards(1-p,sg1)
Duel.SendtoDeck(sg1,nil,1,REASON_EFFECT)
Duel.SortDecktop(p,p,2)
else
local hg=Duel.GetFieldGroup(p,LOCATION_HAND,0)
Duel.ConfirmCards(1-p,hg)
local ct=Duel.SendtoDeck(hg,nil,0,REASON_EFFECT)
Duel.SortDecktop(p,p,ct)
end
end
end
function c12001010.drcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_DECK) and c:IsReason(REASON_REVEAL)
end
function c12001010.drtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,2) end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(2)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,2)
Duel.SetOperationInfo(0,CATEGORY_HANDES,nil,0,tp,1)
end
function c12001010.drop(e,tp,eg,ep,ev,re,r,rp)
local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER)
if Duel.Draw(p,2,REASON_EFFECT)==2 then
Duel.ShuffleHand(tp)
Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(p,aux.TRUE,p,LOCATION_HAND,0,1,1,nil)
Duel.SendtoDeck(g,nil,1,REASON_EFFECT)
end
end
\ No newline at end of file
--六曜的友引
function c12001011.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetTarget(c12001011.target)
e1:SetOperation(c12001011.activate)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(12001011,2))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_TO_GRAVE)
e2:SetCountLimit(1,12001102)
e2:SetCondition(c12001011.spcon)
e2:SetTarget(c12001011.sptg)
e2:SetOperation(c12001011.spop)
c:RegisterEffect(e2)
end
function c12001011.filter(c)
return c:IsSetCard(0xfb0) and c:IsType(TYPE_PENDULUM) and c:IsAbleToHand()
end
function c12001011.target(e,tp,eg,ep,ev,re,r,rp,chk)
if not (Duel.CheckLocation(tp,LOCATION_PZONE,0) or Duel.CheckLocation(tp,LOCATION_PZONE,1)) then return false end
if chk==0 then return Duel.IsExistingMatchingCard(c12001011.filter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil) end
Duel.SetOperationInfo(0,HINTMSG_TOFIELD,nil,1,tp,LOCATION_DECK+LOCATION_GRAVE)
end
function c12001011.activate(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
if not Duel.CheckLocation(tp,LOCATION_PZONE,0) and not Duel.CheckLocation(tp,LOCATION_PZONE,1) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local g=Duel.SelectMatchingCard(tp,c12001011.filter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil)
if g:GetCount()>0 then
Duel.MoveToField(g:GetFirst(),tp,tp,LOCATION_SZONE,POS_FACEUP,true)
end
end
function c12001011.spcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_DECK) and c:IsReason(REASON_REVEAL)
end
function c12001011.filter1(c,e,tp)
return c:IsSetCard(0xfb0) and c:IsType(TYPE_PENDULUM) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c12001011.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c12001011.filter1,tp,LOCATION_DECK,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK)
end
function c12001011.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,c12001011.filter1,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
end
\ No newline at end of file
--六曜 流连的卡尔特
function c12001012.initial_effect(c)
--pendulum summon
aux.EnablePendulumAttribute(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(12001012,0))
e1:SetCategory(CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_PZONE)
e1:SetCountLimit(1)
e1:SetTarget(c12001012.target)
e1:SetOperation(c12001012.operation)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(12001012,1))
e2:SetCategory(CATEGORY_DRAW+CATEGORY_DECKDES)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_TO_GRAVE)
e2:SetCountLimit(1,12001112)
e2:SetCondition(c12001012.drcon)
e2:SetTarget(c12001012.drtg)
e2:SetOperation(c12001012.drop)
c:RegisterEffect(e2)
end
function c12001012.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDiscardDeck(tp,1) end
end
function c12001012.operation(e,tp,eg,ep,ev,re,r,rp)
if not Duel.IsPlayerCanDiscardDeck(tp,1) then return end
Duel.ConfirmDecktop(tp,1)
local g=Duel.GetDecktopGroup(tp,1)
local tc=g:GetFirst()
if tc:IsSetCard(0xfb0) then
Duel.DisableShuffleCheck()
Duel.SendtoGrave(g,REASON_EFFECT+REASON_REVEAL)
else
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ShuffleDeck(tp)
Duel.SendtoDeck(e:GetHandler(),nil,0,REASON_EFFECT)
end
end
function c12001012.drcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_DECK) and c:IsReason(REASON_REVEAL)
end
function c12001012.drtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(1)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
end
function c12001012.drop(e,tp,eg,ep,ev,re,r,rp)
local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER)
Duel.Draw(p,1,REASON_EFFECT)
end
\ No newline at end of file
--六曜 虚亡的克尔米
function c12001013.initial_effect(c)
--pendulum summon
aux.EnablePendulumAttribute(c)
--tohand
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(12001013,0))
e1:SetCategory(CATEGORY_TOHAND)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_PZONE)
e1:SetCountLimit(1,12001013)
e1:SetTarget(c12001013.thtg)
e1:SetOperation(c12001013.thop)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(12001013,2))
e2:SetCategory(CATEGORY_DRAW+CATEGORY_DECKDES)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_TO_GRAVE)
e2:SetCountLimit(1,12001113)
e2:SetCondition(c12001013.necon)
e2:SetOperation(c12001013.neop)
c:RegisterEffect(e2)
end
function c12001013.thfilter(c)
return c:IsFaceup() and c:IsSetCard(0xfb0) and c:IsType(TYPE_PENDULUM) and c:IsAbleToHand()
end
function c12001013.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c12001013.thfilter,tp,LOCATION_EXTRA,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_EXTRA)
end
function c12001013.thop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c12001013.thfilter,tp,LOCATION_EXTRA,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
function c12001013.necon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_DECK) and c:IsReason(REASON_REVEAL)
end
function c12001013.filter(c)
return c:IsFaceup() and (c:IsLocation(LOCATION_SZONE) or c:IsType(TYPE_EFFECT)) and not c:IsDisabled()
end
function c12001013.neop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local g=Duel.GetMatchingGroup(c12001013.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,c)
local tc=g:GetFirst()
while tc do
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e2)
tc=g:GetNext()
end
end
\ No newline at end of file
--六曜 虚亡的克尔米
function c12001015.initial_effect(c)
--pendulum summon
aux.EnablePendulumAttribute(c)
--spsummon
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_PZONE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCountLimit(1)
e1:SetTarget(c12001015.sptg)
e1:SetOperation(c12001015.spop)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(12001015,2))
e2:SetCategory(CATEGORY_DRAW+CATEGORY_DECKDES)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_TO_GRAVE)
e2:SetCountLimit(1,12001015)
e2:SetCondition(c12001015.necon)
e2:SetTarget(c12001015.tptar)
e2:SetOperation(c12001015.tpop)
c:RegisterEffect(e2)
end
function c12001015.filter(c,e,tp)
return c:IsSetCard(0xfb0) and c:IsType(TYPE_PENDULUM) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c12001015.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c12001015.filter(chkc,e,tp) end
if chk==0 then return Duel.IsExistingTarget(c12001015.filter,tp,LOCATION_GRAVE,0,1,nil,e,tp)
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c12001015.filter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end
function c12001015.spop(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) and Duel.SpecialSummonStep(tc,0,tp,tp,false,false,POS_FACEUP) then
local fid=c:GetFieldID()
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetReset(RESET_EVENT+0x1fe0000)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e2:SetReset(RESET_EVENT+0x1fe0000)
tc:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_CANNOT_ATTACK)
e3:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e3:SetReset(RESET_EVENT+0x1fe0000)
tc:RegisterEffect(e3)
tc:RegisterFlagEffect(12001015,RESET_EVENT+0x1fe0000,0,1,fid)
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e4:SetCode(EVENT_PHASE+PHASE_END)
e4:SetCountLimit(1)
e4:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e4:SetLabel(fid)
e4:SetLabelObject(tc)
e4:SetCondition(c12001015.descon)
e4:SetOperation(c12001015.desop)
Duel.RegisterEffect(e4,tp)
end
Duel.SpecialSummonComplete()
end
function c12001015.descon(e,tp,eg,ep,ev,re,r,rp)
local tc=e:GetLabelObject()
if tc:GetFlagEffectLabel(12001015)==e:GetLabel() then
return true
else
e:Reset()
return false
end
end
function c12001015.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=e:GetLabelObject()
Duel.Destroy(tc,REASON_EFFECT)
end
function c12001015.necon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_DECK) and c:IsReason(REASON_REVEAL)
end
function c12001015.tptar(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if not (Duel.CheckLocation(tp,LOCATION_PZONE,0) or Duel.CheckLocation(tp,LOCATION_PZONE,1)) then return false end
if chk==0 then return Duel.IsExistingMatchingCard(c12001015.tpfilter,tp,LOCATION_EXTRA+LOCATION_GRAVE,0,1,nil) and (Duel.CheckLocation(tp,LOCATION_PZONE,0) or Duel.CheckLocation(tp,LOCATION_PZONE,1)) end
end
function c12001015.tpfilter(c)
return c:IsSetCard(0xfb0) and c:IsType(TYPE_PENDULUM) and c:IsFaceup()
end
function c12001015.tpop(e,tp,eg,ep,ev,re,r,rp)
if not (Duel.CheckLocation(tp,LOCATION_PZONE,0) or Duel.CheckLocation(tp,LOCATION_PZONE,1)) then return false end
if Duel.CheckLocation(tp,LOCATION_PZONE,0) and Duel.IsExistingMatchingCard(c12001015.tpfilter,tp,LOCATION_EXTRA+LOCATION_GRAVE,0,1,e:GetHandler()) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local g=Duel.SelectMatchingCard(tp,c12001015.tpfilter,tp,LOCATION_EXTRA+LOCATION_GRAVE,0,1,1,e:GetHandler())
Duel.MoveToField(g:GetFirst(),tp,tp,LOCATION_SZONE,POS_FACEUP, true)
end
if Duel.CheckLocation(tp,LOCATION_PZONE,1) and Duel.IsExistingMatchingCard(c12001015.tpfilter,tp,LOCATION_EXTRA+LOCATION_GRAVE,0,1,e:GetHandler()) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local g=Duel.SelectMatchingCard(tp,c12001015.tpfilter,tp,LOCATION_EXTRA+LOCATION_GRAVE,0,1,1,e:GetHandler())
Duel.MoveToField(g:GetFirst(),tp,tp,LOCATION_SZONE,POS_FACEUP, true)
end
end
\ No newline at end of file
--六曜的先导
function c12001016.initial_effect(c)
end
--六曜的卡莲思特
function c12001021.initial_effect(c)
--link summon
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsType,TYPE_EFFECT),2)
c:EnableReviveLimit()
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(12001021,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DAMAGE_STEP)
e1:SetCondition(c12001021.descon)
e1:SetTarget(c12001021.sptg)
e1:SetValue(c12001021.repval)
e1:SetOperation(c12001021.spop)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_MATERIAL_CHECK)
e2:SetValue(c12001021.valcheck)
e2:SetLabelObject(e1)
c:RegisterEffect(e2)
end
function c12001021.descon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_LINK and e:GetLabel()==1
end
function c12001021.valcheck(e,c)
local g=c:GetMaterial()
if g:IsExists(Card.IsType,1,nil,TYPE_PENDULUM) then
e:GetLabelObject():SetLabel(1)
else
e:GetLabelObject():SetLabel(0)
end
end
function c12001021.filter(c,e,tp,zone)
return c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP,tp,zone) and c:IsFaceup()
end
function c12001021.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local zone=e:GetHandler():GetLinkedZone()
if chkc then return chkc:IsLocation(LOCATION_EXTRA) and chkc:IsControler(tp) and c12001021.filter(chkc,e,tp,zone) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and zone~=0
and Duel.IsExistingTarget(c12001021.filter,tp,LOCATION_EXTRA,0,1,nil,e,tp,zone) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c12001021.filter,tp,LOCATION_EXTRA,0,1,1,nil,e,tp,zone)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end
function c12001021.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local zone=c:GetLinkedZone()
if zone==0 then return end
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP,zone)
end
end
\ No newline at end of file
--六曜的虹光丘儿
function c12001022.initial_effect(c)
--link summon
aux.AddLinkProcedure(c,c12001022.matfilter,2)
c:EnableReviveLimit()
--to hand
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(12001022,0))
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCountLimit(1)
e1:SetTarget(c12001022.target)
e1:SetOperation(c12001022.operation)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_DESTROY_REPLACE)
e2:SetRange(LOCATION_MZONE)
e2:SetTarget(c12001022.desreptg)
e2:SetValue(c12001022.desrepval)
e2:SetOperation(c12001022.desrepop)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
e3:SetValue(1)
e3:SetReset(RESET_EVENT+0x1fe0000)
c:RegisterEffect(e3)
end
function c12001022.repfilter(c,tp)
return c:IsControler(tp) and c:IsLocation(LOCATION_ONFIELD)
and c:IsReason(REASON_BATTLE+REASON_EFFECT) and not c:IsReason(REASON_REPLACE)
end
function c12001022.desfilter(c,tp)
return c:IsControler(tp) and c:IsType(TYPE_MONSTER)
and not c:IsStatus(STATUS_DESTROY_CONFIRMED+STATUS_BATTLE_DESTROYED)
end
function c12001022.desreptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
local g=c:GetLinkedGroup()
if chk==0 then return eg:IsExists(c12001022.repfilter,1,nil,tp)
and g:IsExists(c12001022.desfilter,1,nil,tp) end
if Duel.SelectEffectYesNo(tp,c,96) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESREPLACE)
local sg=g:FilterSelect(tp,c12001022.desfilter,1,1,nil,tp)
e:SetLabelObject(sg:GetFirst())
Duel.HintSelection(sg)
sg:GetFirst():SetStatus(STATUS_DESTROY_CONFIRMED,true)
return true
else return false end
end
function c12001022.desrepval(e,c)
return c12001022.repfilter(c,e:GetHandlerPlayer())
end
function c12001022.desrepop(e,tp,eg,ep,ev,re,r,rp)
local tc=e:GetLabelObject()
tc:SetStatus(STATUS_DESTROY_CONFIRMED,false)
Duel.Destroy(tc,REASON_EFFECT+REASON_REPLACE)
end
function c12001022.matfilter(c)
return c:IsSetCard(0xfb0)
end
function c12001022.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDiscardDeck(tp,1) end
end
function c12001022.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not Duel.IsPlayerCanDiscardDeck(tp,1) then return end
Duel.ConfirmDecktop(tp,1)
local g=Duel.GetDecktopGroup(tp,1)
local tc=g:GetFirst()
if tc:IsSetCard(0xfb0) then
Duel.DisableShuffleCheck()
Duel.SendtoGrave(g,REASON_EFFECT+REASON_REVEAL)
local p=c:GetControler()
local zone=bit.band(c:GetLinkedZone(),0x1f)
if Duel.GetLocationCount(p,LOCATION_MZONE,p,LOCATION_REASON_CONTROL,zone)>0
and Duel.SelectYesNo(tp,aux.Stringid(12001022,1)) then
Duel.BreakEffect()
local s=0
if c:IsControler(tp) then
local flag=bit.bxor(zone,0xff)
Duel.Hint(HINT_SELECTMSG,tp,571)
s=Duel.SelectDisableField(tp,1,LOCATION_MZONE,0,flag)
else
local flag=bit.bxor(zone,0xff)*0x10000
Duel.Hint(HINT_SELECTMSG,tp,571)
s=Duel.SelectDisableField(tp,1,0,LOCATION_MZONE,flag)/0x10000
end
local nseq=0
if s==1 then nseq=0
elseif s==2 then nseq=1
elseif s==4 then nseq=2
elseif s==8 then nseq=3
else nseq=4 end
Duel.MoveSequence(c,nseq)
end
else
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ShuffleDeck(nil)
end
end
\ No newline at end of file
--六曜的霓虹丘儿
function c12001023.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(12001023,0))
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(aux.SynCondition(nil,aux.NonTuner(c12001023.ntfilter),1,99))
e1:SetTarget(aux.SynTarget(nil,aux.NonTuner(c12001023.ntfilter),1,99))
e1:SetOperation(aux.SynOperation(nil,aux.NonTuner(c12001023.ntfilter),1,99))
e1:SetValue(SUMMON_TYPE_SYNCHRO)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetDescription(aux.Stringid(12001023,1))
e2:SetCondition(c12001023.syncon)
e2:SetTarget(c12001023.syntg)
e2:SetOperation(c12001023.synop)
e2:SetValue(SUMMON_TYPE_SYNCHRO)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(12001023,3))
e3:SetCategory(CATEGORY_NEGATE)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetRange(LOCATION_MZONE)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
e3:SetCode(EVENT_CHAINING)
e3:SetCondition(c12001023.discon)
e3:SetTarget(c12001023.distg)
e3:SetOperation(c12001023.disop)
c:RegisterEffect(e3)
local e5=Effect.CreateEffect(c)
e5:SetDescription(aux.Stringid(12001023,4))
e5:SetCategory(CATEGORY_DESTROY+CATEGORY_TOHAND+CATEGORY_SEARCH)
e5:SetType(EFFECT_TYPE_IGNITION)
e5:SetRange(LOCATION_MZONE)
e5:SetCountLimit(1)
e5:SetTarget(c12001023.destg)
e5:SetOperation(c12001023.desop)
c:RegisterEffect(e5)
end
function c12001023.ntfilter(c)
return c:IsFaceup() and c:IsSetCard(0xfb0) and c:IsCanBeSynchroMaterial()
end
function c12001023.matfilter1(c,syncard)
return c:IsType(TYPE_PENDULUM) and c:GetSummonType()==SUMMON_TYPE_PENDULUM and c:IsNotTuner() and c:IsFaceup() and c:IsCanBeSynchroMaterial(syncard)
and Duel.IsExistingMatchingCard(c12001023.matfilter2,0,LOCATION_MZONE,LOCATION_MZONE,1,c,syncard)
end
function c12001023.matfilter2(c,syncard)
return c:IsNotTuner() and c:IsFaceup() and c:IsSetCard(0xfb0) and c:IsCanBeSynchroMaterial(syncard)
end
function c12001023.synfilter(c,syncard,lv,g2,minc)
local tlv=c:GetSynchroLevel(syncard)
if lv-tlv<=0 then return false end
local g=g2:Clone()
g:RemoveCard(c)
return g:CheckWithSumEqual(Card.GetSynchroLevel,lv-tlv,minc-1,63,syncard)
end
function c12001023.syncon(e,c,tuner,mg)
if c==nil then return true end
if c:IsType(TYPE_PENDULUM) and c:IsFaceup() then return false end
local tp=c:GetControler()
local ct=-Duel.GetLocationCount(tp,LOCATION_MZONE)
local minc=2
if minc<ct then minc=ct end
local g1=nil
local g2=nil
if mg then
g1=mg:Filter(c12001023.matfilter1,nil,c)
g2=mg:Filter(c12001023.matfilter2,nil,c)
else
g1=Duel.GetMatchingGroup(c12001023.matfilter1,tp,LOCATION_MZONE,LOCATION_MZONE,nil,c)
g2=Duel.GetMatchingGroup(c12001023.matfilter2,tp,LOCATION_MZONE,LOCATION_MZONE,nil,c)
end
local pe=Duel.IsPlayerAffectedByEffect(tp,EFFECT_MUST_BE_SMATERIAL)
local lv=c:GetLevel()
if tuner then
return c12001023.synfilter(tuner,c,lv,g2,minc)
end
if not pe then
return g1:IsExists(c12001023.synfilter,1,nil,c,lv,g2,minc)
else
return c12001023.synfilter(pe:GetOwner(),c,lv,g2,minc)
end
end
function c12001023.syntg(e,tp,eg,ep,ev,re,r,rp,chk,c,tuner,mg)
local g=Group.CreateGroup()
local g1=nil
local g2=nil
if mg then
g1=mg:Filter(c12001023.matfilter1,nil,c)
g2=mg:Filter(c12001023.matfilter2,nil,c)
else
g1=Duel.GetMatchingGroup(c12001023.matfilter1,tp,LOCATION_MZONE,LOCATION_MZONE,nil,c)
g2=Duel.GetMatchingGroup(c12001023.matfilter2,tp,LOCATION_MZONE,LOCATION_MZONE,nil,c)
end
local ct=-Duel.GetLocationCount(tp,LOCATION_MZONE)
local minc=2
if minc<ct then minc=ct end
local pe=Duel.IsPlayerAffectedByEffect(tp,EFFECT_MUST_BE_SMATERIAL)
local lv=c:GetLevel()
if tuner then
g:AddCard(tuner)
g2:RemoveCard(tuner)
local lv1=tuner:GetSynchroLevel(c)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SMATERIAL)
local m2=g2:SelectWithSumEqual(tp,Card.GetSynchroLevel,lv-lv1,minc-1,63,c)
g:Merge(m2)
else
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SMATERIAL)
local tuner=nil
if not pe then
local t1=g1:FilterSelect(tp,c12001023.synfilter,1,1,nil,c,lv,g2,minc)
tuner=t1:GetFirst()
else
tuner=pe:GetOwner()
Group.FromCards(tuner):Select(tp,1,1,nil)
end
tuner:RegisterFlagEffect(12001023,RESET_EVENT+0x1fe0000,0,1)
g:AddCard(tuner)
g2:RemoveCard(tuner)
local lv1=tuner:GetSynchroLevel(c)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SMATERIAL)
local m2=g2:SelectWithSumEqual(tp,Card.GetSynchroLevel,lv-lv1,minc-1,63,c)
g:Merge(m2)
end
if g then
g:KeepAlive()
e:SetLabelObject(g)
return true
else return false end
end
function c12001023.synop(e,tp,eg,ep,ev,re,r,rp,c,tuner,mg)
local g=e:GetLabelObject()
c:SetMaterial(g)
Duel.SendtoGrave(g,REASON_MATERIAL+REASON_SYNCHRO)
g:DeleteGroup()
end
function c12001023.discon(e,tp,eg,ep,ev,re,r,rp)
return re:GetHandler():IsSetCard(0xfb0) and not re:GetHandler():IsCode(12001023) and Duel.IsChainNegatable(ev) and Duel.GetTurnPlayer()~=tp
end
function c12001023.distg1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDiscardDeck(tp,1) end
end
function c12001023.distg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
local ng=Group.CreateGroup()
for i=1,ev do
local te=Duel.GetChainInfo(i,CHAININFO_TRIGGERING_EFFECT)
local tc=te:GetHandler()
ng:AddCard(tc)
end
Duel.SetOperationInfo(0,CATEGORY_NEGATE,ng,ng:GetCount(),0,0)
end
function c12001023.disop(e,tp,eg,ep,ev,re,r,rp)
if not Duel.IsPlayerCanDiscardDeck(tp,1) then return end
Duel.ConfirmDecktop(tp,1)
local g=Duel.GetDecktopGroup(tp,1)
local tc=g:GetFirst()
if tc:IsSetCard(0xfb0) then
Duel.DisableShuffleCheck()
Duel.SendtoGrave(g,REASON_EFFECT+REASON_REVEAL)
if not e:GetHandler():IsRelateToEffect(e) then return end
for i=1,ev do
local te=Duel.GetChainInfo(i,CHAININFO_TRIGGERING_EFFECT)
if te:GetOwnerPlayer()~=tp then
Duel.NegateActivation(i)
end
Duel.Destroy(e:GetHandler(),REASON_EFFECT)
end
else
Duel.SendtoGrave(g,REASON_EFFECT+REASON_REVEAL)
Duel.ShuffleDeck(nil)
end
end
function c12001023.thfilter(c)
return c:IsSetCard(0xfb0) and c:IsType(TYPE_TRAP) and c:IsAbleToHand()
end
function c12001023.destg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(nil,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,e:GetHandler())
and Duel.IsExistingMatchingCard(c12001023.thfilter,tp,LOCATION_DECK,0,1,nil) end
local g=Duel.GetMatchingGroup(nil,tp,LOCATION_HAND+LOCATION_ONFIELD,0,e:GetHandler())
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function c12001023.desop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectMatchingCard(tp,nil,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,1,e:GetHandler())
if g:GetCount()>0 and Duel.Destroy(g,REASON_EFFECT)~=0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c12001023.thfilter,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
\ No newline at end of file
--六曜的牙月丘儿
function c12001024.initial_effect(c)
--fusion material
c:EnableReviveLimit()
aux.AddFusionProcFun2(c,aux.FilterBoolFunction(Card.IsFusionSetCard,0xfba),c12001024.ffilter,true)
--special summon rule
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_EXTRA)
e1:SetCondition(c12001024.spcon)
e1:SetOperation(c12001024.spop)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(12001024,0))
e2:SetCategory(CATEGORY_REMOVE)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetCountLimit(1,12001024)
e2:SetTarget(c12001024.settg)
e2:SetOperation(c12001024.setop)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(12001024,1))
e3:SetCategory(CATEGORY_NEGATE+CATEGORY_DESTROY)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetRange(LOCATION_MZONE)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
e3:SetCode(EVENT_CHAINING)
e3:SetCountLimit(2)
e3:SetCondition(c12001024.discon)
e3:SetTarget(c12001024.distg)
e3:SetOperation(c12001024.disop)
c:RegisterEffect(e3)
end
function c12001024.matfilter(c)
return c:IsSetCard(0xfb0) and c:IsReleasable() and c:IsFaceup()
end
function c12001024.cfilter1(c,tp,g)
return c:IsFaceup()
end
function c12001024.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
local g=Duel.GetMatchingGroup(c12001024.matfilter,tp,LOCATION_MZONE,0,nil)
return g:IsExists(c12001024.cfilter1,2,nil,tp,g)
end
function c12001024.spop(e,tp,eg,ep,ev,re,r,rp,c)
local g=Duel.GetMatchingGroup(c12001024.matfilter,tp,LOCATION_MZONE,0,nil)
local g1=g:FilterSelect(tp,c12001024.cfilter1,2,2,nil,tp,g)
Duel.Release(g1,POS_FACEUP,REASON_COST)
end
function c12001024.filter(c)
return c:IsSetCard(0xfb0) and c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsSSetable()
end
function c12001024.settg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0
and Duel.IsExistingMatchingCard(c12001024.filter,tp,LOCATION_DECK,0,1,nil) end
end
function c12001024.setop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET)
local g=Duel.SelectMatchingCard(tp,c12001024.filter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
Duel.SSet(tp,g:GetFirst())
Duel.ConfirmCards(1-tp,g)
end
end
function c12001024.discon(e,tp,eg,ep,ev,re,r,rp)
return not e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED)
and re:IsHasType(EFFECT_TYPE_ACTIVATE) and Duel.IsChainNegatable(ev)
end
function c12001024.distg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
if re:GetHandler():IsDestructable() and re:GetHandler():IsRelateToEffect(re) then
Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,1,0,0)
end
end
function c12001024.disop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsFaceup() or not c:IsRelateToEffect(e) then return end
if Duel.NegateActivation(ev) and re:GetHandler():IsRelateToEffect(re) then
Duel.Destroy(eg,REASON_EFFECT)
Duel.Destroy(c,REASON_EFFECT)
end
end
--六曜的新源丘儿
function c12001025.initial_effect(c)
--xyz summon
aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xfb0),4,2)
c:EnableReviveLimit()
--
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(12001025,0))
e1:SetCategory(CATEGORY_NEGATE)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e1:SetRange(LOCATION_MZONE)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCost(c12001025.cost)
e1:SetTarget(c12001025.distg3)
e1:SetOperation(c12001025.disop)
c:RegisterEffect(e1)
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e4:SetRange(LOCATION_MZONE)
e4:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e4:SetValue(1)
c:RegisterEffect(e4)
end
function c12001025.cost(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 c12001025.filter3(c)
return c:IsFaceup() and not c:IsSetCard(0xfb0)
end
function c12001025.distg3(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return eg:IsExists(c12001025.filter3,1,nil) end
local g=eg:Filter(c12001025.filter3,nil)
Duel.SetTargetCard(g)
Duel.SetOperationInfo(0,CATEGORY_DISABLE,g,g:GetCount(),0,0)
end
function c12001025.disop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if c:IsFaceup() and c:IsRelateToEffect(e) and tc:IsFaceup() and tc:IsRelateToEffect(e) and tc:IsType(TYPE_EFFECT) then
c:SetCardTarget(tc)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE+EFFECT_FLAG_OWNER_RELATE+EFFECT_FLAG_CANNOT_DISABLE)
e1:SetRange(LOCATION_MZONE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+0x1fe0000)
e1:SetCondition(c12001025.rcon)
tc:RegisterEffect(e1,true)
local e2=e1:Clone()
e2:SetCode(EFFECT_CANNOT_CHANGE_POSITION)
tc:RegisterEffect(e2,true)
end
end
function c12001025.rcon(e)
return e:GetOwner():IsHasCardTarget(e:GetHandler())
end
\ No newline at end of file
......@@ -38,7 +38,7 @@ function c13257215.initial_effect(c)
c:RegisterEffect(e3)
--remove
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(13257203,1))
e4:SetDescription(aux.Stringid(13257215,2))
e4:SetType(EFFECT_TYPE_QUICK_O)
e4:SetCode(EVENT_FREE_CHAIN)
e4:SetRange(LOCATION_MZONE)
......
......@@ -39,8 +39,12 @@ function c13257219.initial_effect(c)
local e13=e12:Clone()
e13:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e13)
Duel.AddCustomActivityCounter(13257219,ACTIVITY_SPSUMMON,c13257219.counterfilter)
end
function c13257219.counterfilter(c)
return c:GetSummonLocation()~=LOCATION_EXTRA
end
function c13257219.cost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:IsAbleToGraveAsCost() and c:IsDiscardable() end
......@@ -91,7 +95,7 @@ function c13257219.thop(e,tp,eg,ep,ev,re,r,rp)
end
end
function c13257219.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,nil) and Duel.GetActivityCount(tp,ACTIVITY_SPSUMMON)==0 end
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,nil) and Duel.GetCustomActivityCount(13257219,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)
......
--B.E.S 寄生核心
function c13257225.initial_effect(c)
c:EnableCounterPermit(0x1f)
local e11=Effect.CreateEffect(c)
e11:SetDescription(aux.Stringid(13257225,1))
e11:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e11:SetType(EFFECT_TYPE_SINGLE)
e11:SetCode(EFFECT_SUMMON_PROC)
e11:SetCondition(c13257225.otcon)
e11:SetOperation(c13257225.otop)
e11:SetValue(SUMMON_TYPE_ADVANCE)
c:RegisterEffect(e11)
--Destroy replace
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DESTROY_REPLACE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_MZONE)
e1:SetTarget(c13257225.desreptg)
e1:SetOperation(c13257225.desrepop)
c:RegisterEffect(e1)
--counter
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_COUNTER)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_SUMMON_SUCCESS)
e2:SetOperation(c13257225.ctop)
c:RegisterEffect(e2)
local e3=e2:Clone()
e3:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(13257225,2))
e4:SetCategory(CATEGORY_DISABLE)
e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e4:SetCode(EVENT_PHASE+PHASE_END)
e4:SetRange(LOCATION_MZONE)
e4:SetCountLimit(1)
e4:SetOperation(c13257225.negop)
c:RegisterEffect(e4)
local e5=Effect.CreateEffect(c)
e5:SetDescription(aux.Stringid(13257225,3))
e5:SetCategory(CATEGORY_TODECK)
e5:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE)
e5:SetType(EFFECT_TYPE_QUICK_O)
e5:SetCode(EVENT_CHAINING)
e5:SetRange(LOCATION_MZONE)
e5:SetCountLimit(1)
e5:SetCondition(c13257225.tdcon)
e5:SetTarget(c13257225.tdtg)
e5:SetOperation(c13257225.tdop)
c:RegisterEffect(e5)
local e12=Effect.CreateEffect(c)
e12:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e12:SetCode(EVENT_SUMMON_SUCCESS)
e12:SetOperation(c13257225.bgmop)
c:RegisterEffect(e12)
local e13=e12:Clone()
e13:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e13)
end
function c13257225.otfilter(c)
return c:IsType(TYPE_MONSTER) and c:IsReleasable()
end
function c13257225.otcon(e,c,minc)
if c==nil then return true end
local tp=c:GetControler()
local mg=Duel.GetMatchingGroup(c13257225.otfilter,tp,LOCATION_HAND,0,c)
return mg:GetCount()>=1
end
function c13257225.otop(e,tp,eg,ep,ev,re,r,rp,c)
local mg=Duel.GetMatchingGroup(c13257225.otfilter,tp,LOCATION_HAND,0,c)
local sg=mg:Select(tp,1,1,nil)
c:SetMaterial(sg)
Duel.Release(sg,REASON_SUMMON+REASON_MATERIAL)
end
function c13257225.desreptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsReason(REASON_EFFECT+REASON_BATTLE)
and e:GetHandler():GetCounter(0x1f)>0 end
return true
end
function c13257225.desrepop(e,tp,eg,ep,ev,re,r,rp)
e:GetHandler():RemoveCounter(ep,0x1f,1,REASON_EFFECT)
end
function c13257225.ctop(e,tp,eg,ep,ev,re,r,rp)
e:GetHandler():AddCounter(0x1f,3)
end
function c13257225.filter(c)
return c:IsFaceup() and c:IsType(TYPE_EFFECT) and not c:IsDisabled()
end
function c13257225.negop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local g=Duel.GetMatchingGroup(c13257225.filter,tp,LOCATION_MZONE,LOCATION_MZONE,nil)
local tc=g:GetFirst()
while tc do
local e6=Effect.CreateEffect(c)
e6:SetType(EFFECT_TYPE_SINGLE)
e6:SetCode(EFFECT_DISABLE)
e6:SetReset(RESET_EVENT+0x1fe0000)
tc:RegisterEffect(e6)
local e7=Effect.CreateEffect(c)
e7:SetType(EFFECT_TYPE_SINGLE)
e7:SetCode(EFFECT_DISABLE_EFFECT)
e7:SetReset(RESET_EVENT+0x1fe0000)
tc:RegisterEffect(e7)
tc=g:GetNext()
end
end
function c13257225.tdcon(e,tp,eg,ep,ev,re,r,rp)
return ep~=tp and e:GetHandler():GetCounter(0x1f)==0
end
function c13257225.tdtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return re:GetHandler():IsAbleToDeck() end
Duel.SetOperationInfo(0,CATEGORY_TODECK,eg,1,0,0)
end
function c13257225.tdop(e,tp,eg,ep,ev,re,r,rp)
if re:GetHandler():IsRelateToEffect(re) then
Duel.SendtoDeck(eg,nil,2,REASON_EFFECT)
end
end
function c13257225.bgmop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(11,0,aux.Stringid(13257225,4))
end
This diff is collapsed.
......@@ -108,6 +108,8 @@ function c13257308.desop(e,tp,eg,ep,ev,re,r,rp)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetValue(RESET_EVENT+0x1fe0000)
tc:RegisterEffect(e2)
Duel.AdjustInstantly()
Duel.NegateRelatedChain(tc,RESET_TURN_SET)
end
tc=g:GetNext()
end
......
This diff is collapsed.
This diff is collapsed.
--逆行贝琳
function c17060907.initial_effect(c)
c:EnableReviveLimit()
aux.AddLinkProcedure(c,c17060907.matfilter,1)
--extra summon
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_EXTRA_SUMMON_COUNT)
e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(LOCATION_HAND+LOCATION_MZONE,0)
e1:SetTarget(c17060907.sumtg)
c:RegisterEffect(e1)
--atk
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_UPDATE_ATTACK)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetRange(LOCATION_MZONE)
e2:SetValue(c17060907.atkval)
c:RegisterEffect(e2)
end
function c17060907.matfilter(c)
return c:GetLevel()==1 and c:IsType(TYPE_PENDULUM)
end
function c17060907.sumtg(e,c)
return c:IsType(TYPE_PENDULUM)
end
function c17060907.atkval(e,c)
local g=e:GetHandler():GetLinkedGroup()
if g:GetCount()==0 then
return 0
else
local tg,val=g:GetMaxGroup(Card.GetBaseAttack)
return val/2
end
end
\ No newline at end of file
--歌剧三妖精
function c17060908.initial_effect(c)
c:EnableReviveLimit()
aux.AddLinkProcedure(c,c17060908.linkfilter,3,3)
--spsummon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(17060908,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,0x1c0)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,17060908)
e1:SetCost(c17060908.spcost)
e1:SetTarget(c17060908.sptg)
e1:SetOperation(c17060908.spop)
c:RegisterEffect(e1)
end
c17060908.is_named_with_Opera_type=1
function c17060908.IsOpera_type(c)
local m=_G["c"..c:GetCode()]
return m and m.is_named_with_Opera_type
end
function c17060908.linkfilter(c)
return c17060908.IsOpera_type(c)
end
function c17060908.cfilter(c,g)
return g:IsContains(c) and not c:IsStatus(STATUS_BATTLE_DESTROYED)
end
function c17060908.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
local lg=e:GetHandler():GetLinkedGroup()
if chk==0 then return Duel.CheckReleaseGroup(tp,c17060908.cfilter,1,nil,lg) end
local g=Duel.SelectReleaseGroup(tp,c17060908.cfilter,1,1,nil,lg)
Duel.Release(g,REASON_COST)
end
function c17060908.filter(c,e,tp,m)
if bit.band(c:GetOriginalType(),0x81)~=0x81
or not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true) then return false end
if c.mat_filter then
m=m:Filter(c.mat_filter,nil)
end
return m:CheckWithSumEqual(Card.GetRitualLevel,c:GetLevel(),1,99,c)
end
function c17060908.matfilter(c)
return c:IsType(TYPE_PENDULUM) and c:IsAbleToGrave()
end
function c17060908.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return false end
local mg=Duel.GetMatchingGroup(c17060908.matfilter,tp,LOCATION_DECK,0,nil)
return Duel.IsExistingMatchingCard(c17060908.filter,tp,LOCATION_PZONE,0,1,nil,e,tp,mg)
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_PZONE)
end
function c17060908.spop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
local mg=Duel.GetMatchingGroup(c17060908.matfilter,tp,LOCATION_DECK,0,nil)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tg=Duel.SelectMatchingCard(tp,c17060908.filter,tp,LOCATION_PZONE,0,1,1,nil,e,tp,mg)
if tg:GetCount()>0 then
local tc=tg:GetFirst()
if tc.mat_filter then
mg=mg:Filter(tc.mat_filter,nil)
end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local mat=mg:SelectWithSumEqual(tp,Card.GetRitualLevel,tc:GetLevel(),1,99,tc)
tc:SetMaterial(mat)
Duel.SendtoGrave(mat,REASON_EFFECT+REASON_MATERIAL+REASON_RITUAL)
Duel.BreakEffect()
Duel.SpecialSummon(tc,SUMMON_TYPE_RITUAL,tp,tp,false,true,POS_FACEUP)
tc:CompleteProcedure()
end
end
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
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