Commit e4fff4d0 authored by Nemo Ma's avatar Nemo Ma

miniupdate 1020

Created cdb for TYGOC
parent 4b749c68
#[No81DIY 19.10]
!2019.9 DIY
!THE LIST
#99
09910057 1 --
......@@ -180,6 +180,8 @@
#889
88990194 0 --
#987
98745673 2 --Hellfire Blister
#BUGs
......
local cid=c98745671
local id=98745671
function cid.initial_effect(c)
--Self-Special Summon from Hand (0)
local e0=Effect.CreateEffect(c)
e0:SetDescription(aux.Stringid(id,0))
e0:SetCategory(CATEGORY_SPECIAL_SUMMON)
e0:SetType(EFFECT_TYPE_IGNITION)
e0:SetRange(LOCATION_HAND)
e0:SetCountLimit(1,id)
e0:SetCondition(cid.spcon)
e0:SetTarget(cid.sptg)
e0:SetOperation(cid.spop)
c:RegisterEffect(e0)
--Search "Red Dragon Archfiend" Listed Spell/Traps (0)
--cid.card_code_list={70902743}
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,0))
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCountLimit(2,id)
e1:SetTarget(cid.rdatg)
e1:SetOperation(cid.rdaop)
c:RegisterEffect(e1)
end
--Filters
function cid.rdafilter(c)
return c:IsCode(50215517) and c:IsAbleToHand()
or c:IsCode(87614611) and c:IsAbleToHand()
or c:IsCode(02542230) and c:IsAbleToHand()
or c:IsCode(02542230) and c:IsAbleToHand()
or c:IsCode(18634367) and c:IsAbleToHand()
or c:IsCode(60433216) and c:IsAbleToHand()
or c:IsCode(24566654) and c:IsAbleToHand()
or c:IsCode(98745673) and c:IsAbleToHand()
end
--Self-Special Summon from Hand (0)
function cid.spcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetFieldGroupCount(tp,LOCATION_MZONE,0)==0
end
function cid.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,0,0)
end
function cid.spop(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)
end
end
--Search "Red Dragon Archfiend" Listed Spell/Traps (1)
function cid.rdatg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cid.rdafilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function cid.rdaop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cid.rdafilter,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
\ No newline at end of file
local cid=c98745672
local id=98745672
function cid.initial_effect(c)
--Self-Special Summon (1)
local e0=Effect.CreateEffect(c)
e0:SetCategory(CATEGORY_SPECIAL_SUMMON)
e0:SetType(EFFECT_TYPE_IGNITION)
e0:SetRange(LOCATION_HAND)
e0:SetCondition(cid.sscon)
e0:SetTarget(cid.sstg)
e0:SetOperation(cid.ssop)
c:RegisterEffect(e0)
--Special Summon from Deck (2)
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_GRAVE)
e1:SetCost(aux.bfgcost)
e1:SetTarget(cid.sstg2)
e1:SetOperation(cid.ssop2)
c:RegisterEffect(e1)
end
--Filters
function cid.filter(c)
return c:IsSetCard(0x57)
end
--Self-Special Summon (1)
function cid.sscon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cid.filter,tp,LOCATION_MZONE,0,1,nil)
end
function cid.sstg(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 cid.ssop(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)
end
end
--Special Summon from Deck (2)
function cid.sstg2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cid.filter,tp,LOCATION_GRAVE,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_GRAVE)
end
function cid.ssop2(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cid.filter,tp,LOCATION_GRAVE,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
local cid=c98745673
local id=98745673
function cid.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DRAW+CATEGORY_REMOVE+CATEGORY_HANDES)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetTarget(cid.target)
e1:SetOperation(cid.activate)
c:RegisterEffect(e1)
end
function cid.cfilter(c)
return c:IsAttribute(ATTRIBUTE_FIRE) and c:IsRace(RACE_FIEND) and not c:IsPublic()
or c:IsSetCard(0x1045) and not c:IsPublic()
end
function cid.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanRemove(tp) and Duel.IsPlayerCanDraw(tp,2)
and Duel.IsExistingMatchingCard(cid.cfilter,tp,LOCATION_HAND,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CONFIRM)
local g=Duel.SelectMatchingCard(tp,cid.cfilter,tp,LOCATION_HAND,0,1,1,nil)
Duel.ConfirmCards(1-tp,g)
Duel.ShuffleHand(tp)
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(2)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,2)
e:SetLabel(g:GetFirst():GetAttack())
end
function cid.activate(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
local atk=e:GetLabel()
local tatk=atk*2
Duel.Draw(p,d,REASON_EFFECT)
Duel.BreakEffect()
Duel.Damage(tp,tatk,REASON_EFFECT,nil)
end
\ No newline at end of file
local cid=c98745674
local id=98745674
function cid.initial_effect(c)
--Synchro Summon (X)
aux.AddSynchroProcedure(c,aux.Tuner(cid.matfilter),nil,1,1)
c:EnableReviveLimit()
--Name Change (0)
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e0:SetRange(LOCATION_MZONE+LOCATION_GRAVE)
e0:SetCode(EFFECT_CHANGE_CODE)
e0:SetValue(70902743)
c:RegisterEffect(e0)
--Battle Activate Limit (1)
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:SetCountLimit(1,id)
e1:SetValue(1)
e1:SetCondition(cid.actcon)
c:RegisterEffect(e1)
--Special Summon from Deck (2)
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_TRIGGER_O+EFFECT_TYPE_SINGLE)
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetCountLimit(2,id)
e2:SetCondition(cid.sscond)
e2:SetTarget(cid.sstgd)
e2:SetOperation(cid.ssopd)
c:RegisterEffect(e2)
--Special Summon from GY (3)
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_SPECIAL_SUMMON)
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e3:SetRange(LOCATION_GRAVE)
e3:SetCountLimit(3,id)
e3:SetCost(aux.bfgcost)
e3:SetTarget(cid.sstggy)
e3:SetOperation(cid.ssopgy)
c:RegisterEffect(e3)
end
--Filters--
--Synchro Summon (X)
function cid.matfilter(c)
return c:IsAttribute(ATTRIBUTE_DARK)
end
--Special Summon from Deck (2)
function cid.ssfilterd(c,e,tp)
return c:IsSetCard(0x57) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
--Special Summon from GY (3)
function cid.filter2(c,e,tp)
return c:IsLevelAbove(7) and c:IsAttribute(ATTRIBUTE_DARK) and c:IsRace(RACE_DRAGON) and c:IsType(TYPE_SYNCHRO)
and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
--Battle Activate Limit (1)
function cid.actcon(e)
return Duel.GetAttacker()==e:GetHandler() or Duel.GetAttackTarget()==e:GetHandler()
end
--Special Summon from Deck (2)
function cid.sscond(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_SYNCHRO)--:GetSequence()>4
end
function cid.sstgd(e,tp,eg,ep,ev,re,r,rp,chk)
if chkc then return chkc:IsLocation(LOCATION_DECK)
and Duel.IsExistingMatchingCard(cid.ssfilterd,tp,LOCATION_DECK,0,1,nil,e,tp) end
if chk==0 then return Duel.IsExistingMatchingCard(nil,tp,LOCATION_HAND,0,1,nil) end
Duel.DiscardHand(tp,nil,1,1,REASON_COST+REASON_DISCARD)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK)
end
function cid.ssopd(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,cid.ssfilterd,tp,LOCATION_DECK,0,1,1,nil,e,tp)
if c:IsRelateToEffect(e) then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
c:RegisterEffect(e1,true)
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
end
--Special Summon from GY (3)
function cid.sstggy(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and cid.filter2(chkc,e,tp) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingTarget(cid.filter2,tp,LOCATION_GRAVE,0,1,e:GetHandler(),e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,cid.filter2,tp,LOCATION_GRAVE,0,1,1,e:GetHandler(),e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end
function cid.ssopgy(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:IsFaceup() then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
end
end
\ No newline at end of file
local cid=c98745675
local id=98745675
function cid.initial_effect(c)
--Special Summon from GY (1)
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,id)
e1:SetTarget(cid.target)
e1:SetOperation(cid.activate)
c:RegisterEffect(e1)
--DARK Dragon Immunity (2)
local e2=Effect.CreateEffect(c)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetRange(LOCATION_GRAVE)
e2:SetTargetRange(1,LOCATION_MZONE)
e2:SetCountLimit(2,id)
e2:SetCost(aux.bfgcost)
e2:SetTarget(cid.target2)
e2:SetOperation(cid.operation2)
c:RegisterEffect(e2)
end
--Filters
function cid.filter(c,e,tp)
return c:IsAttribute(ATTRIBUTE_DARK) and c:IsRace(RACE_DRAGON) and c:IsType(TYPE_SYNCHRO) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function cid.immfilter(c,e,tp)
return c:IsAttribute(ATTRIBUTE_DARK) and c:IsRace(RACE_DRAGON) and c:IsType(TYPE_SYNCHRO)
end
function cid.efilter(e,re)
return e:GetHandler()~=re:GetOwner()
end
--Special Summon from GY (1)
function cid.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and cid.filter(chkc,e,tp) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingTarget(cid.filter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,cid.filter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end
function cid.activate(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
--DARK Dragon Immunity (2)
function cid.immtarget(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsFaceup() end
if chk==0 then return Duel.IsExistingTarget(cid.immfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SelectTarget(tp,cid.immfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
end
function cid.immoperation(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_IMMUNE_EFFECT)
e1:SetValue(cid.efilter)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
end
end
\ No newline at end of file
local cid=c98745676
local id=98745676
function cid.initial_effect(c)
--Self-Special Summon (0)
local e0=Effect.CreateEffect(c)
e0:SetDescription(aux.Stringid(id,0))
e0:SetCategory(CATEGORY_SPECIAL_SUMMON)
e0:SetType(EFFECT_TYPE_IGNITION)
e0:SetRange(LOCATION_HAND)
e0:SetCountLimit(1,id)
e0:SetCondition(cid.spcon)
e0:SetTarget(cid.sptg)
e0:SetOperation(cid.spop)
c:RegisterEffect(e0)
--Special Summon from GY (1)
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetRange(LOCATION_GRAVE)
e1:SetCountLimit(2,id)
e1:SetCost(aux.bfgcost)
e1:SetTarget(cid.sstg2)
e1:SetOperation(cid.ssop2)
c:RegisterEffect(e1)
end
--Filters
function cid.cfilter(c)
return c:IsFacedown() or not c:IsRace(RACE_FIEND)
end
function cid.filter2(c,e,tp)
return c:IsSetCard(0x57) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
--Self-Special Summon (0)
function cid.spcon(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetFieldGroup(tp,LOCATION_MZONE,0)
return g:GetCount()>0 and not g:IsExists(cid.cfilter,1,nil)
end
function cid.sptg(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 cid.spop(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)
end
end
--Special Summon from GY (1)
function cid.sstg2(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_DECK) and cid.filter2(chkc,e,tp) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingTarget(cid.filter2,tp,LOCATION_DECK,0,1,e:GetHandler(),e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,cid.filter2,tp,LOCATION_DECK,0,1,1,e:GetHandler(),e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end
function cid.ssop2(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
local tc=Duel.GetFirstTarget()
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
end
\ No newline at end of file
local cid=c98745677
local id=98745677
function cid.initial_effect(c)
c:EnableCounterPermit(0x57b)
--Synchro Summon (X)
aux.AddSynchroProcedure(c,nil,aux.NonTuner(nil),1)
c:EnableReviveLimit()
--Equip "Resonator" monster, Gain Counters (1)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetDescription(aux.Stringid(id,0))
e1:SetCategory(CATEGORY_EQUIP)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCondition(cid.eqcon)
e1:SetTarget(cid.eqtg)
e1:SetOperation(cid.eqop)
c:RegisterEffect(e1)
--Remove Counters, Special Summon "Resonator" monsters (2)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(id,0))
e2:SetCategory(CATEGORY_COUNTER)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1,id)
e2:SetCost(cid.sscost)
e2:SetTarget(cid.sstg)
e2:SetOperation(cid.ssop)
c:RegisterEffect(e2)
end
--Filters
function cid.filter(c,e,tp)
return c:IsSetCard(0x57) and c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function cid.eqlimit(e,c)
return c==e:GetLabelObject()
end
function cid.eqfilter(c,tp,mc)
return c:IsSetCard(0x57) and c:IsType(TYPE_MONSTER) and c:CheckUniqueOnField(tp) and not c:IsForbidden() --and mc:IsCanAddCounter(0x57b,c:GetLevel())
end
function cid.eqcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_SYNCHRO)
end
--Equip "Resonator" monster, Gain Counters (1)
function cid.eqtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0
and Duel.IsExistingMatchingCard(cid.eqfilter,tp,LOCATION_DECK,0,1,nil,e:GetHandler()) end
Duel.SetOperationInfo(0,CATEGORY_EQUIP,nil,1,tp,LOCATION_DECK)
end
function cid.eqop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_SZONE)>0 and c:IsFaceup() and c:IsRelateToEffect(e) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
if c:IsFacedown() or not c:IsRelateToEffect(e) then return end
local g=Duel.SelectMatchingCard(tp,cid.eqfilter,tp,LOCATION_DECK,0,1,1,nil,tp,c)
local tc=g:GetFirst()
if tc then
if not Duel.Equip(tp,tc,c,true) then return end
local lk=tc:GetLevel()
if lk>0 then
c:AddCounter(0x57b,lk)
end
--Duel.Equip(tp,g:GetFirst(),c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_EQUIP_LIMIT)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
e1:SetValue(cid.eqlimit)
e1:SetLabelObject(c)
g:GetFirst():RegisterEffect(e1)
end
end
end
--Remove Counters, Special Summon "Resonator" monsters (2)
function cid.sscost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsCanRemoveCounter(tp,0x53,ct,REASON_COST) end
local ct=e:GetHandler():GetCounter(0x57b)
e:SetLabel(ct)
e:GetHandler():RemoveCounter(tp,0x57b,ct,REASON_COST)
end
function cid.sstg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and cid.filter(chkc,e,tp) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingTarget(cid.filter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,e,tp) end
local val=e:GetLabel()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,cid.filter,tp,LOCATION_GRAVE,LOCATION_GRAVE,val,val,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end
function cid.ssop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tg=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS)
local rg=tg:Filter(Card.IsRelateToEffect,nil,e)
if rg:GetCount()>0 then
local ex=Effect.CreateEffect(c)
ex:SetType(EFFECT_TYPE_SINGLE)
ex:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
ex:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
ex:SetValue(1)
c:RegisterEffect(ex)
Duel.SpecialSummon(tg,0,tp,tp,nil,nil,POS_FACEUP)
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