Commit a7c77106 authored by POLYMER's avatar POLYMER

delete mtc cards

parent 03357121
No preview for this file type
--机锋的罪人 卡特斯罗特
local cm,m,o=GetID()
function cm.initial_effect(c)
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e0:SetCode(EVENT_TO_HAND)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetOperation(cm.op0)
c:RegisterEffect(e0)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(cm.con1)
c:RegisterEffect(e1)
--spsummon proc
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_DECK)
e1:SetCondition(cm.spcon)
e1:SetTarget(cm.sptg)
e1:SetOperation(cm.spop)
e1:SetValue(SUMMON_VALUE_SELF)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_SUMMON_PROC)
e2:SetValue(SUMMON_TYPE_ADVANCE)
e2:SetCondition(cm.con2)
e2:SetOperation(cm.op2)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_DRAW)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
e3:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CAN_FORBIDDEN)
e3:SetCode(EVENT_SUMMON_SUCCESS)
e3:SetOperation(cm.op3)
c:RegisterEffect(e3)
local e4=e3:Clone()
e4:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e4)
local e5=Effect.CreateEffect(c)
e5:SetCategory(CATEGORY_DAMAGE+CATEGORY_ATKCHANGE)
e5:SetType(EFFECT_TYPE_IGNITION)
e5:SetRange(LOCATION_MZONE)
e5:SetCountLimit(1)
e5:SetCost(cm.cos5)
e5:SetTarget(cm.tg5)
e5:SetOperation(cm.op5)
c:RegisterEffect(e5)
end
function cm.spfilter(c)
return aux.IsCodeListed(c,m) and c:IsDiscardable()
end
function cm.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_HAND,0,1,c)
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk,c)
local g=Duel.GetMatchingGroup(cm.spfilter,tp,LOCATION_HAND,0,c)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD)
local tc=g:SelectUnselect(nil,tp,false,true,1,1)
if tc then
e:SetLabelObject(tc)
return true
else return false end
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp,c)
local g=e:GetLabelObject()
Duel.SendtoGrave(g,REASON_SPSUMMON+REASON_DISCARD)
end
--e0
function cm.op0(e,tp,eg,ep,ev,re,r,rp)
if e:GetHandler():GetFieldID()<=172 then return end
e:GetHandler():RegisterFlagEffect(m,RESET_EVENT+RESETS_STANDARD,0,1)
end
--e1
function cm.con1(e,c)
if c==nil then return true end
return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0 and c:GetFlagEffect(m)>0
end
--e2
function cm.con2(e,c,minc)
if c==nil then return true end
return minc<=1 and Duel.CheckTribute(c,1)
end
function cm.op2(e,tp,eg,ep,ev,re,r,rp,c)
g=Duel.SelectTribute(tp,c,1,Duel.GetFieldGroupCount(tp,LOCATION_MZONE,LOCATION_MZONE))
c:SetMaterial(g)
Duel.Release(g,REASON_SUMMON+REASON_MATERIAL)
for tc in aux.Next(g) do
if tc:IsLocation(LOCATION_GRAVE) then
tc:RegisterFlagEffect(m,RESET_EVENT+RESETS_STANDARD,0,1)
end
end
end
--e3
function cm.op3f1(c,mc)
return not aux.IsCodeListed(c,mc:GetCode())
end
function cm.op3con1f(c,tp)
return c:IsPreviousControler(tp) and (c:IsReason(REASON_COST) or c:IsReason(REASON_SUMMON+REASON_MATERIAL))
end
function cm.op3con1(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(cm.op3con1f,1,nil,tp)
end
function cm.op3op1(e,tp,eg,ep,ev,re,r,rp)
if #eg<=0 then return end
Duel.Draw(tp,#eg,REASON_EFFECT)
end
function cm.op3(e,tp,eg,ep,ev,re,r,rp)
local c,g=e:GetHandler(),Duel.GetFieldGroup(tp,LOCATION_DECK,0)
Duel.ConfirmCards(1-tp,g)
g=g:Filter(cm.op3f1,nil,c)
if g:GetClassCount(Card.GetCode)==#g then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e1:SetCode(EVENT_RELEASE)
e1:SetCondition(cm.op3con1)
e1:SetOperation(cm.op3op1)
Duel.RegisterEffect(e1,tp)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SET_SUMMON_COUNT_LIMIT)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(1,0)
e1:SetValue(8)
Duel.RegisterEffect(e1,tp)
end
end
--e5
function cm.cos5f1(c)
return c:GetFlagEffect(m)>0 and (c:IsAbleToDeckAsCost() or c:IsAbleToExtraAsCost())
end
function cm.cos5(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.cos5f1,tp,LOCATION_GRAVE,0,2,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,cm.cos5f1,tp,LOCATION_GRAVE,0,2,99,nil)
e:SetLabel(Duel.SendtoDeck(g,tp,2,REASON_COST))
end
function cm.tg5(e,tp,eg,ep,ev,re,r,rp,chk)
local dam=e:GetLabel()>2 and 4000 or 2000
if chk==0 then return true end
Duel.SetTargetPlayer(1-tp)
Duel.SetTargetParam(dam)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,dam)
end
function cm.op5(e,tp,eg,ep,ev,re,r,rp)
local dam=e:GetLabel()>2 and 4000 or 2000
if not e:GetHandler():IsRelateToEffect(e) or not e:GetHandler():IsFaceup() then return end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetValue(dam)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE)
e:GetHandler():RegisterEffect(e1)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Damage(p,d,REASON_EFFECT)
end
--沉溺花园之人
local m=60002224
local cm=_G["c"..m]
function cm.initial_effect(c)
--cannot spsummon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_DRAW)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetRange(LOCATION_HAND)
e1:SetCountLimit(1,m)
e1:SetCost(cm.drcost)
e1:SetTarget(cm.drtg)
e1:SetOperation(cm.drop)
c:RegisterEffect(e1)
--SPsummon
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TOGRAVE+CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_GRAVE)
e1:SetCountLimit(1,m+10000000)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCategory(CATEGORY_DAMAGE)
e1:SetCost(cm.cost)
e1:SetTarget(cm.target)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
end
function cm.cfilter(c)
return c:IsType(TYPE_SPELL) and c:IsDiscardable()
end
function cm.cfilter2(c)
return (c:IsType(TYPE_FIELD)) or (c:IsRace(RACE_WARRIOR) and c:IsLevel(4) and c:IsAttribute(ATTRIBUTE_LIGHT)) and c:IsDiscardable()
end
function cm.drcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsDiscardable()
and Duel.IsExistingMatchingCard(cm.cfilter,tp,LOCATION_HAND,0,1,e:GetHandler()) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD)
local g=Duel.SelectMatchingCard(tp,cm.cfilter,tp,LOCATION_HAND,0,1,1,e:GetHandler())
g:AddCard(e:GetHandler())
Duel.SendtoGrave(g,REASON_DISCARD+REASON_COST)
end
function cm.drtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.cfilter2,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function cm.drop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.cfilter2,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 cm.filter(c,tp)
return c:IsType(TYPE_FIELD) and c:GetOwner()==tp and c:IsAbleToGraveAsCost()
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_ONFIELD,0,1,nil,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,cm.filter,tp,LOCATION_ONFIELD,0,1,1,nil,tp)
e:SetLabelObject(g:GetFirst())
Duel.SendtoGrave(g,REASON_COST)
end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=e:GetLabelObject()
if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 and Duel.SelectYesNo(tp,aux.Stringid(m,1)) and tc:IsLocation(LOCATION_GRAVE) then
Duel.SSet(tp,tc,1-tp)
end
end
\ No newline at end of file
--万物的见证者·洁蒂丝
local m=60002226
local cm=_G["c"..m]
function cm.initial_effect(c)
for i=0,0xffff do
c:EnableCounterPermit(i,LOCATION_ONFIELD)
end
--race
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetCode(EFFECT_CHANGE_RACE)
e1:SetRange(0xff)
e1:SetValue(0xfffffff)
c:RegisterEffect(e1)
--att
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetCode(EFFECT_CHANGE_ATTRIBUTE)
e1:SetRange(0xff)
e1:SetValue(0xff)
c:RegisterEffect(e1)
--爆能强化
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_SUMMON_PROC)
e2:SetValue(SUMMON_TYPE_ADVANCE)
e2:SetCondition(cm.con2)
e2:SetOperation(cm.op2)
c:RegisterEffect(e2)
--进化
local e5=Effect.CreateEffect(c)
e5:SetCategory(CATEGORY_DESTROY+CATEGORY_DRAW+CATEGORY_RECOVER)
e5:SetType(EFFECT_TYPE_IGNITION)
e5:SetRange(LOCATION_MZONE)
e5:SetCountLimit(1)
e5:SetCost(cm.cos5)
e5:SetOperation(cm.op5)
c:RegisterEffect(e5)
--spsummon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,2))
e1:SetCategory(CATEGORY_SEARCH+CATEGORY_SUMMON+CATEGORY_TOHAND)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(cm.spcon)
e1:SetTarget(cm.sptg)
e1:SetOperation(cm.spop)
c:RegisterEffect(e1)
--local e1=Effect.CreateEffect(c)
--e1:SetDescription(aux.Stringid(m,3))
--e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_SUMMON)
--e1:SetType(EFFECT_TYPE_IGNITION)
--e1:SetRange(LOCATION_HAND)
--e1:SetCost(cm.spcost)
--e1:SetCondition(cm.spcon2)
--e1:SetTarget(cm.sptg)
--e1:SetOperation(cm.spop)
--c:RegisterEffect(e1)
end
if not cm.enable_all_setname then
cm.enable_all_setname=true
cm._is_set_card=Card.IsSetCard
Card.IsSetCard=function (c,...)
return c:IsOriginalCodeRule(m) or cm._is_set_card(c,...)
end
cm._is_link_set_card=Card.IsLinkSetCard
Card.IsLinkSetCard=function (c,...)
return c:IsOriginalCodeRule(m) or cm._is_link_set_card(c,...)
end
cm._is_fusion_set_card=Card.IsFusionSetCard
Card.IsFusionSetCard=function (c,...)
return c:IsOriginalCodeRule(m) or cm._is_fusion_set_card(c,...)
end
cm._is_previous_set_card=Card.IsPreviousSetCard
Card.IsPreviousSetCard=function (c,...)
return c:IsOriginalCodeRule(m) or cm._is_previous_set_card(c,...)
end
cm._is_original_set_card=Card.IsOriginalSetCard
Card.IsOriginalSetCard=function (c,...)
return c:IsOriginalCodeRule(m) or cm._is_original_set_card(c,...)
end
cm._is_code=Card.IsCode
Card.IsCode=function (c,...)
return c:IsOriginalCodeRule(m) or cm._is_code(c,...)
end
cm._is_link_code=Card.IsLinkCode
Card.IsLinkCode=function (c,...)
return c:IsOriginalCodeRule(m) or cm._is_link_code(c,...)
end
cm._is_fusion_code=Card.IsFusionCode
Card.IsFusionCode=function (c,...)
return c:IsOriginalCodeRule(m) or cm._is_fusion_code(c,...)
end
cm._is_original_code_rule=Card.IsOriginalCodeRule
Card.IsOriginalCodeRule=function (c,...)
return cm._is_original_code_rule(c,m,...)
end
cm._is_code_listed=aux.IsCodeListed
aux.IsCodeListed=function (c,code,...)
return c:IsOriginalCodeRule(m) or cm._is_code_listed(c,code,...)
end
end
function cm.con2(e,c,minc)
if c==nil then return true end
return minc<=1 and Duel.CheckTribute(c,1)
end
function cm.op2(e,tp,eg,ep,ev,re,r,rp,c)
local g=Duel.SelectTribute(tp,c,1,Duel.GetFieldGroupCount(tp,LOCATION_MZONE,LOCATION_MZONE))
c:SetMaterial(g)
Duel.Release(g,REASON_SUMMON+REASON_MATERIAL)
for tc in aux.Next(g) do
if tc:IsLocation(LOCATION_GRAVE) then
tc:RegisterFlagEffect(m,RESET_EVENT+RESETS_STANDARD,0,1)
end
end
end
function cm.cos5f1(c)
return c:GetFlagEffect(m)>0 and (c:IsAbleToDeckAsCost() or c:IsAbleToExtraAsCost())
end
function cm.cos5(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.cos5f1,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,cm.cos5f1,tp,LOCATION_GRAVE,0,1,99,nil)
e:SetLabel(Duel.SendtoDeck(g,tp,2,REASON_COST))
end
function cm.op5(e,tp,eg,ep,ev,re,r,rp)
local dam=e:GetLabel()
if not e:GetHandler():IsRelateToEffect(e) or not e:GetHandler():IsFaceup() then return end
if dam>=1 then
if Duel.IsExistingMatchingCard(aux.TRUE,tp,0,LOCATION_MZONE,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(m,1)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectMatchingCard(tp,cm.xfilter,tp,0,LOCATION_MZONE,1,1,nil)
Duel.Destroy(g:GetFirst(),REASON_EFFECT)
end
if dam>=2 then
Duel.Draw(tp,1,REASON_EFFECT)
if dam>=3 then
Duel.Recover(tp,1000,REASON_EFFECT)
if dam>=4 then
--avoid damage
local e4=Effect.CreateEffect(e:GetHandler())
e4:SetType(EFFECT_TYPE_FIELD)
e4:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e4:SetCode(EFFECT_CHANGE_DAMAGE)
e4:SetTargetRange(1,0)
e4:SetValue(cm.damval)
e4:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterFlagEffect(tp,70002169,RESET_PHASE+PHASE_END,0,2)
Duel.RegisterEffect(e4,tp)
local e4=Effect.CreateEffect(e:GetHandler())
e4:SetType(EFFECT_TYPE_FIELD)
e4:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e4:SetCode(EFFECT_NO_EFFECT_DAMAGE)
e4:SetTargetRange(1,0)
e4:SetValue(cm.damval)
e4:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterFlagEffect(tp,70002169,RESET_PHASE+PHASE_END,0,2)
Duel.RegisterEffect(e4,tp)
end
end
end
end
end
function cm.damval(e,re,val,r,rp,rc)
if bit.band(r,REASON_EFFECT)~=0 then return 0 end
return val
end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetFieldGroup(tp,LOCATION_MZONE,0)
local sg=g:Filter(Card.IsFaceup,nil)
return sg and sg:GetClassCount(Card.GetRace)>=2
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local g=Duel.GetFieldGroup(tp,LOCATION_MZONE,0):Filter(Card.IsFaceup,nil)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and
Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_DECK,0,1,nil,g) end
Duel.SetOperationInfo(0,CATEGORY_SUMMON,nil,0,0,0)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,0,0,0)
Duel.SetOperationInfo(0,CATEGORY_SEARCH,nil,0,0,0)
end
function cm.thfilter(c,g)
local sg=g
sg:AddCard(c)
if sg:GetClassCount(Card.GetRace)==#sg and sg:GetClassCount(Card.GetAttribute)==#sg then
return true
else
return false
end
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local g=Duel.GetFieldGroup(tp,LOCATION_MZONE,0):Filter(Card.IsFaceup,nil)
local ag=Duel.GetMatchingGroup(cm.thfilter,tp,LOCATION_DECK,0,nil,g)
if not c:IsRelateToEffect(e) then return end
if Duel.SendtoHand(ag,nil,REASON_EFFECT)~=0 then
Duel.Summon(tp,c,true,nil)
end
end
--function cm.spcon2(e,tp,eg,ep,ev,re,r,rp)
--local g=Duel.GetFieldGroup(tp,LOCATION_MZONE,0)
--local sg=g:Filter(Card.IsFaceup,nil)
--return sg and sg:GetClassCount(Card.GetRace)>=2 and Duel.IsExistingMatchingCard(Card.IsCode,tp,LOCATION_MZONE,0,1,nil,60002223)
--end
--function cm.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
--if chk==0 then return true end
--if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
--Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
--local g=Duel.SelectMatchingCard(tp,cm.filter,tp,LOCATION_EXTRA,0,1,1,nil,e,tp)
--if g:GetCount()>0 then
--Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
--end
--end
--function cm.filter(c,e,tp)
--return c:IsSetCard(0x5622) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
--end
--function cm.xfilter(c)
--return c:IsType(TYPE_MONSTER)
--end
--熔铁亲信
local m=60002227
local cm=_G["c"..m]
function cm.initial_effect(c)
aux.AddCodeList(c,60002223)
--爆能强化
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_SUMMON_PROC)
e2:SetValue(SUMMON_TYPE_ADVANCE)
e2:SetCondition(cm.con2)
e2:SetOperation(cm.op2)
c:RegisterEffect(e2)
--进化
local e5=Effect.CreateEffect(c)
e5:SetCategory(CATEGORY_DESTROY+CATEGORY_ATKCHANGE+CATEGORY_TOHAND+CATEGORY_SEARCH)
e5:SetType(EFFECT_TYPE_IGNITION)
e5:SetRange(LOCATION_MZONE)
e5:SetCountLimit(1)
e5:SetCost(cm.cos5)
e5:SetOperation(cm.op5)
c:RegisterEffect(e5)
--to hand
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetType(EFFECT_TYPE_TRIGGER_O+EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetTarget(cm.thtg)
e1:SetOperation(cm.thop)
c:RegisterEffect(e1)
end
function cm.con2(e,c,minc)
if c==nil then return true end
return minc<=1 and Duel.CheckTribute(c,1)
end
function cm.op2(e,tp,eg,ep,ev,re,r,rp,c)
local g=Duel.SelectTribute(tp,c,1,Duel.GetFieldGroupCount(tp,LOCATION_MZONE,LOCATION_MZONE))
c:SetMaterial(g)
Duel.Release(g,REASON_SUMMON+REASON_MATERIAL)
for tc in aux.Next(g) do
if tc:IsLocation(LOCATION_GRAVE) then
tc:RegisterFlagEffect(m,RESET_EVENT+RESETS_STANDARD,0,1)
end
end
end
function cm.cos5f1(c)
return c:GetFlagEffect(m)>0 and (c:IsAbleToDeckAsCost() or c:IsAbleToExtraAsCost())
end
function cm.cos5(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.cos5f1,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,cm.cos5f1,tp,LOCATION_GRAVE,0,1,99,nil)
e:SetLabel(Duel.SendtoDeck(g,tp,2,REASON_COST))
end
function cm.op5(e,tp,eg,ep,ev,re,r,rp)
local dam=e:GetLabel()
if not e:GetHandler():IsRelateToEffect(e) or not e:GetHandler():IsFaceup() then return end
if dam>=1 then
local g=Duel.GetMatchingGroup(nil,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_UPDATE_ATTACK)
e1:SetValue(-800)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1)
if tc:GetAttack()==0 then
Duel.Destroy(tc,REASON_EFFECT)
end
tc=g:GetNext()
end
if dam>=2 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.thfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
end
end
function cm.thfilter(c)
local tp=c:GetControler()
return c:IsCanHaveCounter(0x9620) and Duel.IsCanAddCounter(tp,0x9620,1,c) and c:IsType(TYPE_MONSTER) and c:IsAbleToHand()
end
function cm.thfilter2(c)
return c:IsLevel(1) and c:IsAbleToHand()
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.thfilter2,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.thfilter2,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
if not g:GetFirst():IsCode(60002223) and Duel.SendtoHand(g,nil,REASON_EFFECT)~=0 and g:GetFirst():IsLocation(LOCATION_HAND) then
Duel.ConfirmCards(1-tp,g)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_SUMMON)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(1,0)
e1:SetTarget(cm.sumlimit)
e1:SetLabel(g:GetFirst():GetCode())
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
local e2=e1:Clone()
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
Duel.RegisterEffect(e2,tp)
local e3=e1:Clone()
e3:SetCode(EFFECT_CANNOT_MSET)
Duel.RegisterEffect(e3,tp)
local e4=e1:Clone()
e4:SetCode(EFFECT_CANNOT_ACTIVATE)
e4:SetValue(cm.aclimit)
Duel.RegisterEffect(e4,tp)
end
end
end
function cm.sumlimit(e,c)
return c:IsCode(e:GetLabel())
end
function cm.aclimit(e,re,tp)
return re:GetHandler():IsCode(e:GetLabel()) and re:IsActiveType(TYPE_MONSTER)
end
\ No newline at end of file
--镀黑小卒
local m=60002228
local cm=_G["c"..m]
function cm.initial_effect(c)
aux.AddCodeList(c,60002223)
--爆能强化
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_SUMMON_PROC)
e2:SetValue(SUMMON_TYPE_ADVANCE)
e2:SetCondition(cm.con2)
e2:SetOperation(cm.op2)
c:RegisterEffect(e2)
--进化
local e5=Effect.CreateEffect(c)
e5:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_ATKCHANGE)
e5:SetType(EFFECT_TYPE_IGNITION)
e5:SetRange(LOCATION_MZONE)
e5:SetCountLimit(1)
e5:SetCost(cm.cos5)
e5:SetOperation(cm.op5)
c:RegisterEffect(e5)
--spsummon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,2))
e1:SetCategory(CATEGORY_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_HAND)
e1:SetCost(cm.spcost)
e1:SetTarget(cm.sptg)
e1:SetOperation(cm.spop)
c:RegisterEffect(e1)
end
function cm.con2(e,c,minc)
if c==nil then return true end
return minc<=1 and Duel.CheckTribute(c,1)
end
function cm.op2(e,tp,eg,ep,ev,re,r,rp,c)
local g=Duel.SelectTribute(tp,c,1,Duel.GetFieldGroupCount(tp,LOCATION_MZONE,LOCATION_MZONE))
c:SetMaterial(g)
Duel.Release(g,REASON_SUMMON+REASON_MATERIAL)
for tc in aux.Next(g) do
if tc:IsLocation(LOCATION_GRAVE) then
tc:RegisterFlagEffect(m,RESET_EVENT+RESETS_STANDARD,0,1)
end
end
end
function cm.cos5f1(c)
return c:GetFlagEffect(m)>0 and (c:IsAbleToDeckAsCost() or c:IsAbleToExtraAsCost())
end
function cm.cos5(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.cos5f1,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,cm.cos5f1,tp,LOCATION_GRAVE,0,1,99,nil)
e:SetLabel(Duel.SendtoDeck(g,tp,2,REASON_COST))
end
function cm.op5(e,tp,eg,ep,ev,re,r,rp)
local dam=e:GetLabel()
if not e:GetHandler():IsRelateToEffect(e) or not e:GetHandler():IsFaceup() then return end
if dam==1 then
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,cm.filter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
end
if dam>=2 then
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,cm.filter,tp,LOCATION_DECK+LOCATION_GRAVE,0,2,2,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
local g1=Duel.GetMatchingGroup(aux.TRUE,tp,LOCATION_MZONE,0,nil)
local tc=g1:GetFirst()
while tc do
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
e1:SetValue(1000)
tc:RegisterEffect(e1)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_DEFENSE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
e1:SetValue(1000)
tc:RegisterEffect(e1)
tc=g1:GetNext()
end
end
end
function cm.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) end
Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD)
end
function cm.sptg(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_SUMMON,nil,0,0,0)
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
Duel.Summon(tp,c,true,nil)
if Duel.IsExistingMatchingCard(Card.IsCode,tp,LOCATION_MZONE,0,1,nil,60002223) then
Duel.Draw(tp,1,REASON_EFFECT)
end
end
\ No newline at end of file
--精炼保镳
local m=60002229
local cm=_G["c"..m]
function cm.initial_effect(c)
aux.AddCodeList(c,60002223)
--爆能强化
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_SUMMON_PROC)
e2:SetValue(SUMMON_TYPE_ADVANCE)
e2:SetCondition(cm.con2)
e2:SetOperation(cm.op2)
c:RegisterEffect(e2)
--进化
local e5=Effect.CreateEffect(c)
e5:SetCategory(CATEGORY_DRAW+CATEGORY_RECOVER)
e5:SetType(EFFECT_TYPE_IGNITION)
e5:SetRange(LOCATION_MZONE)
e5:SetCountLimit(1)
e5:SetCost(cm.cos5)
e5:SetOperation(cm.op5)
c:RegisterEffect(e5)
--tohand
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetCategory(CATEGORY_DRAW+CATEGORY_RECOVER+CATEGORY_SUMMON)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetRange(LOCATION_HAND)
e2:SetCost(cm.cost)
e2:SetOperation(cm.operation)
c:RegisterEffect(e2)
end
function cm.con2(e,c,minc)
if c==nil then return true end
return minc<=1 and Duel.CheckTribute(c,1)
end
function cm.op2(e,tp,eg,ep,ev,re,r,rp,c)
local g=Duel.SelectTribute(tp,c,1,Duel.GetFieldGroupCount(tp,LOCATION_MZONE,LOCATION_MZONE))
c:SetMaterial(g)
Duel.Release(g,REASON_SUMMON+REASON_MATERIAL)
for tc in aux.Next(g) do
if tc:IsLocation(LOCATION_GRAVE) then
tc:RegisterFlagEffect(m,RESET_EVENT+RESETS_STANDARD,0,1)
end
end
end
function cm.cos5f1(c)
return c:GetFlagEffect(m)>0 and (c:IsAbleToDeckAsCost() or c:IsAbleToExtraAsCost())
end
function cm.cos5(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.cos5f1,tp,LOCATION_GRAVE,0,2,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,cm.cos5f1,tp,LOCATION_GRAVE,0,2,2,nil)
e:SetLabel(Duel.SendtoDeck(g,tp,2,REASON_COST))
end
function cm.op5(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) or not e:GetHandler():IsFaceup() then return end
Duel.Draw(tp,2,REASON_EFFECT)
Duel.Recover(tp,2000,REASON_EFFECT)
end
function cm.cost(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 cm.filter(c,e,tp)
return c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,cm.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)
if Duel.IsExistingMatchingCard(Card.IsCode,tp,LOCATION_MZONE,0,1,nil,60002223) then
Duel.Draw(tp,1,REASON_EFFECT)
Duel.Recover(tp,1000,REASON_EFFECT)
end
end
end
\ No newline at end of file
--冲沙滑板手
local m=60002230
local cm=_G["c"..m]
function cm.initial_effect(c)
--爆能强化
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_SUMMON_PROC)
e2:SetValue(SUMMON_TYPE_ADVANCE)
e2:SetCondition(cm.con2)
e2:SetOperation(cm.op2)
c:RegisterEffect(e2)
--进化
local e5=Effect.CreateEffect(c)
e5:SetCategory(CATEGORY_DAMAGE)
e5:SetType(EFFECT_TYPE_IGNITION)
e5:SetRange(LOCATION_MZONE)
e5:SetCountLimit(1)
e5:SetCost(cm.cos5)
e5:SetOperation(cm.op5)
c:RegisterEffect(e5)
end
function cm.con2(e,c,minc)
if c==nil then return true end
return minc<=1 and Duel.CheckTribute(c,1)
end
function cm.op2(e,tp,eg,ep,ev,re,r,rp,c)
local g=Duel.SelectTribute(tp,c,1,Duel.GetFieldGroupCount(tp,LOCATION_MZONE,LOCATION_MZONE))
c:SetMaterial(g)
Duel.Release(g,REASON_SUMMON+REASON_MATERIAL)
for tc in aux.Next(g) do
if tc:IsLocation(LOCATION_GRAVE) then
tc:RegisterFlagEffect(m,RESET_EVENT+RESETS_STANDARD,0,1)
end
end
end
function cm.xfilter(c)
return c:IsType(TYPE_MONSTER)
end
function cm.cos5f1(c)
return c:GetFlagEffect(m)>0 and (c:IsAbleToDeckAsCost() or c:IsAbleToExtraAsCost())
end
function cm.cos5(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.cos5f1,tp,LOCATION_GRAVE,0,2,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,cm.cos5f1,tp,LOCATION_GRAVE,0,2,2,nil)
e:SetLabel(Duel.SendtoDeck(g,tp,2,REASON_COST))
end
function cm.op5(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) or not e:GetHandler():IsFaceup() then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectMatchingCard(tp,cm.xfilter,tp,LOCATION_MZONE,0,1,1,nil)
local dmg=g:GetFirst():GetAttack()
Duel.Damage(1-tp,dmg,REASON_EFFECT)
end
\ No newline at end of file
--宣告的天使
local m=60002231
local cm=_G["c"..m]
function cm.initial_effect(c)
--爆能强化
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_SUMMON_PROC)
e2:SetValue(SUMMON_TYPE_ADVANCE)
e2:SetCondition(cm.con2)
e2:SetOperation(cm.op2)
c:RegisterEffect(e2)
--进化
local e5=Effect.CreateEffect(c)
e5:SetCategory(CATEGORY_DAMAGE)
e5:SetType(EFFECT_TYPE_IGNITION)
e5:SetRange(LOCATION_MZONE)
e5:SetCountLimit(1)
e5:SetCost(cm.cos5)
e5:SetOperation(cm.op5)
c:RegisterEffect(e5)
end
function cm.con2(e,c,minc)
if c==nil then return true end
return minc<=1 and Duel.CheckTribute(c,1)
end
function cm.op2(e,tp,eg,ep,ev,re,r,rp,c)
local g=Duel.SelectTribute(tp,c,1,Duel.GetFieldGroupCount(tp,LOCATION_MZONE,LOCATION_MZONE))
c:SetMaterial(g)
Duel.Release(g,REASON_SUMMON+REASON_MATERIAL)
for tc in aux.Next(g) do
if tc:IsLocation(LOCATION_GRAVE) then
tc:RegisterFlagEffect(m,RESET_EVENT+RESETS_STANDARD,0,1)
end
end
end
function cm.xfilter(c)
return c:IsType(TYPE_MONSTER)
end
function cm.cos5f1(c)
return c:GetFlagEffect(m)>0 and (c:IsAbleToDeckAsCost() or c:IsAbleToExtraAsCost())
end
function cm.cos5(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.cos5f1,tp,LOCATION_GRAVE,0,2,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,cm.cos5f1,tp,LOCATION_GRAVE,0,2,2,nil)
e:SetLabel(Duel.SendtoDeck(g,tp,2,REASON_COST))
end
function cm.op5(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) or not e:GetHandler():IsFaceup() then return end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetValue(2000)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE)
e:GetHandler():RegisterEffect(e1)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_DEFENSE)
e1:SetValue(2000)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE)
e:GetHandler():RegisterEffect(e1)
Duel.Damage(1-tp,2000,REASON_EFFECT)
end
--喷射炮手
local m=60002232
local cm=_G["c"..m]
function cm.initial_effect(c)
aux.AddCodeList(c,60002223)
--爆能强化
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_SUMMON_PROC)
e2:SetValue(SUMMON_TYPE_ADVANCE)
e2:SetCondition(cm.con2)
e2:SetOperation(cm.op2)
c:RegisterEffect(e2)
--进化
local e5=Effect.CreateEffect(c)
e5:SetCategory(CATEGORY_DESTROY+CATEGORY_ATKCHANGE+CATEGORY_TOHAND+CATEGORY_SEARCH)
e5:SetType(EFFECT_TYPE_IGNITION)
e5:SetRange(LOCATION_MZONE)
e5:SetCountLimit(1)
e5:SetCost(cm.cos5)
e5:SetOperation(cm.op5)
c:RegisterEffect(e5)
end
function cm.con2(e,c,minc)
if c==nil then return true end
return minc<=1 and Duel.CheckTribute(c,1)
end
function cm.op2(e,tp,eg,ep,ev,re,r,rp,c)
local g=Duel.SelectTribute(tp,c,1,Duel.GetFieldGroupCount(tp,LOCATION_MZONE,LOCATION_MZONE))
c:SetMaterial(g)
Duel.Release(g,REASON_SUMMON+REASON_MATERIAL)
for tc in aux.Next(g) do
if tc:IsLocation(LOCATION_GRAVE) then
tc:RegisterFlagEffect(m,RESET_EVENT+RESETS_STANDARD,0,1)
end
end
end
function cm.cos5f1(c)
return c:GetFlagEffect(m)>0 and (c:IsAbleToDeckAsCost() or c:IsAbleToExtraAsCost())
end
function cm.cos5(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.cos5f1,tp,LOCATION_GRAVE,0,2,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,cm.cos5f1,tp,LOCATION_GRAVE,0,2,99,nil)
e:SetLabel(Duel.SendtoDeck(g,tp,2,REASON_COST))
end
function cm.op5(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local dam=e:GetLabel()
if not e:GetHandler():IsRelateToEffect(e) or not e:GetHandler():IsFaceup() then return end
if dam==2 then
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetValue(1600)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE)
e:GetHandler():RegisterEffect(e1)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_DEFENSE)
e1:SetValue(1600)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE)
e:GetHandler():RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetCode(EFFECT_EXTRA_ATTACK_MONSTER)
e2:SetValue(1)
c:RegisterEffect(e2)
end
if dam>=3 then
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetValue(3200)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE)
e:GetHandler():RegisterEffect(e1)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_DEFENSE)
e1:SetValue(3200)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE)
e:GetHandler():RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetCode(EFFECT_EXTRA_ATTACK_MONSTER)
e2:SetValue(2)
c:RegisterEffect(e2)
end
end
\ No newline at end of file
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