Commit 3d406a00 authored by Nemo Ma's avatar Nemo Ma

Update 210704

Updated 500+ files
parent bbb7fe76
No preview for this file type
expansions/pics/33400502.jpg

30.7 KB | W: | H:

expansions/pics/33400502.jpg

280 KB | W: | H:

expansions/pics/33400502.jpg
expansions/pics/33400502.jpg
expansions/pics/33400502.jpg
expansions/pics/33400502.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/33400524.jpg

29.9 KB | W: | H:

expansions/pics/33400524.jpg

276 KB | W: | H:

expansions/pics/33400524.jpg
expansions/pics/33400524.jpg
expansions/pics/33400524.jpg
expansions/pics/33400524.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/9910105.jpg

47 KB | W: | H:

expansions/pics/9910105.jpg

51.6 KB | W: | H:

expansions/pics/9910105.jpg
expansions/pics/9910105.jpg
expansions/pics/9910105.jpg
expansions/pics/9910105.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/9910109.jpg

49.5 KB | W: | H:

expansions/pics/9910109.jpg

49.7 KB | W: | H:

expansions/pics/9910109.jpg
expansions/pics/9910109.jpg
expansions/pics/9910109.jpg
expansions/pics/9910109.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/9910114.jpg

49.5 KB | W: | H:

expansions/pics/9910114.jpg

50.2 KB | W: | H:

expansions/pics/9910114.jpg
expansions/pics/9910114.jpg
expansions/pics/9910114.jpg
expansions/pics/9910114.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/9910129.jpg

42.7 KB | W: | H:

expansions/pics/9910129.jpg

45.1 KB | W: | H:

expansions/pics/9910129.jpg
expansions/pics/9910129.jpg
expansions/pics/9910129.jpg
expansions/pics/9910129.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/9910134.jpg

41 KB | W: | H:

expansions/pics/9910134.jpg

47 KB | W: | H:

expansions/pics/9910134.jpg
expansions/pics/9910134.jpg
expansions/pics/9910134.jpg
expansions/pics/9910134.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/9910141.jpg

48.3 KB | W: | H:

expansions/pics/9910141.jpg

48.4 KB | W: | H:

expansions/pics/9910141.jpg
expansions/pics/9910141.jpg
expansions/pics/9910141.jpg
expansions/pics/9910141.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/9910202.jpg

50.5 KB | W: | H:

expansions/pics/9910202.jpg

50.4 KB | W: | H:

expansions/pics/9910202.jpg
expansions/pics/9910202.jpg
expansions/pics/9910202.jpg
expansions/pics/9910202.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/9910212.jpg

44 KB | W: | H:

expansions/pics/9910212.jpg

44.5 KB | W: | H:

expansions/pics/9910212.jpg
expansions/pics/9910212.jpg
expansions/pics/9910212.jpg
expansions/pics/9910212.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/9910213.jpg

49.5 KB | W: | H:

expansions/pics/9910213.jpg

49.3 KB | W: | H:

expansions/pics/9910213.jpg
expansions/pics/9910213.jpg
expansions/pics/9910213.jpg
expansions/pics/9910213.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/9910216.jpg

45.6 KB | W: | H:

expansions/pics/9910216.jpg

49.3 KB | W: | H:

expansions/pics/9910216.jpg
expansions/pics/9910216.jpg
expansions/pics/9910216.jpg
expansions/pics/9910216.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/9910223.jpg

43 KB | W: | H:

expansions/pics/9910223.jpg

41.9 KB | W: | H:

expansions/pics/9910223.jpg
expansions/pics/9910223.jpg
expansions/pics/9910223.jpg
expansions/pics/9910223.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/9910436.jpg

47.7 KB | W: | H:

expansions/pics/9910436.jpg

47.7 KB | W: | H:

expansions/pics/9910436.jpg
expansions/pics/9910436.jpg
expansions/pics/9910436.jpg
expansions/pics/9910436.jpg
  • 2-up
  • Swipe
  • Onion skin
--魔皇剑 觉醒之魔剑
function c25000160.initial_effect(c)
c:EnableCounterPermit(0xaf1)
c:SetCounterLimit(0xaf1,3)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_EQUIP)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_CONTINUOUS_TARGET)
e1:SetCountLimit(1,25000160+EFFECT_COUNT_CODE_OATH)
e1:SetTarget(c25000160.target)
e1:SetOperation(c25000160.operation)
c:RegisterEffect(e1)
--COUNTER
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_COUNTER)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_SZONE)
e2:SetCost(c25000160.ctcost)
e2:SetTarget(c25000160.cttg)
e2:SetOperation(c25000160.ctop)
c:RegisterEffect(e2)
--Equip limit
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetCode(EFFECT_EQUIP_LIMIT)
e4:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e4:SetValue(c25000160.eqlimit)
c:RegisterEffect(e4)
end
function c25000160.eqlimit(e,c)
return c:IsRace(RACE_ZOMBIE)
end
function c25000160.filter(c)
return c:IsFaceup() and c:IsRace(RACE_ZOMBIE)
end
function c25000160.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and c25000160.filter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c25000160.filter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
Duel.SelectTarget(tp,c25000160.filter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0)
end
function c25000160.operation(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if e:GetHandler():IsRelateToEffect(e) and tc:IsRelateToEffect(e) and tc:IsFaceup() then
Duel.Equip(tp,e:GetHandler(),tc)
end
end
function c25000160.ctcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckLPCost(tp,Duel.GetLP(tp)/2) end
Duel.PayLPCost(tp,Duel.GetLP(tp)/2)
end
function c25000160.cttg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
local b1=c:GetFlagEffect(25000160)==0
local b2=c:GetFlagEffect(05000160)==0
local b3=c:GetFlagEffect(15000160)==0
if chk==0 then return e:GetHandler():GetEquipTarget()~=nil and e:GetHandler():IsCanAddCounter(0xaf1,1) and (b1 or b2 or b3) end
end
function c25000160.ctop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) then
c:AddCounter(0xaf1,1)
local op=0
local b1=c:GetFlagEffect(25000160)==0
local b2=c:GetFlagEffect(05000160)==0
local b3=c:GetFlagEffect(15000160)==0
if b1 and b2 and b3 then
op=Duel.SelectOption(tp,aux.Stringid(25000160,0),aux.Stringid(25000160,1),aux.Stringid(25000160,2))
elseif b1 and b2 then
op=Duel.SelectOption(tp,aux.Stringid(25000160,0),aux.Stringid(25000160,1))
elseif b2 and b3 then
op=Duel.SelectOption(tp,aux.Stringid(25000160,1),aux.Stringid(25000160,2))+1
elseif b1 and b3 then
op=Duel.SelectOption(tp,aux.Stringid(25000160,0),aux.Stringid(25000160,2))
if op==1 then op=op+1 end
elseif b1 then
op=Duel.SelectOption(tp,aux.Stringid(25000160,0))
elseif b2 then
op=Duel.SelectOption(tp,aux.Stringid(25000160,1))+1
elseif b3 then
op=Duel.SelectOption(tp,aux.Stringid(25000160,2))+2
end
if op==0 then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_EQUIP)
e1:SetCode(EFFECT_CHANGE_BATTLE_DAMAGE)
e1:SetValue(aux.ChangeBattleDamage(1,DOUBLE_DAMAGE))
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e1)
c:RegisterFlagEffect(25000160,RESET_EVENT+RESETS_STANDARD,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(25000160,0))
elseif op==1 then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_EQUIP)
e1:SetCode(EFFECT_ATTACK_ALL)
e1:SetValue(1)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e1)
c:RegisterFlagEffect(05000160,RESET_EVENT+RESETS_STANDARD,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(25000160,1))
elseif op==2 then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_INACTIVATE)
e1:SetRange(LOCATION_SZONE)
e1:SetValue(c25000160.efilter)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e1)
c:RegisterFlagEffect(15000160,RESET_EVENT+RESETS_STANDARD,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(25000160,2))
end
end
end
function c25000160.efilter(e,ct)
local p=e:GetHandlerPlayer()
local te,tp=Duel.GetChainInfo(ct,CHAININFO_TRIGGERING_EFFECT,CHAININFO_TRIGGERING_PLAYER)
return te:GetHandler()==e:GetHandler():GetEquipTarget()
end
--升阶魔法 魔皇力融合
function c25000161.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(25000161,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCountLimit(1,25000161+EFFECT_COUNT_CODE_OATH)
e1:SetTarget(c25000161.target)
e1:SetOperation(c25000161.activate)
c:RegisterEffect(e1)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(25000161,1))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_FUSION_SUMMON)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,25000161+EFFECT_COUNT_CODE_OATH)
e1:SetTarget(c25000161.target1)
e1:SetOperation(c25000161.activate1)
c:RegisterEffect(e1)
end
function c25000161.filter1(c,e,tp)
local rk=c:GetRank()
return c:IsFaceup() and c:IsType(TYPE_XYZ) and c:IsRace(RACE_ZOMBIE)
and Duel.IsExistingMatchingCard(c25000161.filter2,tp,LOCATION_EXTRA,0,1,nil,e,tp,c,rk+1)
and aux.MustMaterialCheck(c,tp,EFFECT_MUST_BE_XMATERIAL)
end
function c25000161.filter2(c,e,tp,mc,rk)
return c:IsRank(rk) and c:IsAttribute(ATTRIBUTE_DARK) and mc:IsCanBeXyzMaterial(c)
and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_XYZ,tp,false,false) and Duel.GetLocationCountFromEx(tp,tp,mc,c)>0
end
function c25000161.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c25000161.filter1(chkc,e,tp) end
if chk==0 then return Duel.IsExistingTarget(c25000161.filter1,tp,LOCATION_MZONE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
Duel.SelectTarget(tp,c25000161.filter1,tp,LOCATION_MZONE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function c25000161.activate(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if not aux.MustMaterialCheck(tc,tp,EFFECT_MUST_BE_XMATERIAL) then return end
if tc:IsFacedown() or not tc:IsRelateToEffect(e) or tc:IsControler(1-tp) or tc:IsImmuneToEffect(e) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c25000161.filter2,tp,LOCATION_EXTRA,0,1,1,nil,e,tp,tc,tc:GetRank()+1)
local sc=g:GetFirst()
if sc then
local mg=tc:GetOverlayGroup()
if mg:GetCount()~=0 then
Duel.Overlay(sc,mg)
end
sc:SetMaterial(Group.FromCards(tc))
Duel.Overlay(sc,Group.FromCards(tc))
Duel.SpecialSummon(sc,SUMMON_TYPE_XYZ,tp,tp,false,false,POS_FACEUP)
--immune
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetDescription(aux.Stringid(25000161,2))
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_IMMUNE_EFFECT)
e1:SetProperty(EFFECT_FLAG_CLIENT_HINT)
e1:SetValue(c25000161.efilter)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
sc:RegisterEffect(e1)
sc:CompleteProcedure()
end
end
function c25000161.fefilter(e,te)
return te:GetOwnerPlayer()~=e:GetHandlerPlayer() and te:GetActivateLocation()==LOCATION_MZONE and te:IsActivated()
end
function c25000161.ffilter(c,e,tp,m,f,chkf)
return c:IsType(TYPE_FUSION) and (not f or f(c)) and c:IsAttribute(ATTRIBUTE_DARK)
and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_FUSION,tp,false,false) and c:CheckFusionMaterial(m,nil,chkf)
end
function c25000161.ffilter2(c,e)
return not c:IsImmuneToEffect(e)
end
function c25000161.ffcheck(tp,sg,fc)
return sg:IsExists(Card.IsRace,nil,1,RACE_ZOMBIE)
end
function c25000161.target1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
local chkf=tp
local mg1=Duel.GetFusionMaterial(tp)
aux.FCheckAdditional=c25000161.ffcheck
local res=Duel.IsExistingMatchingCard(c25000161.ffilter,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 mg3=fgroup(ce,e,tp)
local mf=ce:GetValue()
res=Duel.IsExistingMatchingCard(c25000161.ffilter,tp,LOCATION_EXTRA,0,1,nil,e,tp,mg3,mf,chkf)
end
end
aux.FCheckAdditional=nil
return res
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function c25000161.activate1(e,tp,eg,ep,ev,re,r,rp)
local chkf=tp
local mg1=Duel.GetFusionMaterial(tp):Filter(c25000161.ffilter2,nil,e)
aux.FCheckAdditional=c25000161.ffcheck
local sg1=Duel.GetMatchingGroup(c25000161.ffilter,tp,LOCATION_EXTRA,0,nil,e,tp,mg1,nil,chkf)
local mg3=nil
local sg2=nil
local ce=Duel.GetChainMaterial(tp)
if ce~=nil then
local fgroup=ce:GetTarget()
mg3=fgroup(ce,e,tp)
local mf=ce:GetValue()
sg2=Duel.GetMatchingGroup(c25000161.ffilter,tp,LOCATION_EXTRA,0,nil,e,tp,mg3,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,mg3,nil,chkf)
local fop=ce:GetOperation()
fop(ce,e,tp,tc,mat2)
end
--immune
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetDescription(aux.Stringid(25000161,2))
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_IMMUNE_EFFECT)
e1:SetProperty(EFFECT_FLAG_CLIENT_HINT)
e1:SetValue(c25000161.efilter)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1)
tc:CompleteProcedure()
end
aux.FCheckAdditional=nil
end
...@@ -39,13 +39,10 @@ function c30000625.lvtg1(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -39,13 +39,10 @@ function c30000625.lvtg1(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SelectTarget(tp,c30000625.filter,tp,LOCATION_MZONE+LOCATION_GRAVE,0,1,1,nil) Duel.SelectTarget(tp,c30000625.filter,tp,LOCATION_MZONE+LOCATION_GRAVE,0,1,1,nil)
end end
function c30000625.filter1(c,att)
return c:IsAttribute(att) and c:IsFaceup()
end
function c30000625.lvop1(e,tp,eg,ep,ev,re,r,rp) function c30000625.lvop1(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
local c=e:GetHandler() local c=e:GetHandler()
local g=Duel.GetMatchingGroup(c30000625.filter1,tp,LOCATION_MZONE,0,nil,tc:GetAttribute()) local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_MZONE,0,nil)
if g:GetCount()<1 then return end if g:GetCount()<1 then return end
if tc:IsFaceup() and tc:IsRelateToEffect(e) then if tc:IsFaceup() and tc:IsRelateToEffect(e) then
for ac in aux.Next(g) do for ac in aux.Next(g) do
......
...@@ -23,13 +23,10 @@ c:EnableReviveLimit() ...@@ -23,13 +23,10 @@ c:EnableReviveLimit()
c:RegisterEffect(e1) c:RegisterEffect(e1)
--activate --activate
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(m,2)) e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e3:SetCode(EVENT_PHASE+PHASE_END) e3:SetCode(EVENT_TO_GRAVE)
e3:SetRange(LOCATION_GRAVE) e3:SetOperation(cm.regop)
e3:SetCost(cm.thcost)
e3:SetTarget(cm.acttg)
e3:SetOperation(cm.actop)
c:RegisterEffect(e3) c:RegisterEffect(e3)
end end
function cm.matfilter(c) function cm.matfilter(c)
...@@ -46,7 +43,7 @@ end ...@@ -46,7 +43,7 @@ end
function cm.desreptg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.desreptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return eg:IsExists(cm.repfilter,1,nil,tp) if chk==0 then return eg:IsExists(cm.repfilter,1,nil,tp)
and Duel.IsExistingMatchingCard(cm.desfilter,tp,LOCATION_GRAVE,0,3,nil,e,tp) end and Duel.IsExistingMatchingCard(cm.desfilter,tp,LOCATION_GRAVE,0,3,nil,e,tp) end
if Duel.SelectYesNo(tp,aux.Stringid(m,1)) then if Duel.SelectYesNo(tp,aux.Stringid(m,0)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,cm.desfilter,tp,LOCATION_GRAVE,0,3,3,nil,e,tp) local g=Duel.SelectMatchingCard(tp,cm.desfilter,tp,LOCATION_GRAVE,0,3,3,nil,e,tp)
g:KeepAlive() g:KeepAlive()
...@@ -62,7 +59,22 @@ function cm.desrepop(e,tp,eg,ep,ev,re,r,rp) ...@@ -62,7 +59,22 @@ function cm.desrepop(e,tp,eg,ep,ev,re,r,rp)
local tg=e:GetLabelObject() local tg=e:GetLabelObject()
Duel.SendtoDeck(tg,nil,2,REASON_EFFECT+REASON_REPLACE) Duel.SendtoDeck(tg,nil,2,REASON_EFFECT+REASON_REPLACE)
end end
function cm.regop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsPreviousLocation(LOCATION_ONFIELD) then
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TOHAND)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_PHASE+PHASE_END)
e1:SetRange(LOCATION_GRAVE)
e1:SetCountLimit(1,m)
e1:SetCost(cm.thcost)
e1:SetTarget(cm.acttg)
e1:SetOperation(cm.actop)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
c:RegisterEffect(e1)
end
end
function cm.thcost(e,tp,eg,ep,ev,re,r,rp,chk) function cm.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToExtraAsCost() end if chk==0 then return e:GetHandler():IsAbleToExtraAsCost() end
Duel.SendtoDeck(e:GetHandler(),nil,2,REASON_COST) Duel.SendtoDeck(e:GetHandler(),nil,2,REASON_COST)
...@@ -82,3 +94,5 @@ function cm.actop(e,tp,eg,ep,ev,re,r,rp) ...@@ -82,3 +94,5 @@ function cm.actop(e,tp,eg,ep,ev,re,r,rp)
Duel.ConfirmCards(1-tp,g) Duel.ConfirmCards(1-tp,g)
end end
end end
--懵懂的暗芽
local m=30005030
local cm=_G["c"..m]
function cm.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_RITUAL_LEVEL)
e1:SetValue(cm.rlevel)
c:RegisterEffect(e1)
--yishijiefang
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_EXTRA_RITUAL_MATERIAL)
e2:SetValue(cm.mtval)
c:RegisterEffect(e2)
--yishimudchuwai
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e3:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
e3:SetValue(1)
c:RegisterEffect(e3)
--not link
end
function cm.rlevel(e,c)
local lv=e:GetHandler():GetLevel()
if c:IsAttribute(ATTRIBUTE_DARK) then
local clv=c:GetLevel()
return lv*65536+clv
else return lv end
end
function cm.mtval(e,c)
return c:IsAttribute(ATTRIBUTE_DARK)
end
\ No newline at end of file
...@@ -76,47 +76,49 @@ end ...@@ -76,47 +76,49 @@ end
function c33400033.fusfilter5(c) function c33400033.fusfilter5(c)
return c:IsSetCard(0x3341) return c:IsSetCard(0x3341)
end end
function c33400033.spfilter1(c,fc,tp) function c33400033.spfilter1(c)
return c:IsSetCard(0x3341) and c:IsFusionType(TYPE_FUSION) and c:IsCanBeFusionMaterial(fc) and c:IsAbleToRemoveAsCost() return (c:IsFaceup() or c:IsLocation(LOCATION_GRAVE)) and c:IsSetCard(0x3341) and c:IsFusionType(TYPE_FUSION) and c:IsAbleToRemoveAsCost()
end end
function c33400033.spfilter2(c,fc,tp) function c33400033.spfilter2(c)
return c:IsSetCard(0x3341) and c:IsFusionType(TYPE_SYNCHRO) and c:IsCanBeFusionMaterial(fc) and c:IsAbleToRemoveAsCost() return (c:IsFaceup() or c:IsLocation(LOCATION_GRAVE)) and c:IsSetCard(0x3341) and c:IsFusionType(TYPE_SYNCHRO) and c:IsAbleToRemoveAsCost()
end end
function c33400033.spfilter3(c,fc,tp) function c33400033.spfilter3(c)
return c:IsSetCard(0x3341) and c:IsFusionType(TYPE_XYZ) and c:IsCanBeFusionMaterial(fc) and c:IsAbleToRemoveAsCost() return (c:IsFaceup() or c:IsLocation(LOCATION_GRAVE)) and c:IsSetCard(0x3341) and c:IsFusionType(TYPE_XYZ) and c:IsAbleToRemoveAsCost()
end end
function c33400033.spfilter4(c,fc,tp) function c33400033.spfilter4(c)
return c:IsSetCard(0x3341) and c:IsFusionType(TYPE_LINK) and c:IsCanBeFusionMaterial(fc) and c:IsAbleToRemoveAsCost() return (c:IsFaceup() or c:IsLocation(LOCATION_GRAVE)) and c:IsSetCard(0x3341) and c:IsFusionType(TYPE_LINK) and c:IsAbleToRemoveAsCost()
end end
function c33400033.spfilter5(c,fc,tp) function c33400033.spfilter5(c)
return c:IsSetCard(0x3341) and c:IsLevelBelow(4) and c:IsType(TYPE_EFFECT) and c:IsCanBeFusionMaterial(fc) and c:IsAbleToRemoveAsCost() return (c:IsFaceup() or c:IsLocation(LOCATION_GRAVE)) and c:IsSetCard(0x3341) and c:IsLevelBelow(4) and c:IsType(TYPE_EFFECT) and c:IsAbleToRemoveAsCost()
end
function c33400033.spcostfilter(c)
return (c:IsFaceup() or c:IsLocation(LOCATION_GRAVE)) and c:IsSetCard(0x3341)
and c:IsAbleToRemoveAsCost() and (c:IsType(TYPE_FUSION+TYPE_SYNCHRO+TYPE_XYZ+TYPE_LINK) or c:IsLevelBelow(4))
end end
function c33400033.spcon(e,c) function c33400033.spcon(e,c)
if c==nil then return true end if c==nil then return true end
local tp=c:GetControler() local tp=c:GetControler()
return Duel.GetLocationCountFromEx(tp,tp,nil,c)>0 return (Duel.GetLocationCountFromEx(tp,tp,nil,c)>0 or Duel.IsExistingMatchingCard(c33400033.spcostfilter,tp,LOCATION_MZONE,0,1,nil,c))
and Duel.IsExistingMatchingCard(c33400033.spfilter1,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,nil,c,fc,tp) and Duel.IsExistingMatchingCard(c33400033.spfilter1,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,nil)
and Duel.IsExistingMatchingCard(c33400033.spfilter2,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,nil,c,fc,tp) and Duel.IsExistingMatchingCard(c33400033.spfilter2,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,nil)
and Duel.IsExistingMatchingCard(c33400033.spfilter3,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,nil,c,fc,tp) and Duel.IsExistingMatchingCard(c33400033.spfilter3,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,nil)
and Duel.IsExistingMatchingCard(c33400033.spfilter4,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,nil,c,fc,tp) and Duel.IsExistingMatchingCard(c33400033.spfilter4,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,nil)
and Duel.IsExistingMatchingCard(c33400033.spfilter5,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,nil,c,fc,tp) and Duel.IsExistingMatchingCard(c33400033.spfilter5,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,nil)
end
function c33400033.check(g)
return g:IsExists(c33400033.spfilter1,1,nil)
and g:IsExists(c33400033.spfilter2,1,nil)
and g:IsExists(c33400033.spfilter3,1,nil)
and g:IsExists(c33400033.spfilter4,1,nil)
and g:IsExists(c33400033.spfilter5,1,nil)
and Duel.GetLocationCountFromEx(tp,tp,g,c)>0
end end
function c33400033.spop(e,tp,eg,ep,ev,re,r,rp,c) function c33400033.spop(e,tp,eg,ep,ev,re,r,rp,c)
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(33400033,1)) local g=Duel.GetMatchingGroup(c33400033.spcostfilter,tp,LOCATION_GRAVE+LOCATION_MZONE,0,nil)
local g1=Duel.SelectMatchingCard(tp,c33400033.spfilter1,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,1,nil,c,tp) if g:GetCount()<5 then return end
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(33400033,2)) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g2=Duel.SelectMatchingCard(tp,c33400033.spfilter2,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,1,nil,c,tp) local g1=g:SelectSubGroup(tp,c33400033.check,false,5,5)
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(33400033,3)) c:SetMaterial(nil)
local g3=Duel.SelectMatchingCard(tp,c33400033.spfilter3,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,1,nil,c,tp)
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(33400033,4))
local g4=Duel.SelectMatchingCard(tp,c33400033.spfilter4,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,1,nil,c,tp)
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(33400033,5))
local g5=Duel.SelectMatchingCard(tp,c33400033.spfilter5,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,1,nil,c,tp)
g1:Merge(g2)
g1:Merge(g3)
g1:Merge(g4)
g1:Merge(g5)
c:SetMaterial(g1)
Duel.Remove(g1,POS_FACEUP,REASON_EFFECT) Duel.Remove(g1,POS_FACEUP,REASON_EFFECT)
end end
function c33400033.afilter(c) function c33400033.afilter(c)
......
--天使-冰结傀儡 --天使-冰结傀儡
function c33400502.initial_effect(c) local m=33400502
c:SetUniqueOnField(1,0,33400502) local cm=_G["c"..m]
function cm.initial_effect(c)
c:SetUniqueOnField(1,0,m)
--atc --atc
local e0=Effect.CreateEffect(c) local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_ACTIVATE) e0:SetType(EFFECT_TYPE_ACTIVATE)
...@@ -11,220 +13,69 @@ c:SetUniqueOnField(1,0,33400502) ...@@ -11,220 +13,69 @@ c:SetUniqueOnField(1,0,33400502)
e1:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e1:SetCode(EVENT_CHAINING) e1:SetCode(EVENT_CHAINING)
e1:SetRange(LOCATION_SZONE) e1:SetRange(LOCATION_SZONE)
e1:SetCondition(c33400502.condition) e1:SetCondition(cm.condition)
e1:SetOperation(c33400502.counter) e1:SetOperation(cm.counter)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--search --destroy
local e2=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOHAND+CATEGORY_RECOVER+CATEGORY_ATKCHANGE+CATEGORY_DEFCHANGE) e3:SetCategory(CATEGORY_DESTROY+CATEGORY_SEARCH+CATEGORY_TOHAND+CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_QUICK_O) e3:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_SZONE) e3:SetCountLimit(1,m)
e2:SetCode(EVENT_FREE_CHAIN) e3:SetRange(LOCATION_SZONE)
e2:SetCost(c33400502.cost) e3:SetCost(cm.cost)
e2:SetTarget(c33400502.thtg2) e3:SetTarget(cm.destg)
e2:SetOperation(c33400502.thop2) e3:SetOperation(cm.desop)
c:RegisterEffect(e2) c:RegisterEffect(e3)
end end
function c33400502.cnfilter(c) function cm.cnfilter(c)
return c:IsSetCard(0x6341) and c:IsFaceup() return c:IsSetCard(0x6341) and c:IsFaceup()
end end
function c33400502.cost(e,tp,eg,ep,ev,re,r,rp,chk) function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckLPCost(tp,1000) or Duel.IsExistingMatchingCard(c33400502.cnfilter,tp,LOCATION_ONFIELD,0,1,nil) end if chk==0 then return Duel.CheckLPCost(tp,1000) or Duel.IsExistingMatchingCard(cm.cnfilter,tp,LOCATION_ONFIELD,0,1,nil) end
if not Duel.IsExistingMatchingCard(c33400502.cnfilter,tp,LOCATION_ONFIELD,0,1,nil)then Duel.PayLPCost(tp,1000) if not Duel.IsExistingMatchingCard(cm.cnfilter,tp,LOCATION_ONFIELD,0,1,nil)then Duel.PayLPCost(tp,1000)
end end
end end
function c33400502.condition(e,tp,eg,ep,ev,re,r,rp) function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return re:GetHandler():IsOnField() and re:GetHandler():IsRelateToEffect(re) and re:GetHandler()~=e:GetHandler() and re:GetHandler():IsCanAddCounter(0x1015,1) return re:GetHandler():IsOnField() and re:GetHandler():IsRelateToEffect(re) and re:GetHandler()~=e:GetHandler() and re:GetHandler():IsCanAddCounter(0x1015,1)
end end
function c33400502.counter(e,tp,eg,ep,ev,re,r,rp) function cm.counter(e,tp,eg,ep,ev,re,r,rp)
local c=re:GetHandler() local c=re:GetHandler()
if c:IsLocation(LOCATION_ONFIELD) and re:GetHandler():IsRelateToEffect(re) then if c:IsLocation(LOCATION_ONFIELD) and re:GetHandler():IsRelateToEffect(re) then
c:AddCounter(0x1015,1) c:AddCounter(0x1015,1)
end end
end end
function c33400502.thtg2(e,tp,eg,ep,ev,re,r,rp,chk) function cm.destg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsCanRemoveCounter(tp,1,1,0x1015,1,REASON_COST) if chk==0 then return Duel.IsExistingMatchingCard(nil,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,e:GetHandler()) end
end local g=Duel.GetMatchingGroup(nil,tp,LOCATION_HAND+LOCATION_ONFIELD,0,e:GetHandler())
local cn=Duel.GetCounter(tp,1,1,0x1015) Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
local lvt={}
for i=1,16 do
if cn>=i then lvt[i]=i end
end
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(33400502,0))
local sc1=Duel.AnnounceNumber(tp,table.unpack(lvt))
Duel.RemoveCounter(tp,1,1,0x1015,sc1,REASON_COST)
for i=1,sc1 do
Duel.RegisterFlagEffect(tp,33400502,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
end
e:SetLabel(sc1)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON+CATEGORY_TOHAND+CATEGORY_RECOVER+CATEGORY_ATKCHANGE+CATEGORY_DEFCHANGE,0,0,0,0)
end end
function c33400502.thop2(e,tp,eg,ep,ev,re,r,rp) function cm.desop(e,tp,eg,ep,ev,re,r,rp)
local nm=e:GetLabel() local c=e:GetHandler()
local op={} Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local t local g=Duel.SelectMatchingCard(tp,nil,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,1,c)
local i=1
if Duel.GetFlagEffect(tp,33430502)==0 and Duel.GetFlagEffect(tp,33400502)>=4 and Duel.IsExistingMatchingCard(Card.IsSetCard,tp,LOCATION_MZONE,0,1,nil,0x341) then
op[i]=3
i=i+1
end
if Duel.GetFlagEffect(tp,33440502)==0 and Duel.GetFlagEffect(tp,33400502)>=7 and Duel.IsExistingMatchingCard(c33400502.filter1,tp,LOCATION_ONFIELD,0,1,nil) then
op[i]=4
i=i+1
end
if Duel.GetFlagEffect(tp,33450502)==0 and Duel.GetFlagEffect(tp,33400502)>=10 and Duel.IsExistingMatchingCard(c33400502.filter2,tp,LOCATION_MZONE,0,1,nil) then
op[i]=5
i=i+1
end
if Duel.GetFlagEffect(tp,33470502)==0 and Duel.GetFlagEffect(tp,33400502)>=13 and Duel.IsExistingMatchingCard(c33400502.filter3,tp,LOCATION_DECK+LOCATION_EXTRA,0,1,nil) then
op[i]=6
i=i+1
end
if Duel.GetFlagEffect(tp,33460502)==0 and Duel.GetFlagEffect(tp,33400502)>=16 then
op[i]=7
i=i+1
end
if i==1 then
Duel.Recover(tp,nm*100,REASON_EFFECT)
else
t=Duel.SelectOption(tp,aux.Stringid(33400502,1),aux.Stringid(33400502,2))
if t==0 then Duel.Recover(tp,nm*100,REASON_EFFECT)
else
local j=0
local op1
repeat
if i==2 then
op1=1
end
if i==3 then
op1=Duel.SelectOption(tp,aux.Stringid(33400502,op[1]),aux.Stringid(33400502,op[2]))+1
end
if i==4 then
op1=Duel.SelectOption(tp,aux.Stringid(33400502,op[1]),aux.Stringid(33400502,op[2]),aux.Stringid(33400502,op[3]))+1
end
if i==5 then
op1=Duel.SelectOption(tp,aux.Stringid(33400502,op[1]),aux.Stringid(33400502,op[2]),aux.Stringid(33400502,op[3]),aux.Stringid(33400502,op[4]))+1
end
if i==6 then
op1=Duel.SelectOption(tp,aux.Stringid(33400502,op[1]),aux.Stringid(33400502,op[2]),aux.Stringid(33400502,op[3]),aux.Stringid(33400502,op[4]),aux.Stringid(33400502,op[5]))+1
end
local xz=0
if op[op1]==3 then
local tc3=Duel.SelectMatchingCard(tp,Card.IsSetCard,tp,LOCATION_MZONE,0,1,1,nil,0x341)
local tc2=tc3:GetFirst()
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(c33400502.valcon)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc2:RegisterEffect(e1)
Duel.RegisterFlagEffect(tp,33430502,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
if op1~=i-1 then
for i2=op1,i-1 do
op[op1]=op[op1+1]
end
end
i=i-1
xz=1
end
if op[op1]==4 and xz==0 then
local tc3=Duel.SelectMatchingCard(tp,c33400502.filter1,tp,LOCATION_ONFIELD,0,1,1,nil)
local tc2=tc3:GetFirst()
local e4=Effect.CreateEffect(e:GetHandler())
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetCode(EFFECT_IMMUNE_EFFECT)
e4:SetValue(c33400502.efilter)
e4:SetOwnerPlayer(tp)
e4:SetReset(RESET_EVENT+0x1fe0000+RESET_CHAIN)
tc2:RegisterEffect(e4)
Duel.RegisterFlagEffect(tp,33440502,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
if op1~=i-1 then
for i2=op1,i-1 do
op[op1]=op[op1+1]
end
end
i=i-1
xz=1
end
if op[op1]==5 and xz==0 then
local tc3=Duel.SelectMatchingCard(tp,c33400502.filter2,tp,LOCATION_MZONE,0,1,1,nil)
local tc2=tc3:GetFirst()
local nm1=Duel.GetCounter(tp,1,1,0x1015)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(200*nm1)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc2:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_UPDATE_DEFENSE)
tc2:RegisterEffect(e2)
Duel.RegisterFlagEffect(tp,33450502,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
if op1~=i-1 then
for i2=op1,i-1 do
op[op1]=op[op1+1]
end
end
i=i-1
xz=1
end
if op[op1]==7 and xz==0 then
local g=Duel.GetMatchingGroup(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,0x1015,1)
local tc=g:GetFirst() local tc=g:GetFirst()
while tc do if tc and Duel.Destroy(tc,REASON_EFFECT)~=0 then
tc:AddCounter(0x1015,1,REASON_EFFECT) if tc:IsSetCard(0x3344) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
tc=g:GetNext() and Duel.IsExistingMatchingCard(cm.spfilter1,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil,e,tp)
end and Duel.SelectYesNo(tp,aux.Stringid(m,1)) then
Duel.RegisterFlagEffect(tp,33460502,RESET_EVENT+RESET_PHASE+PHASE_END,0,0) Duel.BreakEffect()
if op1~=i-1 then Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
for i2=op1,i-1 do local tg=Duel.SelectMatchingCard(tp,cm.spfilter1,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil,e,tp)
op[op1]=op[op1+1] Duel.SpecialSummon(tg,0,tp,tp,false,false,POS_FACEUP)
end
end
i=i-1
xz=1
end
if op[op1]==6 and xz==0 then
local tc2=Duel.SelectMatchingCard(tp,c33400502.filter3,tp,LOCATION_DECK+LOCATION_EXTRA,0,2,2,nil)
Duel.SendtoHand(tc2,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc2)
Duel.RegisterFlagEffect(tp,33470502,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
if op1~=i-1 then
for i2=op1,i-1 do
op[op1]=op[op1+1]
end
end
i=i-1
xz=1
end
if i==1 then j=0
else if Duel.SelectYesNo(tp,aux.Stringid(33400502,8)) then j=1
else j=0
end
end end
xz=0 if tc:IsSetCard(0x6341) and Duel.IsExistingMatchingCard(cm.thfilter1,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(m,2)) then
until(j==0)
Duel.BreakEffect() Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local tg2=Duel.SelectMatchingCard(tp,cm.thfilter1,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil)
Duel.SendtoHand(tg2,nil,REASON_EFFECT)
end end
end end
end end
function c33400502.valcon(e,re,r,rp) function cm.spfilter1(c,e,tp)
return bit.band(r,REASON_BATTLE+REASON_EFFECT)~=0 return c:IsSetCard(0x6341) and c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c33400502.efilter(e,re)
return e:GetOwnerPlayer()~=re:GetOwnerPlayer()
end
function c33400502.filter1(c)
return c:IsSetCard(0x341) or c:IsSetCard(0x340)
end
function c33400502.filter2(c)
return c:IsType(TYPE_MONSTER)and c:IsSetCard(0x6341) or c:IsSetCard(0x3344)
end end
function c33400502.filter3(c) function cm.thfilter1(c)
return c:IsAbleToHand()and c:IsType(TYPE_MONSTER)and c:IsLevel(4) and (c:IsSetCard(0x6341) or c:IsSetCard(0x3344)) return c:IsSetCard(0x3344) and c:IsAbleToHand()
end end
\ No newline at end of file
...@@ -18,7 +18,8 @@ function cm.initial_effect(c) ...@@ -18,7 +18,8 @@ function cm.initial_effect(c)
e1:SetDescription(aux.Stringid(m,0)) e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION) e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_GRAVE) e1:SetRange(LOCATION_GRAVE+LOCATION_HAND)
e1:SetCountLimit(1,m)
e1:SetCost(cm.spcost) e1:SetCost(cm.spcost)
e1:SetTarget(cm.sptg) e1:SetTarget(cm.sptg)
e1:SetOperation(cm.spop) e1:SetOperation(cm.spop)
...@@ -54,11 +55,11 @@ function cm.ckfilter(c) ...@@ -54,11 +55,11 @@ function cm.ckfilter(c)
return c:IsSetCard(0x3344) and c:IsFaceup() return c:IsSetCard(0x3344) and c:IsFaceup()
end end
function cm.spcost(e,tp,eg,ep,ev,re,r,rp,chk) function cm.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsCanRemoveCounter(tp,1,1,0x1015,3,REASON_COST) and (Duel.CheckLPCost(tp,1000) or Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_ONFIELD,0,1,nil)) end if chk==0 then return Duel.IsCanRemoveCounter(tp,1,1,0x1015,4,REASON_COST) and (Duel.CheckLPCost(tp,1000) or Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_ONFIELD,0,1,nil)) end
if not Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_ONFIELD,0,1,nil)then Duel.PayLPCost(tp,1000) if not Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_ONFIELD,0,1,nil)then Duel.PayLPCost(tp,1000)
end end
Duel.Hint(HINT_OPSELECTED,tp,aux.Stringid(m,1)) Duel.Hint(HINT_OPSELECTED,tp,aux.Stringid(m,1))
Duel.RemoveCounter(tp,1,1,0x1015,3,REASON_COST) Duel.RemoveCounter(tp,1,1,0x1015,4,REASON_COST)
end end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
......
...@@ -32,27 +32,24 @@ function cm.initial_effect(c) ...@@ -32,27 +32,24 @@ function cm.initial_effect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY) e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_DESTROYED) e2:SetCode(EVENT_DESTROYED)
e2:SetCountLimit(1,m+10000)
e2:SetCost(cm.cost) e2:SetCost(cm.cost)
e2:SetTarget(cm.tgtg) e2:SetTarget(cm.tgtg)
e2:SetOperation(cm.tgop) e2:SetOperation(cm.tgop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function cm.desfilter(c)
return c:GetCounter(0x1015)~=0
end
function cm.destg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.destg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.desfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,e:GetHandler()) end
local g=Duel.SelectTarget(tp,cm.desfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil) local g=Duel.SelectTarget(tp,Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,e:GetHandler())
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0) Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0)
end end
function cm.desop(e,tp,eg,ep,ev,re,r,rp) function cm.desop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end if not e:GetHandler():IsRelateToEffect(e) then return end
local g=Duel.GetMatchingGroup(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,0x1015,1) local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil)
if g:GetCount()==0 then return end local gc=g:GetFirst()
for i=1,2 do while gc do
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_COUNTER) gc:AddCounter(0x1015,1)
local tc=g:Select(tp,1,1,nil):GetFirst() gc=g:GetNext()
tc:AddCounter(0x1015,1)
end end
local tc1=Duel.GetFirstTarget() local tc1=Duel.GetFirstTarget()
local g1=Group.CreateGroup() local g1=Group.CreateGroup()
...@@ -94,12 +91,11 @@ function cm.tgtg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -94,12 +91,11 @@ function cm.tgtg(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_EXTRA) Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_EXTRA)
end end
function cm.tgop(e,tp,eg,ep,ev,re,r,rp) function cm.tgop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,0x1015,1) local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil)
if g:GetCount()==0 then return end local gc=g:GetFirst()
for i=1,2 do while gc do
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_COUNTER) gc:AddCounter(0x1015,1)
local tc=g:Select(tp,1,1,nil):GetFirst() gc=g:GetNext()
tc:AddCounter(0x1015,1)
end end
if Duel.IsExistingMatchingCard(cm.tgfilter,tp,LOCATION_EXTRA,0,1,nil) then if Duel.IsExistingMatchingCard(cm.tgfilter,tp,LOCATION_EXTRA,0,1,nil) then
if Duel.SelectYesNo(tp,aux.Stringid(m,2)) then if Duel.SelectYesNo(tp,aux.Stringid(m,2)) then
......
...@@ -17,32 +17,17 @@ function cm.initial_effect(c) ...@@ -17,32 +17,17 @@ function cm.initial_effect(c)
e0:SetTarget(cm.destg) e0:SetTarget(cm.destg)
e0:SetOperation(cm.desop) e0:SetOperation(cm.desop)
c:RegisterEffect(e0) c:RegisterEffect(e0)
-- --to extra
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0)) e1:SetDescription(aux.Stringid(m,1))
e1:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD) e1:SetCategory(CATEGORY_TOEXTRA)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_SUMMON_SUCCESS) e1:SetCountLimit(1,m+10000)
e1:SetRange(LOCATION_MZONE) e1:SetTarget(cm.tetg)
e1:SetCost(cm.cost) e1:SetOperation(cm.teop)
e1:SetCondition(cm.ctcon)
e1:SetOperation(cm.ctop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e2)
--
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(m,1))
e3:SetCategory(CATEGORY_COUNTER+CATEGORY_DRAW)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_DESTROYED)
e3:SetCountLimit(1,m+10000)
e3:SetCost(cm.cost)
e3:SetTarget(cm.target)
e3:SetOperation(cm.operation)
c:RegisterEffect(e3)
end end
function cm.lcheck(g) function cm.lcheck(g)
return g:IsExists(Card.IsLinkSetCard,1,nil,0x6341,0x3344) return g:IsExists(Card.IsLinkSetCard,1,nil,0x6341,0x3344)
...@@ -90,35 +75,17 @@ function cm.desop(e,tp,eg,ep,ev,re,r,rp) ...@@ -90,35 +75,17 @@ function cm.desop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function cm.cfilter(c) function cm.tefilter(c)
return c:IsFaceup() and c:IsControler(tp) and c:IsCanAddCounter(0x1015,1) return c:IsType(TYPE_PENDULUM) and c:IsSetCard(0x341)
end
function cm.ctcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(cm.cfilter,1,nil)
end end
function cm.ctop(e,tp,eg,ep,ev,re,r,rp) function cm.tetg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() if chk==0 then return Duel.IsExistingMatchingCard(cm.tefilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil) end
local g=eg:Filter(cm.cfilter,nil) Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,nil,1,tp,LOCATION_DECK+LOCATION_GRAVE)
local tc=g:GetFirst()
while tc do
tc:AddCounter(0x1015,1)
tc=g:GetNext()
end
end end
function cm.teop(e,tp,eg,ep,ev,re,r,rp)
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk) Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(m,3))
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) local g=Duel.SelectMatchingCard(tp,cm.tefilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil)
and Duel.IsExistingMatchingCard(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil,0x1015,1) end if g:GetCount()>0 then
end Duel.SendtoExtraP(g,tp,REASON_EFFECT)
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
local ct=Duel.GetMatchingGroupCount(cm.ctfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil)
if ct==0 then return end
local g=Duel.GetMatchingGroup(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,0x1015,1)
if g:GetCount()==0 then return end
for i=1,4 do
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_COUNTER)
local tc=g:Select(tp,1,1,nil):GetFirst()
tc:AddCounter(0x1015,1)
end end
Duel.Draw(tp,1,REASON_EFFECT)
end end
\ No newline at end of file
...@@ -73,7 +73,7 @@ function cm.spcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -73,7 +73,7 @@ function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_XYZ) return e:GetHandler():IsSummonType(SUMMON_TYPE_XYZ)
end end
function cm.spfilter(c,e,tp) function cm.spfilter(c,e,tp)
return c:IsType(TYPE_MONSTER) and (c:IsSetCard(0x341)or c:IsAttribute(ATTRIBUTE_WATER)) and c:IsLevelBelow(4) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsType(TYPE_MONSTER) and (c:IsSetCard(0x341)or c:IsAttribute(ATTRIBUTE_WATER)) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and cm.spfilter(chkc,e,tp) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and cm.spfilter(chkc,e,tp) end
......
...@@ -19,28 +19,26 @@ function cm.initial_effect(c) ...@@ -19,28 +19,26 @@ function cm.initial_effect(c)
--counter --counter
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0)) e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_COUNTER) e1:SetCategory(CATEGORY_RECOVER)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCost(cm.cost) e1:SetCost(cm.cost)
e1:SetCondition(cm.ctcon)
e1:SetTarget(cm.cttg)
e1:SetOperation(cm.ctop) e1:SetOperation(cm.ctop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
-- --negate
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,1)) e2:SetDescription(aux.Stringid(m,1))
e2:SetCategory(CATEGORY_DESTROY+CATEGORY_DRAW) e2:SetCategory(CATEGORY_NEGATE+CATEGORY_DESTROY)
e2:SetType(EFFECT_TYPE_QUICK_O) e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN) e2:SetCode(EVENT_CHAINING)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET) e2:SetCountLimit(1,m)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCost(cm.cost) e2:SetCost(cm.cost2)
e2:SetCountLimit(1) e2:SetCondition(cm.discon)
e2:SetTarget(cm.target) e2:SetTarget(cm.distg)
e2:SetOperation(cm.operation) e2:SetOperation(cm.disop)
e2:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--pendulum --pendulum
local e6=Effect.CreateEffect(c) local e6=Effect.CreateEffect(c)
...@@ -82,44 +80,37 @@ function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -82,44 +80,37 @@ function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if not Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_ONFIELD,0,1,nil)then Duel.PayLPCost(tp,1000) if not Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_ONFIELD,0,1,nil)then Duel.PayLPCost(tp,1000)
end end
end end
function cm.ctcon(e,tp,eg,ep,ev,re,r,rp) function cm.ctop(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_SYNCHRO) local d=Duel.GetCounter(tp,LOCATION_ONFIELD,LOCATION_ONFIELD,0x1015)
Duel.Recover(tp,d*400,REASON_EFFECT)
end end
function cm.cttg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) function cm.discon(e,tp,eg,ep,ev,re,r,rp)
and Duel.IsExistingMatchingCard(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil,0x1015,1) end return rp==1-tp and not e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED) and Duel.IsChainNegatable(ev)
end end
function cm.ctop(e,tp,eg,ep,ev,re,r,rp) function cm.cost2(e,tp,eg,ep,ev,re,r,rp,chk)
local ct=Duel.GetMatchingGroupCount(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,0x1015,1) local ct=e:GetLabel()
if ct==0 then return end if chk==0 then return Duel.IsCanRemoveCounter(tp,1,1,0x1015,3,REASON_COST) and Duel.CheckLPCost(tp,1000) or Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_ONFIELD,0,1,nil) end
local g=Duel.GetMatchingGroup(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,0x1015,1) if not Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_ONFIELD,0,1,nil)then Duel.PayLPCost(tp,1000)
if g:GetCount()==0 then return end
for i=1,4 do
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_COUNTER)
local tc=g:Select(tp,1,1,nil):GetFirst()
tc:AddCounter(0x1015,1)
end end
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
Duel.RemoveCounter(tp,1,1,0x1015,3,REASON_COST)
end end
function cm.distg(e,tp,eg,ep,ev,re,r,rp,chk)
function cm.filter(c) if chk==0 then return true end
return c:GetCounter(0x1015)~=0 Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
end end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function cm.disop(e,tp,eg,ep,ev,re,r,rp)
if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_ONFIELD) and cm.filter(chkc) end if Duel.NegateActivation(ev) and Duel.IsExistingMatchingCard(cm.ckfilter1,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(m,2)) then
if chk==0 then return Duel.IsPlayerCanDraw(tp,1)
and Duel.IsExistingTarget(cm.filter,tp,0,LOCATION_ONFIELD,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectTarget(tp,cm.filter,tp,0,LOCATION_ONFIELD,1,1,nil) local tg=Duel.SelectMatchingCard(tp,cm.ckfilter1,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0) Duel.Destroy(tg,REASON_EFFECT)
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:GetAttack()<tc:GetBaseAttack() and Duel.Destroy(tc,REASON_EFFECT)~=0 then
if Duel.SelectYesNo(tp,aux.Stringid(m,2)) then
Duel.Draw(tp,1,REASON_EFFECT)
end
end end
end end
function cm.ckfilter1(c)
return c:GetCounter(0x1015)~=0
end
function cm.pencon(e,tp,eg,ep,ev,re,r,rp) function cm.pencon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
......
...@@ -100,18 +100,29 @@ function cm.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -100,18 +100,29 @@ function cm.operation(e,tp,eg,ep,ev,re,r,rp)
Duel.RegisterEffect(e1,tp) Duel.RegisterEffect(e1,tp)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_DISABLE) e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetTargetRange(0,LOCATION_GRAVE) e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetTarget(cm.disable) e2:SetTargetRange(0,1)
e2:SetTarget(cm.sumlimit)
e2:SetReset(RESET_PHASE+PHASE_END) e2:SetReset(RESET_PHASE+PHASE_END)
e2:SetLabel(c:GetFieldID())
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetCode(EFFECT_CANNOT_REMOVE)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e3:SetTargetRange(0,1)
e3:SetTarget(cm.relimit)
e3:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e3,tp)
end end
function cm.aclimit(e,re,tp) function cm.aclimit(e,re,tp)
return re:GetActivateLocation()==LOCATION_GRAVE return re:GetActivateLocation()==LOCATION_GRAVE
end end
function cm.disable(e,c) function cm.sumlimit(e,c,sump,sumtype,sumpos,targetp,se)
return c:GetFieldID()~=e:GetLabel() and (not c:IsType(TYPE_MONSTER) or (c:IsType(TYPE_EFFECT) or bit.band(c:GetOriginalType(),TYPE_EFFECT)==TYPE_EFFECT)) return c:IsLocation(LOCATION_GRAVE)
end
function cm.relimit(e,c)
return c:IsLocation(LOCATION_GRAVE)
end end
function cm.target(e,c) function cm.target(e,c)
......
...@@ -23,6 +23,7 @@ function cm.initial_effect(c) ...@@ -23,6 +23,7 @@ function cm.initial_effect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCountLimit(1,m)
e1:SetCost(cm.cost) e1:SetCost(cm.cost)
e1:SetCondition(cm.ctcon) e1:SetCondition(cm.ctcon)
e1:SetTarget(cm.cttg) e1:SetTarget(cm.cttg)
...@@ -75,47 +76,36 @@ end ...@@ -75,47 +76,36 @@ end
function cm.ctcon(e,tp,eg,ep,ev,re,r,rp) function cm.ctcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_FUSION) return e:GetHandler():IsSummonType(SUMMON_TYPE_FUSION)
end end
function cm.tgfilter(c)
return c:IsType(TYPE_MONSTER) and c:IsSetCard(0x341) and c:IsAbleToHand() and c:IsType(TYPE_RITUAL) and c:IsLevelBelow(8)
end
function cm.tgfil(c)
return c:IsType(TYPE_SPELL) and c:IsSetCard(0x341) and c:IsAbleToHand() and c:IsType(TYPE_RITUAL)
end
function cm.thfilter3(c)
return ((c:IsType(TYPE_MONSTER) and c:IsType(TYPE_RITUAL) and c:IsLevelBelow(8)) or (c:IsType(TYPE_SPELL) and c:IsType(TYPE_RITUAL)) )and c:IsSetCard(0x341) and c:IsAbleToHand()
end
function cm.cttg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.cttg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) if chk==0 then return Duel.IsExistingMatchingCard(cm.tgfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil) or Duel.IsExistingMatchingCard(cm.tgfil,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil) end
and Duel.IsExistingMatchingCard(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil,0x1015,1) end Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,2,tp,LOCATION_DECK+LOCATION_GRAVE)
end end
function cm.ctop(e,tp,eg,ep,ev,re,r,rp) function cm.ctop(e,tp,eg,ep,ev,re,r,rp)
local ct=Duel.GetMatchingGroupCount(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,0x1015,1) local g1=Duel.GetMatchingGroup(cm.thfilter3,tp,LOCATION_DECK+LOCATION_GRAVE,0,nil)
if ct==0 then return end if g1:GetCount()==0 then return end
local g=Duel.GetMatchingGroup(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,0x1015,1) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
if g:GetCount()==0 then return end local g=g1:SelectSubGroup(tp,cm.check,false,1,2)
for i=1,3 do if g:GetCount()>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_COUNTER) Duel.SendtoHand(g,nil,REASON_EFFECT)
local tc=g:Select(tp,1,1,nil):GetFirst() Duel.ConfirmCards(1-tp,g)
tc:AddCounter(0x1015,1)
end
if Duel.IsExistingMatchingCard(aux.disfilter1,tp,0,LOCATION_ONFIELD,1,nil) then
if Duel.SelectYesNo(tp,aux.Stringid(m,2)) then
local g3=Duel.SelectMatchingCard(tp,aux.disfilter1,tp,0,LOCATION_ONFIELD,1,1,nil)
local tc=g3:GetFirst()
Duel.NegateRelatedChain(tc,RESET_TURN_SET)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(e:GetHandler())
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetValue(RESET_TURN_SET)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e2)
if tc:IsType(TYPE_TRAPMONSTER) then
local e3=Effect.CreateEffect(e:GetHandler())
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e3:SetCode(EFFECT_DISABLE_TRAPMONSTER)
e3:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e3)
end
end end
end
function cm.check(g,c)
if #g==1 then return true end
local res=0
if #g==2 then
if g:IsExists(cm.tgfilter,1,nil,c) then res=res+1 end
if g:IsExists(cm.tgfil,1,nil,c) then res=res+4 end
return res==5
end end
end end
......
...@@ -19,7 +19,7 @@ function cm.initial_effect(c) ...@@ -19,7 +19,7 @@ function cm.initial_effect(c)
--Negate --Negate
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(m,0)) e3:SetDescription(aux.Stringid(m,0))
e3:SetCategory(CATEGORY_NEGATE+CATEGORY_DESTROY) e3:SetCategory(CATEGORY_NEGATE+CATEGORY_DESTROY+CATEGORY_TOHAND)
e3:SetType(EFFECT_TYPE_QUICK_O) e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_CHAINING) e3:SetCode(EVENT_CHAINING)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL) e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
...@@ -37,6 +37,7 @@ function cm.initial_effect(c) ...@@ -37,6 +37,7 @@ function cm.initial_effect(c)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e4:SetProperty(EFFECT_FLAG_DELAY) e4:SetProperty(EFFECT_FLAG_DELAY)
e4:SetCode(EVENT_DESTROYED) e4:SetCode(EVENT_DESTROYED)
e4:SetCountLimit(1,m)
e4:SetCost(cm.cost) e4:SetCost(cm.cost)
e4:SetTarget(cm.sptg) e4:SetTarget(cm.sptg)
e4:SetOperation(cm.spop) e4:SetOperation(cm.spop)
...@@ -57,7 +58,7 @@ function cm.ckfilter(c) ...@@ -57,7 +58,7 @@ function cm.ckfilter(c)
return c:IsSetCard(0x3344) and c:IsFaceup() return c:IsSetCard(0x3344) and c:IsFaceup()
end end
function cm.negcon(e,tp,eg,ep,ev,re,r,rp) function cm.negcon(e,tp,eg,ep,ev,re,r,rp)
return not e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED) and ep~=tp and Duel.IsChainNegatable(ev) and re:GetHandler():GetCounter(0x1015)~=0 return not e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED) and Duel.IsChainNegatable(ev)
end end
function cm.negcost(e,tp,eg,ep,ev,re,r,rp,chk) function cm.negcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.ckfilter1,tp,LOCATION_ONFIELD,0,1,nil) and (Duel.CheckLPCost(tp,1000) or Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_ONFIELD,0,1,nil)) end if chk==0 then return Duel.IsExistingMatchingCard(cm.ckfilter1,tp,LOCATION_ONFIELD,0,1,nil) and (Duel.CheckLPCost(tp,1000) or Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_ONFIELD,0,1,nil)) end
...@@ -73,17 +74,17 @@ function cm.negtg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -73,17 +74,17 @@ function cm.negtg(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,1,0,0) Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,1,0,0)
end end
end end
function cm.thfilter(c)
return c:IsAbleToHand() and c:GetCounter(0x1015)~=0
end
function cm.negop(e,tp,eg,ep,ev,re,r,rp) function cm.negop(e,tp,eg,ep,ev,re,r,rp)
if Duel.NegateActivation(ev) and re:GetHandler():IsRelateToEffect(re)then if Duel.NegateActivation(ev) and re:GetHandler():IsRelateToEffect(re)then
local ct=Duel.GetMatchingGroupCount(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,0x1015,1) local ct=Duel.GetMatchingGroupCount(cm.thfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil)
Duel.Destroy(eg,REASON_EFFECT) Duel.Destroy(eg,REASON_EFFECT)
if ct~=0 then if ct~=0 and Duel.SelectYesNo(tp,aux.Stringid(m,2)) then
local g=Duel.GetMatchingGroup(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,0x1015,1) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
for i=1,3 do local g=Duel.SelectMatchingCard(tp,cm.thfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_COUNTER) Duel.SendtoHand(g,nil,REASON_EFFECT)
local tc=g:Select(tp,1,1,nil):GetFirst()
tc:AddCounter(0x1015,1)
end
end end
end end
end end
......
...@@ -55,11 +55,14 @@ function cm.cfilter5(c) ...@@ -55,11 +55,14 @@ function cm.cfilter5(c)
return c:IsType(TYPE_LINK)and c:IsType(TYPE_MONSTER) return c:IsType(TYPE_LINK)and c:IsType(TYPE_MONSTER)
end end
function cm.filter2(c,tp) function cm.filter2(c,tp)
return c:IsSetCard(0x3344) and c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsSSetable(true) and (c:IsType(TYPE_FIELD) or Duel.GetLocationCount(tp,LOCATION_SZONE)>0) return c:IsSetCard(0x3344,0x6341) and c:IsAbleToHand()
end end
function cm.filter3(c,e,tp) function cm.filter3(c,e,tp)
return c:IsSetCard(0x341) and (c:IsFaceup() or not c:IsLocation(LOCATION_EXTRA))and c:IsLevel(4) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and (c:IsLocation(LOCATION_GRAVE) or Duel.GetLocationCountFromEx(tp,tp,nil,c)>0) return c:IsSetCard(0x341) and (c:IsFaceup() or not c:IsLocation(LOCATION_EXTRA))and c:IsLevel(4) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and (c:IsLocation(LOCATION_GRAVE) or Duel.GetLocationCountFromEx(tp,tp,nil,c)>0)
end end
function cm.filter4(c)
return c:IsSetCard(0x3344) and c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsSSetable()
end
function cm.pcfilter(c) function cm.pcfilter(c)
return c:IsSetCard(0x341) and c:IsLevelBelow(8) and c:IsType(TYPE_PENDULUM) and not c:IsForbidden() return c:IsSetCard(0x341) and c:IsLevelBelow(8) and c:IsType(TYPE_PENDULUM) and not c:IsForbidden()
end end
...@@ -81,15 +84,15 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp) ...@@ -81,15 +84,15 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp)
op[i]=0 op[i]=0
i=i+1 i=i+1
end end
if eg:IsExists(cm.cfilter2,1,nil) and Duel.GetFlagEffect(tp,m+20000)==0 and Duel.IsExistingMatchingCard(cm.filter2,tp,LOCATION_GRAVE,0,1,nil,tp) then if eg:IsExists(cm.cfilter2,1,nil) and Duel.GetFlagEffect(tp,m+20000)==0 and Duel.IsExistingMatchingCard(cm.filter3,tp,LOCATION_EXTRA+LOCATION_GRAVE,0,1,nil,e,tp) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then
op[i]=1 op[i]=1
i=i+1 i=i+1
end end
if eg:IsExists(cm.cfilter3,1,nil) and Duel.GetFlagEffect(tp,m+30000)==0 and Duel.IsExistingMatchingCard(cm.filter3,tp,LOCATION_EXTRA+LOCATION_GRAVE,0,1,nil,e,tp) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then if eg:IsExists(cm.cfilter3,1,nil) and Duel.GetFlagEffect(tp,m+30000)==0 and Duel.IsExistingMatchingCard(cm.filter2,tp,LOCATION_GRAVE,0,1,nil,tp)then
op[i]=2 op[i]=2
i=i+1 i=i+1
end end
if eg:IsExists(cm.cfilter4,1,nil) and Duel.GetFlagEffect(tp,m+40000)==0 and Duel.IsExistingMatchingCard(nil,tp,LOCATION_ONFIELD,0,1,nil) then if eg:IsExists(cm.cfilter4,1,nil) and Duel.GetFlagEffect(tp,m+40000)==0 and Duel.IsExistingMatchingCard(cm.filter4,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil) then
op[i]=3 op[i]=3
i=i+1 i=i+1
end end
...@@ -133,9 +136,11 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp) ...@@ -133,9 +136,11 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp)
xz=1 xz=1
end end
if op[op1]==1 and xz==0 then if op[op1]==1 and xz==0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tc3=Duel.SelectMatchingCard(tp,cm.filter2,tp,LOCATION_GRAVE,0,1,1,nil,tp) local g=Duel.SelectMatchingCard(tp,cm.filter3,tp,LOCATION_GRAVE+LOCATION_EXTRA,0,1,1,nil,e,tp)
Duel.SSet(tp,tc3) if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
Duel.RegisterFlagEffect(tp,m+20000,RESET_EVENT+RESET_PHASE+PHASE_END,0,0) Duel.RegisterFlagEffect(tp,m+20000,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
if op1~=i then if op1~=i then
for i2=op1,i-1 do for i2=op1,i-1 do
...@@ -146,11 +151,9 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp) ...@@ -146,11 +151,9 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp)
xz=1 xz=1
end end
if op[op1]==2 and xz==0 then if op[op1]==2 and xz==0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.filter3,tp,LOCATION_GRAVE+LOCATION_EXTRA,0,1,1,nil,e,tp) local tc3=Duel.SelectMatchingCard(tp,cm.filter2,tp,LOCATION_GRAVE,0,1,1,nil,tp)
if g:GetCount()>0 then Duel.SendtoHand(tc3,nil,REASON_EFFECT)
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
Duel.RegisterFlagEffect(tp,m+30000,RESET_EVENT+RESET_PHASE+PHASE_END,0,0) Duel.RegisterFlagEffect(tp,m+30000,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
if op1~=i then if op1~=i then
for i2=op1,i-1 do for i2=op1,i-1 do
...@@ -161,17 +164,23 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp) ...@@ -161,17 +164,23 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp)
xz=1 xz=1
end end
if op[op1]==3 and xz==0 then if op[op1]==3 and xz==0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end
local g=Duel.SelectMatchingCard(tp,nil,tp,LOCATION_ONFIELD,0,1,1,nil)
Duel.Destroy(g,REASON_EFFECT)
if Duel.GetLocationCount(tp,LOCATION_PZONE)~=0 and Duel.IsExistingMatchingCard(cm.pcfilter,tp,LOCATION_EXTRA,0,1,nil) then
if Duel.SelectYesNo(tp,aux.Stringid(m,7)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local g=Duel.SelectMatchingCard(tp,cm.pcfilter,tp,LOCATION_EXTRA,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,cm.filter4,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil)
if g:GetCount()>0 then local tc=g:GetFirst()
Duel.MoveToField(g:GetFirst(),tp,tp,LOCATION_PZONE,POS_FACEUP,true) if tc and Duel.SSet(tp,tc)~=0 then
end local e1=Effect.CreateEffect(e:GetHandler())
end e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_TRAP_ACT_IN_SET_TURN)
e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(e:GetHandler())
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_SET_AVAILABLE)
e2:SetCode(EFFECT_QP_ACT_IN_SET_TURN)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e2)
end end
Duel.RegisterFlagEffect(tp,m+40000,RESET_EVENT+RESET_PHASE+PHASE_END,0,0) Duel.RegisterFlagEffect(tp,m+40000,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
if op1~=i then if op1~=i then
......
...@@ -14,28 +14,82 @@ function cm.initial_effect(c) ...@@ -14,28 +14,82 @@ function cm.initial_effect(c)
e0:SetCode(EFFECT_SPSUMMON_CONDITION) e0:SetCode(EFFECT_SPSUMMON_CONDITION)
e0:SetValue(aux.fuslimit) e0:SetValue(aux.fuslimit)
c:RegisterEffect(e0) c:RegisterEffect(e0)
-- --immune effect
local e8=Effect.CreateEffect(c)
e8:SetType(EFFECT_TYPE_FIELD)
e8:SetCode(EFFECT_IMMUNE_EFFECT)
e8:SetRange(LOCATION_PZONE)
e8:SetTargetRange(LOCATION_ONFIELD,0)
e8:SetTarget(cm.etarget)
e8:SetValue(cm.efilter)
c:RegisterEffect(e8)
--indes
local e9=Effect.CreateEffect(c)
e9:SetType(EFFECT_TYPE_FIELD)
e9:SetProperty(EFFECT_FLAG_SET_AVAILABLE)
e9:SetCode(EFFECT_INDESTRUCTABLE_COUNT)
e9:SetRange(LOCATION_PZONE)
e9:SetTargetRange(LOCATION_ONFIELD,0)
e9:SetValue(cm.indct)
c:RegisterEffect(e9)
--counter
local e10=Effect.CreateEffect(c)
e10:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e10:SetCode(EVENT_CHAINING)
e10:SetProperty(EFFECT_FLAG_DELAY)
e10:SetRange(LOCATION_PZONE)
e10:SetCondition(cm.condition)
e10:SetOperation(cm.counter)
c:RegisterEffect(e10)
--
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0)) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetType(EFFECT_TYPE_IGNITION) e1:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(2,m) e1:SetTargetRange(LOCATION_MZONE,0)
e1:SetCost(cm.cost) e1:SetTarget(cm.indtg)
e1:SetOperation(cm.op) e1:SetValue(aux.indoval)
c:RegisterEffect(e1) c:RegisterEffect(e1)
-- local e2=e1:Clone()
local e2=Effect.CreateEffect(c) e2:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET)
e2:SetDescription(aux.Stringid(m,1)) e2:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e2:SetCategory(CATEGORY_DESTROY+CATEGORY_NEGATE+CATEGORY_REMOVE) e2:SetValue(aux.tgoval)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_CHAINING)
e2:SetCountLimit(2,m)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
e2:SetRange(LOCATION_MZONE)
e2:SetCondition(cm.negcon)
e2:SetTarget(cm.negtg)
e2:SetOperation(cm.negop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--Disable
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetCode(EFFECT_DISABLE)
e3:SetRange(LOCATION_MZONE)
e3:SetTargetRange(0,LOCATION_ONFIELD)
e3:SetTarget(cm.attg)
c:RegisterEffect(e3)
--atkup
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD)
e4:SetCode(EFFECT_SET_ATTACK)
e4:SetRange(LOCATION_MZONE)
e4:SetTargetRange(0,LOCATION_ONFIELD)
e4:SetTarget(cm.attg)
e4:SetValue(0)
c:RegisterEffect(e4)
--atkup
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_FIELD)
e5:SetCode(EFFECT_SET_DEFENSE)
e5:SetRange(LOCATION_MZONE)
e5:SetTargetRange(0,LOCATION_ONFIELD)
e5:SetTarget(cm.attg)
e5:SetValue(0)
c:RegisterEffect(e5)
--material
local e7=Effect.CreateEffect(c)
e7:SetDescription(aux.Stringid(m,3))
e7:SetType(EFFECT_TYPE_QUICK_O)
e7:SetRange(LOCATION_MZONE)
e7:SetCode(EVENT_FREE_CHAIN)
e7:SetCountLimit(2,m)
e7:SetOperation(cm.maop)
c:RegisterEffect(e7)
--Equip Okatana --Equip Okatana
local e6=Effect.CreateEffect(c) local e6=Effect.CreateEffect(c)
e6:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e6:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
...@@ -43,6 +97,17 @@ function cm.initial_effect(c) ...@@ -43,6 +97,17 @@ function cm.initial_effect(c)
e6:SetProperty(EFFECT_FLAG_DELAY) e6:SetProperty(EFFECT_FLAG_DELAY)
e6:SetOperation(cm.Eqop1) e6:SetOperation(cm.Eqop1)
c:RegisterEffect(e6) c:RegisterEffect(e6)
--pendulum
local e11=Effect.CreateEffect(c)
e11:SetDescription(aux.Stringid(m,2))
e11:SetCategory(CATEGORY_DESTROY)
e11:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e11:SetCode(EVENT_LEAVE_FIELD)
e11:SetProperty(EFFECT_FLAG_DELAY)
e11:SetCondition(cm.pencon)
e11:SetTarget(cm.pentg)
e11:SetOperation(cm.penop)
c:RegisterEffect(e11)
end end
function cm.fusfilter3(c) function cm.fusfilter3(c)
return c:IsSetCard(0x341) and c:IsType(TYPE_RITUAL) return c:IsSetCard(0x341) and c:IsType(TYPE_RITUAL)
...@@ -67,7 +132,7 @@ function cm.efilter(e,re) ...@@ -67,7 +132,7 @@ function cm.efilter(e,re)
return re:GetOwnerPlayer()~=e:GetHandlerPlayer() return re:GetOwnerPlayer()~=e:GetHandlerPlayer()
end end
function cm.indct12(e,re,r,rp) function cm.indct(e,re,r,rp)
if bit.band(r,REASON_BATTLE)~=0 then if bit.band(r,REASON_BATTLE)~=0 then
return 1 return 1
else return 0 end else return 0 end
...@@ -86,92 +151,34 @@ function cm.counter(e,tp,eg,ep,ev,re,r,rp) ...@@ -86,92 +151,34 @@ function cm.counter(e,tp,eg,ep,ev,re,r,rp)
tc:AddCounter(0x1015,1) tc:AddCounter(0x1015,1)
end end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk) function cm.indtg(e,c)
if chk==0 then return Duel.IsCanRemoveCounter(tp,1,1,0x1015,3,REASON_COST) end return c:GetCounter(0x1015)~=0
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
Duel.RemoveCounter(tp,1,1,0x1015,3,REASON_COST)
end
function cm.efilter(e,re)
return e:GetHandlerPlayer()~=re:GetOwnerPlayer()
end
function cm.op(e,tp,eg,ep,ev,re,r,rp)
local tg=Duel.SelectMatchingCard(tp,nil,tp,LOCATION_ONFIELD,0,1,1,nil)
local tc=tg:GetFirst()
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_INDESTRUCTABLE_BATTLE)
e1:SetValue(1)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(e:GetHandler())
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_IMMUNE_EFFECT)
e2:SetValue(cm.efilter)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e2)
end end
function cm.negcon(e,tp,eg,ep,ev,re,r,rp) function cm.attg(e,c)
local c=e:GetHandler() return c:GetCounter(0x1015)~=0
if ep~=tp or c:IsStatus(STATUS_BATTLE_DESTROYED) then return false end
return re:IsActiveType(TYPE_SPELL+TYPE_TRAP) and (re:GetHandler():IsSetCard(0x341) or re:GetHandler():IsSetCard(0x340))
end
function cm.negtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(nil,tp,0,LOCATION_GRAVE+LOCATION_ONFIELD,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_DISABLE,nil,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,nil,1,0,0)
end end
function cm.negop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() function cm.maop(e,tp,eg,ep,ev,re,r,rp)
local tg=Duel.SelectMatchingCard(tp,nil,tp,0,LOCATION_GRAVE+LOCATION_ONFIELD,1,1,nil) if not Duel.IsExistingMatchingCard(nil,tp,LOCATION_ONFIELD,0,1,nil) then return false end
local tc=tg:GetFirst() Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_OPERATECARD)
if not tc:IsDisabled() or tc:IsType(TYPE_TRAPMONSTER) then local g=Duel.SelectMatchingCard(tp,nil,tp,LOCATION_ONFIELD,0,1,1,nil)
Duel.NegateRelatedChain(tc,RESET_TURN_SET) if g:GetCount()>0 then
local e1=Effect.CreateEffect(c) local tc=g:GetFirst()
e1:SetType(EFFECT_TYPE_SINGLE) if tc and tc:IsAbleToHand() and Duel.SelectOption(tp,aux.Stringid(m,4),aux.Stringid(m,5))==0 then
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) if Duel.SendtoHand(tc,nil,REASON_EFFECT)~=0 then
e1:SetCode(EFFECT_DISABLE) Duel.ConfirmCards(1-tp,tc)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) local tg1=Duel.SelectMatchingCard(tp,Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil,0x1015,4)
tc:RegisterEffect(e1) local tc1=tg1:GetFirst()
local e2=Effect.CreateEffect(c) tc1:AddCounter(0x1015,4)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetValue(RESET_TURN_SET)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e2)
if tc:IsType(TYPE_TRAPMONSTER) then
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e3:SetCode(EFFECT_DISABLE_TRAPMONSTER)
e3:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e3)
end
end end
if tc:IsLocation(LOCATION_ONFIELD) then Duel.Destroy(tc,REASON_EFFECT) end else
if Duel.IsCanRemoveCounter(tp,1,1,0x1015,3,REASON_EFFECT) and tc:IsAbleToRemove(tp) then if Duel.Destroy(tc,REASON_EFFECT)~=0 then
if Duel.SelectYesNo(tp,aux.Stringid(m,3)) then local tg1=Duel.SelectMatchingCard(tp,Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil,0x1015,4)
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription()) local tc1=tg1:GetFirst()
Duel.RemoveCounter(tp,1,1,0x1015,3,REASON_EFFECT) tc1:AddCounter(0x1015,4)
Duel.Remove(tc,POS_FACEDOWN,REASON_EFFECT)
end end
end end
end
function cm.setcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousPosition(POS_FACEUP) and c:IsPreviousLocation(LOCATION_MZONE)
end
function cm.settg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetFieldGroupCount(tp,LOCATION_PZONE,0)>0 end
local g=Duel.GetFieldGroup(tp,LOCATION_PZONE,0)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0)
end
function cm.setop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetFieldGroup(tp,LOCATION_PZONE,0)
if Duel.Destroy(g,REASON_EFFECT)~=0 and e:GetHandler():IsRelateToEffect(e) then
Duel.MoveToField(e:GetHandler(),tp,tp,LOCATION_SZONE,POS_FACEUP,true)
end end
end end
...@@ -220,7 +227,7 @@ function cm.TojiEquip(ec,e,tp,eg,ep,ev,re,r,rp) ...@@ -220,7 +227,7 @@ function cm.TojiEquip(ec,e,tp,eg,ep,ev,re,r,rp)
e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP) e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP)
e2:SetCode(EVENT_DESTROYED) e2:SetCode(EVENT_DESTROYED)
e2:SetRange(LOCATION_SZONE) e2:SetRange(LOCATION_SZONE)
e2:SetCountLimit(2,m+1) e2:SetCountLimit(2)
e2:SetTarget(cm.cttg) e2:SetTarget(cm.cttg)
e2:SetOperation(cm.ctop) e2:SetOperation(cm.ctop)
token:RegisterEffect(e2) token:RegisterEffect(e2)
...@@ -239,14 +246,26 @@ function cm.cttg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -239,14 +246,26 @@ function cm.cttg(e,tp,eg,ep,ev,re,r,rp,chk)
and Duel.IsExistingMatchingCard(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil,0x1015,1) end and Duel.IsExistingMatchingCard(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil,0x1015,1) end
end end
function cm.ctop(e,tp,eg,ep,ev,re,r,rp) function cm.ctop(e,tp,eg,ep,ev,re,r,rp)
local ct=Duel.GetMatchingGroupCount(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,0x1015,1) local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil)
if ct==0 then return end local gc=g:GetFirst()
local g=Duel.GetMatchingGroup(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,0x1015,1) while gc do
if g:GetCount()==0 then return end gc:AddCounter(0x1015,1)
local ct1=Duel.GetMatchingGroupCount(nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil) gc=g:GetNext()
for i=1,ct1 do end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_COUNTER) end
local tc=g:Select(tp,1,1,nil):GetFirst()
tc:AddCounter(0x1015,1) function cm.pencon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_MZONE) and c:IsFaceup()
end
function cm.pentg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetFieldGroupCount(tp,LOCATION_PZONE,0)>0 end
local g=Duel.GetFieldGroup(tp,LOCATION_PZONE,0)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0)
end
function cm.penop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetFieldGroup(tp,LOCATION_PZONE,0)
if Duel.Destroy(g,REASON_EFFECT)~=0 and e:GetHandler():IsRelateToEffect(e) then
Duel.MoveToField(e:GetHandler(),tp,tp,LOCATION_PZONE,POS_FACEUP,true)
end end
end end
\ No newline at end of file
--D.A.L 四糸乃·冰铠形态
local m=33400526
local cm=_G["c"..m]
function cm.initial_effect(c)
--fusion materia
c:EnableReviveLimit()
aux.AddFusionProcMix(c,false,true,cm.fusfilter3,cm.fusfilter4,cm.fusfilter5,cm.fusfilter6,cm.fusfilter7)
--pendulum summon
aux.EnablePendulumAttribute(c,false)
--spsummon condition
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
e0:SetValue(cm.splimit)
c:RegisterEffect(e0)
--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:SetValue(1)
e1:SetCondition(cm.spcon)
e1:SetOperation(cm.spop)
c:RegisterEffect(e1)
--immune effect
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_IMMUNE_EFFECT)
e2:SetRange(LOCATION_PZONE)
e2:SetTargetRange(LOCATION_ONFIELD,0)
e2:SetTarget(cm.etarget)
e2:SetValue(cm.efilter)
c:RegisterEffect(e2)
--avoid damage
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetCode(EFFECT_CHANGE_DAMAGE)
e3:SetRange(LOCATION_PZONE)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e3:SetTargetRange(1,0)
e3:SetCondition(cm.ndcon)
e3:SetValue(0)
c:RegisterEffect(e3)
local e4=e3:Clone()
e4:SetCode(EFFECT_NO_EFFECT_DAMAGE)
c:RegisterEffect(e4)
--counter
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e5:SetCode(EVENT_CHAINING)
e5:SetProperty(EFFECT_FLAG_DELAY)
e5:SetRange(LOCATION_PZONE)
e5:SetCondition(cm.condition)
e5:SetOperation(cm.counter)
c:RegisterEffect(e5)
--
local e6=Effect.CreateEffect(c)
e6:SetType(EFFECT_TYPE_SINGLE)
e6:SetCode(EFFECT_IMMUNE_EFFECT)
e6:SetCondition(cm.imcon)
e6:SetValue(cm.efilter1)
c:RegisterEffect(e6)
--extra attack
local e7=Effect.CreateEffect(c)
e7:SetType(EFFECT_TYPE_SINGLE)
e7:SetCode(EFFECT_EXTRA_ATTACK)
e7:SetCondition(cm.imcon)
e7:SetValue(1)
c:RegisterEffect(e7)
--pierce
local e8=Effect.CreateEffect(c)
e8:SetType(EFFECT_TYPE_SINGLE)
e8:SetCode(EFFECT_PIERCE)
e8:SetCondition(cm.imcon)
c:RegisterEffect(e8)
--avoid damage
local e9=Effect.CreateEffect(c)
e9:SetType(EFFECT_TYPE_FIELD)
e9:SetCode(EFFECT_CHANGE_DAMAGE)
e9:SetRange(LOCATION_MZONE)
e9:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e9:SetTargetRange(1,0)
e9:SetCondition(cm.ndcon)
e9:SetValue(0)
c:RegisterEffect(e9)
local e10=e9:Clone()
e10:SetCode(EFFECT_NO_EFFECT_DAMAGE)
c:RegisterEffect(e10)
--atk/def
local e11=Effect.CreateEffect(c)
e11:SetType(EFFECT_TYPE_SINGLE)
e11:SetCode(EFFECT_UPDATE_ATTACK)
e11:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e11:SetRange(LOCATION_MZONE)
e11:SetValue(cm.adval)
c:RegisterEffect(e11)
local e12=e11:Clone()
e12:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e12)
--attack up
local e13=Effect.CreateEffect(c)
e13:SetDescription(aux.Stringid(m,3))
e13:SetCategory(CATEGORY_TOHAND+CATEGORY_ATKCHANGE)
e13:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e13:SetCode(EVENT_ATTACK_ANNOUNCE)
e13:SetCondition(cm.attcon)
e13:SetTarget(cm.thtg)
e13:SetOperation(cm.thop)
c:RegisterEffect(e13)
--pendulum
local e11=Effect.CreateEffect(c)
e11:SetDescription(aux.Stringid(m,2))
e11:SetCategory(CATEGORY_DESTROY)
e11:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e11:SetCode(EVENT_LEAVE_FIELD)
e11:SetProperty(EFFECT_FLAG_DELAY)
e11:SetCondition(cm.pencon)
e11:SetTarget(cm.pentg)
e11:SetOperation(cm.penop)
c:RegisterEffect(e11)
end
function cm.fusfilter3(c)
return c:IsSetCard(0x341) and c:IsType(TYPE_RITUAL)
end
function cm.fusfilter4(c)
return c:IsSetCard(0x341) and c:IsType(TYPE_FUSION)
end
function cm.fusfilter5(c)
return c:IsSetCard(0x341) and c:IsType(TYPE_SYNCHRO)
end
function cm.fusfilter6(c)
return c:IsSetCard(0x341) and c:IsType(TYPE_XYZ)
end
function cm.fusfilter7(c)
return c:IsSetCard(0x341) and c:IsType(TYPE_LINK)
end
function cm.fusfilter8(c)
return c:IsCode(33400502) and c:IsFaceup()
end
function cm.splimit(e,se,sp,st)
local c=e:GetHandler()
return bit.band(st,SUMMON_TYPE_FUSION)==SUMMON_TYPE_FUSION and Duel.IsExistingMatchingCard(cm.fusfilter8,e:GetHandlerPlayer(),LOCATION_ONFIELD,0,1,nil)
end
function cm.spfilter1(c)
return c:IsSetCard(0x341) and c:IsType(TYPE_FUSION) and c:IsAbleToExtraAsCost()
end
function cm.spfilter2(c)
return c:IsSetCard(0x341) and c:IsType(TYPE_SYNCHRO)and c:IsAbleToExtraAsCost()
end
function cm.spfilter3(c)
return c:IsSetCard(0x341) and c:IsType(TYPE_XYZ) and c:IsAbleToExtraAsCost()
end
function cm.spfilter4(c)
return c:IsSetCard(0x341) and c:IsType(TYPE_LINK) and c:IsAbleToExtraAsCost()
end
function cm.spfilter5(c)
return c:IsSetCard(0x341) and c:IsType(TYPE_RITUAL) and c:IsAbleToDeckAsCost()
end
function cm.spcostfilter(c)
return (c:IsFaceup() or c:IsLocation(LOCATION_GRAVE)) and c:IsSetCard(0x341)
and c:IsAbleToRemoveAsCost() and c:IsType(TYPE_RITUAL+TYPE_FUSION+TYPE_SYNCHRO+TYPE_XYZ+TYPE_LINK)
end
function cm.tdfilter1(c)
return c:IsSetCard(0x3344) and c:IsAbleToDeckAsCost()
end
function cm.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
local g1=Duel.GetMatchingGroup(cm.tdfilter1,tp,LOCATION_ONFIELD+LOCATION_GRAVE+LOCATION_REMOVED,0,nil)
return (Duel.GetLocationCountFromEx(tp,tp,nil,c)>0 or Duel.IsExistingMatchingCard(cm.spcostfilter,tp,LOCATION_MZONE,0,1,nil,c))
and Duel.IsExistingMatchingCard(cm.spfilter1,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,nil)
and Duel.IsExistingMatchingCard(cm.spfilter2,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,nil)
and Duel.IsExistingMatchingCard(cm.spfilter3,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,nil)
and Duel.IsExistingMatchingCard(cm.spfilter4,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,nil)
and Duel.IsExistingMatchingCard(cm.spfilter5,tp,LOCATION_GRAVE+LOCATION_MZONE,0,1,nil)
and g1:GetClassCount(Card.GetCode)>=5
and Duel.IsExistingMatchingCard(cm.fusfilter8,e:GetHandlerPlayer(),LOCATION_ONFIELD,0,1,nil)
end
function cm.check(g)
return g:IsExists(cm.spfilter1,1,nil)
and g:IsExists(cm.spfilter2,1,nil)
and g:IsExists(cm.spfilter3,1,nil)
and g:IsExists(cm.spfilter4,1,nil)
and g:IsExists(cm.spfilter5,1,nil)
and Duel.GetLocationCountFromEx(tp,tp,g,c)>0
end
function cm.check2(g)
return g:GetClassCount(Card.GetCode)>=5
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp,c)
local g1=Duel.GetMatchingGroup(cm.tdfilter1,tp,LOCATION_ONFIELD+LOCATION_GRAVE+LOCATION_REMOVED,0,nil)
local g2=Duel.GetMatchingGroup(cm.spcostfilter,tp,LOCATION_MZONE+LOCATION_GRAVE,0,nil)
if g1:GetClassCount(Card.GetCode)<5 or g2:GetCount()<5 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g3=g2:SelectSubGroup(tp,cm.check,false,5,5)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g4=g1:SelectSubGroup(tp,cm.check2,false,5,5)
g3:Merge(g4)
Duel.SendtoDeck(g3,nil,2,REASON_EFFECT)
c:SetMaterial(nil)
end
function cm.etarget(e,c)
return c:GetCounter(0x1015)~=0
end
function cm.efilter(e,re)
return re:GetOwnerPlayer()~=e:GetHandlerPlayer()
end
function cm.ndcon(e)
return Duel.IsExistingMatchingCard(nil,e:GetHandlerPlayer(),LOCATION_MZONE,0,1,nil)
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return ep~=tp and Duel.IsExistingMatchingCard(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil,0x1015,1)
end
function cm.counter(e,tp,eg,ep,ev,re,r,rp)
local ct=Duel.GetMatchingGroupCount(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,0x1015,1)
if ct==0 then return end
local g=Duel.GetMatchingGroup(Card.IsCanAddCounter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,0x1015,1)
if g:GetCount()==0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_COUNTER)
local tc=g:Select(tp,1,1,nil):GetFirst()
tc:AddCounter(0x1015,1)
end
function cm.imcon(e)
return Duel.IsExistingMatchingCard(nil,e:GetHandlerPlayer(),LOCATION_SZONE,0,1,nil)
end
function cm.efilter1(e,re)
return e:GetOwnerPlayer()~=re:GetOwnerPlayer()
end
function cm.adval(e,c)
return Duel.GetCounter(e:GetHandlerPlayer(),LOCATION_ONFIELD,LOCATION_ONFIELD,0x1015)*400
end
function cm.attcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsRelateToBattle()
end
function cm.tfilter3(c)
return c:GetCounter(0x1015)~=0 or c:IsFacedown()
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingMatchingCard(cm.tfilter3,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,nil,tp,LOCATION_ONFIELD)
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g1=Duel.SelectMatchingCard(tp,cm.tfilter3,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,30,nil)
if g1:GetCount()>0 then
local ss=Duel.SendtoHand(g1,nil,REASON_EFFECT)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetCode(EFFECT_UPDATE_ATTACK)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
e2:SetValue(ss*1000)
c:RegisterEffect(e2)
local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil)
local gc=g:GetFirst()
while gc do
gc:AddCounter(0x1015,1)
gc=g:GetNext()
end
end
end
function cm.pencon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_MZONE) and c:IsFaceup()
end
function cm.pentg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetFieldGroupCount(tp,LOCATION_ONFIELD,0)>0 end
local g=Duel.GetFieldGroup(tp,LOCATION_ONFIELD,0)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0)
end
function cm.penop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_OPERATECARD)
local g=Duel.SelectMatchingCard(tp,nil,tp,LOCATION_ONFIELD,0,1,1,nil)
if Duel.Destroy(g,REASON_EFFECT)~=0 and e:GetHandler():IsRelateToEffect(e) then
Duel.MoveToField(e:GetHandler(),tp,tp,LOCATION_PZONE,POS_FACEUP,true)
end
end
...@@ -8,75 +8,33 @@ function cm.initial_effect(c) ...@@ -8,75 +8,33 @@ function cm.initial_effect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_CHAINING) e1:SetCode(EVENT_CHAINING)
e1:SetCost(cm.cost) e1:SetCost(cm.cost)
e1:SetCondition(cm.condition1)
e1:SetTarget(cm.target) e1:SetTarget(cm.target)
e1:SetOperation(cm.activate) e1:SetOperation(cm.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCondition(cm.condition2)
c:RegisterEffect(e2)
--destroy --destroy
local e3=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(m,0)) e2:SetCategory(CATEGORY_ATKCHANGE+CATEGORY_DEFCHANGE)
e3:SetCategory(CATEGORY_DESTROY) e2:SetType(EFFECT_TYPE_QUICK_O)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e2:SetCode(EVENT_FREE_CHAIN)
e3:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DAMAGE_STEP) e2:SetRange(LOCATION_SZONE)
e3:SetCode(EVENT_DESTROYED) e2:SetCost(cm.cost2)
e3:SetRange(LOCATION_SZONE) e2:SetOperation(cm.op)
e3:SetCost(cm.cost2) c:RegisterEffect(e2)
e3:SetCondition(cm.descon)
e3:SetTarget(cm.destg)
e3:SetOperation(cm.desop)
c:RegisterEffect(e3)
--remain field --remain field
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE) e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetCode(EFFECT_REMAIN_FIELD) e4:SetCode(EFFECT_REMAIN_FIELD)
c:RegisterEffect(e4) c:RegisterEffect(e4)
if not cm.global_check then
cm.global_check=true
local ge1=Effect.CreateEffect(c)
ge1:SetType(EFFECT_TYPE_FIELD)
ge1:SetCode(EFFECT_ACTIVATE_COST)
ge1:SetRange(LOCATION_ONFIELD+LOCATION_DECK+LOCATION_GRAVE+LOCATION_REMOVED+LOCATION_HAND)
ge1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_SET_AVAILABLE)
ge1:SetTargetRange(0,1)
ge1:SetTarget(cm.actarget)
ge1:SetCost(cm.costchk)
Duel.RegisterEffect(ge1,0)
end
end
function cm.costchk(e,re,tp)
if re:GetHandler():GetFlagEffect(m)==1 then return end
local ct=0
if Duel.GetFlagEffect(tp,m)~=0 then
ct=1
end
re:GetHandler():RegisterFlagEffect(m,RESET_PHASE+RESET_CHAIN,0,0)
return true
end
function cm.actarget(e,te,tp)
return te:GetHandler():IsLocation(LOCATION_ONFIELD) and te:GetHandler():GetCounter(0x1015)~=0
end
function cm.cfilter(c)
return c:IsLocation(LOCATION_ONFIELD) and c:GetCounter(0x1015)~=0
end end
function cm.ckfilter(c) function cm.ckfilter(c)
return c:IsSetCard(0x6341) and c:IsFaceup() return c:IsSetCard(0x6341) and c:IsFaceup()
end end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk) function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckLPCost(tp,1000) or Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_ONFIELD,0,1,nil) end if chk==0 then return Duel.IsCanRemoveCounter(tp,1,1,0x1015,4,REASON_COST) and (Duel.CheckLPCost(tp,1000) or Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_ONFIELD,0,1,nil) )end
if not Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_ONFIELD,0,1,nil)then Duel.PayLPCost(tp,1000) if not Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_ONFIELD,0,1,nil)then Duel.PayLPCost(tp,1000)
end end
end Duel.Hint(HINT_OPSELECTED,tp,aux.Stringid(m,1))
function cm.condition1(e,tp,eg,ep,ev,re,r,rp) Duel.RemoveCounter(tp,1,1,0x1015,4,REASON_COST)
if not re:IsHasProperty(EFFECT_FLAG_CARD_TARGET) then return end
local tg=Duel.GetChainInfo(ev,CHAININFO_TARGET_CARDS)
return tg and tg:IsExists(cm.cfilter,1,nil) and Duel.IsChainNegatable(ev)
end
function cm.condition2(e,tp,eg,ep,ev,re,r,rp)
if re:GetHandler():GetFlagEffect(m)==0 then return end
return Duel.IsChainNegatable(ev)
end end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk) function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
...@@ -102,22 +60,22 @@ function cm.cost2(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -102,22 +60,22 @@ function cm.cost2(e,tp,eg,ep,ev,re,r,rp,chk)
end end
Duel.Release(e:GetHandler(),REASON_COST) Duel.Release(e:GetHandler(),REASON_COST)
end end
function cm.cfilter2(c,tp) function cm.op(e,tp,eg,ep,ev,re,r,rp)
return c:IsPreviousLocation(LOCATION_ONFIELD) and c:GetPreviousControler()==tp local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_MZONE,0,nil)
end if g:GetCount()>0 then
function cm.descon(e,tp,eg,ep,ev,re,r,rp) local d=Duel.GetCounter(tp,LOCATION_ONFIELD,LOCATION_ONFIELD,0x1015)
return eg:IsExists(cm.cfilter2,1,nil,tp) local sc=g:GetFirst()
end while sc do
function cm.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) local e1=Effect.CreateEffect(e:GetHandler())
if chkc then return chkc:IsOnField() end e1:SetType(EFFECT_TYPE_SINGLE)
if chk==0 then return Duel.IsExistingTarget(cm.cfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end e1:SetCode(EFFECT_UPDATE_ATTACK)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
local g=Duel.SelectTarget(tp,cm.cfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil) e1:SetValue(d*100)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0) sc:RegisterEffect(e1)
end local e2=e1:Clone()
function cm.desop(e,tp,eg,ep,ev,re,r,rp) e2:SetCode(EFFECT_UPDATE_DEFENSE)
local tc=Duel.GetFirstTarget() sc:RegisterEffect(e2)
if tc:IsRelateToEffect(e) then sc=g:GetNext()
Duel.Destroy(tc,REASON_EFFECT) end
end end
end end
--罗德岛·先锋干员-格拉尼 --罗德岛·先锋干员-格拉尼
function c79029024.initial_effect(c) function c79029024.initial_effect(c)
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkType,TYPE_EFFECT),2) --link summon
aux.AddLinkProcedure(c,nil,2,99,c79029024.lcheck)
c:EnableReviveLimit() c:EnableReviveLimit()
--to hand --to hand
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
...@@ -10,28 +11,41 @@ function c79029024.initial_effect(c) ...@@ -10,28 +11,41 @@ function c79029024.initial_effect(c)
e1:SetProperty(EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCountLimit(1,79029024) e1:SetCountLimit(1,79029024)
e1:SetCondition(c79029024.thcon)
e1:SetTarget(c79029024.thtg) e1:SetTarget(c79029024.thtg)
e1:SetOperation(c79029024.thop) e1:SetOperation(c79029024.thop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--indes --negate
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetDescription(aux.Stringid(79029024,0))
e2:SetCode(EFFECT_INDESTRUCTABLE_BATTLE) e2:SetCategory(CATEGORY_NEGATE+CATEGORY_REMOVE)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
e2:SetCode(EVENT_CHAINING)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) e2:SetCountLimit(1,19029024)
e2:SetTarget(c79029024.indtg) e2:SetCondition(c79029024.negcon)
e2:SetValue(1) e2:SetCost(c79029024.negcost)
e2:SetTarget(c79029024.negtg)
e2:SetOperation(c79029024.negop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
local e3=e2:Clone() --SpecialSummon
e3:SetCode(EFFECT_INDESTRUCTABLE_EFFECT) local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_FREE_CHAIN)
e3:SetHintTiming(0,TIMING_END_PHASE)
e3:SetRange(LOCATION_GRAVE)
e3:SetCountLimit(1,09029024)
e3:SetCost(c79029024.spcost)
e3:SetTarget(c79029024.sptg)
e3:SetOperation(c79029024.spop)
c:RegisterEffect(e3) c:RegisterEffect(e3)
--effect gain end
local e4=Effect.CreateEffect(c) function c79029024.lcheck(g)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) return g:IsExists(Card.IsLinkSetCard,1,nil,0xa900)
e4:SetCode(EVENT_BE_MATERIAL) end
e4:SetCondition(c79029024.efcon) function c79029024.thcon(e,tp,eg,ep,ev,re,r,rp)
e4:SetOperation(c79029024.efop) return e:GetHandler():IsSummonType(SUMMON_TYPE_LINK)
c:RegisterEffect(e4)
end end
function c79029024.thfilter(c) function c79029024.thfilter(c)
return c:IsSetCard(0x1901) and c:IsAbleToHand() return c:IsSetCard(0x1901) and c:IsAbleToHand()
...@@ -50,35 +64,81 @@ function c79029024.thop(e,tp,eg,ep,ev,re,r,rp) ...@@ -50,35 +64,81 @@ function c79029024.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029024,2)) Duel.Hint(HINT_SOUND,0,aux.Stringid(79029024,2))
end end
end end
function c79029024.indtg(e,c) function c79029024.negcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetLinkedGroup():IsContains(c) return not e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED)
and (re:IsActiveType(TYPE_MONSTER) or re:IsHasType(EFFECT_TYPE_ACTIVATE)) and Duel.IsChainNegatable(ev) and rp~=tp
end
function c79029024.cfilter(c,rtype)
return c:IsType(rtype) and c:IsAbleToGraveAsCost() and c:IsSetCard(0x1901)
end
function c79029024.negcost(e,tp,eg,ep,ev,re,r,rp,chk)
local rtype=bit.band(re:GetActiveType(),0x7)
if chk==0 then return Duel.IsExistingMatchingCard(c79029024.cfilter,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,nil,rtype) end
local g=Duel.SelectMatchingCard(tp,c79029024.cfilter,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,1,nil,rtype)
Duel.SendtoGrave(g,REASON_COST)
end
function c79029024.negtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return aux.nbcon(tp,re) end
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
if re:GetHandler():IsRelateToEffect(re) then
Duel.SetOperationInfo(0,CATEGORY_REMOVE,eg,1,0,0)
end
end
function c79029024.negop(e,tp,eg,ep,ev,re,r,rp)
if Duel.NegateActivation(ev) and re:GetHandler():IsRelateToEffect(re) then
Duel.Remove(eg,POS_FACEUP,REASON_EFFECT)
Debug.Message("只要交锋就会决出胜负!")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029024,4))
end
end
function c79029024.ctfil(c)
return c:IsAbleToRemoveAsCost() and c:IsRace(RACE_CYBERSE) and c:IsLinkAbove(3) and Duel.GetMZoneCount(tp,c)>0
end
function c79029024.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c79029024.ctfil,tp,LOCATION_MZONE,0,1,nil) end
local g=Duel.SelectMatchingCard(tp,c79029024.ctfil,tp,LOCATION_MZONE,0,1,1,nil)
Duel.Remove(g,POS_FACEUP,REASON_COST)
end end
function c79029024.efcon(e,tp,eg,ep,ev,re,r,rp) function c79029024.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local ec=e:GetHandler():GetReasonCard() if chk==0 then return e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end
return ec:IsSetCard(0xa900) and bit.band(r,REASON_FUSION+REASON_SYNCHRO+REASON_XYZ+REASON_LINK)~=0 Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,tp,LOCATION_GRAVE)
end end
function c79029024.efop(e,tp,eg,ep,ev,re,r,rp) function c79029024.spop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,0,79029024)
local c=e:GetHandler() local c=e:GetHandler()
local rc=c:GetReasonCard() if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
local e1=Effect.CreateEffect(rc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_ATTACK_ALL)
e1:SetValue(1)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE)
rc:RegisterEffect(e1,true)
local e2=Effect.CreateEffect(rc)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_CANNOT_SELECT_BATTLE_TARGET)
e2:SetRange(LOCATION_MZONE)
e2:SetTargetRange(0,LOCATION_MZONE)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE)
e2:SetValue(c79029024.catktg)
rc:RegisterEffect(e2,true)
rc:RegisterFlagEffect(79029024,RESET_EVENT+RESETS_STANDARD,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(79029024,0))
Debug.Message("以我的枪尖开路!") Debug.Message("以我的枪尖开路!")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029024,3)) Duel.Hint(HINT_SOUND,0,aux.Stringid(79029024,3))
if Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) then
--cannot target
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(79029024,0))
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE+EFFECT_FLAG_CLIENT_HINT)
e1:SetRange(LOCATION_MZONE)
e1:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET)
e1:SetValue(aux.tgoval)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e1)
--indes
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetRange(LOCATION_MZONE)
e2:SetValue(aux.indoval)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e2)
end
end end
function c79029024.catktg(e,c)
return c:IsFaceup() and not c:GetMaterial():IsExists(Card.IsCode,1,nil,79029024)
end
\ No newline at end of file
...@@ -12,7 +12,7 @@ function c79029035.initial_effect(c) ...@@ -12,7 +12,7 @@ function c79029035.initial_effect(c)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--to hand --to hand
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_DESTROY) e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_SPSUMMON_SUCCESS) e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetProperty(EFFECT_FLAG_DELAY) e2:SetProperty(EFFECT_FLAG_DELAY)
...@@ -28,12 +28,12 @@ function c79029035.initial_effect(c) ...@@ -28,12 +28,12 @@ function c79029035.initial_effect(c)
e3:SetRange(LOCATION_MZONE) e3:SetRange(LOCATION_MZONE)
e3:SetTargetRange(LOCATION_MZONE,0) e3:SetTargetRange(LOCATION_MZONE,0)
e3:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0xa905)) e3:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0xa905))
e3:SetValue(1200) e3:SetValue(1500)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--destroy --destroy
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(20366274,1)) e4:SetDescription(aux.Stringid(20366274,1))
e4:SetCategory(CATEGORY_DESTROY) e4:SetCategory(CATEGORY_REMOVE)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e4:SetCode(EVENT_BATTLE_START) e4:SetCode(EVENT_BATTLE_START)
e4:SetCondition(c79029035.descon) e4:SetCondition(c79029035.descon)
...@@ -54,15 +54,16 @@ function c79029035.condition(e,tp,eg,ep,ev,re,r,rp) ...@@ -54,15 +54,16 @@ function c79029035.condition(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_SYNCHRO) return e:GetHandler():IsSummonType(SUMMON_TYPE_SYNCHRO)
end end
function c79029035.tgfilter(c) function c79029035.tgfilter(c)
return c:IsType(TYPE_SPELL) and c:IsAbleToHand() return c:IsAbleToHand() and (c:IsSetCard(0xb90d) or c:IsSetCard(0xc90e))
end end
function c79029035.target(e,tp,eg,ep,ev,re,r,rp,chk) function c79029035.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c79029035.tgfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c79029035.tgfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil) and e:GetHandler():GetMaterialCount()>0 end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK+LOCATION_GRAVE) Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK+LOCATION_GRAVE)
end end
function c79029035.operation(e,tp,eg,ep,ev,re,r,rp) function c79029035.operation(e,tp,eg,ep,ev,re,r,rp)
local x=e:GetHandler():GetMaterialCount()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c79029035.tgfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,2,nil) local g=Duel.SelectMatchingCard(tp,c79029035.tgfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,x,nil)
if g:GetCount()>0 then if g:GetCount()>0 then
Duel.SendtoHand(g,tp,REASON_EFFECT) Duel.SendtoHand(g,tp,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g) Duel.ConfirmCards(1-tp,g)
...@@ -77,13 +78,13 @@ function c79029035.descon(e,tp,eg,ep,ev,re,r,rp) ...@@ -77,13 +78,13 @@ function c79029035.descon(e,tp,eg,ep,ev,re,r,rp)
end end
function c79029035.destg(e,tp,eg,ep,ev,re,r,rp,chk) function c79029035.destg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_DESTROY,e:GetHandler():GetBattleTarget(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_REMOVE,e:GetHandler():GetBattleTarget(),1,0,0)
end end
function c79029035.desop(e,tp,eg,ep,ev,re,r,rp) function c79029035.desop(e,tp,eg,ep,ev,re,r,rp)
local bc=e:GetHandler():GetBattleTarget() local bc=e:GetHandler():GetBattleTarget()
local x=bc:GetAttack() local x=bc:GetAttack()
if bc:IsRelateToBattle() then if bc:IsRelateToBattle() then
Duel.Destroy(bc,REASON_EFFECT) Duel.Remove(bc,POS_FACEDOWN,REASON_EFFECT)
Duel.Damage(1-tp,x,REASON_EFFECT) Duel.Damage(1-tp,x,REASON_EFFECT)
Debug.Message("可能有点热哦?") Debug.Message("可能有点热哦?")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029035,1)) Duel.Hint(HINT_SOUND,0,aux.Stringid(79029035,1))
......
--喀兰贸易·近卫干员-银灰 --喀兰贸易·近卫干员-银灰
function c79029072.initial_effect(c) function c79029072.initial_effect(c)
--link summon --link summon
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkType,TYPE_EFFECT),3,99,c79029072.lcheck)
c:EnableReviveLimit() c:EnableReviveLimit()
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkType,TYPE_EFFECT),3,6) --SpecialSummon
--immune
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetRange(LOCATION_MZONE) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCode(EFFECT_IMMUNE_EFFECT) e1:SetCountLimit(1,79029072)
e1:SetValue(c79029072.efilter) e1:SetCondition(c79029072.spcon)
e1:SetCondition(c79029072.imcon) e1:SetTarget(c79029072.sptg)
e1:SetOperation(c79029072.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--hand --immuse
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_REMOVE+CATEGORY_HANDES) e2:SetDescription(aux.Stringid(79029072,1))
e2:SetType(EFFECT_TYPE_IGNITION) e2:SetCategory(CATEGORY_NEGATE)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_CHAINING)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL+EFFECT_FLAG_CANNOT_INACTIVATE+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1) e2:SetCondition(c79029072.imcon)
e2:SetCost(c79029072.spcost) e2:SetCost(c79029072.imcost)
e2:SetTarget(c79029072.sptg) e2:SetTarget(c79029072.imtg)
e2:SetOperation(c79029072.spop) e2:SetOperation(c79029072.imop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--summon success --draw
local e4=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(7200041,0)) e3:SetCategory(CATEGORY_DRAW)
e4:SetCategory(CATEGORY_COUNTER) e3:SetType(EFFECT_TYPE_IGNITION)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F) e3:SetRange(LOCATION_MZONE)
e4:SetCode(EVENT_SPSUMMON_SUCCESS) e3:SetCountLimit(1,19029072)
e4:SetTarget(c79029072.addct) e3:SetTarget(c79029072.drtg)
e4:SetCondition(c79029072.addcon) e3:SetOperation(c79029072.drop)
e4:SetOperation(c79029072.addc) c:RegisterEffect(e3)
c:RegisterEffect(e4)
--cannot release
local e5=e1:Clone()
e5:SetType(EFFECT_TYPE_SINGLE)
e5:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e5:SetRange(LOCATION_MZONE)
e5:SetCode(EFFECT_UNRELEASABLE_SUM)
c:RegisterEffect(e5)
local e6=e1:Clone()
e6:SetCode(EFFECT_UNRELEASABLE_NONSUM)
c:RegisterEffect(e6)
end end
function c79029072.addcon(e,tp,eg,ep,ev,re,r,rp) function c79029072.lcheck(g)
return g:IsExists(Card.IsLinkSetCard,1,nil,0x1906)
end
function c79029072.spcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_LINK) return e:GetHandler():IsSummonType(SUMMON_TYPE_LINK)
end end
function c79029072.addct(e,tp,eg,ep,ev,re,r,rp,chk) function c79029072.spfil(c,e,tp)
if chk==0 then return true end return c:IsCanBeSpecialSummoned(e,0,tp,false,false) and Duel.GetLocationCountFromEx(tp,tp,nil,c)>0 and c:IsLinkBelow(3) and c:IsSetCard(0x1906)
Duel.SetOperationInfo(0,CATEGORY_COUNTER,nil,1,0,0x1099)
end end
function c79029072.addc(e,tp,eg,ep,ev,re,r,rp) function c79029072.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if e:GetHandler():IsRelateToEffect(e) then if chk==0 then return Duel.IsExistingMatchingCard(c79029072.spfil,tp,LOCATION_GRAVE+LOCATION_EXTRA,0,1,nil,e,tp) end
e:GetHandler():AddCounter(0x1099,1) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE+LOCATION_EXTRA)
end
end end
function c79029072.efilter(e,te) function c79029072.spop(e,tp,eg,ep,ev,re,r,rp)
return te:GetOwner()~=e:GetOwner() local g=Duel.GetMatchingGroup(c79029072.spfil,tp,LOCATION_GRAVE+LOCATION_EXTRA,0,nil,e,tp)
if g:GetCount()<=0 then return end
Debug.Message("客随主便,按你的想法安排就好。")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029072,0))
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local sg=g:Select(tp,1,1,nil)
Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP)
end end
function c79029072.imcon(e,tp,eg,ep,ev,re,r,rp) function c79029072.imcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() return rp==1-tp and not e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED)
return c:GetCounter(0x1099)>0
end end
function c79029072.spcost(e,tp,eg,ep,ev,re,r,rp,chk) function c79029072.ctfil(c)
if chk==0 then return e:GetHandler():IsCanRemoveCounter(tp,0x1099,1,REASON_COST) end return c:IsSetCard(0x1906) and c:IsAbleToGraveAsCost() and c:IsType(TYPE_MONSTER)
e:GetHandler():RemoveCounter(tp,0x1099,1,REASON_COST)
end end
function c79029072.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function c79029072.imcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetFieldGroupCount(tp,0,LOCATION_HAND)>0 end if chk==0 then return Duel.IsExistingMatchingCard(c79029072.ctfil,tp,LOCATION_ONFIELD,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CARDTYPE) local g=Duel.SelectMatchingCard(tp,c79029072.ctfil,tp,LOCATION_ONFIELD,0,1,1,nil)
e:SetLabel(Duel.AnnounceType(tp)) Duel.SendtoGrave(g,REASON_COST)
Duel.SetOperationInfo(0,CATEGORY_HANDES,e:GetHandler(),1,0,0)
end end
function c79029072.spop(e,tp,eg,ep,ev,re,r,rp) function c79029072.imtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
end
function c79029072.imop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetFieldGroupCount(tp,0,LOCATION_HAND)==0 then return end Debug.Message("战场之上,善良是无法拯救他人的。")
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SELECT) Duel.Hint(HINT_SOUND,0,aux.Stringid(79029072,1))
Duel.SelectTarget(tp,nil,tp,0,LOCATION_HAND,1,1,nil) local g=Duel.GetFieldGroup(tp,LOCATION_ONFIELD,0)
local tc=Duel.GetFirstTarget() local tc=g:GetFirst()
Duel.ConfirmCards(1-tp,tc) while tc do
local opt=e:GetLabel() --
if (opt==0 and tc:IsType(TYPE_MONSTER)) or (opt==1 and tc:IsType(TYPE_SPELL)) or (opt==2 and tc:IsType(TYPE_TRAP)) then local e1=Effect.CreateEffect(e:GetHandler())
if not c:IsRelateToEffect(e) then return end
Duel.Remove(tc,POS_FACEUP,REASON_EFFECT)
c:AddCounter(0x1099,1)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK) e1:SetCode(EFFECT_IMMUNE_EFFECT)
e1:SetValue(1000) e1:SetValue(c79029072.efilter)
c:RegisterEffect(e1) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_CHAIN)
e1:SetOwnerPlayer(tp)
tc:RegisterEffect(e1)
tc=g:GetNext()
end
end end
function c79029072.efilter(e,re)
return e:GetOwnerPlayer()~=re:GetOwnerPlayer()
end end
function c79029072.lxfil(c)
return c:IsSetCard(0xa900) and c:IsType(TYPE_LINK)
end
function c79029072.drtg(e,tp,eg,ep,ev,re,r,rp,chk)
local g=e:GetHandler():GetLinkedGroup()
if chk==0 then return g:IsExists(c79029072.lxfil,1,nil) end
Duel.SetTargetPlayer(tp)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,g:GetCount())
end
function c79029072.drop(e,tp,eg,ep,ev,re,r,rp)
local g=e:GetHandler():GetLinkedGroup()
if g:GetCount()<=0 then return end
Debug.Message("有什么想法?")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029072,2))
p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER)
Duel.Draw(p,g:GetCount(),REASON_EFFECT)
end
...@@ -11,7 +11,7 @@ function c79029158.initial_effect(c) ...@@ -11,7 +11,7 @@ function c79029158.initial_effect(c)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--special summon --special summon
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(2688979029158,0)) e2:SetDescription(aux.Stringid(79029158,0))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON) e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY) e2:SetProperty(EFFECT_FLAG_DELAY)
......
...@@ -37,11 +37,23 @@ function c79029239.tiop(e,tp,eg,ep,ev,re,r,rp) ...@@ -37,11 +37,23 @@ function c79029239.tiop(e,tp,eg,ep,ev,re,r,rp)
c:RegisterEffect(e0) c:RegisterEffect(e0)
Debug.Message("来了。") Debug.Message("来了。")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029239,0)) Duel.Hint(HINT_SOUND,0,aux.Stringid(79029239,0))
--act limit
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_ACTIVATE)
e1:SetTargetRange(1,0)
e1:SetValue(c79029239.aclimit)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
function c79029239.aclimit(e,re,tp)
return not re:GetHandler():IsSetCard(0xa900) and (re:GetHandler():IsType(TYPE_MONSTER))
end end
function c79029239.tiop2(e,tp,eg,ep,ev,re,r,rp) function c79029239.tiop2(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if re:GetHandler():GetControler()==tp then return end if re:GetHandler():GetControler()==tp then return end
if e:GetHandler():GetFlagEffect(79029239)==9 and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then if e:GetHandler():GetFlagEffect(79029239)==11 and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then
Duel.SpecialSummon(e:GetHandler(),0,tp,tp,true,false,POS_FACEUP) Duel.SpecialSummon(e:GetHandler(),0,tp,tp,true,false,POS_FACEUP)
local g=Duel.GetMatchingGroup(aux.TRUE,tp,0,LOCATION_ONFIELD,nil) local g=Duel.GetMatchingGroup(aux.TRUE,tp,0,LOCATION_ONFIELD,nil)
local tc=g:GetFirst() local tc=g:GetFirst()
......
...@@ -45,7 +45,7 @@ function c79029327.initial_effect(c) ...@@ -45,7 +45,7 @@ function c79029327.initial_effect(c)
c:RegisterEffect(e3) c:RegisterEffect(e3)
end end
function c79029327.ovfilter(c) function c79029327.ovfilter(c)
return c:IsFaceup() and c:IsRace(RACE_CYBERSE) and c:IsType(TYPE_DUAL) return c:IsFaceup() and c:IsSetCard(0xa900) and c:IsType(TYPE_DUAL)
end end
function c79029327.matfilter(c) function c79029327.matfilter(c)
return c:IsRace(RACE_CYBERSE) return c:IsRace(RACE_CYBERSE)
...@@ -67,7 +67,7 @@ function c79029327.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -67,7 +67,7 @@ function c79029327.target(e,tp,eg,ep,ev,re,r,rp,chk)
end end
end end
function c79029327.spfil(c,e,tp) function c79029327.spfil(c,e,tp)
return c:IsRace(RACE_CYBERSE) and c:IsType(TYPE_DUAL) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsSetCard(0xa900) and c:IsType(TYPE_DUAL) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function c79029327.operation(e,tp,eg,ep,ev,re,r,rp) function c79029327.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
...@@ -83,7 +83,7 @@ function c79029327.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -83,7 +83,7 @@ function c79029327.operation(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c79029327.dixfil(c) function c79029327.dixfil(c)
return c:IsRace(RACE_CYBERSE) and c:IsType(TYPE_DUAL) return c:IsSetCard(0xa900) and c:IsType(TYPE_DUAL)
end end
function c79029327.discon(e,c) function c79029327.discon(e,c)
return e:GetHandler():GetOverlayGroup():IsExists(c79029327.dixfil,1,nil) return e:GetHandler():GetOverlayGroup():IsExists(c79029327.dixfil,1,nil)
......
...@@ -48,9 +48,14 @@ function c79029360.condition(e,tp,eg,ep,ev,re,r,rp) ...@@ -48,9 +48,14 @@ function c79029360.condition(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase() local ph=Duel.GetCurrentPhase()
return Duel.GetTurnPlayer()~=tp and (ph==PHASE_MAIN1 or ph==PHASE_MAIN2) return Duel.GetTurnPlayer()~=tp and (ph==PHASE_MAIN1 or ph==PHASE_MAIN2)
end end
function c79029360.ctfil(c)
return c:IsSetCard(0xa900) and c:IsType(TYPE_MONSTER) and c:IsAbleToGraveAsCost()
end
function c79029360.cost(e,tp,eg,ep,ev,re,r,rp,chk) function c79029360.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToGraveAsCost() end if chk==0 then return e:GetHandler():IsAbleToGraveAsCost() and Duel.IsExistingMatchingCard(c79029360.ctfil,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,e:GetHandler()) end
Duel.SendtoGrave(e:GetHandler(),REASON_COST) local g=Duel.SelectMatchingCard(tp,c79029360.ctfil,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,1,e:GetHandler())
g:AddCard(e:GetHandler())
Duel.SendtoGrave(g,REASON_COST)
end end
function c79029360.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c79029360.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_MZONE) and c79029360.filter(chkc) end if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_MZONE) and c79029360.filter(chkc) end
......
...@@ -86,7 +86,7 @@ function c79029429.chain_operation(e,te,tp,tc,mat,sumtype) ...@@ -86,7 +86,7 @@ function c79029429.chain_operation(e,te,tp,tc,mat,sumtype)
Duel.SpecialSummon(tc,sumtype,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(tc,sumtype,tp,tp,false,false,POS_FACEUP)
end end
function c79029429.succon(e,tp,eg,ep,ev,re,r,rp) function c79029429.succon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetMaterial():FilterCount(Card.IsSetCard,nil,0xa900)==e:GetHandler():GetMaterialCount() return e:GetHandler():GetMaterial():FilterCount(Card.IsSetCard,nil,0xa900)==e:GetHandler():GetMaterialCount() and e:GetHandler():GetMaterialCount()>0
end end
function c79029429.sucop(e,tp,eg,ep,ev,re,r,rp) function c79029429.sucop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
......
...@@ -41,7 +41,7 @@ function c79029430.initial_effect(c) ...@@ -41,7 +41,7 @@ function c79029430.initial_effect(c)
c:RegisterEffect(e8) c:RegisterEffect(e8)
end end
function c79029430.ovfilter(c) function c79029430.ovfilter(c)
return c:IsFaceup() and c:IsRace(RACE_CYBERSE) and c:IsType(TYPE_DUAL) return c:IsFaceup() and c:IsSetCard(0xa900) and c:IsType(TYPE_DUAL)
end end
function c79029430.cltg(e,tp,eg,ep,ev,re,r,rp,chk) function c79029430.cltg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsSummonType(SUMMON_TYPE_XYZ) end if chk==0 then return e:GetHandler():IsSummonType(SUMMON_TYPE_XYZ) end
...@@ -62,7 +62,7 @@ function c79029430.dscost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -62,7 +62,7 @@ function c79029430.dscost(e,tp,eg,ep,ev,re,r,rp,chk)
e:GetHandler():RemoveOverlayCard(tp,1,1,REASON_COST) e:GetHandler():RemoveOverlayCard(tp,1,1,REASON_COST)
end end
function c79029430.dixfil(c) function c79029430.dixfil(c)
return c:IsRace(RACE_CYBERSE) and c:IsType(TYPE_DUAL) return c:IsSetCard(0xa900) and c:IsType(TYPE_DUAL)
end end
function c79029430.dscon(e,tp,eg,ep,ev,re,r,rp) function c79029430.dscon(e,tp,eg,ep,ev,re,r,rp)
return tp~=ep and Duel.GetCurrentChain()==0 and e:GetHandler():GetOverlayGroup():IsExists(c79029430.dixfil,1,nil) return tp~=ep and Duel.GetCurrentChain()==0 and e:GetHandler():GetOverlayGroup():IsExists(c79029430.dixfil,1,nil)
......
...@@ -47,10 +47,10 @@ function c79029449.aclimit(e,re,tp) ...@@ -47,10 +47,10 @@ function c79029449.aclimit(e,re,tp)
return not re:GetHandler():IsSetCard(0xc90e) and not re:GetHandler():IsSetCard(0xb90d) and not re:GetHandler():IsSetCard(0xa900) and not re:GetHandler():IsSetCard(0xa90f) return not re:GetHandler():IsSetCard(0xc90e) and not re:GetHandler():IsSetCard(0xb90d) and not re:GetHandler():IsSetCard(0xa900) and not re:GetHandler():IsSetCard(0xa90f)
end end
function c79029449.thfil(c) function c79029449.thfil(c)
return c:IsAbleToHand() and (c:IsSetCard(0xa900) or c:IsSetCard(0xc90e) or c:IsSetCard(0xb90d)) return c:IsAbleToHand() and (c:IsSetCard(0xa900) or c:IsSetCard(0xc90e) or c:IsSetCard(0xb90d) or c:IsSetCard(0xa90f))
end end
function c79029449.ckfil(c) function c79029449.ckfil(c)
return c:IsSetCard(0xa900) or c:IsSetCard(0xc90e) or c:IsSetCard(0xb90d) return (c:IsSetCard(0xa900) or c:IsSetCard(0xc90e) or c:IsSetCard(0xb90d) or c:IsSetCard(0xa90f))
end end
function c79029449.recon(e,tp,eg,ep,ev,re,r,rp) function c79029449.recon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetFlagEffect(tp,79029449)==0 return Duel.GetFlagEffect(tp,79029449)==0
......
...@@ -12,7 +12,7 @@ function c79029470.initial_effect(c) ...@@ -12,7 +12,7 @@ function c79029470.initial_effect(c)
--race --race
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetRange(LOCATION_SZONE) e2:SetRange(LOCATION_FZONE)
e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e2:SetCode(EFFECT_CHANGE_ATTRIBUTE) e2:SetCode(EFFECT_CHANGE_ATTRIBUTE)
e2:SetValue(ATTRIBUTE_WATER) e2:SetValue(ATTRIBUTE_WATER)
......
...@@ -29,7 +29,7 @@ function c79029476.thfil(c) ...@@ -29,7 +29,7 @@ function c79029476.thfil(c)
return c:IsAbleToHand() and c:IsRace(RACE_CYBERSE) and c:IsAttribute(ATTRIBUTE_WATER) return c:IsAbleToHand() and c:IsRace(RACE_CYBERSE) and c:IsAttribute(ATTRIBUTE_WATER)
end end
function c79029476.thtg(e,tp,eg,ep,ev,re,r,rp,chk) function c79029476.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c79029476.thfil,tp,LOCATION_DECK,0,1,nil) and e:GetHandler():IsSummonType(SUMMON_TYPE_FUSION) end if chk==0 then return Duel.IsExistingMatchingCard(c79029476.thfil,tp,LOCATION_DECK,0,1,nil) and e:GetHandler():IsSummonType(SUMMON_TYPE_SYNCHRO) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,tp,LOCATION_DECK) Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,tp,LOCATION_DECK)
end end
function c79029476.thop(e,tp,eg,ep,ev,re,r,rp) function c79029476.thop(e,tp,eg,ep,ev,re,r,rp)
...@@ -44,6 +44,7 @@ function c79029476.thop(e,tp,eg,ep,ev,re,r,rp) ...@@ -44,6 +44,7 @@ function c79029476.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.ConfirmCards(1-tp,sg) Duel.ConfirmCards(1-tp,sg)
if Duel.CheckLPCost(tp,2000) and Duel.SelectYesNo(tp,aux.Stringid(79029476,0)) then if Duel.CheckLPCost(tp,2000) and Duel.SelectYesNo(tp,aux.Stringid(79029476,0)) then
Duel.BreakEffect() Duel.BreakEffect()
Duel.PayLPCost(tp,2000)
Debug.Message("好的......我会维持这光亮,大家不要走散。") Debug.Message("好的......我会维持这光亮,大家不要走散。")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029476,4)) Duel.Hint(HINT_SOUND,0,aux.Stringid(79029476,4))
--extra summon --extra summon
......
...@@ -68,7 +68,7 @@ function c79029478.sttg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -68,7 +68,7 @@ function c79029478.sttg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c79029478.stfil,tp,LOCATION_DECK+LOCATION_GRAVE+LOCATION_HAND,0,1,nil) and Duel.GetLocationCount(1-tp,LOCATION_SZONE)>0 end if chk==0 then return Duel.IsExistingMatchingCard(c79029478.stfil,tp,LOCATION_DECK+LOCATION_GRAVE+LOCATION_HAND,0,1,nil) and Duel.GetLocationCount(1-tp,LOCATION_SZONE)>0 end
end end
function c79029478.stop(e,tp,eg,ep,ev,re,r,rp) function c79029478.stop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end if Duel.GetLocationCount(1-tp,LOCATION_SZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local g=Duel.SelectMatchingCard(tp,c79029478.stfil,tp,LOCATION_DECK+LOCATION_GRAVE+LOCATION_HAND,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c79029478.stfil,tp,LOCATION_DECK+LOCATION_GRAVE+LOCATION_HAND,0,1,1,nil)
Debug.Message("这样就行了吧?明白了。") Debug.Message("这样就行了吧?明白了。")
......
...@@ -30,6 +30,7 @@ function c79029480.initial_effect(c) ...@@ -30,6 +30,7 @@ function c79029480.initial_effect(c)
e3:SetCategory(CATEGORY_SPECIAL_SUMMON) e3:SetCategory(CATEGORY_SPECIAL_SUMMON)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_REMOVE) e3:SetCode(EVENT_REMOVE)
e3:SetProperty(EFFECT_FLAG_DELAY)
e3:SetRange(LOCATION_MZONE) e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,19029480) e3:SetCountLimit(1,19029480)
e3:SetCost(c79029480.spcost) e3:SetCost(c79029480.spcost)
......
--个人行动-镜中虚影
function c79029481.initial_effect(c)
--fusion material
c:EnableReviveLimit()
aux.AddFusionProcFunFunRep(c,aux.FilterBoolFunction(Card.IsFusionSetCard,0xa904),aux.FilterBoolFunction(Card.IsFusionType,TYPE_TRAP),2,2,true)
aux.AddContactFusionProcedure(c,Card.IsReleasable,LOCATION_ONFIELD,0,Duel.Release,REASON_COST+REASON_MATERIAL)
--spsummon condition
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_SPSUMMON_CONDITION)
e1:SetValue(c79029481.splimit)
c:RegisterEffect(e1)
--battle
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REFLECT_BATTLE_DAMAGE)
e1:SetValue(1)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_INDESTRUCTABLE_BATTLE)
e2:SetValue(1)
c:RegisterEffect(e2)
--set
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(79029481,0))
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_FREE_CHAIN)
e3:SetHintTiming(0,TIMING_END_PHASE)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,79029481)
e3:SetCost(c79029481.stcost)
e3:SetTarget(c79029481.sttg)
e3:SetOperation(c79029481.stop)
c:RegisterEffect(e3)
--th or sp
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(79029481,1))
e4:SetType(EFFECT_TYPE_QUICK_O)
e4:SetCode(EVENT_FREE_CHAIN)
e4:SetHintTiming(0,TIMING_END_PHASE)
e4:SetRange(LOCATION_MZONE)
e4:SetCountLimit(1,19029481)
e4:SetCost(c79029481.tscost)
e4:SetTarget(c79029481.tstg)
e4:SetOperation(c79029481.tsop)
c:RegisterEffect(e4)
end
function c79029481.splimit(e,se,sp,st)
return bit.band(st,SUMMON_TYPE_FUSION)==SUMMON_TYPE_FUSION
end
function c79029481.ctfil(c)
return c:IsAbleToRemoveAsCost() and c:IsSetCard(0xa900) and c:IsType(TYPE_MONSTER)
end
function c79029481.stcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c79029481.ctfil,tp,LOCATION_HAND+LOCATION_ONFIELD+LOCATION_GRAVE,0,1,nil) end
local g=Duel.SelectMatchingCard(tp,c79029481.ctfil,tp,LOCATION_HAND+LOCATION_ONFIELD+LOCATION_GRAVE,0,1,1,nil)
Duel.Remove(g,POS_FACEUP,REASON_COST)
end
function c79029481.stfilter(c)
return (c:IsSetCard(0xc90e) or c:IsSetCard(0xb90d)) and c:IsType(TYPE_TRAP) and c:IsSSetable()
end
function c79029481.sttg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c79029481.stfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil) end
end
function c79029481.stop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET)
local g=Duel.SelectMatchingCard(tp,c79029481.stfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil)
if g:GetCount()>0 then
Debug.Message("给与引导,这我不陌生。")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029481,2))
Duel.SSet(tp,g:GetFirst())
end
end
function c79029481.xxfil(c)
return c:IsAbleToRemoveAsCost() and c:IsType(TYPE_TRAP)
end
function c79029481.tscost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c79029481.xxfil,tp,LOCATION_ONFIELD+LOCATION_GRAVE,0,1,nil) end
local g=Duel.SelectMatchingCard(tp,c79029481.xxfil,tp,LOCATION_ONFIELD+LOCATION_GRAVE,0,1,1,nil)
Duel.Remove(g,POS_FACEUP,REASON_COST)
end
function c79029481.tsfilter(c,e,tp,ft)
return c:IsSetCard(0xa904) and (c:IsAbleToHand() or (ft>0 and c:IsCanBeSpecialSummoned(e,0,tp,false,false)))
end
function c79029481.tstg(e,tp,eg,ep,ev,re,r,rp,chk)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
if chk==0 then return Duel.IsExistingMatchingCard(c79029481.tsfilter,tp,LOCATION_DECK,0,1,nil,e,tp,ft) end
end
function c79029481.tsop(e,tp,eg,ep,ev,re,r,rp)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_OPERATECARD)
local g=Duel.SelectMatchingCard(tp,c79029481.tsfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,ft)
local tc=g:GetFirst()
if tc then
if ft>0 and tc:IsCanBeSpecialSummoned(e,0,tp,false,false)
and (not tc:IsAbleToHand() or Duel.SelectOption(tp,1190,1152)==1) then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
if tc:IsCode(79029203) then
Debug.Message("这片黑暗是庇护所,也是宝座,更是乐园。过去的亡灵从未离去,而我在他们的骸骨上诅咒这一切......看到我这副模样,你还想聆听我的歌声,你还敢...站在我身前吗?")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029481,6))
else
Debug.Message("演员是台词的傀儡。")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029481,4))
end
else
Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc)
if tc:IsCode(79029203) then
Debug.Message("这一步无法回头,无法后望。我将与你分享的东西,恐怕并不像你想象中那样美妙。......过来,来这里,这黑夜的幕布,就让我为你揭开。")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029481,5))
else
Debug.Message("戏剧该揭开它的帷幕了。")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029481,3))
end
end
end
end
--联合行动-双龙出鞘
function c79029482.initial_effect(c)
--add code
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_ADD_CODE)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetValue(29065574)
c:RegisterEffect(e0)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,79029482)
e1:SetCondition(c79029482.condition)
e1:SetTarget(c79029482.target)
e1:SetOperation(c79029482.activate)
c:RegisterEffect(e1)
--xx
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_DAMAGE)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetRange(LOCATION_GRAVE)
e2:SetCountLimit(1,19029482)
e2:SetCondition(c79029482.xxcon)
e2:SetCost(aux.bfgcost)
e2:SetTarget(c79029482.xxtg)
e2:SetOperation(c79029482.xxop)
c:RegisterEffect(e2)
end
function c79029482.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetCurrentPhase()<PHASE_MAIN2
end
function c79029482.filter(c)
return c:IsFaceup() and c:GetFlagEffect(79029482)==0 and c:IsLinkAbove(6) and c:IsSetCard(0xa900)
end
function c79029482.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c79029482.filter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c79029482.filter,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SelectTarget(tp,c79029482.filter,tp,LOCATION_MZONE,0,1,1,nil)
end
function c79029482.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
if tc:GetFlagEffect(79029482)==0 then
if tc:IsCode(79029359) then
Debug.Message("我背负着许多人的愤怒。")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029482,3))
elseif tc:IsCode(79029025) then
Debug.Message("没问题。")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029482,4))
end
tc:RegisterFlagEffect(79029482,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(79029482,0))
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:SetCondition(c79029482.actcon)
e1:SetValue(1)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_PIERCE)
e2:SetCondition(c79029482.effcon)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetRange(LOCATION_MZONE)
e3:SetTargetRange(0,LOCATION_ONFIELD)
e3:SetCode(EFFECT_DISABLE)
e3:SetCondition(c79029482.actcon)
e3:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e4:SetCode(EVENT_PRE_BATTLE_DAMAGE)
e4:SetCondition(c79029482.damcon)
e4:SetOperation(c79029482.damop)
e4:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e4)
end
end
end
function c79029482.actcon(e)
local c=e:GetHandler()
return (Duel.GetAttacker()==c or Duel.GetAttackTarget()==c) and e:GetOwnerPlayer()==e:GetHandlerPlayer()
end
function c79029482.effcon(e)
return e:GetOwnerPlayer()==e:GetHandlerPlayer()
end
function c79029482.damcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return (Duel.GetAttacker()==c or Duel.GetAttackTarget()==c) and ep~=tp and e:GetOwnerPlayer()==e:GetHandlerPlayer()
end
function c79029482.damop(e,tp,eg,ep,ev,re,r,rp)
Duel.ChangeBattleDamage(ep,ev*4)
if e:GetHandler():IsCode(79029359) then
Debug.Message("“我该用什么回应你的不义?”")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029482,1))
elseif e:GetHandler():IsCode(79029025) then
Debug.Message("闪!")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029482,2))
end
end
function c79029482.xxcon(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase()
return ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE
end
function c79029482.xxfil(c)
return c:GetBaseAttack()>0 and c:IsSetCard(0xa900) and c:IsLinkAbove(6)
end
function c79029482.xxtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return eg:IsExists(c79029482.xxfil,1,nil) end
Duel.SetTargetPlayer(1-tp)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,eg:Filter(c79029482.xxfil,nil):GetSum(Card.GetBaseAttack)/2)
end
function c79029482.xxop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local g=eg:Filter(c79029482.xxfil,nil)
local x=g:GetSum(Card.GetBaseAttack)/2
local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER)
Duel.Damage(p,x,REASON_EFFECT)
local tc=g:GetFirst()
while tc do
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCode(EFFECT_EXTRA_ATTACK)
e1:SetValue(1)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
if tc:IsCode(79029359) then
Debug.Message("要战斗到哪一天,蔓延在大地上的怒火才会平息呢......")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029482,5))
elseif tc:IsCode(79029025) then
Debug.Message("罪恶绝不能被容忍,不管用什么办法我都要阻止你们。")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029482,6))
end
tc=g:GetNext()
end
end
--煌·音律联觉收藏-爆裂菲林
function c79029483.initial_effect(c)
--xyz summon
aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xa900),6,2)
c:EnableReviveLimit()
--add code
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_ADD_CODE)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetValue(79029125)
c:RegisterEffect(e0)
--cannot target
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_MZONE)
e1:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET)
e1:SetValue(aux.tgoval)
c:RegisterEffect(e1)
--indes
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetRange(LOCATION_MZONE)
e2:SetValue(aux.indoval)
c:RegisterEffect(e2)
--ov
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_SPSUMMON_SUCCESS)
e3:SetTarget(c79029483.xyztg)
e3:SetOperation(c79029483.xyzop)
c:RegisterEffect(e3)
--xyz
local e4=Effect.CreateEffect(c)
e4:SetCategory(CATEGORY_SPECIAL_SUMMON)
e4:SetType(EFFECT_TYPE_QUICK_O)
e4:SetCode(EVENT_FREE_CHAIN)
e4:SetRange(LOCATION_MZONE)
e4:SetCountLimit(1,79029483)
e4:SetTarget(c79029483.sptg)
e4:SetOperation(c79029483.spop)
c:RegisterEffect(e4)
end
function c79029483.xyzfil(c)
return c:IsCanOverlay() and c:IsSetCard(0xa900) and c:IsType(TYPE_MONSTER)
end
function c79029483.xyztg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsSummonType(SUMMON_TYPE_XYZ) and Duel.IsExistingMatchingCard(c79029483.xyzfil,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_DECK,0,1,nil) end
end
function c79029483.xyzop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsLocation(LOCATION_MZONE) then return end
local g=Duel.GetMatchingGroup(c79029483.xyzfil,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_DECK,0,nil)
if g:GetCount()<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_XMATERIAL)
local sg=g:Select(tp,1,1,nil)
Debug.Message("哈,有没有感觉周围的空气变得燥热了?没有?咦,我再加加温试试,还想着这样能炒热气氛来着......")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029483,0))
Duel.Overlay(c,sg)
end
function c79029483.filter2(c,e,tp,mc,rk,rc,code)
return c:IsRank(rk+1,rk-1) and c:IsSetCard(0xa900) and mc:IsCanBeXyzMaterial(c) and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_XYZ,tp,false,false) and Duel.GetLocationCountFromEx(tp,tp,mc,c)>0
end
function c79029483.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler()
if chk==0 then return Duel.IsExistingMatchingCard(c79029483.filter2,tp,LOCATION_EXTRA,0,1,nil,e,tp,c,c:GetRank(),c:GetRace(),c:GetCode()) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function c79029483.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not aux.MustMaterialCheck(c,tp,EFFECT_MUST_BE_XMATERIAL) then return end
if c:IsFacedown() or not c:IsRelateToEffect(e) or c:IsControler(1-tp) or c:IsImmuneToEffect(e) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c79029483.filter2,tp,LOCATION_EXTRA,0,1,1,nil,e,tp,c,c:GetRank(),c:GetRace(),c:GetCode())
local sc=g:GetFirst()
if sc then
Debug.Message("虽然有点暴力,但我可是很喜欢切裂钢铁和掩体的!")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029483,1))
local mg=c:GetOverlayGroup()
if mg:GetCount()~=0 then
Duel.Overlay(sc,mg)
end
sc:SetMaterial(Group.FromCards(c))
Duel.Overlay(sc,Group.FromCards(c))
Duel.SpecialSummon(sc,SUMMON_TYPE_XYZ,tp,tp,false,false,POS_FACEUP)
sc:CompleteProcedure()
end
end
--能天使·瑟谣浮收藏-机凯行者
function c79029485.initial_effect(c)
--add code
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_ADD_CODE)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetValue(79029051)
c:RegisterEffect(e0)
--race
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetProperty(EFFECT_FLAG_SINGLE_RANGE+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetCode(EFFECT_ADD_RACE)
e0:SetRange(0xff)
e0:SetValue(RACE_MACHINE)
c:RegisterEffect(e0)
--immuse
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(c79029485.iccon)
e1:SetOperation(c79029485.icop)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e2)
--to hand and SpecialSummon
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SPECIAL_SUMMON)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_FREE_CHAIN)
e3:SetHintTiming(0,TIMING_END_PHASE)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetRange(LOCATION_GRAVE)
e3:SetCountLimit(1,09029485)
e3:SetTarget(c79029485.tstg)
e3:SetOperation(c79029485.tsop)
c:RegisterEffect(e3)
end
function c79029485.ckfil(c,e,tp)
return c:GetSummonPlayer()==tp and c:IsSetCard(0xa900,0x6a19)
end
function c79029485.iccon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c79029485.ckfil,1,nil,e,tp) and e:GetHandler():IsAbleToGrave() and Duel.GetFlagEffect(tp,79029485)==0
end
function c79029485.icop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if Duel.SelectEffectYesNo(tp,c) then
Duel.RegisterFlagEffect(tp,79029485,RESET_PHASE+PHASE_END,0,1)
Debug.Message("出发!让我们像风暴一样碾过去!")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029485,0))
Duel.SendtoGrave(c,REASON_EFFECT)
local g=eg:Filter(c79029485.ckfil,nil,e,tp)
g:KeepAlive()
--inactivatable
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_INACTIVATE)
e1:SetValue(c79029485.efilter)
e1:SetLabelObject(g)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
local e2=e1:Clone()
e2:SetCode(EFFECT_CANNOT_DISABLE)
Duel.RegisterEffect(e2,tp)
end
end
function c79029485.efilter(e,ct)
local p=e:GetHandlerPlayer()
local te,tp=Duel.GetChainInfo(ct,CHAININFO_TRIGGERING_EFFECT,CHAININFO_TRIGGERING_PLAYER)
return p==tp and e:GetLabelObject():IsContains(te:GetHandler())
end
function c79029485.rhfil(c)
return c:IsSetCard(0xa900,0x6a19) and c:IsAbleToHand() and Duel.GetMZoneCount(tp,c)>0
end
function c79029485.tstg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingTarget(c79029485.rhfil,tp,LOCATION_ONFIELD,0,1,e:GetHandler()) and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end
local g=Duel.SelectTarget(tp,c79029485.rhfil,tp,LOCATION_ONFIELD+LOCATION_GRAVE,0,1,1,e:GetHandler())
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,tp,LOCATION_ONFIELD+LOCATION_GRAVE)
end
function c79029485.tsop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and c:IsRelateToEffect(e) then
Debug.Message("轮到我出场了吗?")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029485,1))
Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetTargetRange(1,0)
e2:SetTarget(c79029485.splimit)
e2:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e2,tp)
end
function c79029485.splimit(e,c)
return not c:IsRace(RACE_MACHINE) and not c:IsRace(RACE_CYBERSE)
end
--拉普兰德·瑟谣浮收藏-亡胧黯铠
function c79029486.initial_effect(c)
--add code
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_ADD_CODE)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetValue(79029026)
c:RegisterEffect(e0)
--race
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetProperty(EFFECT_FLAG_SINGLE_RANGE+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetCode(EFFECT_ADD_RACE)
e0:SetRange(0xff)
e0:SetValue(RACE_MACHINE)
c:RegisterEffect(e0)
--immuse
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_SUMMON)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(c79029486.iccon)
e1:SetOperation(c79029486.icop)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EVENT_SPSUMMON)
c:RegisterEffect(e2)
--negate
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_DISABLE)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_CHAINING)
e3:SetRange(LOCATION_GRAVE+LOCATION_MZONE)
e3:SetCountLimit(1,79029486)
e3:SetCondition(c79029486.negcon)
e3:SetCost(aux.bfgcost)
e3:SetTarget(c79029486.negtg)
e3:SetOperation(c79029486.negop)
c:RegisterEffect(e3)
end
function c79029486.ckfil(c,e,tp)
return c:GetSummonPlayer()==tp and c:IsSetCard(0xa900,0x6a19)
end
function c79029486.iccon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c79029486.ckfil,1,nil,e,tp) and e:GetHandler():IsAbleToGrave() and Duel.GetFlagEffect(tp,79029486)==0
end
function c79029486.icop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if Duel.SelectEffectYesNo(tp,c) then
Duel.RegisterFlagEffect(tp,79029486,RESET_PHASE+PHASE_END,0,1)
Debug.Message("哈哈,诸位,反正我记不住你们的脸......算了,出发吧?")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029486,0))
Duel.SendtoGrave(c,REASON_EFFECT)
local g=eg:Filter(c79029486.ckfil,nil,e,tp)
local tc=g:GetFirst()
while tc do
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_CANNOT_DISABLE_SUMMON)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_CANNOT_DISABLE_SPSUMMON)
tc:RegisterEffect(e2)
tc=g:GetNext()
end
Duel.SetChainLimitTillChainEnd(c79029486.chainlm)
end
end
function c79029486.chainlm(e,rp,tp)
return not e:IsHasCategory(CATEGORY_DISABLE_SUMMON)
end
function c79029486.tfilter(c,tp)
return c:IsLocation(LOCATION_MZONE) and c:IsControler(tp) and c:IsFaceup() and c:IsSetCard(0x88)
end
function c79029486.negcon(e,tp,eg,ep,ev,re,r,rp)
local te=Duel.GetChainInfo(ev-1,CHAININFO_TRIGGERING_EFFECT)
return rp~=tp and te:GetHandler():IsSetCard(0xa900,0x6a19) and Duel.IsChainDisablable(ev)
end
function c79029486.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)
if re:GetHandler():IsRelateToEffect(re) then
Duel.SetOperationInfo(0,CATEGORY_REMOVE,eg,1,0,0)
end
end
function c79029486.negop(e,tp,eg,ep,ev,re,r,rp)
Debug.Message("再加把劲!")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029486,1))
if Duel.NegateActivation(ev) and re:GetHandler():IsRelateToEffect(re) then
Duel.Remove(eg,POS_FACEUP,REASON_EFFECT)
end
end
--SNo.39 希望皇 霍普·桃源 --SNo.39 希望皇 霍普·桃源
function c79029530.initial_effect(c)
--SNo.39 希望皇 霍普·桃源
function c79029530.initial_effect(c) function c79029530.initial_effect(c)
aux.AddXyzProcedure(c,nil,7,4,nil,nil,99) aux.AddXyzProcedure(c,nil,7,4,nil,nil,99)
c:EnableReviveLimit() c:EnableReviveLimit()
...@@ -86,14 +88,4 @@ function c79029530.atkop(e,tp,eg,ep,ev,re,r,rp) ...@@ -86,14 +88,4 @@ function c79029530.atkop(e,tp,eg,ep,ev,re,r,rp)
e1:SetValue(c:GetAttack()*2) e1:SetValue(c:GetAttack()*2)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
c:RegisterEffect(e1) c:RegisterEffect(e1)
if not Duel.IsExistingMatchingCard(aux.TRUE,tp,0,LOCATION_MZONE,1,nil) then return end
if Duel.SelectYesNo(tp,aux.Stringid(79029530,0)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SELECT)
local g=Duel.SelectMatchingCard(tp,aux.TRUE,tp,0,LOCATION_MZONE,1,1,nil)
Duel.CalculateDamage(c,g:GetFirst())
end
end end
...@@ -56,8 +56,7 @@ function c79029534.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -56,8 +56,7 @@ function c79029534.operation(e,tp,eg,ep,ev,re,r,rp)
e1:SetTargetRange(0,LOCATION_MZONE) e1:SetTargetRange(0,LOCATION_MZONE)
e1:SetTarget(c79029534.distg) e1:SetTarget(c79029534.distg)
e1:SetLabel(flag) e1:SetLabel(flag)
e1:SetRange(LOCATION_MZONE) e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
Duel.RegisterEffect(e1,tp) Duel.RegisterEffect(e1,tp)
end end
end end
......
--逆元构造 红莲
function c79029800.initial_effect(c)
--special summon
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(c79029800.spcon)
c:RegisterEffect(e1)
--t g
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_TO_GRAVE)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCountLimit(1,79029800)
e2:SetCondition(c79029800.tgcon)
e2:SetTarget(c79029800.settg)
e2:SetOperation(c79029800.setop)
c:RegisterEffect(e2)
--ww
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_DRAW)
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetRange(LOCATION_GRAVE)
e3:SetCost(aux.bfgcost)
e3:SetCountLimit(1,19029800)
e3:SetTarget(c79029800.drtg)
e3:SetOperation(c79029800.drop)
c:RegisterEffect(e3)
end
function c79029800.xxfilter(c)
return not c:IsLevel(3) and not c:IsRank(3) and not c:IsLink(3)
end
function c79029800.spcon(e,c)
if c==nil then return true end
return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0 and
not Duel.IsExistingMatchingCard(c79029800.xxfilter,c:GetControler(),LOCATION_MZONE,0,1,nil) and not Duel.IsExistingMatchingCard(Card.IsFacedown,c:GetControler(),LOCATION_MZONE,0,1,nil) and Duel.GetFieldGroupCount(c:GetControler(),LOCATION_MZONE,0)>0
end
function c79029800.filter(c)
return c:IsSetCard(0xa991) and c:IsSSetable() and not c:IsType(TYPE_FIELD)
end
function c79029800.tgcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD)
end
function c79029800.settg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c79029800.filter,tp,LOCATION_DECK,0,1,nil,tp) end
end
function c79029800.setop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET)
local sg=Duel.SelectMatchingCard(tp,c79029800.filter,tp,LOCATION_DECK,0,1,1,nil,tp)
if sg:GetCount()>0 then
local tc=sg:GetFirst()
Duel.SSet(tp,tc)
end
end
function c79029800.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,1,tp,0,0)
end
function c79029800.drop(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetTargetRange(1,0)
e1:SetTarget(c79029800.splimit)
Duel.RegisterEffect(e1,tp)
Duel.Draw(tp,1,REASON_EFFECT)
end
function c79029800.splimit(e,c,sump,sumtype,sumpos,targetp,se)
return not c:IsSetCard(0xa991) and c:IsLocation(LOCATION_EXTRA)
end
\ No newline at end of file
--逆元构造 蚀暗
function c79029801.initial_effect(c)
--special summon
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(c79029801.spcon)
c:RegisterEffect(e1)
--t g
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_TODECK+CATEGORY_DRAW)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_TO_GRAVE)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCountLimit(1,79029801)
e2:SetCondition(c79029801.tgcon)
e2:SetTarget(c79029801.tdtg)
e2:SetOperation(c79029801.tdop)
c:RegisterEffect(e2)
--ww
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_RECOVER)
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetRange(LOCATION_GRAVE)
e3:SetCost(aux.bfgcost)
e3:SetCountLimit(1,19029801)
e3:SetTarget(c79029801.rctg)
e3:SetOperation(c79029801.rcop)
c:RegisterEffect(e3)
end
function c79029801.xxfilter(c)
return not c:IsLevel(3) and not c:IsRank(3) and not c:IsLink(3)
end
function c79029801.spcon(e,c)
if c==nil then return true end
return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0 and
not Duel.IsExistingMatchingCard(c79029801.xxfilter,c:GetControler(),LOCATION_MZONE,0,1,nil) and not Duel.IsExistingMatchingCard(Card.IsFacedown,c:GetControler(),LOCATION_MZONE,0,1,nil) and Duel.GetFieldGroupCount(c:GetControler(),LOCATION_MZONE,0)>0
end
function c79029801.filter(c)
return c:IsAbleToDeck() and c:IsSetCard(0xa991) and (c:IsLocation(LOCATION_GRAVE) or c:IsFaceup())
end
function c79029801.tgcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD)
end
function c79029801.tdtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c79029801.filter,tp,LOCATION_REMOVED+LOCATION_GRAVE,0,3,nil,tp) and Duel.IsPlayerCanDraw(tp,1) end
Duel.SetOperationInfo(0,CATEGORY_TODECK,nil,3,tp,0,0)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,1,tp,0,0)
end
function c79029801.sfilter(c,tp)
return c:IsLocation(LOCATION_DECK) and c:IsControler(tp)
end
function c79029801.tdop(e,tp,eg,ep,ev,re,r,rp)
local a1=Duel.IsExistingMatchingCard(c79029801.filter,tp,LOCATION_REMOVED+LOCATION_GRAVE,0,3,nil,tp) and Duel.IsPlayerCanDraw(tp,1)
local a2=Duel.IsExistingMatchingCard(c79029801.filter,tp,LOCATION_REMOVED+LOCATION_GRAVE,0,6,nil,tp) and Duel.IsPlayerCanDraw(tp,2)
local op=2
if a1 and a2 then
op=Duel.SelectOption(tp,aux.Stringid(79029801,0),aux.Stringid(79029801,1))
elseif a1 then
op=Duel.SelectOption(tp,aux.Stringid(79029801,0))
elseif a2 then
op=Duel.SelectOption(tp,aux.Stringid(79029801,1))+1
else
return
end
local tg=Group.CreateGroup()
if op==0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
tg=Duel.SelectMatchingCard(tp,c79029801.filter,tp,LOCATION_REMOVED+LOCATION_GRAVE,0,3,3,nil)
else
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
tg=Duel.SelectMatchingCard(tp,c79029801.filter,tp,LOCATION_REMOVED+LOCATION_GRAVE,0,6,6,nil)
end
Duel.SendtoDeck(tg,nil,0,REASON_EFFECT)
local g=Duel.GetOperatedGroup()
if g:IsExists(c79029801.sfilter,1,nil,tp) then Duel.ShuffleDeck(tp) end
local ct=g:FilterCount(Card.IsLocation,nil,LOCATION_DECK+LOCATION_EXTRA)
if ct>=3 then
Duel.BreakEffect()
local num=math.floor(ct/3)
Duel.Draw(tp,num,REASON_EFFECT)
end
end
function c79029801.rcfilter(c)
return c:IsFaceup() and (c:IsAttackAbove(0) or c:IsDefenseAbove(0))
end
function c79029801.rctg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return c:IsLocation(LOCATION_MZONE) and c79029801.rcfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c79029801.rcfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
g=Duel.SelectTarget(tp,c79029801.rcfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
local tc=g:GetFirst()
Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,math.max(tc:GetAttack(),tc:GetDefense()),tp,0,0)
end
function c79029801.rcop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:IsFaceup() then
Duel.Recover(tp,math.max(tc:GetAttack(),tc:GetDefense()),REASON_EFFECT)
end
end
\ No newline at end of file
--逆元构造 异火
function c79029802.initial_effect(c)
--special summon
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(c79029802.spcon)
c:RegisterEffect(e1)
--t g
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_TO_GRAVE)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCountLimit(1,79029802)
e2:SetCondition(c79029802.tgcon)
e2:SetTarget(c79029802.detg)
e2:SetOperation(c79029802.deop)
c:RegisterEffect(e2)
--ww
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_DISABLE)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_CHAINING)
e3:SetRange(LOCATION_GRAVE)
e3:SetCondition(c79029802.negcon)
e3:SetCost(aux.bfgcost)
e3:SetTarget(c79029802.negtg)
e3:SetOperation(c79029802.negop)
c:RegisterEffect(e3)
end
function c79029802.xxfilter(c)
return not c:IsLevel(3) and not c:IsRank(3) and not c:IsLink(3)
end
function c79029802.spcon(e,c)
if c==nil then return true end
return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0 and
not Duel.IsExistingMatchingCard(c79029802.xxfilter,c:GetControler(),LOCATION_MZONE,0,1,nil) and not Duel.IsExistingMatchingCard(Card.IsFacedown,c:GetControler(),LOCATION_MZONE,0,1,nil) and Duel.GetFieldGroupCount(c:GetControler(),LOCATION_MZONE,0)>0
end
function c79029802.tgcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD)
end
function c79029802.detg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
end
function c79029802.deop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local sg=Duel.SelectMatchingCard(tp,nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil,tp)
if sg:GetCount()>0 then
Duel.Destroy(sg,REASON_EFFECT)
end
end
function c79029802.filter(c,tp)
return c:IsControler(tp) and c:IsSetCard(0xa991) and c:IsFaceup()
end
function c79029802.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(c79029802.filter,1,nil,tp)
end
function c79029802.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 c79029802.negop(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateEffect(ev)
end
\ No newline at end of file
--逆元构造 风暴
function c79029803.initial_effect(c)
--special summon
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(c79029803.spcon)
c:RegisterEffect(e1)
--t g
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_TO_GRAVE)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCountLimit(1,79029803)
e2:SetCondition(c79029803.tgcon)
e2:SetTarget(c79029803.detg)
e2:SetOperation(c79029803.deop)
c:RegisterEffect(e2)
--ww
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_TODECK)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_FREE_CHAIN)
e3:SetHintTiming(0,TIMING_END_PHASE)
e3:SetRange(LOCATION_GRAVE)
e3:SetCost(aux.bfgcost)
e3:SetCountLimit(1,19029803)
e3:SetTarget(c79029803.tdtg)
e3:SetOperation(c79029803.tdop)
c:RegisterEffect(e3)
end
function c79029803.xxfilter(c)
return not c:IsLevel(3) and not c:IsRank(3) and not c:IsLink(3)
end
function c79029803.spcon(e,c)
if c==nil then return true end
return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0 and
not Duel.IsExistingMatchingCard(c79029803.xxfilter,c:GetControler(),LOCATION_MZONE,0,1,nil) and not Duel.IsExistingMatchingCard(Card.IsFacedown,c:GetControler(),LOCATION_MZONE,0,1,nil) and Duel.GetFieldGroupCount(c:GetControler(),LOCATION_MZONE,0)>0
end
function c79029803.defilter(c)
return c:IsLocation(LOCATION_SZONE) or (c:IsType(TYPE_TRAP+TYPE_SPELL) and c:IsFaceup())
end
function c79029803.tgcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD)
end
function c79029803.detg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c79029803.defilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_DESTROY,nil,1,tp,0,0)
end
function c79029803.deop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local sg=Duel.SelectMatchingCard(tp,c79029803.defilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,2,nil)
if sg:GetCount()>0 then
Duel.HintSelection(sg)
Duel.Destroy(sg,REASON_EFFECT)
end
end
function c79029803.tdtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToDeck,tp,LOCATION_REMOVED+LOCATION_GRAVE,LOCATION_REMOVED+LOCATION_GRAVE,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TODECK,nil,1,0,0)
end
function c79029803.tdop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,Card.IsAbleToDeck,tp,LOCATION_REMOVED+LOCATION_GRAVE,LOCATION_REMOVED+LOCATION_GRAVE,1,1,nil)
if g:GetCount()>0 then
Duel.HintSelection(g)
Duel.SendtoDeck(g,nil,1,REASON_EFFECT)
end
end
\ No newline at end of file
--逆元构造 黎明
function c79029804.initial_effect(c)
--link summon
aux.AddLinkProcedure(c,nil,2,3,c79029804.lcheck)
c:EnableReviveLimit()
--Disable
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(79029804,1))
e2:SetCategory(CATEGORY_DISABLE)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetRange(LOCATION_MZONE)
e2:SetHintTiming(0,TIMINGS_CHECK_MONSTER)
e2:SetCountLimit(1,79029804)
e2:SetCost(c79029804.descost)
e2:SetTarget(c79029804.destg)
e2:SetOperation(c79029804.desop)
c:RegisterEffect(e2)
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:SetCondition(c79029804.atkcon)
e3:SetValue(1500)
c:RegisterEffect(e3)
--cannot target
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e4:SetRange(LOCATION_MZONE)
e4:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET)
e4:SetCondition(c79029804.atkcon)
e4:SetValue(aux.tgoval)
c:RegisterEffect(e4)
--indes
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_SINGLE)
e5:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e5:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e5:SetRange(LOCATION_MZONE)
e5:SetCondition(c79029804.atkcon)
e5:SetValue(aux.indoval)
c:RegisterEffect(e5)
end
function c79029804.lcheck(g,lc)
return g:IsExists(Card.IsLinkSetCard,1,nil,0xa991)
end
function c79029804.descost(e,tp,eg,ep,ev,re,r,rp,chk)
e:SetLabel(100)
return true
end
function c79029804.costfilter(c)
return c:IsAbleToGraveAsCost() and c:IsFaceup() and c:IsRace(RACE_MACHINE)
end
function c79029804.destg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
local dg=Duel.GetMatchingGroup(Card.IsFaceup,tp,0,LOCATION_ONFIELD,nil)
if chk==0 then
if e:GetLabel()~=100 then
e:SetLabel(0)
return false
end
return Duel.GetMatchingGroupCount(c79029804.costfilter,tp,LOCATION_MZONE,0,nil)>0 and dg:GetCount()>0
end
e:SetLabel(0)
local cg=Duel.SelectMatchingCard(tp,c79029804.costfilter,tp,LOCATION_MZONE,0,1,dg:GetCount(),nil)
local dct=Duel.SendtoGrave(cg,REASON_COST)
Duel.SetOperationInfo(0,CATEGORY_DISABLE,nil,dct,tp,LOCATION_ONFIELD)
e:SetValue(dct)
end
function c79029804.desop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local dct=e:GetValue()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISABLE)
local dg=Duel.SelectMatchingCard(tp,Card.IsFaceup,tp,0,LOCATION_ONFIELD,dct,dct,nil)
if #dg>0 then
Duel.HintSelection(dg)
local tc=dg:GetFirst()
while tc do
Duel.NegateRelatedChain(tc,RESET_TURN_SET)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1)
tc=dg:GetNext()
end
end
end
function c79029804.cfilter(c)
return c:GetSequence()<5
end
function c79029804.atkcon(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsExistingMatchingCard(c79029804.cfilter,e:GetHandlerPlayer(),LOCATION_MZONE,0,1,nil)
end
\ No newline at end of file
--逆元构造 流光
function c79029805.initial_effect(c)
aux.AddSynchroProcedure(c,nil,aux.NonTuner(Card.IsRace,RACE_MACHINE),1)
c:EnableReviveLimit()
--add type & attack
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCondition(c79029805.tncon)
e1:SetOperation(c79029805.tnop)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_MATERIAL_CHECK)
e2:SetValue(c79029805.valcheck)
e2:SetLabelObject(e1)
c:RegisterEffect(e2)
--special summon
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(79029805,1))
e3:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_RECOVER)
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,79029805)
e3:SetCost(c79029805.cost)
e3:SetTarget(c79029805.sptg)
e3:SetOperation(c79029805.spop)
c:RegisterEffect(e3)
--destroy replace
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e4:SetCode(EFFECT_DESTROY_REPLACE)
e4:SetRange(LOCATION_GRAVE+LOCATION_MZONE)
e4:SetTarget(c79029805.reptg)
e4:SetValue(c79029805.repval)
e4:SetOperation(c79029805.repop)
c:RegisterEffect(e4)
end
function c79029805.valcheck(e,c)
local flag=0
local g=c:GetMaterial()
if g:IsExists(Card.IsSetCard,1,nil,0xa991) then
flag=flag|1
end
e:GetLabelObject():SetLabel(flag)
end
function c79029805.mfilter(c)
return not c:IsType(TYPE_SYNCHRO)
end
function c79029805.tncon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_SYNCHRO) and e:GetLabel()>0
end
function c79029805.tnop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if e:GetLabel()&1==1 then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCode(EFFECT_ADD_TYPE)
e1:SetValue(TYPE_TUNER)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
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_CHANGE_LEVEL)
e2:SetValue(3)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e2)
end
end
function c79029805.cost(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 c79029805.spfilter(c,e,tp)
return c:IsRace(RACE_MACHINE) and c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and (c:IsLevelBelow(3) or c:IsRankBelow(3) or c:IsLinkBelow(3))
end
function c79029805.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c79029805.spfilter,tp,LOCATION_HAND+LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_HAND+LOCATION_GRAVE)
Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,1500,tp,0,0)
end
function c79029805.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then
local g=Duel.GetMatchingGroup(c79029805.spfilter,tp,LOCATION_HAND+LOCATION_GRAVE,0,nil,e,tp)
if g:GetCount()>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local sg=g:Select(tp,1,1,nil)
if Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP)>0 then
Duel.Recover(tp,1500,REASON_EFFECT)
end
end
end
end
function c79029805.repfilter(c,tp)
return c:IsFaceup() and c:IsSetCard(0xa991)
and c:IsControler(tp) and c:IsReason(REASON_EFFECT+REASON_BATTLE) and not c:IsReason(REASON_REPLACE)
end
function c79029805.reptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToRemove() and eg:IsExists(c79029805.repfilter,1,nil,tp) end
return Duel.SelectEffectYesNo(tp,e:GetHandler(),96)
end
function c79029805.repval(e,c)
return c79029805.repfilter(c,e:GetHandlerPlayer())
end
function c79029805.repop(e,tp,eg,ep,ev,re,r,rp)
Duel.Remove(e:GetHandler(),POS_FACEUP,REASON_EFFECT)
Duel.Recover(tp,1000,REASON_EFFECT)
end
\ No newline at end of file
--逆元构造 乱数
function c79029806.initial_effect(c)
--xyz summon
aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsRace,RACE_MACHINE),3,2,nil,nil,99)
c:EnableReviveLimit()
--search
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(79029806,0))
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCountLimit(1,79029806)
e1:SetCondition(c79029806.thcon)
e1:SetTarget(c79029806.thtg)
e1:SetOperation(c79029806.thop)
c:RegisterEffect(e1)
--xx
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_DAMAGE)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetCode(EVENT_BATTLE_DESTROYING)
e2:SetCondition(c79029806.xyzcon)
e2:SetTarget(c79029806.xyztg)
e2:SetOperation(c79029806.xyzop)
c:RegisterEffect(e2)
--negate
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_NEGATE+CATEGORY_DESTROY)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_CHAINING)
e3:SetCountLimit(1,19029806)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
e3:SetRange(LOCATION_MZONE)
e3:SetCondition(c79029806.discon)
e3:SetCost(c79029806.discost)
e3:SetTarget(c79029806.distg)
e3:SetOperation(c79029806.disop)
c:RegisterEffect(e3)
end
function c79029806.thcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_XYZ)
end
function c79029806.filter(c)
return c:IsType(TYPE_MONSTER) and c:IsLevel(3)
and (c:IsAbleToHand() or c:IsAbleToGrave())
end
function c79029806.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
return Duel.IsExistingMatchingCard(c79029806.filter,tp,LOCATION_DECK,0,1,nil)
end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,0,tp,LOCATION_DECK)
end
function c79029806.thop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_OPERATECARD)
local tc=Duel.SelectMatchingCard(tp,c79029806.filter,tp,LOCATION_DECK,0,1,1,nil):GetFirst()
if tc then
local bool_a=tc:IsAbleToGrave()
local bool_b=tc:IsAbleToHand()
local op=2
if bool_a and bool_b then
op=Duel.SelectOption(tp,aux.Stringid(79029806,2),aux.Stringid(79029806,3))
elseif bool_a then
op=Duel.SelectOption(tp,aux.Stringid(79029806,2))
elseif bool_b then
op=Duel.SelectOption(tp,aux.Stringid(79029806,3))+1
end
if op==0 then
Duel.SendtoHand(tc,tp,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc)
elseif op==1 then
Duel.SendtoGrave(tc,REASON_EFFECT)
else
end
end
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_ACTIVATE)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(1,0)
e1:SetValue(c79029806.splimit)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
function c79029806.aclimit1(e,re,tp)
local tc=re:GetHandler()
return re:IsActiveType(TYPE_MONSTER) and not (tc:IsLevelBelow(3) or tc:IsRankBelow(3) or tc:IsLinkBelow(3))
end
function c79029806.xyzcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=c:GetBattleTarget()
if not c:IsRelateToBattle() or c:IsFacedown() then return false end
e:SetLabelObject(tc)
return tc:IsType(TYPE_MONSTER) and tc:IsReason(REASON_BATTLE)
end
function c79029806.xyztg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsType(TYPE_XYZ) end
local tc=e:GetLabelObject()
Duel.SetTargetCard(tc)
Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,tc,1,0,0)
end
function c79029806.xyzop(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
Duel.Overlay(c,tc)
if not c:GetOverlayGroup():IsContains(tc) then return end
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetValue(500)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE)
c:RegisterEffect(e1)
Duel.ChainAttack()
end
end
function c79029806.discon(e,tp,eg,ep,ev,re,r,rp)
return not e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED) and Duel.IsChainNegatable(ev) and rp~=tp
end
function c79029806.discost(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)
end
function c79029806.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 c79029806.disop(e,tp,eg,ep,ev,re,r,rp)
if Duel.NegateActivation(ev) and re:GetHandler():IsRelateToEffect(re) then
Duel.Destroy(eg,REASON_EFFECT)
end
end
\ No newline at end of file
--逆元构造 脉冲
function c79029807.initial_effect(c)
--xyz summon
aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsRace,RACE_MACHINE),3,2,nil,nil,99)
c:EnableReviveLimit()
--Draw
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(79029807,0))
e1:SetCategory(CATEGORY_DRAW)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_PLAYER_TARGET)
e1:SetCountLimit(1,79029807)
e1:SetCondition(c79029807.drcon)
e1:SetTarget(c79029807.drtg)
e1:SetOperation(c79029807.drop)
c:RegisterEffect(e1)
--add cost
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(79029807,1))
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetRange(LOCATION_MZONE)
e2:SetHintTiming(0,TIMING_MAIN_END)
e2:SetCountLimit(1,19029807)
e2:SetCost(c79029807.cost2)
e2:SetCondition(c79029807.condition2)
e2:SetTarget(c79029807.target2)
e2:SetOperation(c79029807.activate)
c:RegisterEffect(e2)
--negate
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e3:SetCode(EVENT_CHAINING)
e3:SetRange(LOCATION_GRAVE)
e3:SetCountLimit(1,29029807)
e3:SetCondition(c79029807.condition)
e3:SetOperation(c79029807.op)
c:RegisterEffect(e3)
end
function c79029807.drcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_XYZ)
end
function c79029807.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 c79029807.drop(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Draw(p,d,REASON_EFFECT)
end
function c79029807.cost2(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:CheckRemoveOverlayCard(tp,1,REASON_COST)
end
c:RemoveOverlayCard(tp,1,1,REASON_COST)
end
function c79029807.condition2(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==1-tp and (Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2)
end
function c79029807.target2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
end
function c79029807.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
Duel.RegisterFlagEffect(1-tp,79029807,RESET_PHASE+PHASE_END,0,1)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_ACTIVATE_COST)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(0,1)
e1:SetCost(c79029807.costchk)
e1:SetOperation(c79029807.costop)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
function c79029807.costchk(e,te_or_c,tp)
local ct=Duel.GetFlagEffect(tp,79029807)
return Duel.CheckLPCost(tp,ct*800)
end
function c79029807.costop(e,tp,eg,ep,ev,re,r,rp)
Duel.PayLPCost(tp,800)
end
function c79029807.condfil(c,tp)
return c:GetPreviousControler()==tp and c:IsSetCard(0xa991)
end
function c79029807.condition(e,tp,eg,ep,ev,re,r,rp)
local chain=Duel.GetChainInfo(ev-1,CHAININFO_TRIGGERING_EFFECT)
local chc=chain:GetHandler()
return Duel.GetCurrentChain()>1 and c79029807.condfil(chc,tp) and rp~=tp and e:GetHandler():IsAbleToRemove()
end
function c79029807.op(e,tp,eg,ep,ev,re,r,rp)
if Duel.SelectYesNo(tp,aux.Stringid(79029807,2)) then
if Duel.Remove(e:GetHandler(),POS_FACEUP,REASON_EFFECT) then
if Duel.NegateActivation(ev) and re:GetHandler():IsRelateToEffect(re) then
Duel.Destroy(eg,REASON_EFFECT)
end
end
end
end
\ No newline at end of file
--升格构造 阿尔法
function c79029808.initial_effect(c)
c:SetSPSummonOnce(79029808)
c:EnableReviveLimit()
--special summon condition
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_SPSUMMON_CONDITION)
c:RegisterEffect(e1)
--special summon
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(79029808,0))
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_SPSUMMON_PROC)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e2:SetRange(LOCATION_HAND+LOCATION_GRAVE)
e2:SetCondition(c79029808.spcon)
e2:SetOperation(c79029808.spop)
c:RegisterEffect(e2)
--cannot target
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET)
e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e3:SetRange(LOCATION_MZONE)
e3:SetCondition(c79029808.ctcon)
e3:SetValue(aux.tgoval)
c:RegisterEffect(e3)
--indes
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e4:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e4:SetRange(LOCATION_MZONE)
e4:SetCondition(c79029808.ctcon)
e4:SetValue(aux.indoval)
c:RegisterEffect(e4)
--damage
local e5=Effect.CreateEffect(c)
e5:SetDescription(aux.Stringid(79029808,1))
e5:SetCategory(CATEGORY_DAMAGE)
e5:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e5:SetCode(EVENT_BATTLE_CONFIRM)
e5:SetCondition(c79029808.damcon)
e5:SetTarget(c79029808.damtg)
e5:SetOperation(c79029808.damop)
c:RegisterEffect(e5)
end
function c79029808.spcfilter(c)
return (c:IsFaceup() or c:IsLocation(LOCATION_HAND)) and c:IsSetCard(0xa991) and c:IsAbleToGraveAsCost() and c:IsType(TYPE_MONSTER)
end
function c79029808.mzfilter(c,tp)
return c:GetSequence()<5
end
function c79029808.spzfilter(c,tp)
return Duel.GetMZoneCount(tp,c,tp)>0
end
function c79029808.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
local sg=Duel.GetMatchingGroup(c79029808.spcfilter,tp,LOCATION_MZONE+LOCATION_HAND,0,nil)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
return sg:GetCount()>0 and (ft>0 or sg:IsExists(c79029808.spzfilter,1,nil,tp))
end
function c79029808.spop(e,tp,eg,ep,ev,re,r,rp,c)
local g=Duel.GetMatchingGroup(c79029808.spcfilter,tp,LOCATION_MZONE+LOCATION_HAND,0,nil)
local num=5
if #g<num then num=#g end
local sg=g:SelectSubGroup(tp,c79029808.spzfilter,false,1,num,tp)
Duel.SendtoGrave(sg,REASON_COST)
local ct=#sg
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_LEVEL)
e1:SetValue(-ct)
e1:SetReset(RESET_EVENT+0xff0000)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_UPDATE_ATTACK)
e2:SetRange(LOCATION_MZONE)
e2:SetValue(ct*500)
e2:SetReset(RESET_EVENT+0xff0000)
c:RegisterEffect(e2)
local e3=e2:Clone()
e3:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e3)
end
function c79029808.ctcon(e)
return e:GetHandler():IsLevel(3)
end
function c79029808.damcon(e,tp,eg,ep,ev,re,r,rp)
local bc=e:GetHandler():GetBattleTarget()
return bc and bc:IsControler(1-tp)
end
function c79029808.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,e:GetHandler():GetBattleTarget():GetAttack())
end
function c79029808.damop(e,tp,eg,ep,ev,re,r,rp)
local tc=e:GetHandler():GetBattleTarget()
if tc and tc:IsFaceup() and tc:IsControler(1-tp) and tc:IsRelateToBattle() then
local atk=tc:GetAttack()
Duel.Damage(1-tp,atk,REASON_EFFECT)
end
end
\ No newline at end of file
--升格构造 深红之渊
function c79029809.initial_effect(c)
--fusion
aux.AddFusionProcFunFunRep(c,c79029809.ffilter,aux.FilterBoolFunction(Card.IsRace,RACE_MACHINE),2,99,true)
c:EnableReviveLimit()
--
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SET_BASE_ATTACK)
e1:SetProperty(EFFECT_FLAG_REPEAT)
e1:SetRange(LOCATION_MZONE)
e1:SetValue(c79029809.akval)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_SET_BASE_DEFENSE)
c:RegisterEffect(e2)
--move
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(79029809,0))
e2:SetCategory(CATEGORY_TOGRAVE)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1,79029809)
e2:SetTarget(c79029809.seqtg)
e2:SetOperation(c79029809.seqop)
c:RegisterEffect(e2)
if not c79029809.global_check then
c79029809.global_check=true
local ge1=Effect.CreateEffect(c)
ge1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge1:SetCode(EVENT_CHAINING)
ge1:SetOperation(c79029809.checkop)
Duel.RegisterEffect(ge1,0)
end
end
function c79029809.checkop(e,tp,eg,ep,ev,re,r,rp)
local xp=re:GetHandlerPlayer()
local flag=Duel.GetFlagEffectLabel(xp,79029809)
if flag then
Duel.SetFlagEffectLabel(xp,79029809,flag+1)
else
Duel.RegisterFlagEffect(xp,79029809,0,0,1,1)
end
end
function c79029809.ffilter(c,fc,sub,mg,sg)
return c:IsCode(79029808) and c:IsLevelBelow(3)
end
function c79029809.akval(e)
local tp=e:GetHandlerPlayer()
local x=Duel.GetFlagEffectLabel(tp,79029809)
return e:GetHandler():GetMaterialCount()*100*x
end
function c79029809.seqtg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE,PLAYER_NONE,0)>0 end
Duel.SetChainLimit(c79029809.chlimit)
end
function c79029809.chlimit(e,ep,tp)
return tp==ep
end
function c79029809.seqop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) or c:IsImmuneToEffect(e) or not c:IsControler(tp) or Duel.GetLocationCount(tp,LOCATION_MZONE,PLAYER_NONE,0)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOZONE)
local fd=Duel.SelectDisableField(tp,1,LOCATION_MZONE,0,0)
Duel.Hint(HINT_ZONE,tp,fd)
local seq=math.log(fd,2)
local pseq=c:GetSequence()
Duel.MoveSequence(c,seq)
if c:GetSequence()==seq then
local g=c:GetColumnGroup():Filter(Card.IsControler,nil,1-tp)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(79029809,1)) then
Duel.BreakEffect()
Duel.SendtoGrave(g,REASON_EFFECT)
end
end
if c:IsRelateToEffect(e) then
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetCode(EFFECT_DIRECT_ATTACK)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
c:RegisterEffect(e2)
end
end
--逆元构造 凛冽
function c79029810.initial_effect(c)
--synchro summon
aux.AddSynchroProcedure(c,aux.FilterBoolFunction(Card.IsRace,RACE_MACHINE),aux.NonTuner(Card.IsRace,RACE_MACHINE),1)
c:EnableReviveLimit()
--tograve
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetOperation(c79029810.sumsuc)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_MATERIAL_CHECK)
e2:SetValue(c79029810.valcheck)
e2:SetLabelObject(e1)
c:RegisterEffect(e2)
--negate
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_NEGATE+CATEGORY_DESTROY)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_CHAINING)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,79029810)
e3:SetCondition(c79029810.discon)
e3:SetCost(c79029810.discost)
e3:SetTarget(c79029810.distg)
e3:SetOperation(c79029810.disop)
c:RegisterEffect(e3)
--cannot be target
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD)
e4:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET)
e4:SetRange(LOCATION_MZONE)
e4:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e4:SetTargetRange(LOCATION_ONFIELD+LOCATION_GRAVE,0)
e4:SetTarget(c79029810.tgtg)
e4:SetValue(aux.tgoval)
c:RegisterEffect(e4)
end
function c79029810.valcheck(e,c)
local flag=0
local g=c:GetMaterial()
if g:IsExists(Card.IsSetCard,1,nil,0xa991) then
flag=flag|1
end
e:GetLabelObject():SetLabel(flag)
end
function c79029810.sumsuc(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetFlagEffect(tp,79029810)>0 then return end
local c=e:GetHandler()
local ct=c:GetMaterial():GetCount()
if ct*2>=c:GetLevel() then return end
if Duel.IsPlayerCanDiscardDeck(e:GetHandlerPlayer(),ct*2) and c:IsSummonType(SUMMON_TYPE_SYNCHRO) and e:GetLabel()&1==1 and Duel.SelectEffectYesNo(tp,c) then
Duel.RegisterFlagEffect(tp,79029810,RESET_PHASE+PHASE_END,0,1)
if Duel.DiscardDeck(tp,ct*2,REASON_EFFECT) then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_LEVEL)
e1:SetValue(-(ct*2))
e1:SetReset(RESET_EVENT+0xff0000)
c:RegisterEffect(e1)
end
end
end
function c79029810.discon(e,tp,eg,ep,ev,re,r,rp)
return rp==1-tp and not e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED) and Duel.IsChainNegatable(ev)
end
function c79029810.costfilter(c)
return c:IsSetCard(0xa991) and c:IsAbleToGraveAsCost() and (c:IsFaceup() or c:IsLocation(LOCATION_HAND))
end
function c79029810.discost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c79029810.costfilter,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,c79029810.costfilter,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,1,nil)
Duel.SendtoGrave(g,REASON_COST)
end
function c79029810.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 c79029810.disop(e,tp,eg,ep,ev,re,r,rp)
if Duel.NegateActivation(ev) and re:GetHandler():IsRelateToEffect(re) then
Duel.Destroy(eg,REASON_EFFECT)
end
end
function c79029810.tgtg(e,c)
return c:IsSetCard(0xa991) and (c:IsFaceup() or c:IsLocation(LOCATION_GRAVE))
end
\ No newline at end of file
--构造的集结
function c79029811.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_TOGRAVE)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,79029811)
e1:SetTarget(c79029811.target)
e1:SetOperation(c79029811.activate)
c:RegisterEffect(e1)
--to hand
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_TOHAND)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_GRAVE)
e2:SetCondition(aux.exccon)
e2:SetCost(aux.bfgcost)
e2:SetCountLimit(1,19029811)
e2:SetTarget(c79029811.thtg)
e2:SetOperation(c79029811.thop)
c:RegisterEffect(e2)
end
function c79029811.filter(c)
return c:IsSetCard(0xa991) and (c:IsAbleToHand() or c:IsAbleToGrave())
end
function c79029811.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c79029811.filter,tp,LOCATION_DECK,0,1,nil) end
end
function c79029811.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_OPERATECARD)
local g=Duel.SelectMatchingCard(tp,c79029811.filter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()<=0 then return end
local tc=g:GetFirst()
if tc:IsAbleToHand() and (not tc:IsAbleToGrave() or Duel.SelectOption(tp,1190,1191)==0) then
Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc)
else
Duel.SendtoGrave(tc,REASON_EFFECT)
end
end
function c79029811.thfilter(c)
return c:IsSetCard(0xa991) and (c:IsLocation(LOCATION_GRAVE) or c:IsFaceup()) and c:IsAbleToHand()
end
function c79029811.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c79029811.thfilter,tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,e:GetHandler()) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_GRAVE+LOCATION_REMOVED)
end
function c79029811.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c79029811.thfilter,tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,e:GetHandler())
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
--构造的压制
function c79029812.initial_effect(c)
--activate
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_ACTIVATE)
e0:SetCode(EVENT_CHAINING)
e0:SetCost(c79029812.cost)
e0:SetCondition(c79029812.con)
e0:SetTarget(c79029812.tg)
e0:SetOperation(c79029812.op)
c:RegisterEffect(e0)
end
function c79029812.cost(e,tp,eg,ep,ev,re,r,rp,chk)
e:SetLabel(100)
return true
end
function c79029812.con(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsChainNegatable(ev) and rp~=tp
end
function c79029812.rlfilter(c)
return bit.band(c:GetOriginalType(),TYPE_MONSTER)==TYPE_MONSTER and c:IsSetCard(0xa991) and c:IsReleasable()
end
function c79029812.tg(e,tp,eg,ep,ev,re,r,rp,chk)
local mg=Duel.GetMatchingGroup(c79029812.rlfilter,tp,LOCATION_MZONE,0,1,nil)
if chk==0 then
if e:GetLabel()~=100 then return false end
e:SetLabel(0)
return mg:GetCount()>0
end
local rg=Duel.SelectReleaseGroup(tp,c79029812.rlfilter,1,mg:GetCount(),nil)
local num_1=Duel.Release(rg,REASON_COST)
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
if num_1>=2 then
e:SetCategory(CATEGORY_NEGATE+CATEGORY_DAMAGE)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,num_1*400,1-tp,0,0)
elseif num_1>=3 then
e:SetCategory(CATEGORY_NEGATE+CATEGORY_DAMAGE+CATEGORY_DRAW)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,num_1*400,1-tp,0,0)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,1,tp,0,0)
elseif num_1>=4 then
e:SetCategory(CATEGORY_NEGATE+CATEGORY_DAMAGE+CATEGORY_DRAW+CATEGORY_ATKCHANGE+CATEGORY_DEFCHANGE)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,num_1*400,1-tp,0,0)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,1,tp,0,0)
elseif num_1>=5 then
e:SetCategory(CATEGORY_NEGATE+CATEGORY_DAMAGE+CATEGORY_DRAW+CATEGORY_ATKCHANGE+CATEGORY_DEFCHANGE)
e:SetProperty(EFFECT_FLAG_CANNOT_INACTIVATE+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,num_1*400,1-tp,0,0)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,1,tp,0,0)
end
if num_1>0 then
if re and re:GetHandler():IsRelateToEffect(e) then
Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,1,tp,0,0)
end
end
e:SetLabel(num_1)
end
function c79029812.op(e,tp,eg,ep,ev,re,r,rp)
local num=e:GetLabel()
if num>0 and Duel.NegateActivation(ev) and re:GetHandler():IsRelateToEffect(re) then
Duel.Destroy(eg,REASON_EFFECT)
end
if num>1 then
Duel.Damage(1-tp,num*400,REASON_EFFECT)
end
if num>2 then
Duel.Draw(tp,1,REASON_EFFECT)
end
if num>3 then
local cg=Duel.GetMatchingGroup(nil,tp,0,LOCATION_MZONE,nil)
for tc in aux.Next(cg) 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+RESETS_STANDARD)
tc:RegisterEffect(e1)
local e3=e1:Clone()
e3:SetCode(EFFECT_SET_DEFENSE_FINAL)
tc:RegisterEffect(e3)
local e2=Effect.CreateEffect(e:GetHandler())
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_CANNOT_TRIGGER)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetRange(LOCATION_MZONE)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e2)
end
end
end
\ No newline at end of file
--构造基地 空中花园
function c79029813.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
c:RegisterEffect(e1)
--atk&def
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_UPDATE_ATTACK)
e2:SetRange(LOCATION_FZONE)
e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e2:SetTarget(aux.TargetBoolFunction(c79029813.filter))
e2:SetValue(500)
c:RegisterEffect(e2)
local e3=e2:Clone()
e3:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e3)
--race
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetRange(LOCATION_FZONE)
e3:SetTargetRange(LOCATION_MZONE,0)
e3:SetCode(EFFECT_CHANGE_RACE)
e3:SetValue(RACE_MACHINE)
c:RegisterEffect(e3)
--SpecialSummon
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(79029813,0))
e4:SetCategory(CATEGORY_SPECIAL_SUMMON)
e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetRange(LOCATION_FZONE)
e4:SetCountLimit(1)
e4:SetTarget(c79029813.sptg1)
e4:SetOperation(c79029813.spop1)
c:RegisterEffect(e4)
--Destroy replace
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_SINGLE)
e5:SetCode(EFFECT_DESTROY_REPLACE)
e5:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e5:SetRange(LOCATION_FZONE)
e5:SetTarget(c79029813.desreptg)
e5:SetOperation(c79029813.desrepop)
c:RegisterEffect(e5)
end
function c79029813.filter(c)
return c:IsFaceup() and c:IsSetCard(0xa991)
end
function c79029813.spfilter1(c,e,tp)
return c:IsSetCard(0xa991)
and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c79029813.sptg1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c79029813.spfilter1,tp,LOCATION_HAND+LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND+LOCATION_GRAVE)
end
function c79029813.spop1(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c79029813.spfilter1,tp,LOCATION_HAND+LOCATION_GRAVE,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
end
function c79029813.repfilter(c,e)
return c:IsFaceup() and c:IsSetCard(0xa991)
and c:IsAbleToGrave() and not c:IsImmuneToEffect(e) and not c:IsStatus(STATUS_DESTROY_CONFIRMED+STATUS_BATTLE_DESTROYED)
end
function c79029813.desreptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:IsReason(REASON_EFFECT) and not c:IsReason(REASON_REPLACE)
and Duel.IsExistingMatchingCard(c79029813.repfilter,tp,LOCATION_MZONE,0,1,c,e) end
if Duel.SelectEffectYesNo(tp,c,96) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESREPLACE)
local g=Duel.SelectMatchingCard(tp,c79029813.repfilter,tp,LOCATION_MZONE,0,1,1,c,e)
e:SetLabelObject(g:GetFirst())
g:GetFirst():SetStatus(STATUS_DESTROY_CONFIRMED,true)
return true
else return false end
end
function c79029813.desrepop(e,tp,eg,ep,ev,re,r,rp)
local tc=e:GetLabelObject()
tc:SetStatus(STATUS_DESTROY_CONFIRMED,false)
Duel.SendtoGrave(tc,REASON_REPLACE+REASON_EFFECT)
end
\ No newline at end of file
--构造终解 赤渊之上
function c79029814.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_FUSION_SUMMON+CATEGORY_DECKDES)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,79029814+EFFECT_COUNT_CODE_OATH)
e1:SetTarget(c79029814.target)
e1:SetOperation(c79029814.activate)
c:RegisterEffect(e1)
--destroy replace
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EFFECT_DESTROY_REPLACE)
e2:SetRange(LOCATION_GRAVE)
e2:SetTarget(c79029814.reptg)
e2:SetValue(c79029814.repval)
e2:SetOperation(c79029814.repop)
c:RegisterEffect(e2)
end
function c79029814.filter0(c)
return c:IsSetCard(0xa991) and c:IsType(TYPE_MONSTER) and c:IsCanBeFusionMaterial() and c:IsAbleToGrave()
end
function c79029814.filter1(c,e)
return not c:IsImmuneToEffect(e)
end
function c79029814.filter2(c,e,tp,m,f,chkf)
return c:IsType(TYPE_FUSION) and c:IsSetCard(0xa991) and (not f or f(c))
and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_FUSION,tp,false,false) and c:CheckFusionMaterial(m,nil,chkf)
end
function c79029814.cfilter(c)
return c:GetSummonLocation()==LOCATION_EXTRA
end
function c79029814.fcheck(tp,sg,fc)
return sg:FilterCount(Card.IsLocation,nil,LOCATION_DECK+LOCATION_EXTRA)<=1
end
function c79029814.gcheck(sg)
return sg:FilterCount(Card.IsLocation,nil,LOCATION_DECK+LOCATION_EXTRA)<=1
end
function c79029814.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
local chkf=tp
local mg1=Duel.GetFusionMaterial(tp)
if Duel.IsExistingMatchingCard(c79029814.cfilter,tp,0,LOCATION_MZONE,1,nil) then
local mg2=Duel.GetMatchingGroup(c79029814.filter0,tp,LOCATION_DECK+LOCATION_EXTRA,0,nil)
if mg2:GetCount()>0 then
mg1:Merge(mg2)
aux.FCheckAdditional=c79029814.fcheck
aux.GCheckAdditional=c79029814.gcheck
end
end
local res=Duel.IsExistingMatchingCard(c79029814.filter2,tp,LOCATION_EXTRA,0,1,nil,e,tp,mg1,nil,chkf)
aux.FCheckAdditional=nil
aux.GCheckAdditional=nil
if not res then
local ce=Duel.GetChainMaterial(tp)
if ce~=nil then
local fgroup=ce:GetTarget()
local mg3=fgroup(ce,e,tp)
local mf=ce:GetValue()
res=Duel.IsExistingMatchingCard(c79029814.filter2,tp,LOCATION_EXTRA,0,1,nil,e,tp,mg3,mf,chkf)
end
end
return res
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function c79029814.activate(e,tp,eg,ep,ev,re,r,rp)
local chkf=tp
local mg1=Duel.GetFusionMaterial(tp):Filter(c79029814.filter1,nil,e)
local exmat=false
if Duel.IsExistingMatchingCard(c79029814.cfilter,tp,0,LOCATION_MZONE,1,nil) then
local mg2=Duel.GetMatchingGroup(c79029814.filter0,tp,LOCATION_DECK+LOCATION_EXTRA,0,nil)
if mg2:GetCount()>0 then
mg1:Merge(mg2)
exmat=true
end
end
if exmat then
aux.FCheckAdditional=c79029814.fcheck
aux.GCheckAdditional=c79029814.gcheck
end
local sg1=Duel.GetMatchingGroup(c79029814.filter2,tp,LOCATION_EXTRA,0,nil,e,tp,mg1,nil,chkf)
aux.FCheckAdditional=nil
aux.GCheckAdditional=nil
local mg3=nil
local sg2=nil
local ce=Duel.GetChainMaterial(tp)
if ce~=nil then
local fgroup=ce:GetTarget()
mg3=fgroup(ce,e,tp)
local mf=ce:GetValue()
sg2=Duel.GetMatchingGroup(c79029814.filter2,tp,LOCATION_EXTRA,0,nil,e,tp,mg3,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()
mg1:RemoveCard(tc)
if sg1:IsContains(tc) and (sg2==nil or not sg2:IsContains(tc) or not Duel.SelectYesNo(tp,ce:GetDescription())) then
if exmat then
aux.FCheckAdditional=c79029814.fcheck
aux.GCheckAdditional=c79029814.gcheck
end
local mat1=Duel.SelectFusionMaterial(tp,tc,mg1,nil,chkf)
aux.FCheckAdditional=nil
aux.GCheckAdditional=nil
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,mg3,nil,chkf)
local fop=ce:GetOperation()
fop(ce,e,tp,tc,mat2)
end
if tc:IsCode(79029808) then
--
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetDescription(aux.Stringid(79029814,0))
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_IMMUNE_EFFECT)
e1:SetProperty(EFFECT_FLAG_CLIENT_HINT)
e1:SetValue(c79029814.efilter)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
e1:SetOwnerPlayer(tp)
tc:RegisterEffect(e1)
end
tc:CompleteProcedure()
end
end
function c79029814.efilter(e,re)
return e:GetOwnerPlayer()~=re:GetOwnerPlayer()
end
function c79029814.repfilter(c,tp)
return c:IsFaceup() and c:IsSetCard(0xa991)
and c:IsControler(tp) and c:IsReason(REASON_EFFECT+REASON_BATTLE) and not c:IsReason(REASON_REPLACE)
end
function c79029814.reptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToRemove() and eg:IsExists(c79029814.repfilter,1,nil,tp) end
return Duel.SelectEffectYesNo(tp,e:GetHandler(),96)
end
function c79029814.repval(e,c)
return c79029814.repfilter(c,e:GetHandlerPlayer())
end
function c79029814.repop(e,tp,eg,ep,ev,re,r,rp)
Duel.Remove(e:GetHandler(),POS_FACEUP,REASON_EFFECT)
end
\ No newline at end of file
--个人行动-影霄·奔夜
function c79029900.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
c:RegisterEffect(e1)
--SpecialSummon
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_REMOVE)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetRange(LOCATION_SZONE)
e1:SetCountLimit(1,79029900)
e1:SetTarget(c79029900.sptg)
e1:SetOperation(c79029900.spop)
c:RegisterEffect(e1)
--link
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetHintTiming(0,TIMING_END_PHASE)
e2:SetRange(LOCATION_SZONE)
e2:SetCountLimit(1,09029900)
e2:SetCost(c79029900.lkcost)
e2:SetTarget(c79029900.lktg)
e2:SetOperation(c79029900.lkop)
c:RegisterEffect(e2)
--cd
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetCode(EFFECT_CANNOT_DISABLE_SPSUMMON)
e3:SetProperty(EFFECT_FLAG_IGNORE_RANGE+EFFECT_FLAG_SET_AVAILABLE)
e3:SetRange(LOCATION_SZONE)
e3:SetTarget(c79029900.cdtg)
e3:SetTargetRange(LOCATION_MZONE,0)
c:RegisterEffect(e3)
end
function c79029900.spfil(c,e,tp)
return c:IsSetCard(0xa900) and c:IsType(TYPE_LINK) and c:IsLinkBelow(3)
and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and Duel.GetLocationCountFromEx(tp,tp,nil,c)>0
end
function c79029900.ckfil(c)
return c:IsSetCard(0xa900) and c:IsPreviousLocation(LOCATION_ONFIELD)
end
function c79029900.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c79029900.spfil,tp,LOCATION_EXTRA,0,1,nil,e,tp) and eg:IsExists(c79029900.ckfil,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function c79029900.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local g=Duel.GetMatchingGroup(c79029900.spfil,tp,LOCATION_EXTRA,0,nil,e,tp)
if g:GetCount()<=0 then return end
Debug.Message("死亡应该铭刻在我们的记忆里,永不遗忘,无论这死亡是谁带来的,又是被带给了谁。我们的错误永远不会变成正确......那些疤痕应该要一直提醒我们,警告我们有多脆弱。")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029900,0))
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local sg=g:Select(tp,1,1,nil)
Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetTargetRange(1,0)
e1:SetTarget(c79029900.splimit)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
function c79029900.splimit(e,c)
return not c:IsSetCard(0xa900)
end
function c79029900.lkcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckLPCost(tp,1000) end
Duel.PayLPCost(tp,1000)
end
function c79029900.filter(c,mg)
return c:IsLinkSummonable(nil) and c:IsSetCard(0xa900)
end
function c79029900.lmfil(c)
return c:IsSetCard(0xa900) and c:IsCanBeLinkMaterial(nil)
end
function c79029900.lktg(e,tp,eg,ep,ev,re,r,rp,chk)
local mg=Duel.GetMatchingGroup(c79029900.lmfil,tp,LOCATION_MZONE,0,nil)
if chk==0 then return Duel.IsExistingMatchingCard(c79029900.filter,tp,LOCATION_EXTRA,0,1,nil,mg) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,0)
end
function c79029900.lkop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local mg=Duel.GetMatchingGroup(c79029900.lmfil,tp,LOCATION_MZONE,0,nil)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c79029900.filter,tp,LOCATION_EXTRA,0,1,1,nil,mg)
local tc=g:GetFirst()
if tc then
if tc:IsCode(79029359) then
Debug.Message("好的,我知道了。")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029900,2))
else
Debug.Message("行动开始。我们走!")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029900,1))
end
Duel.LinkSummon(tp,tc,mg)
end
end
function c79029900.cdtg(e,c)
return c:IsSetCard(0xa900) and c:IsType(TYPE_LINK)
end
...@@ -10,14 +10,18 @@ function c9910109.initial_effect(c) ...@@ -10,14 +10,18 @@ function c9910109.initial_effect(c)
e1:SetTarget(c9910109.sptg) e1:SetTarget(c9910109.sptg)
e1:SetOperation(c9910109.spop) e1:SetOperation(c9910109.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--activate limit --active limit
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_XMATERIAL+EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_XMATERIAL+EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_CANNOT_ACTIVATE) e2:SetCode(EFFECT_CANNOT_TO_HAND)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetTargetRange(0,1) e2:SetTargetRange(0,1)
e2:SetValue(c9910109.aclimit) e2:SetCondition(c9910109.condition)
e2:SetTarget(c9910109.actlimit)
c:RegisterEffect(e2) c:RegisterEffect(e2)
local e3=e2:Clone()
e3:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
c:RegisterEffect(e3)
end end
function c9910109.spcost(e,tp,eg,ep,ev,re,r,rp,chk) function c9910109.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return not e:GetHandler():IsPublic() end if chk==0 then return not e:GetHandler():IsPublic() end
...@@ -54,6 +58,9 @@ function c9910109.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -54,6 +58,9 @@ function c9910109.spop(e,tp,eg,ep,ev,re,r,rp)
Duel.SendtoDeck(c,nil,0,REASON_EFFECT) Duel.SendtoDeck(c,nil,0,REASON_EFFECT)
end end
end end
function c9910109.aclimit(e,re,tp) function c9910109.condition(e,tp,eg,ep,ev,re,r,rp)
return re:GetActivateLocation()==LOCATION_GRAVE return e:GetHandler():IsRace(RACE_MACHINE)
end
function c9910109.actlimit(e,c)
return c:IsLocation(LOCATION_GRAVE) and c:IsType(TYPE_MONSTER)
end end
...@@ -10,24 +10,23 @@ function c9910114.initial_effect(c) ...@@ -10,24 +10,23 @@ function c9910114.initial_effect(c)
e1:SetTarget(c9910114.sptg) e1:SetTarget(c9910114.sptg)
e1:SetOperation(c9910114.spop) e1:SetOperation(c9910114.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--pos --activate limit
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_XMATERIAL+EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_XMATERIAL+EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_SET_POSITION) e2:SetCode(EFFECT_CANNOT_ACTIVATE)
e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetCondition(c9910114.poscon) e2:SetTargetRange(1,1)
e2:SetTarget(c9910114.postg) e2:SetCondition(c9910114.condition)
e2:SetValue(POS_FACEUP_DEFENSE) e2:SetValue(c9910114.aclimit)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--activate limit if not c9910114.global_check then
local e3=Effect.CreateEffect(c) c9910114.global_check=true
e3:SetType(EFFECT_TYPE_XMATERIAL+EFFECT_TYPE_FIELD) local ge1=Effect.CreateEffect(c)
e3:SetCode(EFFECT_CANNOT_ACTIVATE) ge1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET) ge1:SetCode(EVENT_BATTLED)
e3:SetTargetRange(1,1) ge1:SetOperation(c9910114.checkop)
e3:SetCondition(c9910114.poscon) Duel.RegisterEffect(ge1,0)
e3:SetValue(c9910114.aclimit) end
c:RegisterEffect(e3)
end end
function c9910114.spcost(e,tp,eg,ep,ev,re,r,rp,chk) function c9910114.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return not e:GetHandler():IsPublic() end if chk==0 then return not e:GetHandler():IsPublic() end
...@@ -64,15 +63,22 @@ function c9910114.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -64,15 +63,22 @@ function c9910114.spop(e,tp,eg,ep,ev,re,r,rp)
Duel.SendtoDeck(c,nil,0,REASON_EFFECT) Duel.SendtoDeck(c,nil,0,REASON_EFFECT)
end end
end end
function c9910114.poscon(e) function c9910114.condition(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() return e:GetHandler():IsRace(RACE_MACHINE)
return c:IsLocation(LOCATION_MZONE) and c:IsDefensePos()
end
function c9910114.postg(e,c)
return c:IsFaceup()
end end
function c9910114.aclimit(e,re,tp) function c9910114.aclimit(e,re,tp)
return re:IsActiveType(TYPE_MONSTER) local rc=re:GetHandler()
and (re:GetActivateLocation()==LOCATION_HAND return re:IsActiveType(TYPE_MONSTER) and re:GetActivateLocation()==LOCATION_MZONE and rc:IsAttackPos()
or (re:GetActivateLocation()==LOCATION_MZONE and re:GetHandler():IsAttackPos())) and rc:GetAttackedCount()==0 and rc:GetFlagEffect(9910114)==0
end
function c9910114.atkfilter(c)
return c:GetAttackedCount()>0 and c:IsFaceup() and c:GetFlagEffect(9910114)==0
end
function c9910114.checkop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c9910114.atkfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil)
local tc=g:GetFirst()
while tc do
tc:RegisterFlagEffect(9910114,RESET_EVENT+RESETS_STANDARD,0,1)
tc=g:GetNext()
end
end end
...@@ -9,47 +9,57 @@ function c9910134.initial_effect(c) ...@@ -9,47 +9,57 @@ function c9910134.initial_effect(c)
e1:SetType(EFFECT_TYPE_IGNITION) e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET) e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(2,9910134) e1:SetCountLimit(1)
e1:SetCost(c9910134.cost)
e1:SetTarget(c9910134.target) e1:SetTarget(c9910134.target)
e1:SetOperation(c9910134.operation) e1:SetOperation(c9910134.operation)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_MAIN_END)
e2:SetCondition(c9910134.condition)
e2:SetCost(c9910134.cost)
c:RegisterEffect(e2)
end end
function c9910134.xyzfilter(c,xyzc) function c9910134.xyzfilter(c,xyzc)
return (c:IsType(TYPE_MONSTER) or (c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsSetCard(0x952) and c:IsFaceup())) return (c:IsType(TYPE_MONSTER) or (c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsSetCard(0x952) and c:IsFaceup()))
and c:IsRace(RACE_MACHINE) and c:IsRace(RACE_MACHINE)
end end
function c9910134.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()~=tp
and (Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2)
end
function c9910134.cost(e,tp,eg,ep,ev,re,r,rp,chk) function c9910134.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,2,REASON_COST) end if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end
e:GetHandler():RemoveOverlayCard(tp,2,2,REASON_COST) e:GetHandler():RemoveOverlayCard(tp,1,1,REASON_COST)
end
function c9910134.xfilter(c)
return c:IsFaceup() and c:IsRace(RACE_MACHINE) and c:IsType(TYPE_XYZ)
end end
function c9910134.filter(c,tp) function c9910134.xfilter2(c,e)
return c:IsFaceup() and not c:IsType(TYPE_TOKEN) and (c:IsControler(tp) or c:IsAbleToChangeControler()) return c:IsFaceup() and c:IsRace(RACE_MACHINE) and c:IsType(TYPE_XYZ) and not c:IsImmuneToEffect(e)
end end
function c9910134.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c9910134.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler() local c=e:GetHandler()
if chkc then return chkc:IsOnField() and c9910134.filter(chkc) end if chkc then return chkc:IsOnField() and chkc:IsControler(1-tp) and chkc:IsCanOverlay() end
if chk==0 then return Duel.IsExistingTarget(c9910134.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,c,tp) end if chk==0 then return Duel.IsExistingTarget(Card.IsCanOverlay,tp,0,LOCATION_ONFIELD,1,nil)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) and Duel.IsExistingMatchingCard(c9910134.xfilter,tp,LOCATION_MZONE,0,1,c) end
Duel.SelectTarget(tp,c9910134.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,c,tp) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_XMATERIAL)
Duel.SelectTarget(tp,Card.IsCanOverlay,tp,0,LOCATION_ONFIELD,1,1,nil)
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription()) Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
end end
function c9910134.operation(e,tp,eg,ep,ev,re,r,rp) function c9910134.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and not tc:IsImmuneToEffect(e) then if tc:IsRelateToEffect(e) and not tc:IsImmuneToEffect(e)
and Duel.IsExistingMatchingCard(c9910134.xfilter2,tp,LOCATION_MZONE,0,1,c,e) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local sg=Duel.SelectMatchingCard(tp,c9910134.xfilter2,tp,LOCATION_MZONE,0,1,1,c,e)
local sc=sg:GetFirst()
local og=tc:GetOverlayGroup() local og=tc:GetOverlayGroup()
if og:GetCount()>0 then if og:GetCount()>0 then
Duel.SendtoGrave(og,REASON_RULE) Duel.SendtoGrave(og,REASON_RULE)
end end
Duel.Overlay(c,Group.FromCards(tc)) Duel.Overlay(sc,Group.FromCards(tc))
else return end
local g=Duel.GetMatchingGroup(nil,1-tp,LOCATION_MZONE+LOCATION_HAND,0,nil)
if c:GetOverlayGroup():IsExists(Card.IsSetCard,1,nil,0x952) and g:GetCount()>0 then
Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,1-tp,HINTMSG_TOGRAVE)
local sg=g:Select(1-tp,1,1,nil)
Duel.HintSelection(sg)
Duel.SendtoGrave(sg,REASON_RULE)
end end
end end
...@@ -9,7 +9,6 @@ function c9910202.initial_effect(c) ...@@ -9,7 +9,6 @@ function c9910202.initial_effect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCountLimit(1,9910202)
e1:SetTarget(c9910202.destg) e1:SetTarget(c9910202.destg)
e1:SetOperation(c9910202.desop) e1:SetOperation(c9910202.desop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
...@@ -20,7 +19,6 @@ function c9910202.initial_effect(c) ...@@ -20,7 +19,6 @@ function c9910202.initial_effect(c)
e2:SetCode(EVENT_CHAINING) e2:SetCode(EVENT_CHAINING)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL) e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1,9910203)
e2:SetCondition(c9910202.discon) e2:SetCondition(c9910202.discon)
e2:SetCost(c9910202.discost) e2:SetCost(c9910202.discost)
e2:SetTarget(c9910202.distg) e2:SetTarget(c9910202.distg)
...@@ -45,6 +43,7 @@ function c9910202.desop(e,tp,eg,ep,ev,re,r,rp) ...@@ -45,6 +43,7 @@ function c9910202.desop(e,tp,eg,ep,ev,re,r,rp)
end end
function c9910202.discon(e,tp,eg,ep,ev,re,r,rp) function c9910202.discon(e,tp,eg,ep,ev,re,r,rp)
return rp==1-tp and not e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED) and Duel.IsChainNegatable(ev) return rp==1-tp and not e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED) and Duel.IsChainNegatable(ev)
and e:GetHandler():IsSummonType(SUMMON_TYPE_LINK)
end end
function c9910202.discost(e,tp,eg,ep,ev,re,r,rp,chk) function c9910202.discost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
...@@ -66,15 +65,24 @@ end ...@@ -66,15 +65,24 @@ end
function c9910202.distg(e,tp,eg,ep,ev,re,r,rp,chk) function c9910202.distg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0) Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,0,tp,LOCATION_REMOVED)
if re:GetHandler():IsDestructable() and re:GetHandler():IsRelateToEffect(re) then
Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,1,0,0)
end
end end
function c9910202.spfilter(c,e,tp) function c9910202.spfilter(c,e,tp)
return c:IsType(TYPE_LINK) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsType(TYPE_LINK) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function c9910202.locfilter(c)
return c:IsLocation(LOCATION_ONFIELD+LOCATION_GRAVE)
or c:IsPreviousLocation(LOCATION_ONFIELD+LOCATION_GRAVE)
end
function c9910202.disop(e,tp,eg,ep,ev,re,r,rp) function c9910202.disop(e,tp,eg,ep,ev,re,r,rp)
local tg=Duel.GetChainInfo(ev,CHAININFO_TARGET_CARDS) local tg=Duel.GetChainInfo(ev,CHAININFO_TARGET_CARDS)
if not Duel.NegateActivation(ev) then return end if Duel.NegateActivation(ev) and re:GetHandler():IsRelateToEffect(re) then
if tg and (tg:IsExists(Card.IsOnField,1,nil) or tg:IsExists(Card.IsPreviousLocation,1,nil,LOCATION_ONFIELD)) Duel.Destroy(eg,REASON_EFFECT)
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
if tg and tg:IsExists(c9910202.locfilter,1,nil) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c9910202.spfilter,tp,LOCATION_REMOVED,0,1,nil,e,tp) and Duel.IsExistingMatchingCard(c9910202.spfilter,tp,LOCATION_REMOVED,0,1,nil,e,tp)
and Duel.SelectYesNo(tp,aux.Stringid(9910202,0)) then and Duel.SelectYesNo(tp,aux.Stringid(9910202,0)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
......
--天空漫步者-眼镜蛇式 --天空漫步者-拦截
function c9910212.initial_effect(c) function c9910212.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE)
e1:SetCondition(c9910212.condition) e1:SetCondition(c9910212.condition)
e1:SetCost(c9910212.cost)
e1:SetTarget(c9910212.target) e1:SetTarget(c9910212.target)
e1:SetOperation(c9910212.activate) e1:SetOperation(c9910212.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--remove
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_REMOVE)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP)
e2:SetCode(EVENT_CHAINING)
e2:SetRange(LOCATION_GRAVE)
e2:SetCountLimit(1,9910212)
e2:SetCondition(c9910212.rmcon)
e2:SetCost(aux.bfgcost)
e2:SetTarget(c9910212.rmtg)
e2:SetOperation(c9910212.rmop)
c:RegisterEffect(e2)
end end
function c9910212.cfilter(c) function c9910212.cfilter(c)
return c:GetSequence()<5 and (c:IsFacedown() or not c:IsRace(RACE_PSYCHO)) return c:GetSequence()<5 and (c:IsFacedown() or not c:IsRace(RACE_PSYCHO))
...@@ -16,60 +31,47 @@ end ...@@ -16,60 +31,47 @@ end
function c9910212.condition(e,tp,eg,ep,ev,re,r,rp) function c9910212.condition(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsExistingMatchingCard(c9910212.cfilter,tp,LOCATION_MZONE,0,1,nil) return not Duel.IsExistingMatchingCard(c9910212.cfilter,tp,LOCATION_MZONE,0,1,nil)
end end
function c9910212.costfilter(c) function c9910212.seqfilter(c)
return c:IsFaceup() and c:IsSetCard(0x955) and c:IsAbleToRemoveAsCost() return c:IsFaceup() and c:IsSetCard(0x955)
end end
function c9910212.cost(e,tp,eg,ep,ev,re,r,rp,chk) function c9910212.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler() if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c9910212.seqfilter(chkc) end
if chk==0 then return Duel.IsExistingMatchingCard(c9910212.costfilter,tp,LOCATION_MZONE,0,1,nil) end if chk==0 then return Duel.IsExistingTarget(c9910212.seqfilter,tp,LOCATION_MZONE,0,1,nil)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) and Duel.GetLocationCount(tp,LOCATION_MZONE,PLAYER_NONE,0)>0 end
local g=Duel.SelectMatchingCard(tp,c9910212.costfilter,tp,LOCATION_MZONE,0,1,1,nil) Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(9910212,1))
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.SelectTarget(tp,c9910212.seqfilter,tp,LOCATION_MZONE,0,1,1,nil)
end
function c9910212.retop(e,tp,eg,ep,ev,re,r,rp)
Duel.ReturnToField(e:GetLabelObject())
end
function c9910212.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
if Duel.GetCurrentChain()>2 then e:SetCategory(CATEGORY_DESTROY) end
end end
function c9910212.activate(e,tp,eg,ep,ev,re,r,rp) function c9910212.activate(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler()) local tc=Duel.GetFirstTarget()
e1:SetType(EFFECT_TYPE_FIELD) if not tc:IsRelateToEffect(e) or tc:IsControler(1-tp) or Duel.GetLocationCount(tp,LOCATION_MZONE,PLAYER_NONE,0)<=0 then return end
e1:SetCode(EFFECT_CHANGE_DAMAGE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOZONE)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET) local s=Duel.SelectDisableField(tp,1,LOCATION_MZONE,0,0)
e1:SetTargetRange(1,0) local nseq=math.log(s,2)
e1:SetValue(c9910212.damval) Duel.MoveSequence(tc,nseq)
e1:SetReset(RESET_PHASE+PHASE_END) local tg=tc:GetColumnGroup():Filter(Card.IsLocation,nil,LOCATION_MZONE)
Duel.RegisterEffect(e1,tp) tg:AddCard(tc)
Duel.RegisterFlagEffect(tp,9910212,RESET_PHASE+PHASE_END,0,1) if tg:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(9910212,0)) then
local e2=Effect.CreateEffect(e:GetHandler()) Duel.BreakEffect()
e2:SetDescription(aux.Stringid(9910212,1)) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) local sg=tg:Select(tp,1,1,nil)
e2:SetCode(EVENT_PHASE+PHASE_END) Duel.HintSelection(sg)
e2:SetLabel(Duel.GetCurrentChain()) Duel.Destroy(sg,REASON_EFFECT)
e2:SetCountLimit(1) end
e2:SetCondition(c9910212.descon)
e2:SetOperation(c9910212.desop)
e2:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e2,tp)
end end
function c9910212.damval(e,re,val,r,rp,rc) function c9910212.rmcon(e,tp,eg,ep,ev,re,r,rp)
local tp=e:GetHandlerPlayer() local loc=Duel.GetChainInfo(ev,CHAININFO_TRIGGERING_LOCATION)
if Duel.GetFlagEffect(tp,9910212)==0 or bit.band(r,REASON_BATTLE)==0 then return val end return bit.band(loc,LOCATION_GRAVE)~=0 and re:IsActiveType(TYPE_MONSTER) and re:GetHandler():GetOriginalRace()==RACE_PSYCHO
Duel.ResetFlagEffect(tp,9910212)
return 0
end end
function c9910212.descon(e,tp,eg,ep,ev,re,r,rp) function c9910212.rmtg(e,tp,eg,ep,ev,re,r,rp,chk)
return Duel.IsExistingMatchingCard(aux.TRUE,tp,0,LOCATION_ONFIELD,1,nil) local g=Duel.GetMatchingGroup(Card.IsAbleToRemove,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil)
if chk==0 then return g:GetCount()>0 end
Duel.SetOperationInfo(0,CATEGORY_REMOVE,g,1,0,0)
end end
function c9910212.desop(e,tp,eg,ep,ev,re,r,rp) function c9910212.rmop(e,tp,eg,ep,ev,re,r,rp)
local ct=1 Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
if e:GetLabel()>2 then ct=2 end local g=Duel.SelectMatchingCard(tp,Card.IsAbleToRemove,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
Duel.Hint(HINT_CARD,0,9910212)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectMatchingCard(tp,aux.TRUE,tp,0,LOCATION_ONFIELD,1,ct,nil)
if g:GetCount()>0 then if g:GetCount()>0 then
Duel.Destroy(g,REASON_EFFECT) Duel.HintSelection(g)
Duel.Remove(g,POS_FACEUP,REASON_EFFECT)
end end
end end
...@@ -45,7 +45,7 @@ function c9910213.cost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -45,7 +45,7 @@ function c9910213.cost(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.PayLPCost(tp,1000) Duel.PayLPCost(tp,1000)
end end
function c9910213.spfilter(c,e,tp) function c9910213.spfilter(c,e,tp)
return c:IsLevelBelow(4) and c:IsSetCard(0x955) and (c:IsAbleToHand() or (Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and c:IsCanBeSpecialSummoned(e,0,tp,false,false))) return c:IsSetCard(0x955) and (c:IsLevelBelow(4) or c:IsLink(1)) and (c:IsAbleToHand() or (Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and c:IsCanBeSpecialSummoned(e,0,tp,false,false)))
end end
function c9910213.target2(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c9910213.target2(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and c9910213.spfilter(chkc,e,tp) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and c9910213.spfilter(chkc,e,tp) end
......
--天空漫步者-追击 --天空漫步者 保坂实里
function c9910216.initial_effect(c) function c9910216.initial_effect(c)
--Activate --spsummon link
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_REMOVE+CATEGORY_RECOVER+CATEGORY_DRAW) e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetHintTiming(0,TIMING_END_PHASE) e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY)
e1:SetCondition(c9910216.condition) e1:SetTarget(c9910216.sptg)
e1:SetTarget(c9910216.target) e1:SetOperation(c9910216.spop)
e1:SetOperation(c9910216.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
if not c9910216.global_check then --summon
c9910216.global_check=true local e2=Effect.CreateEffect(c)
local ge1=Effect.CreateEffect(c) e2:SetCategory(CATEGORY_SUMMON)
ge1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_QUICK_O)
ge1:SetCode(EVENT_DESTROYED) e2:SetCode(EVENT_CHAINING)
ge1:SetOperation(c9910216.checkop) e2:SetRange(LOCATION_MZONE+LOCATION_GRAVE)
Duel.RegisterEffect(ge1,0) e2:SetCountLimit(1,9910216)
end e2:SetCondition(c9910216.sumcon)
e2:SetCost(c9910216.sumcost)
e2:SetTarget(c9910216.sumtg)
e2:SetOperation(c9910216.sumop)
c:RegisterEffect(e2)
end
function c9910216.get_zone(c,seq)
local zone=0
if seq<4 and c:IsLinkMarker(LINK_MARKER_LEFT) then zone=bit.replace(zone,0x1,seq+1) end
if seq>0 and seq<5 and c:IsLinkMarker(LINK_MARKER_RIGHT) then zone=bit.replace(zone,0x1,seq-1) end
return zone
end
function c9910216.spfilter(c,e,tp,seq)
local zone=c9910216.get_zone(c,seq)
return zone~=0 and c:IsSetCard(0x955) and c:IsType(TYPE_LINK)
and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP,tp,zone)
end
function c9910216.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local seq=e:GetHandler():GetSequence()
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c9910216.spfilter(chkc,e,tp,seq) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingTarget(c9910216.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp,seq) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c9910216.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp,seq)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end end
function c9910216.checkop(e,tp,eg,ep,ev,re,r,rp) function c9910216.spop(e,tp,eg,ep,ev,re,r,rp)
local tc=eg:GetFirst() local c=e:GetHandler()
local p1=false local tc=Duel.GetFirstTarget()
local p2=false if c:IsRelateToEffect(e) and c:IsControler(tp) and tc:IsRelateToEffect(e) then
while tc do local zone=c9910216.get_zone(tc,c:GetSequence())
if tc:IsPreviousLocation(LOCATION_MZONE) then if zone~=0 and Duel.SpecialSummonStep(tc,0,tp,tp,false,false,POS_FACEUP,zone) then
if tc:GetPreviousControler()~=0 then p1=true else p2=true end local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_SET_ATTACK)
e3:SetValue(0)
e3:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e3)
end end
tc=eg:GetNext() Duel.SpecialSummonComplete()
end end
if p1 then Duel.RegisterFlagEffect(0,9910216,RESET_PHASE+PHASE_END,0,1) end local e1=Effect.CreateEffect(c)
if p2 then Duel.RegisterFlagEffect(1,9910216,RESET_PHASE+PHASE_END,0,1) end e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(1,0)
e1:SetTarget(c9910216.splimit)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end end
function c9910216.cfilter(c) function c9910216.splimit(e,c)
return c:GetSequence()<5 and (c:IsFacedown() or not c:IsRace(RACE_PSYCHO)) return not c:IsSetCard(0x955)
end end
function c9910216.condition(e,tp,eg,ep,ev,re,r,rp) function c9910216.sumcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetFlagEffect(tp,9910216)~=0 local c=e:GetHandler()
and not Duel.IsExistingMatchingCard(c9910216.cfilter,tp,LOCATION_MZONE,0,1,nil) if not re:IsHasProperty(EFFECT_FLAG_CARD_TARGET) then return false end
local g=Duel.GetChainInfo(ev,CHAININFO_TARGET_CARDS)
return g and g:IsContains(c)
end end
function c9910216.target(e,tp,eg,ep,ev,re,r,rp,chk) function c9910216.sumcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,0,LOCATION_HAND+LOCATION_ONFIELD+LOCATION_GRAVE,1,nil) end if chk==0 then return e:GetHandler():IsAbleToDeckAsCost() end
Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,0,LOCATION_HAND+LOCATION_ONFIELD+LOCATION_GRAVE) Duel.SendtoDeck(e:GetHandler(),nil,2,REASON_COST)
end end
function c9910216.activate(e,tp,eg,ep,ev,re,r,rp) function c9910216.sumfilter(c)
local g1=Duel.GetMatchingGroup(Card.IsAbleToRemove,tp,0,LOCATION_ONFIELD,nil) return c:IsSetCard(0x955) and c:IsSummonable(true,nil)
local g2=Duel.GetMatchingGroup(Card.IsAbleToRemove,tp,0,LOCATION_GRAVE,nil) end
local g3=Duel.GetMatchingGroup(Card.IsAbleToRemove,tp,0,LOCATION_HAND,nil) function c9910216.sumtg(e,tp,eg,ep,ev,re,r,rp,chk)
local sg=Group.CreateGroup() if chk==0 then return Duel.IsExistingMatchingCard(c9910216.sumfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,1,nil) end
if g1:GetCount()>0 and ((g2:GetCount()==0 and g3:GetCount()==0) or Duel.SelectYesNo(tp,aux.Stringid(9910216,3))) then Duel.SetOperationInfo(0,CATEGORY_SUMMON,nil,1,0,0)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) end
local sg1=g1:Select(tp,1,1,nil) function c9910216.sumop(e,tp,eg,ep,ev,re,r,rp)
Duel.HintSelection(sg1) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON)
sg:Merge(sg1) local g=Duel.SelectMatchingCard(tp,c9910216.sumfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,1,1,nil)
end local tc=g:GetFirst()
if g2:GetCount()>0 and ((sg:GetCount()==0 and g3:GetCount()==0) or Duel.SelectYesNo(tp,aux.Stringid(9910216,4))) then if tc then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) Duel.Summon(tp,tc,true,nil)
local sg2=g2:Select(tp,1,1,nil)
Duel.HintSelection(sg2)
sg:Merge(sg2)
end
if g3:GetCount()>0 and (sg:GetCount()==0 or Duel.SelectYesNo(tp,aux.Stringid(9910216,5))) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local sg3=g3:RandomSelect(tp,1)
sg:Merge(sg3)
end
if Duel.Remove(sg,POS_FACEUP,REASON_EFFECT)>0 and Duel.SelectYesNo(1-tp,aux.Stringid(9910216,0)) then
Duel.BreakEffect()
if not Duel.IsPlayerCanDraw(1-tp,1) then Duel.Recover(1-tp,3000,REASON_EFFECT) return end
if Duel.GetCurrentChain()>2 then
if Duel.SelectOption(tp,aux.Stringid(9910216,1),aux.Stringid(9910216,2))==0 then
Duel.Recover(1-tp,3000,REASON_EFFECT)
else
Duel.Draw(1-tp,1,REASON_EFFECT)
end
else
if Duel.SelectOption(1-tp,aux.Stringid(9910216,1),aux.Stringid(9910216,2))==0 then
Duel.Recover(1-tp,3000,REASON_EFFECT)
else
Duel.Draw(1-tp,1,REASON_EFFECT)
end
end
end end
end end
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
function c9910223.initial_effect(c) function c9910223.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_ATKCHANGE+CATEGORY_DESTROY+CATEGORY_DAMAGE) e1:SetCategory(CATEGORY_ATKCHANGE+CATEGORY_DESTROY+CATEGORY_REMOVE)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DAMAGE_STEP) e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DAMAGE_STEP)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
...@@ -20,9 +20,23 @@ function c9910223.condition(e,tp,eg,ep,ev,re,r,rp) ...@@ -20,9 +20,23 @@ function c9910223.condition(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsExistingMatchingCard(c9910223.cfilter,tp,LOCATION_MZONE,0,1,nil) return not Duel.IsExistingMatchingCard(c9910223.cfilter,tp,LOCATION_MZONE,0,1,nil)
end end
function c9910223.cost(e,tp,eg,ep,ev,re,r,rp,chk) function c9910223.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckLPCost(tp,100) end e:SetLabel(100)
if chk==0 then return true end
end
function c9910223.target(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
if e:GetLabel()~=100 then return false end
e:SetLabel(0)
return Duel.CheckLPCost(tp,100) and Duel.IsExistingTarget(Card.IsFaceup,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil)
end
local maxlp=2000
if e:IsHasType(EFFECT_TYPE_ACTIVATE) and Duel.GetCurrentChain()>2 then
maxlp=3000
Duel.SetChainLimit(c9910223.chainlm)
end
local lp=Duel.GetLP(tp) local lp=Duel.GetLP(tp)
local m=math.floor(math.min(lp,2000)/100) local m=math.floor(math.min(lp,maxlp)/100)
local t={} local t={}
for i=1,m do for i=1,m do
t[i]=i*100 t[i]=i*100
...@@ -30,13 +44,8 @@ function c9910223.cost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -30,13 +44,8 @@ function c9910223.cost(e,tp,eg,ep,ev,re,r,rp,chk)
local ac=Duel.AnnounceNumber(tp,table.unpack(t)) local ac=Duel.AnnounceNumber(tp,table.unpack(t))
Duel.PayLPCost(tp,ac) Duel.PayLPCost(tp,ac)
e:SetLabel(ac) e:SetLabel(ac)
end
function c9910223.target(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(Card.IsFaceup,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SelectTarget(tp,Card.IsFaceup,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil) Duel.SelectTarget(tp,Card.IsFaceup,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
if Duel.GetCurrentChain()>2 then Duel.SetChainLimit(c9910223.chainlm) end
end end
function c9910223.chainlm(e,rp,tp) function c9910223.chainlm(e,rp,tp)
return tp==rp return tp==rp
...@@ -57,10 +66,8 @@ function c9910223.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -57,10 +66,8 @@ function c9910223.activate(e,tp,eg,ep,ev,re,r,rp)
tc:RegisterEffect(e1) tc:RegisterEffect(e1)
local atkb=tc:GetBaseAttack() local atkb=tc:GetBaseAttack()
local atkn=tc:GetAttack() local atkn=tc:GetAttack()
if atkb>0 and math.fmod(atkn,atkb)==0 then if atkn==0 or (atkb>0 and math.fmod(atkn,atkb)==0) then
Duel.BreakEffect() Duel.BreakEffect()
if Duel.Destroy(tc,REASON_EFFECT)~=0 then Duel.Destroy(tc,REASON_EFFECT,LOCATION_REMOVED)
Duel.Damage(1-tp,atkb,REASON_EFFECT)
end
end end
end end
...@@ -38,7 +38,7 @@ function c9910436.atkop(e,tp,eg,ep,ev,re,r,rp) ...@@ -38,7 +38,7 @@ function c9910436.atkop(e,tp,eg,ep,ev,re,r,rp)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK) e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE+RESET_PHASE+PHASE_END) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE+RESET_PHASE+PHASE_END)
e1:SetValue(cg:GetCount()*1500) e1:SetValue(cg:GetCount()*1200)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
......
...@@ -727,3 +727,4 @@ ...@@ -727,3 +727,4 @@
!setname 0x930 舰队装姬 Kantai Collection !setname 0x930 舰队装姬 Kantai Collection
!setname 0x940 深瞳明星 EyeDrops !setname 0x940 深瞳明星 EyeDrops
!setname 0x941 折纸 !setname 0x941 折纸
!setname 0xa991 构造
\ 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