Commit 1219d02d authored by POLYMER's avatar POLYMER

fix

parent ce38c4ea
......@@ -8,7 +8,7 @@ function cm.initial_effect(c)
local e1=rsef.SV_CANNOT_BE_MATERIAL(c,"xyz")
local e2=rsef.STO(c,EVENT_ATTACK_ANNOUNCE,{m,1},nil,"dis,atk",nil,cm.atkcon,rscost.rmxyz(2),cm.atktg,cm.atkop)
end
cm.xyz_number=62
aux.xyz_number[10150099]=62
function cm.ovfilter(c)
return c:IsFaceup() and c:IsSetCard(0x107b) and c:IsType(TYPE_XYZ) and c:IsRank(8)
end
......
......@@ -22,6 +22,7 @@ function c114514.initial_effect(c)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e3)
end
aux.xyz_number[114514]=114514
function c114514.rfilter(c,tp)
return c:IsControler(tp) and c:IsFaceup() and not c:IsCode(114514)
end
......
......@@ -62,8 +62,7 @@ end
function c12825613.drop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Draw(p,d,REASON_EFFECT)
if c:GetOwner()~=e:GetHandlerPlayer() then
if Duel.Draw(p,d,REASON_EFFECT)>0 and c:GetOwner()~=e:GetHandlerPlayer() then
if Duel.GetLocationCount(1-tp,LOCATION_MZONE)>0 then
Duel.GetControl(c,1-tp)
else
......
......@@ -37,6 +37,7 @@ function cm.initial_effect(c)
e3:SetOperation(cm.remop)
c:RegisterEffect(e3)
end
aux.xyz_number[m]=21
function cm.ovfilter(c)
return c:IsFaceup() and c:IsXyzType(TYPE_XYZ) and c:IsRank(6)
end
......
......@@ -2,11 +2,11 @@
local s,id=GetID()
function s.initial_effect(c)
--xyz summon
aux.AddXyzProcedure(c,nil,9,3,s.ovfilter,aux.Stringid(id,4))
aux.AddXyzProcedure(c,nil,9,3,s.ovfilter,aux.Stringid(id,4))
c:EnableReviveLimit()
--Enable pendulum summon
aux.EnablePendulumAttribute(c,false)
--disable
--Enable pendulum summon
aux.EnablePendulumAttribute(c,false)
--disable
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetCode(EFFECT_DISABLE)
......@@ -14,23 +14,23 @@ function s.initial_effect(c)
e3:SetTargetRange(0,LOCATION_MZONE)
e3:SetTarget(s.distg)
c:RegisterEffect(e3)
--Special Summon
--Special Summon
local e22=Effect.CreateEffect(c)
e22:SetDescription(aux.Stringid(id,3))
e22:SetCategory(CATEGORY_SPECIAL_SUMMON)
e22:SetType(EFFECT_TYPE_IGNITION)
e22:SetRange(LOCATION_PZONE)
e22:SetCountLimit(1,id)
e22:SetCountLimit(1,id)
e22:SetCost(s.spcost)
e22:SetTarget(s.sptg)
e22:SetOperation(s.spop)
c:RegisterEffect(e22)
--特殊召唤不能被无效
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_CANNOT_DISABLE_SPSUMMON)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e0)
--特殊召唤不能被无效
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_CANNOT_DISABLE_SPSUMMON)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e0)
--xyzlimit
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
......@@ -40,36 +40,36 @@ function s.initial_effect(c)
c:RegisterEffect(e1)
--remove
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(id,0))
e2:SetDescription(aux.Stringid(id,0))
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1,id)
e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1,id)
e2:SetCost(s.rmcost)
e2:SetTarget(s.rmtg)
e2:SetOperation(s.rmop)
c:RegisterEffect(e2)
--banish
--banish
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(id,1))
e4:SetCategory(CATEGORY_REMOVE+CATEGORY_TOGRAVE)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e4:SetProperty(EFFECT_FLAG_DELAY)
e4:SetProperty(EFFECT_FLAG_DELAY)
e4:SetCode(EVENT_SPSUMMON_SUCCESS)
e4:SetCountLimit(1,id)
e4:SetCountLimit(1,id)
e4:SetTarget(s.bantg)
e4:SetOperation(s.banop)
c:RegisterEffect(e4)
--multi attack
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_EXTRA_ATTACK)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetRange(LOCATION_MZONE)
e2:SetValue(s.val)
c:RegisterEffect(e2)
--pendulum
--multi attack
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_EXTRA_ATTACK)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetRange(LOCATION_MZONE)
e2:SetValue(s.val)
c:RegisterEffect(e2)
--pendulum
local e12=Effect.CreateEffect(c)
e12:SetDescription(aux.Stringid(id,2))
e12:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
......@@ -80,10 +80,10 @@ function s.initial_effect(c)
e12:SetOperation(s.penop)
c:RegisterEffect(e12)
end
s.xyz_number=95
aux.xyz_number[id]=95
s.pendulum_level=9
function s.chlimit(e,ep,tp)
return tp==ep
return tp==ep
end
function s.ovfilter(c,tp,xyzc)
return c:IsFaceup() and c:IsSetCard(0x107b,xyzc,SUMMON_TYPE_XYZ,tp) and c:IsType(TYPE_XYZ,xyzc,SUMMON_TYPE_XYZ,tp)
......@@ -106,7 +106,7 @@ end
function s.rmtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetFieldGroupCount(tp,0,LOCATION_HAND)>1
and not Duel.IsPlayerAffectedByEffect(1-tp,30459350) end
Duel.SetChainLimit(s.chlimit)
Duel.SetChainLimit(s.chlimit)
end
function s.rmfilter(c)
return c:IsType(TYPE_MONSTER+TYPE_SPELL+TYPE_TRAP) and c:IsAbleToRemove()
......@@ -129,7 +129,7 @@ end
function s.bantg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingMatchingCard(s.banfilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,0,0)
Duel.SetChainLimit(s.chlimit)
Duel.SetChainLimit(s.chlimit)
end
function s.banop(e,tp,eg,ep,ev,re,r,rp)
local ct=Duel.GetFieldGroupCount(1-tp,LOCATION_DECK,0)
......@@ -153,45 +153,45 @@ function s.banop(e,tp,eg,ep,ev,re,r,rp)
end
end
end
function s.val(e,c)
return c:GetOverlayCount()
end
function s.pencon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_MZONE) and c:IsFaceup() and c:IsPreviousPosition(POS_FACEUP)
end
function s.pentg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckLocation(tp,LOCATION_PZONE,0) or Duel.CheckLocation(tp,LOCATION_PZONE,1) end
Duel.SetTargetCard(e:GetHandler())
Duel.SetChainLimit(s.chlimit)
end
function s.penop(e,tp,eg,ep,ev,re,r,rp)
if not Duel.CheckLocation(tp,LOCATION_PZONE,0) and not Duel.CheckLocation(tp,LOCATION_PZONE,1) then return false end
local c=e:GetHandler()
if c:IsRelateToEffect(e) then
Duel.MoveToField(c,tp,tp,LOCATION_PZONE,POS_FACEUP,true)
end
end
function s.val(e,c)
return c:GetOverlayCount()
end
function s.pencon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_MZONE) and c:IsFaceup() and c:IsPreviousPosition(POS_FACEUP)
end
function s.pentg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckLocation(tp,LOCATION_PZONE,0) or Duel.CheckLocation(tp,LOCATION_PZONE,1) end
Duel.SetTargetCard(e:GetHandler())
Duel.SetChainLimit(s.chlimit)
end
function s.penop(e,tp,eg,ep,ev,re,r,rp)
if not Duel.CheckLocation(tp,LOCATION_PZONE,0) and not Duel.CheckLocation(tp,LOCATION_PZONE,1) then return false end
local c=e:GetHandler()
if c:IsRelateToEffect(e) then
Duel.MoveToField(c,tp,tp,LOCATION_PZONE,POS_FACEUP,true)
end
end
function s.distg(e,c)
return c:IsType(TYPE_MONSTER) and c:IsLevel(0)
end
function s.spfilter1(c)
return c:IsSummonLocation(LOCATION_EXTRA) and c:IsFaceup() and c:IsRace(RACE_DRAGON) and c:IsReleasable()
end
function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
local loc=LOCATION_ONFIELD
if ft==0 then loc=LOCATION_MZONE end
if chk==0 then return Duel.IsExistingMatchingCard(s.spfilter1,tp,loc,0,1,e:GetHandler(),e,tp) end
local g=Duel.SelectMatchingCard(tp,s.spfilter1,tp,loc,0,1,1,e:GetHandler())
Duel.Release(g,REASON_COST)
end
function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end
function s.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end
\ No newline at end of file
function s.spfilter1(c)
return c:IsSummonLocation(LOCATION_EXTRA) and c:IsFaceup() and c:IsRace(RACE_DRAGON) and c:IsReleasable()
end
function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
local loc=LOCATION_ONFIELD
if ft==0 then loc=LOCATION_MZONE end
if chk==0 then return Duel.IsExistingMatchingCard(s.spfilter1,tp,loc,0,1,e:GetHandler(),e,tp) end
local g=Duel.SelectMatchingCard(tp,s.spfilter1,tp,loc,0,1,1,e:GetHandler())
Duel.Release(g,REASON_COST)
end
function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end
function s.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end
......@@ -2,21 +2,21 @@
local s,id=GetID()
function s.initial_effect(c)
--xyz summon
aux.AddXyzProcedure(c,nil,9,3,s.ovfilter,aux.Stringid(id,0),3,s.xyzop)
aux.AddXyzProcedure(c,nil,9,3,s.ovfilter,aux.Stringid(id,0),3,s.xyzop)
c:EnableReviveLimit()
--检索
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,1))
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCountLimit(1)
e1:SetCondition(s.con)
e1:SetTarget(s.target)
e1:SetOperation(s.activate)
c:RegisterEffect(e1)
--检索
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,1))
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCountLimit(1)
e1:SetCondition(s.con)
e1:SetTarget(s.target)
e1:SetOperation(s.activate)
c:RegisterEffect(e1)
--无效
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,2))
......@@ -37,7 +37,7 @@ function s.initial_effect(c)
e3:SetOperation(s.op)
c:RegisterEffect(e3)
end
s.xyz_number=107
aux.xyz_number[id]=107
function s.cfilter(c)
return c:IsSetCard(0x95) and c:IsType(TYPE_SPELL) and c:IsDiscardable()
end
......@@ -49,31 +49,31 @@ function s.xyzop(e,tp,chk)
Duel.DiscardHand(tp,s.cfilter,1,1,REASON_COST+REASON_DISCARD)
end
function s.con(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_XYZ)
return e:GetHandler():IsSummonType(SUMMON_TYPE_XYZ)
end
function s.filter(c)
return (c:IsCode(8038143) or (c:IsSetCard(0x95) and c:GetType()==TYPE_QUICKPLAY+TYPE_SPELL)) and c:IsAbleToHand()
return (c:IsCode(8038143) or (c:IsSetCard(0x95) and c:GetType()==TYPE_QUICKPLAY+TYPE_SPELL)) and c:IsAbleToHand()
end
function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.filter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK+LOCATION_GRAVE)
Duel.SetChainLimit(s.chlimit)
if chk==0 then return Duel.IsExistingMatchingCard(s.filter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK+LOCATION_GRAVE)
Duel.SetChainLimit(s.chlimit)
end
function s.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,s.filter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,s.filter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
function s.chlimit(e,ep,tp)
return tp==ep
return tp==ep
end
function s.negcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,2,REASON_COST) end
e:GetHandler():RemoveOverlayCard(tp,2,2,REASON_COST)
Duel.SetChainLimit(s.chlimit)
Duel.SetChainLimit(s.chlimit)
end
function s.negop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
......@@ -104,7 +104,7 @@ end
function s.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():GetFlagEffect(id)==0 end
e:GetHandler():RegisterFlagEffect(id,RESET_PHASE+PHASE_DAMAGE_CAL,0,1)
Duel.SetChainLimit(s.chlimit)
Duel.SetChainLimit(s.chlimit)
end
function s.op(e,tp,eg,ep,ev,re,r,rp)
local a=Duel.GetAttacker()
......
......@@ -24,6 +24,7 @@ function c22348446.initial_effect(c)
e2:SetOperation(c22348446.op)
c:RegisterEffect(e2)
end
aux.xyz_number[22348446]=90
function c22348446.discon(e,tp,eg,ep,ev,re,r,rp)
return re:IsActiveType(TYPE_SPELL+TYPE_TRAP) or Duel.IsChainDisablable(ev)
end
......
......@@ -25,7 +25,7 @@ function cm.initial_effect(c)
e2:SetOperation(cm.desop)
c:RegisterEffect(e2)
end
cm.xyz_number=39
aux.xyz_number[m]=39
function cm.efilter(e,te)
local tc=te:GetHandler()
if tc==e:GetHandler() then return false end
......
......@@ -43,7 +43,7 @@ function c4875102.initial_effect(c)
e7:SetValue(aux.xyzlimit)
c:RegisterEffect(e7)
end
c4875102.xyz_number=62
aux.xyz_number[4875102]=62
function c4875102.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,2,REASON_COST) end
e:GetHandler():RemoveOverlayCard(tp,2,2,REASON_COST)
......@@ -73,7 +73,7 @@ function c4875102.desop(e,tp,eg,ep,ev,re,r,rp)
end
end
function c4875102.actlimit(e,te,tp)
return te:IsHasType(EFFECT_TYPE_ACTIVATE) and te:IsActiveType(TYPE_SPELL)
return te:IsHasType(EFFECT_TYPE_ACTIVATE) and te:IsActiveType(TYPE_SPELL)
end
function c4875102.imfilter(c)
return c:IsCode(93717133)
......
......@@ -28,8 +28,7 @@ function c49678550.initial_effect(c)
e2:SetOperation(c49678550.spop)
c:RegisterEffect(e2)
end
c49678550.xyz_number=102
aux.xyz_number[49678550]=102
function c49678550.counterfilter(c)
return c:IsSetCard(0x86) or not c:IsSummonLocation(LOCATION_HAND) or not c:IsSummonLocation(LOCATION_GRAVE)
end
......
......@@ -86,16 +86,17 @@ function cm.initial_effect(c)
e12:SetOperation(cm.atkop)
c:RegisterEffect(e12)
end
function cm.spfilter(c)
aux.xyz_number[m]=1500
function cm.spfilter(c)
return c:IsSetCard(0x1115) and c:IsAbleToRemoveAsCost() and not c:IsCode(m)
end
function cm.spcon(e,c)
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_EXTRA,0,14,c)
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk,c)
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk,c)
local g=Duel.GetMatchingGroup(cm.spfilter,tp,LOCATION_EXTRA,0,c)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local sg=g:CancelableSelect(tp,14,14,nil)
......@@ -110,56 +111,56 @@ end
Duel.Remove(g,POS_FACEDOWN,REASON_SPSUMMON)
g:DeleteGroup()
end
function cm.atkval(e,c)
function cm.atkval(e,c)
if Duel.GetTurnPlayer()==1-e:GetHandlerPlayer() then
return 150000
else
return 1500
end
end
function cm.indtg(e,c)
function cm.indtg(e,c)
return c:IsCode(m)
end
function cm.efilter(e,re)
function cm.efilter(e,re)
return e:GetHandlerPlayer()~=re:GetOwnerPlayer()
end
function cm.wincon(e,tp,eg,ep,ev,re,r,rp)
function cm.wincon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousControler(tp) and c:GetReasonPlayer()==1-tp
end
function cm.winop(e,tp,eg,ep,ev,re,r,rp)
function cm.winop(e,tp,eg,ep,ev,re,r,rp)
local WIN_REASON_NUMERONIUS_NUMERONIA=0x21
Duel.Win(tp,WIN_REASON_NUMERONIUS_NUMERONIA)
end
function cm.filter(c)
function cm.filter(c)
return c:IsSetCard(0x115) and c:IsAbleToGrave()
end
function cm.tgtg(e,tp,eg,ep,ev,re,r,rp,chk)
function cm.tgtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK)
end
function cm.tgop(e,tp,eg,ep,ev,re,r,rp)
function cm.tgop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,cm.filter,tp,LOCATION_DECK,0,1,1,nil)
Duel.SendtoGrave(g,REASON_EFFECT)
end
function cm.thfilter(c,tp)
function cm.thfilter(c,tp)
return c:IsSetCard(0x115) and c:IsType(TYPE_SPELL) and c:IsAbleToHand()
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and cm.thfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(cm.thfilter,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local sg=Duel.SelectTarget(tp,cm.thfilter,tp,LOCATION_GRAVE,0,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,sg,1,0,0)
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
function cm.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 cm.op(e,tp,eg,ep,ev,re,r,rp)
function cm.op(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)
......@@ -169,15 +170,15 @@ end
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
function cm.opfilter(c,tp)
function cm.opfilter(c,tp)
return c:IsSetCard(0x115) and c:IsType(TYPE_SPELL) and c:IsAbleToHand()
and not Duel.IsExistingMatchingCard(Card.IsCode,tp,LOCATION_GRAVE,0,1,nil,c:GetCode())
end
function cm.tg2(e,tp,eg,ep,ev,re,r,rp,chk)
function cm.tg2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.opfilter,tp,LOCATION_DECK,0,1,nil,tp) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function cm.op2(e,tp,eg,ep,ev,re,r,rp)
function cm.op2(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.opfilter,tp,LOCATION_DECK,0,1,1,nil,tp)
if g:GetCount()>0 then
......@@ -185,13 +186,13 @@ end
Duel.ConfirmCards(1-tp,g)
end
end
function cm.atktg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
function cm.atktg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) and chkc:IsFaceup() end
if chk==0 then return Duel.IsExistingTarget(Card.IsFaceup,tp,0,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SelectTarget(tp,Card.IsFaceup,tp,0,LOCATION_MZONE,1,1,nil)
end
function cm.atkop(e,tp,eg,ep,ev,re,r,rp)
function cm.atkop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
local e1=Effect.CreateEffect(e:GetHandler())
......
......@@ -38,7 +38,7 @@ function s.initial_effect(c)
e2:SetOperation(s.operation)
c:RegisterEffect(e2)
end
s.xyz_number=69
aux.xyz_number[id]=69
--Xyz Summon(normal)
function s.Xyzfilter2(c,sc)
return c:IsSetCard(0x76) and c:IsCanBeXyzMaterial(sc) and c:IsXyzLevel(sc,4)
......
......@@ -55,7 +55,7 @@ function c79029505.initial_effect(c)
e6:SetValue(1)
c:RegisterEffect(e6)
end
c79029505.xyz_number=88
aux.xyz_number[79029505]=88
function c79029505.sprfilter(c)
return c:GetOriginalLevel()==10 and c:IsFaceup() and c:IsCanOverlay()
end
......
......@@ -59,7 +59,7 @@ function c79029506.initial_effect(c)
e7:SetOperation(c79029506.spop)
c:RegisterEffect(e7)
end
c79029506.xyz_number=5
aux.xyz_number[79029506]=5
function c79029506.atkval(e,c)
local g=e:GetHandler():GetOverlayGroup()
return g:GetCount()*1500
......
......@@ -49,7 +49,7 @@ function c79029515.initial_effect(c)
e1:SetValue(c79029515.splimit)
c:RegisterEffect(e1)
end
c79029515.xyz_number=103
aux.xyz_number[79029515]=103
function c79029515.splimit(e,se,sp,st)
return se:GetHandler():IsSetCard(0x95) and se:GetHandler():IsType(TYPE_SPELL)
end
......
......@@ -41,7 +41,7 @@ function c79029516.initial_effect(c)
e4:SetOperation(c79029516.spop)
c:RegisterEffect(e4)
end
c79029516.xyz_number=53
aux.xyz_number[79029516]=53
function c79029516.ovfilter(c)
return c:IsFaceup() and c:IsCode(23998625)
end
......
......@@ -45,7 +45,7 @@ function c79029520.initial_effect(c)
e3:SetOperation(c79029520.spop1)
c:RegisterEffect(e3)
end
c79029520.xyz_number=62
aux.xyz_number[79029520]=62
function c79029520.atkval(e,c)
return c:GetOverlayCount()*500
end
......
......@@ -38,7 +38,7 @@ function c79029521.initial_effect(c)
e5:SetCode(EVENT_BECOME_TARGET)
c:RegisterEffect(e5)
end
c79029521.xyz_number=69
aux.xyz_number[79029521]=69
function c79029521.effilter(c)
return c:IsType(TYPE_MONSTER) and c:IsFaceup()
end
......
......@@ -33,6 +33,7 @@ function c79029525.initial_effect(c)
e3:SetOperation(c79029525.op)
c:RegisterEffect(e3)
end
aux.xyz_number[79029525]=65
function c79029525.eqcon(e,tp,eg,ep,ev,re,r,rp)
local ec=e:GetLabelObject()
return ec==nil or ec:GetFlagEffect(79029525)==0 and e:GetHandler():IsSummonType(SUMMON_TYPE_XYZ)
......
......@@ -53,7 +53,7 @@ function c79029526.initial_effect(c)
e1:SetValue(c79029526.splimit)
c:RegisterEffect(e1)
end
c79029526.xyz_number=101
aux.xyz_number[79029526]=101
function c79029526.splimit(e,se,sp,st)
return se:GetHandler():IsSetCard(0x95) and se:GetHandler():IsType(TYPE_SPELL)
end
......
......@@ -44,7 +44,7 @@ function c79029528.initial_effect(c)
e1:SetValue(c79029528.splimit)
c:RegisterEffect(e1)
end
c79029528.xyz_number=104
aux.xyz_number[79029528]=104
function c79029528.splimit(e,se,sp,st)
return se:GetHandler():IsSetCard(0x95) and se:GetHandler():IsType(TYPE_SPELL)
end
......
......@@ -37,7 +37,7 @@ function c79029530.initial_effect(c)
e3:SetOperation(c79029530.atkop)
c:RegisterEffect(e3)
end
c79029530.xyz_number=39
aux.xyz_number[79029530]=39
function c79029530.condition(e,tp,eg,ep,ev,re,r,rp,chk)
return not e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED) and ep~=tp
end
......
......@@ -40,7 +40,7 @@ function c79029531.initial_effect(c)
e1:SetValue(c79029531.splimit)
c:RegisterEffect(e1)
end
c79029531.xyz_number=106
aux.xyz_number[79029531]=106
function c79029531.splimit(e,se,sp,st)
return se:GetHandler():IsSetCard(0x95) and se:GetHandler():IsType(TYPE_SPELL)
end
......
......@@ -61,6 +61,7 @@ function c79029532.initial_effect(c)
e8:SetOperation(c79029532.atkop)
c:RegisterEffect(e8)
end
aux.xyz_number[79029532]=96
function c79029532.target(e,c)
return c:IsLocation(LOCATION_MZONE)
end
......
......@@ -25,7 +25,7 @@ function c79029533.initial_effect(c)
e3:SetOperation(c79029533.op)
c:RegisterEffect(e3)
end
c79029533.xyz_number=54
aux.xyz_number[79029533]=54
function c79029533.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)
......
......@@ -25,6 +25,7 @@ function c79029534.initial_effect(c)
e2:SetOperation(c79029534.dcop)
c:RegisterEffect(e2)
end
aux.xyz_number[79029534]=39
function c79029534.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)
......
......@@ -44,7 +44,7 @@ function c79029549.initial_effect(c)
e5:SetOperation(c79029549.activate)
c:RegisterEffect(e5)
end
c79029549.xyz_number=99
aux.xyz_number[79029549]=99
function c79029549.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)
......
......@@ -45,7 +45,7 @@ function c79029550.initial_effect(c)
e5:SetOperation(c79029550.rop)
c:RegisterEffect(e5)
end
c79029550.xyz_number=0
aux.xyz_number[79029550]=0
function c79029550.mfilter(c,xyzc)
return c:IsXyzType(TYPE_XYZ)
end
......
......@@ -59,7 +59,7 @@ function c79029555.initial_effect(c)
e1:SetValue(c79029555.splimit)
c:RegisterEffect(e1)
end
c79029555.xyz_number=105
aux.xyz_number[79029555]=105
function c79029555.splimit(e,se,sp,st)
return se:GetHandler():IsSetCard(0x95) and se:GetHandler():IsType(TYPE_SPELL)
end
......
......@@ -49,7 +49,7 @@ function c79029556.initial_effect(c)
e1:SetValue(c79029556.splimit)
c:RegisterEffect(e1)
end
c79029556.xyz_number=102
aux.xyz_number[79029556]=102
function c79029556.splimit(e,se,sp,st)
return se:GetHandler():IsSetCard(0x95) and se:GetHandler():IsType(TYPE_SPELL)
end
......
......@@ -35,7 +35,7 @@ function c79029557.initial_effect(c)
e1:SetValue(c79029557.splimit)
c:RegisterEffect(e1)
end
c79029557.xyz_number=107
aux.xyz_number[79029557]=107
function c79029557.splimit(e,se,sp,st)
return se:GetHandler():IsSetCard(0x95) and se:GetHandler():IsType(TYPE_SPELL)
end
......
......@@ -37,7 +37,7 @@ function c79029560.initial_effect(c)
e5:SetOperation(c79029560.slop)
c:RegisterEffect(e5)
end
c79029560.xyz_number=89
aux.xyz_number[79029560]=89
function c79029560.rmcost(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)
......
......@@ -65,7 +65,7 @@ function c79029561.initial_effect(c)
Duel.RegisterEffect(ge1,0)
end
end
c79029561.xyz_number=92
aux.xyz_number[79029561]=92
function c79029561.checkop(e,tp,eg,ep,ev,re,r,rp)
local tc=eg:GetFirst()
while tc do
......
......@@ -36,7 +36,7 @@ function c79029562.initial_effect(c)
e3:SetOperation(c79029562.rop)
c:RegisterEffect(e3)
end
c79029562.xyz_number=73
aux.xyz_number[79029562]=73
function c79029562.atkcon(e,tp,eg,ep,ev,re,r,rp)
local a=Duel.GetAttacker()
local d=Duel.GetAttackTarget()
......
......@@ -39,7 +39,7 @@ function s.initial_effect(c)
e5:SetRange(LOCATION_MZONE)
e5:SetTargetRange(1,1)
e5:SetValue(s.aclimit)
Duel.RegisterEffect(e5)
c:RegisterEffect(e5)
--tograve
local e6=Effect.CreateEffect(c)
e6:SetCategory(CATEGORY_TOGRAVE)
......
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