Commit 6fdb5a10 authored by Huangnan's avatar Huangnan

fix

parent 075c5d12
Pipeline #41729 failed with stages
in 112 minutes and 58 seconds
No preview for this file type
--妮蒂亚 --妮蒂亚
local s,id,o=GetID() local s,id,o=GetID()
function s.initial_effect(c) function s.initial_effect(c)
local e1=Effect.CreateEffect(c) local e0=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE) e0:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN) e0:SetCode(EVENT_FREE_CHAIN)
e1:SetTarget(s.target) e0:SetHintTiming(0,TIMINGS_CHECK_MONSTER)
e1:SetOperation(s.operation) e0:SetRange(LOCATION_HAND)
e1:SetLabel(id) e0:SetCountLimit(1,id)
c:RegisterEffect(e1) e0:SetCost(s.cost)
e0:SetOperation(s.operation)
c:RegisterEffect(e0)
end end
function s.target(e,tp,eg,ep,ev,re,r,rp,chk) function s.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetFlagEffect(tp,id)==0 end if chk==0 then return e:GetHandler():IsDiscardable() end
Duel.SendtoGrave(e:GetHandler(),REASON_COST+REASON_DISCARD)
end end
function s.operation(e,tp,eg,ep,ev,re,r,rp) function s.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
...@@ -45,18 +48,18 @@ function s.costop(e,tp,eg,ep,ev,re,r,rp) ...@@ -45,18 +48,18 @@ function s.costop(e,tp,eg,ep,ev,re,r,rp)
Duel.MoveToField(c,tp,tp,LOCATION_SZONE,POS_FACEUP,false) Duel.MoveToField(c,tp,tp,LOCATION_SZONE,POS_FACEUP,false)
c:CreateEffectRelation(te) c:CreateEffectRelation(te)
local ev0=Duel.GetCurrentChain()+1 local ev0=Duel.GetCurrentChain()+1
local e1=Effect.CreateEffect(c) local e0=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e0:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE) e0:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetCode(EVENT_CHAIN_SOLVING) e0:SetCode(EVENT_CHAIN_SOLVING)
e1:SetCountLimit(1) e0:SetCountLimit(1)
e1:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return ev==ev0 end) e0:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return ev==ev0 end)
e1:SetOperation(s.rsop) e0:SetOperation(s.rsop)
e1:SetReset(RESET_CHAIN) e0:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e0,tp)
local e1=e0:Clone()
e1:SetCode(EVENT_CHAIN_NEGATED)
Duel.RegisterEffect(e1,tp) Duel.RegisterEffect(e1,tp)
local e2=e1:Clone()
e2:SetCode(EVENT_CHAIN_NEGATED)
Duel.RegisterEffect(e2,tp)
end end
function s.rsop(e,tp,eg,ep,ev,re,r,rp) function s.rsop(e,tp,eg,ep,ev,re,r,rp)
local rc=re:GetHandler() local rc=re:GetHandler()
...@@ -77,11 +80,11 @@ function s.op(e,tp,eg,ep,ev,re,r,rp) ...@@ -77,11 +80,11 @@ function s.op(e,tp,eg,ep,ev,re,r,rp)
tc:RegisterFlagEffect(id,RESET_PHASE+PHASE_END,0,1) tc:RegisterFlagEffect(id,RESET_PHASE+PHASE_END,0,1)
local le={tc:GetActivateEffect()} local le={tc:GetActivateEffect()}
for _,te in pairs(le) do for _,te in pairs(le) do
local e1=te:Clone() local e0=te:Clone()
e1:SetDescription(aux.Stringid(id,0)) e0:SetDescription(aux.Stringid(id,0))
e1:SetRange(LOCATION_DECK) e0:SetRange(LOCATION_DECK)
e1:SetReset(RESET_PHASE+PHASE_END) e0:SetReset(RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1) tc:RegisterEffect(e0)
end end
end end
end end
\ No newline at end of file
...@@ -70,11 +70,12 @@ function c16317010.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -70,11 +70,12 @@ function c16317010.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel.SetOperationInfo(0,CATEGORY_POSITION,g,1,0,0) Duel.SetOperationInfo(0,CATEGORY_POSITION,g,1,0,0)
end end
function c16317010.activate(e,tp,eg,ep,ev,re,r,rp) function c16317010.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:IsLocation(LOCATION_MZONE) if tc:IsRelateToEffect(e) and tc:IsLocation(LOCATION_MZONE)
and not c:IsPosition(POS_FACEUP_DEFENSE) then and not c:IsPosition(POS_FACEUP_DEFENSE) then
if Duel.ChangePosition(tc,POS_FACEUP_DEFENSE)>0 then if Duel.ChangePosition(tc,POS_FACEUP_DEFENSE)>0 then
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_MZONE)
......
--光之战士 维克特利 --光之战士 维克特利
function c16400310.initial_effect(c) function c16400310.initial_effect(c)
--spirit return
aux.EnableSpiritReturn(c,EVENT_SPSUMMON_SUCCESS)
--xyz summon --xyz summon
aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xce9),4,2) aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xce9),4,2)
c:EnableReviveLimit() c:EnableReviveLimit()
...@@ -17,30 +19,6 @@ function c16400310.initial_effect(c) ...@@ -17,30 +19,6 @@ function c16400310.initial_effect(c)
e1:SetTarget(c16400310.destg) e1:SetTarget(c16400310.destg)
e1:SetOperation(c16400310.desop) e1:SetOperation(c16400310.desop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--return
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(16400310,1))
e2:SetCategory(CATEGORY_TOEXTRA)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetCondition(c16400310.retcon)
e2:SetTarget(c16400310.rettg)
e2:SetOperation(c16400310.retop)
c:RegisterEffect(e2)
end
function c16400310.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsStatus(STATUS_SPSUMMON_TURN)
end
function c16400310.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,e:GetHandler(),1,0,0)
end
function c16400310.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
Duel.SendtoDeck(c,nil,2,REASON_EFFECT)
end
end end
function c16400310.descost(e,tp,eg,ep,ev,re,r,rp,chk) function c16400310.descost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end
...@@ -54,7 +32,7 @@ function c16400310.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -54,7 +32,7 @@ function c16400310.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return false end if chkc then return false end
if chk==0 then return Duel.IsExistingTarget(c16400310.desfilter,tp,0x4,0,1,nil,e,tp) end if chk==0 then return Duel.IsExistingTarget(c16400310.desfilter,tp,0x4,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g1=Duel.SelectTarget(tp,c16400310.desfilter,tp,0x4,0,1,1,nil) local g1=Duel.SelectTarget(tp,c16400310.desfilter,tp,0x4,0,1,1,nil,e,tp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g2=Duel.SelectTarget(tp,nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,g1) local g2=Duel.SelectTarget(tp,nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,g1)
g1:Merge(g2) g1:Merge(g2)
......
--光之战士 银河 --光之战士 银河
function c16400315.initial_effect(c) function c16400315.initial_effect(c)
--spirit return
aux.EnableSpiritReturn(c,EVENT_SPSUMMON_SUCCESS)
--xyz summon --xyz summon
aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xce9),4,2) aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xce9),4,2)
c:EnableReviveLimit() c:EnableReviveLimit()
...@@ -17,30 +19,6 @@ function c16400315.initial_effect(c) ...@@ -17,30 +19,6 @@ function c16400315.initial_effect(c)
e1:SetTarget(c16400315.thtg) e1:SetTarget(c16400315.thtg)
e1:SetOperation(c16400315.thop) e1:SetOperation(c16400315.thop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--return
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(16400315,1))
e2:SetCategory(CATEGORY_TOEXTRA)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetCondition(c16400315.retcon)
e2:SetTarget(c16400315.rettg)
e2:SetOperation(c16400315.retop)
c:RegisterEffect(e2)
end
function c16400315.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsStatus(STATUS_SPSUMMON_TURN)
end
function c16400315.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,e:GetHandler(),1,0,0)
end
function c16400315.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
Duel.SendtoDeck(c,nil,2,REASON_EFFECT)
end
end end
function c16400315.thcost(e,tp,eg,ep,ev,re,r,rp,chk) function c16400315.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end
......
--光之战士 艾克斯 --光之战士 艾克斯
function c16400320.initial_effect(c) function c16400320.initial_effect(c)
--spirit return
aux.EnableSpiritReturn(c,EVENT_SPSUMMON_SUCCESS)
--xyz summon --xyz summon
aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xce9),4,2) aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xce9),4,2)
c:EnableReviveLimit() c:EnableReviveLimit()
...@@ -17,30 +19,6 @@ function c16400320.initial_effect(c) ...@@ -17,30 +19,6 @@ function c16400320.initial_effect(c)
e1:SetTarget(c16400320.rmtg) e1:SetTarget(c16400320.rmtg)
e1:SetOperation(c16400320.rmop) e1:SetOperation(c16400320.rmop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--return
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(16400320,1))
e2:SetCategory(CATEGORY_TOEXTRA)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetCondition(c16400320.retcon)
e2:SetTarget(c16400320.rettg)
e2:SetOperation(c16400320.retop)
c:RegisterEffect(e2)
end
function c16400320.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsStatus(STATUS_SPSUMMON_TURN)
end
function c16400320.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,e:GetHandler(),1,0,0)
end
function c16400320.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
Duel.SendtoDeck(c,nil,2,REASON_EFFECT)
end
end end
function c16400320.rmcost(e,tp,eg,ep,ev,re,r,rp,chk) function c16400320.rmcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end
......
--光之战士 奈克赛斯 --光之战士 奈克赛斯
function c16400325.initial_effect(c) function c16400325.initial_effect(c)
--spirit return
aux.EnableSpiritReturn(c,EVENT_SPSUMMON_SUCCESS)
--xyz summon --xyz summon
aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xce9),4,2) aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xce9),4,2)
c:EnableReviveLimit() c:EnableReviveLimit()
...@@ -16,30 +18,6 @@ function c16400325.initial_effect(c) ...@@ -16,30 +18,6 @@ function c16400325.initial_effect(c)
e1:SetTarget(c16400325.thtg) e1:SetTarget(c16400325.thtg)
e1:SetOperation(c16400325.thop) e1:SetOperation(c16400325.thop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--return
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(16400325,1))
e2:SetCategory(CATEGORY_TOEXTRA)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetCondition(c16400325.retcon)
e2:SetTarget(c16400325.rettg)
e2:SetOperation(c16400325.retop)
c:RegisterEffect(e2)
end
function c16400325.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsStatus(STATUS_SPSUMMON_TURN)
end
function c16400325.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,e:GetHandler(),1,0,0)
end
function c16400325.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
Duel.SendtoDeck(c,nil,2,REASON_EFFECT)
end
end end
function c16400325.thcost(e,tp,eg,ep,ev,re,r,rp,chk) function c16400325.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end
......
--光之战士 迪迦 --光之战士 迪迦
local s,id=GetID() local s,id=GetID()
function s.initial_effect(c) function s.initial_effect(c)
-- ①:墓地特殊召唤「光之战士」怪兽 --spirit return
local e1=Effect.CreateEffect(c) aux.EnableSpiritReturn(c,EVENT_SUMMON_SUCCESS,EVENT_SPSUMMON_SUCCESS)
e1:SetDescription(aux.Stringid(id,0)) --
e1:SetType(EFFECT_TYPE_QUICK_O) local e1=Effect.CreateEffect(c)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetDescription(aux.Stringid(id,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_MZONE) e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetCountLimit(1,id) e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetTarget(s.sptg) e1:SetRange(LOCATION_MZONE)
e1:SetOperation(s.spop) e1:SetCountLimit(1,id)
c:RegisterEffect(e1) e1:SetTarget(s.sptg)
e1:SetOperation(s.spop)
local e3=Effect.CreateEffect(c) c:RegisterEffect(e1)
e3:SetDescription(aux.Stringid(id,1)) --
e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_IGNITION) e3:SetDescription(aux.Stringid(id,1))
e3:SetRange(LOCATION_HAND) e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e3:SetCountLimit(1,id+1) e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetCost(s.thcost) e3:SetRange(LOCATION_HAND)
e3:SetTarget(s.thtg) e3:SetCountLimit(1,id+1)
e3:SetOperation(s.thop) e3:SetCost(s.thcost)
c:RegisterEffect(e3) e3:SetTarget(s.thtg)
e3:SetOperation(s.thop)
local e4=Effect.CreateEffect(c) c:RegisterEffect(e3)
e4:SetDescription(aux.Stringid(id,2))
e4:SetCategory(CATEGORY_TOHAND)
e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e4:SetCode(EVENT_PHASE+PHASE_END)
e4:SetRange(LOCATION_MZONE)
e4:SetCondition(s.retcon)
e4:SetTarget(s.rettg)
e4:SetOperation(s.retop)
c:RegisterEffect(e4)
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e5:SetCode(EVENT_SUMMON_SUCCESS)
e5:SetOperation(s.regop)
c:RegisterEffect(e5)
local e6=e5:Clone()
e6:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e6)
end end
function s.spfilter(c,e,tp) function s.spfilter(c,e,tp)
return c:IsSetCard(0xce9) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsSetCard(0xce9) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.spfilter(chkc,e,tp) end if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.spfilter(chkc,e,tp) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingTarget(s.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end and Duel.IsExistingTarget(s.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,s.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) local g=Duel.SelectTarget(tp,s.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end end
function s.spop(e,tp,eg,ep,ev,re,r,rp) function s.spop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc and tc:IsRelateToEffect(e) then if tc and tc:IsRelateToEffect(e) then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
end end
end end
function s.thcost(e,tp,eg,ep,ev,re,r,rp,chk) function s.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return c:IsDiscardable() if chk==0 then return c:IsDiscardable()
and Duel.IsExistingMatchingCard(s.thfilter2,tp,LOCATION_HAND,0,1,c) end and Duel.IsExistingMatchingCard(s.thfilter2,tp,LOCATION_HAND,0,1,c) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD)
local g=Duel.SelectMatchingCard(tp,s.thfilter2,tp,LOCATION_HAND,0,1,1,c) local g=Duel.SelectMatchingCard(tp,s.thfilter2,tp,LOCATION_HAND,0,1,1,c)
g:AddCard(c) g:AddCard(c)
Duel.SendtoGrave(g,REASON_COST+REASON_DISCARD) Duel.SendtoGrave(g,REASON_COST+REASON_DISCARD)
end end
function s.thfilter2(c) function s.thfilter2(c)
return c:IsType(TYPE_MONSTER) and c:IsDiscardable() return c:IsType(TYPE_MONSTER) and c:IsDiscardable()
end end
function s.thfilter(c) function s.thfilter(c)
return c:IsSetCard(0xce9) and c:IsType(TYPE_MONSTER) and c:IsAbleToHand() return c:IsSetCard(0xce9) and c:IsType(TYPE_MONSTER) and c:IsAbleToHand()
end end
function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,2,nil) end if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,2,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,2,tp,LOCATION_DECK) Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,2,tp,LOCATION_DECK)
end end
function s.thop(e,tp,eg,ep,ev,re,r,rp) function s.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,2,2,nil) local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,2,2,nil)
if #g==2 then if #g==2 then
Duel.SendtoHand(g,nil,REASON_EFFECT) Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g) Duel.ConfirmCards(1-tp,g)
end end
end
function s.regop(e,tp,eg,ep,ev,re,r,rp)
e:GetHandler():RegisterFlagEffect(id+2,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,0,1)
end
function s.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetFlagEffect(id+2)>0
end
function s.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,e:GetHandler(),1,0,0)
end
function s.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
Duel.SendtoHand(c,nil,REASON_EFFECT)
end
end end
\ No newline at end of file
local s,id=GetID() local s,id=GetID()
function s.initial_effect(c) function s.initial_effect(c)
--spirit return
local e1=Effect.CreateEffect(c) aux.EnableSpiritReturn(c,EVENT_SUMMON_SUCCESS,EVENT_SPSUMMON_SUCCESS)
e1:SetDescription(aux.Stringid(id,0)) --
e1:SetCategory(CATEGORY_TOHAND) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_QUICK_O) e1:SetDescription(aux.Stringid(id,0))
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCategory(CATEGORY_TOHAND)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET) e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetRange(LOCATION_MZONE) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,id) e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetTarget(s.thtg1) e1:SetRange(LOCATION_MZONE)
e1:SetOperation(s.thop1) e1:SetCountLimit(1,id)
c:RegisterEffect(e1) e1:SetTarget(s.thtg1)
e1:SetOperation(s.thop1)
local e3=Effect.CreateEffect(c) c:RegisterEffect(e1)
e3:SetDescription(aux.Stringid(id,1)) --
e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_IGNITION) e3:SetDescription(aux.Stringid(id,1))
e3:SetRange(LOCATION_HAND) e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e3:SetCountLimit(1,id+1) e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetCost(s.thcost2) e3:SetRange(LOCATION_HAND)
e3:SetTarget(s.thtg2) e3:SetCountLimit(1,id+1)
e3:SetOperation(s.thop2) e3:SetCost(s.thcost2)
c:RegisterEffect(e3) e3:SetTarget(s.thtg2)
e3:SetOperation(s.thop2)
local e4=Effect.CreateEffect(c) c:RegisterEffect(e3)
e4:SetDescription(aux.Stringid(id,2))
e4:SetCategory(CATEGORY_TOHAND)
e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e4:SetCode(EVENT_PHASE+PHASE_END)
e4:SetRange(LOCATION_MZONE)
e4:SetCondition(s.retcon)
e4:SetTarget(s.rettg)
e4:SetOperation(s.retop)
c:RegisterEffect(e4)
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e5:SetCode(EVENT_SUMMON_SUCCESS)
e5:SetOperation(s.regop)
c:RegisterEffect(e5)
local e6=e5:Clone()
e6:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e6)
end end
function s.thfilter1(c) function s.thfilter1(c)
return c:IsSetCard(0xce9) and c:IsType(TYPE_SPELL) and c:IsAbleToHand() return c:IsSetCard(0xce9) and c:IsType(TYPE_SPELL) and c:IsAbleToHand()
end end
function s.thtg1(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function s.thtg1(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.thfilter1(chkc) end if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.thfilter1(chkc) end
if chk==0 then return Duel.IsExistingTarget(s.thfilter1,tp,LOCATION_GRAVE,0,1,nil) end if chk==0 then return Duel.IsExistingTarget(s.thfilter1,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectTarget(tp,s.thfilter1,tp,LOCATION_GRAVE,0,1,1,nil) local g=Duel.SelectTarget(tp,s.thfilter1,tp,LOCATION_GRAVE,0,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0) Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end end
function s.thop1(e,tp,eg,ep,ev,re,r,rp) function s.thop1(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc and tc:IsRelateToEffect(e) then if tc and tc:IsRelateToEffect(e) then
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc) Duel.ConfirmCards(1-tp,tc)
end end
end end
-- ②:费用(丢弃自己+1张魔法卡)
function s.thcost2(e,tp,eg,ep,ev,re,r,rp,chk) function s.thcost2(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return c:IsDiscardable() if chk==0 then return c:IsDiscardable()
and Duel.IsExistingMatchingCard(s.thfilter3,tp,LOCATION_HAND,0,1,c) end and Duel.IsExistingMatchingCard(s.thfilter3,tp,LOCATION_HAND,0,1,c) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD)
local g=Duel.SelectMatchingCard(tp,s.thfilter3,tp,LOCATION_HAND,0,1,1,c) local g=Duel.SelectMatchingCard(tp,s.thfilter3,tp,LOCATION_HAND,0,1,1,c)
g:AddCard(c) g:AddCard(c)
Duel.SendtoGrave(g,REASON_COST+REASON_DISCARD) Duel.SendtoGrave(g,REASON_COST+REASON_DISCARD)
end end
function s.thfilter3(c) function s.thfilter3(c)
return c:IsType(TYPE_SPELL) and c:IsDiscardable() return c:IsType(TYPE_SPELL) and c:IsDiscardable()
end end
function s.thfilter2(c) function s.thfilter2(c)
return c:IsSetCard(0xce9) and c:IsType(TYPE_SPELL) and c:IsAbleToHand() return c:IsSetCard(0xce9) and c:IsType(TYPE_SPELL) and c:IsAbleToHand()
end end
function s.thtg2(e,tp,eg,ep,ev,re,r,rp,chk) function s.thtg2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter2,tp,LOCATION_DECK,0,2,nil) end if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter2,tp,LOCATION_DECK,0,2,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,2,tp,LOCATION_DECK) Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,2,tp,LOCATION_DECK)
end end
function s.thop2(e,tp,eg,ep,ev,re,r,rp) function s.thop2(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,s.thfilter2,tp,LOCATION_DECK,0,2,2,nil) local g=Duel.SelectMatchingCard(tp,s.thfilter2,tp,LOCATION_DECK,0,2,2,nil)
if #g==2 then if #g==2 then
Duel.SendtoHand(g,nil,REASON_EFFECT) Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g) Duel.ConfirmCards(1-tp,g)
end end
end
function s.regop(e,tp,eg,ep,ev,re,r,rp)
e:GetHandler():RegisterFlagEffect(id+2,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,0,1)
end
function s.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetFlagEffect(id+2)>0
end
function s.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,e:GetHandler(),1,0,0)
end
function s.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
Duel.SendtoHand(c,nil,REASON_EFFECT)
end
end end
\ No newline at end of file
--光之战士 盖亚 --光之战士 盖亚
local s,id=GetID() local s,id=GetID()
function s.initial_effect(c) function s.initial_effect(c)
--spirit return
local e1=Effect.CreateEffect(c) aux.EnableSpiritReturn(c,EVENT_SUMMON_SUCCESS,EVENT_SPSUMMON_SUCCESS)
e1:SetDescription(aux.Stringid(id,0)) --
e1:SetType(EFFECT_TYPE_QUICK_O) local e1=Effect.CreateEffect(c)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetDescription(aux.Stringid(id,0))
e1:SetProperty(EFFECT_FLAG_CARD_TARGET) e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetRange(LOCATION_MZONE) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,id) e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER_E) e1:SetRange(LOCATION_MZONE)
e1:SetTarget(s.settg) e1:SetCountLimit(1,id)
e1:SetOperation(s.setop) e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER_E)
c:RegisterEffect(e1) e1:SetTarget(s.settg)
e1:SetOperation(s.setop)
local e2=Effect.CreateEffect(c) c:RegisterEffect(e1)
e2:SetDescription(aux.Stringid(id,1)) --
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_IGNITION) e2:SetDescription(aux.Stringid(id,1))
e2:SetRange(LOCATION_HAND) e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e2:SetCountLimit(1,id+1) e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetCost(s.thcost) e2:SetRange(LOCATION_HAND)
e2:SetTarget(s.thtg) e2:SetCountLimit(1,id+1)
e2:SetOperation(s.thop) e2:SetCost(s.thcost)
c:RegisterEffect(e2) e2:SetTarget(s.thtg)
e2:SetOperation(s.thop)
local e3=Effect.CreateEffect(c) c:RegisterEffect(e2)
e3:SetDescription(aux.Stringid(id,2))
e3:SetCategory(CATEGORY_TOHAND)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e3:SetCode(EVENT_PHASE+PHASE_END)
e3:SetRange(LOCATION_MZONE)
e3:SetCondition(s.retcon)
e3:SetTarget(s.rettg)
e3:SetOperation(s.retop)
c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e4:SetCode(EVENT_SUMMON_SUCCESS)
e4:SetOperation(s.regop)
c:RegisterEffect(e4)
local e5=e4:Clone()
e5:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e5)
end end
function s.setfilter(c) function s.setfilter(c)
return c:IsSetCard(0xce9) and c:IsType(TYPE_TRAP) and c:IsSSetable() return c:IsSetCard(0xce9) and c:IsType(TYPE_TRAP) and c:IsSSetable()
end end
function s.settg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function s.settg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.setfilter(chkc) end if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.setfilter(chkc) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0
and Duel.IsExistingTarget(s.setfilter,tp,LOCATION_GRAVE,0,1,nil) end and Duel.IsExistingTarget(s.setfilter,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET)
local g=Duel.SelectTarget(tp,s.setfilter,tp,LOCATION_GRAVE,0,1,1,nil) local g=Duel.SelectTarget(tp,s.setfilter,tp,LOCATION_GRAVE,0,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,g,1,0,0) Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,g,1,0,0)
end end
function s.setop(e,tp,eg,ep,ev,re,r,rp) function s.setop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc and tc:IsRelateToEffect(e) and Duel.GetLocationCount(tp,LOCATION_SZONE)>0 then if tc and tc:IsRelateToEffect(e) and Duel.GetLocationCount(tp,LOCATION_SZONE)>0 then
Duel.SSet(tp,tc) Duel.SSet(tp,tc)
end end
end end
function s.thcost(e,tp,eg,ep,ev,re,r,rp,chk) function s.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return c:IsDiscardable() if chk==0 then return c:IsDiscardable()
and Duel.IsExistingMatchingCard(Card.IsType,tp,LOCATION_HAND,0,1,c,TYPE_TRAP) end and Duel.IsExistingMatchingCard(Card.IsType,tp,LOCATION_HAND,0,1,c,TYPE_TRAP) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD)
local g=Duel.SelectMatchingCard(tp,Card.IsType,tp,LOCATION_HAND,0,1,1,c,TYPE_TRAP) local g=Duel.SelectMatchingCard(tp,Card.IsType,tp,LOCATION_HAND,0,1,1,c,TYPE_TRAP)
g:AddCard(c) g:AddCard(c)
Duel.SendtoGrave(g,REASON_COST+REASON_DISCARD) Duel.SendtoGrave(g,REASON_COST+REASON_DISCARD)
end end
function s.thfilter(c) function s.thfilter(c)
return c:IsSetCard(0xce9) and c:IsType(TYPE_TRAP) and c:IsAbleToHand() return c:IsSetCard(0xce9) and c:IsType(TYPE_TRAP) and c:IsAbleToHand()
end end
function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,2,nil) end if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,2,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,2,tp,LOCATION_DECK) Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,2,tp,LOCATION_DECK)
end end
function s.thop(e,tp,eg,ep,ev,re,r,rp) function s.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,2,2,nil) local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,2,2,nil)
if #g==2 then if #g==2 then
Duel.SendtoHand(g,nil,REASON_EFFECT) Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g) Duel.ConfirmCards(1-tp,g)
end end
end
function s.regop(e,tp,eg,ep,ev,re,r,rp)
e:GetHandler():RegisterFlagEffect(id+2,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,0,1)
end
function s.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetFlagEffect(id+2)>0
end
function s.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,e:GetHandler(),1,0,0)
end
function s.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
Duel.SendtoHand(c,nil,REASON_EFFECT)
end
end end
\ No newline at end of file
--光之战士 罗索 烈火 --光之战士 罗索 烈火
function c16400385.initial_effect(c) function c16400385.initial_effect(c)
--xyz summon --spirit return
aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xce9),4,2) aux.EnableSpiritReturn(c,EVENT_SPSUMMON_SUCCESS)
--link summon
c:EnableReviveLimit() c:EnableReviveLimit()
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkSetCard,0xce9),2,2)
--Destroy --Destroy
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(16400385,0)) e1:SetDescription(aux.Stringid(16400385,0))
...@@ -17,30 +19,6 @@ function c16400385.initial_effect(c) ...@@ -17,30 +19,6 @@ function c16400385.initial_effect(c)
e1:SetTarget(c16400385.sptg) e1:SetTarget(c16400385.sptg)
e1:SetOperation(c16400385.spop) e1:SetOperation(c16400385.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--return
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(16400385,1))
e2:SetCategory(CATEGORY_TOEXTRA)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetCondition(c16400385.retcon)
e2:SetTarget(c16400385.rettg)
e2:SetOperation(c16400385.retop)
c:RegisterEffect(e2)
end
function c16400385.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsStatus(STATUS_SPSUMMON_TURN)
end
function c16400385.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,e:GetHandler(),1,0,0)
end
function c16400385.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
Duel.SendtoDeck(c,nil,2,REASON_EFFECT)
end
end end
function c16400385.spcon(e,tp,eg,ep,ev,re,r,rp) function c16400385.spcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsMainPhase() return Duel.IsMainPhase()
......
--光之战士 赛迦 --光之战士 赛迦
function c16400400.initial_effect(c) function c16400400.initial_effect(c)
--spirit return
aux.EnableSpiritReturn(c,EVENT_SPSUMMON_SUCCESS)
--fusion material --fusion material
c:EnableReviveLimit() c:EnableReviveLimit()
aux.AddFusionProcCode3(c,16400245,16400280,16400345,true,true) aux.AddFusionProcCode3(c,16400245,16400280,16400345,true,true)
...@@ -16,27 +18,6 @@ function c16400400.initial_effect(c) ...@@ -16,27 +18,6 @@ function c16400400.initial_effect(c)
e1:SetTarget(c16400400.destg) e1:SetTarget(c16400400.destg)
e1:SetOperation(c16400400.desop) e1:SetOperation(c16400400.desop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--return
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_TOEXTRA)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetCountLimit(1)
e2:SetCondition(c16400400.retcon)
e2:SetTarget(c16400400.rettg)
e2:SetOperation(c16400400.retop)
c:RegisterEffect(e2)
if not c16400400.global_check then
c16400400.global_check=true
local ge1=Effect.CreateEffect(c)
ge1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge1:SetCode(EVENT_SPSUMMON_SUCCESS)
ge1:SetLabel(16400400)
ge1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
ge1:SetOperation(aux.sumreg)
Duel.RegisterEffect(ge1,0)
end
end end
function c16400400.costfilter(c) function c16400400.costfilter(c)
return c:IsSetCard(0xce9) and c:IsAbleToRemoveAsCost() return c:IsSetCard(0xce9) and c:IsAbleToRemoveAsCost()
...@@ -68,17 +49,4 @@ function c16400400.desop(e,tp,eg,ep,ev,re,r,rp) ...@@ -68,17 +49,4 @@ function c16400400.desop(e,tp,eg,ep,ev,re,r,rp)
Duel.SendtoHand(sg,nil,0x40) Duel.SendtoHand(sg,nil,0x40)
end end
end end
end
function c16400400.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetFlagEffect(16400400)~=0
end
function c16400400.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,e:GetHandler(),1,0,0)
end
function c16400400.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) then
Duel.SendtoDeck(c,nil,0,REASON_EFFECT)
end
end end
\ No newline at end of file
--光之战士 雷杰多 --光之战士 雷杰多
function c16400405.initial_effect(c) function c16400405.initial_effect(c)
--spirit return
aux.EnableSpiritReturn(c,EVENT_SPSUMMON_SUCCESS)
--fusion material --fusion material
c:EnableReviveLimit() c:EnableReviveLimit()
aux.AddFusionProcCode2(c,16400245,16400395,true,true) aux.AddFusionProcCode2(c,16400245,16400395,true,true)
...@@ -16,27 +18,6 @@ function c16400405.initial_effect(c) ...@@ -16,27 +18,6 @@ function c16400405.initial_effect(c)
e1:SetTarget(c16400405.thtg) e1:SetTarget(c16400405.thtg)
e1:SetOperation(c16400405.thop) e1:SetOperation(c16400405.thop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--return
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_TOEXTRA)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetCountLimit(1)
e2:SetCondition(c16400405.retcon)
e2:SetTarget(c16400405.rettg)
e2:SetOperation(c16400405.retop)
c:RegisterEffect(e2)
if not c16400405.global_check then
c16400405.global_check=true
local ge1=Effect.CreateEffect(c)
ge1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge1:SetCode(EVENT_SPSUMMON_SUCCESS)
ge1:SetLabel(16400405)
ge1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
ge1:SetOperation(aux.sumreg)
Duel.RegisterEffect(ge1,0)
end
end end
function c16400405.costfilter(c) function c16400405.costfilter(c)
return c:IsSetCard(0xce9) and c:IsAbleToRemoveAsCost() return c:IsSetCard(0xce9) and c:IsAbleToRemoveAsCost()
...@@ -54,7 +35,7 @@ function c16400405.thtg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -54,7 +35,7 @@ function c16400405.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
local ct=Duel.GetFieldGroupCount(tp,0,LOCATION_MZONE) local ct=Duel.GetFieldGroupCount(tp,0,LOCATION_MZONE)
local g=Duel.GetMatchingGroup(c16400405.thfilter,tp,LOCATION_DECK,0,nil) local g=Duel.GetMatchingGroup(c16400405.thfilter,tp,LOCATION_DECK,0,nil)
if chk==0 then return c:IsRelateToEffect(e) and ct>0 and g:GetClassCount(Card.GetCode)>=ct end if chk==0 then return ct>0 and g:GetClassCount(Card.GetCode)>=ct end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,ct,tp,LOCATION_DECK) Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,ct,tp,LOCATION_DECK)
end end
function c16400405.thop(e,tp,eg,ep,ev,re,r,rp) function c16400405.thop(e,tp,eg,ep,ev,re,r,rp)
...@@ -66,17 +47,4 @@ function c16400405.thop(e,tp,eg,ep,ev,re,r,rp) ...@@ -66,17 +47,4 @@ function c16400405.thop(e,tp,eg,ep,ev,re,r,rp)
local hg=g:SelectSubGroup(tp,aux.dncheck,false,ct,ct) local hg=g:SelectSubGroup(tp,aux.dncheck,false,ct,ct)
Duel.SendtoHand(hg,nil,REASON_EFFECT) Duel.SendtoHand(hg,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,hg) Duel.ConfirmCards(1-tp,hg)
end
function c16400405.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetFlagEffect(16400405)~=0
end
function c16400405.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,e:GetHandler(),1,0,0)
end
function c16400405.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) then
Duel.SendtoDeck(c,nil,0,REASON_EFFECT)
end
end end
\ No newline at end of file
--光之战士 艾克斯 超越 --光之战士 艾克斯 超越
function c16400410.initial_effect(c) function c16400410.initial_effect(c)
--spirit return
aux.EnableSpiritReturn(c,EVENT_SPSUMMON_SUCCESS)
--xyz summon --xyz summon
c:EnableReviveLimit() c:EnableReviveLimit()
aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xce9),10,2,c16400410.ovfilter,aux.Stringid(16400410,0)) aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0xce9),10,2,c16400410.ovfilter,aux.Stringid(16400410,0))
...@@ -17,30 +19,6 @@ function c16400410.initial_effect(c) ...@@ -17,30 +19,6 @@ function c16400410.initial_effect(c)
e1:SetTarget(c16400410.rmtg) e1:SetTarget(c16400410.rmtg)
e1:SetOperation(c16400410.rmop) e1:SetOperation(c16400410.rmop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--return
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(16400410,2))
e2:SetCategory(CATEGORY_TOEXTRA)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetCondition(c16400410.retcon)
e2:SetTarget(c16400410.rettg)
e2:SetOperation(c16400410.retop)
c:RegisterEffect(e2)
end
function c16400410.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsStatus(STATUS_SPSUMMON_TURN)
end
function c16400410.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,e:GetHandler(),1,0,0)
end
function c16400410.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
Duel.SendtoDeck(c,nil,2,REASON_EFFECT)
end
end end
function c16400410.ovfilter(c) function c16400410.ovfilter(c)
return c:IsFaceup() and c:IsCode(16400410) return c:IsFaceup() and c:IsCode(16400410)
......
--光之战士 格丽乔 --光之战士 格丽乔
function c16400415.initial_effect(c) function c16400415.initial_effect(c)
--spirit return
aux.EnableSpiritReturn(c,EVENT_SPSUMMON_SUCCESS)
c:EnableReviveLimit() c:EnableReviveLimit()
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkSetCard,0xce9),2) aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkSetCard,0xce9),2)
--SpecialSummon --SpecialSummon
...@@ -16,30 +18,6 @@ function c16400415.initial_effect(c) ...@@ -16,30 +18,6 @@ function c16400415.initial_effect(c)
e1:SetTarget(c16400415.sptg) e1:SetTarget(c16400415.sptg)
e1:SetOperation(c16400415.spop) e1:SetOperation(c16400415.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--return
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(16400415,1))
e2:SetCategory(CATEGORY_TOEXTRA)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetCondition(c16400415.retcon)
e2:SetTarget(c16400415.rettg)
e2:SetOperation(c16400415.retop)
c:RegisterEffect(e2)
end
function c16400415.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsStatus(STATUS_SPSUMMON_TURN)
end
function c16400415.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,e:GetHandler(),1,0,0)
end
function c16400415.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
Duel.SendtoDeck(c,nil,2,REASON_EFFECT)
end
end end
function c16400415.spcon(e,tp,eg,ep,ev,re,r,rp) function c16400415.spcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsMainPhase() return Duel.IsMainPhase()
......
--光之战士 布莱泽 --光之战士 布莱泽
local s,id=GetID() local s,id=GetID()
function s.initial_effect(c) function s.initial_effect(c)
local e1=Effect.CreateEffect(c) --spirit return
e1:SetDescription(aux.Stringid(id,0)) aux.EnableSpiritReturn(c,EVENT_SUMMON_SUCCESS,EVENT_SPSUMMON_SUCCESS)
e1:SetCategory(CATEGORY_RECOVER) --
e1:SetType(EFFECT_TYPE_QUICK_O) local e1=Effect.CreateEffect(c)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetDescription(aux.Stringid(id,0))
e1:SetRange(LOCATION_MZONE) e1:SetCategory(CATEGORY_RECOVER)
e1:SetCountLimit(1,id) e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCost(s.reccost1) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetTarget(s.rectg1) e1:SetRange(LOCATION_MZONE)
e1:SetOperation(s.recop1) e1:SetCountLimit(1,id)
c:RegisterEffect(e1) e1:SetCost(s.reccost1)
e1:SetTarget(s.rectg1)
local e2=Effect.CreateEffect(c) e1:SetOperation(s.recop1)
e2:SetDescription(aux.Stringid(id,1)) c:RegisterEffect(e1)
e2:SetCategory(CATEGORY_RECOVER) --
e2:SetType(EFFECT_TYPE_QUICK_O) local e2=Effect.CreateEffect(c)
e2:SetCode(EVENT_BATTLE_START) e2:SetDescription(aux.Stringid(id,1))
e2:SetRange(LOCATION_GRAVE) e2:SetCategory(CATEGORY_RECOVER)
e2:SetCountLimit(1,id+1) e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCondition(s.reccon2) e2:SetCode(EVENT_BATTLE_START)
e2:SetCost(s.reccost2) e2:SetRange(LOCATION_GRAVE)
e2:SetTarget(s.rectg2) e2:SetCountLimit(1,id+1)
e2:SetOperation(s.recop2) e2:SetCondition(s.reccon2)
c:RegisterEffect(e2) e2:SetCost(s.reccost2)
e2:SetTarget(s.rectg2)
local e3=Effect.CreateEffect(c) e2:SetOperation(s.recop2)
e3:SetDescription(aux.Stringid(id,2)) c:RegisterEffect(e2)
e3:SetCategory(CATEGORY_TOHAND)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e3:SetCode(EVENT_PHASE+PHASE_END)
e3:SetRange(LOCATION_MZONE)
e3:SetCondition(s.retcon)
e3:SetTarget(s.rettg)
e3:SetOperation(s.retop)
c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e4:SetCode(EVENT_SUMMON_SUCCESS)
e4:SetOperation(s.regop)
c:RegisterEffect(e4)
local e5=e4:Clone()
e5:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e5)
end end
function s.banfilter(c) function s.banfilter(c)
return c:IsSetCard(0xce9) and c:IsType(TYPE_MONSTER) and c:IsAbleToRemoveAsCost() and c:GetBaseAttack()>=0 return c:IsSetCard(0xce9) and c:IsType(TYPE_MONSTER) and c:IsAbleToRemoveAsCost() and c:GetBaseAttack()>=0
end end
function s.reccost1(e,tp,eg,ep,ev,re,r,rp,chk) function s.reccost1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.banfilter,tp,LOCATION_GRAVE,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(s.banfilter,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,s.banfilter,tp,LOCATION_GRAVE,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,s.banfilter,tp,LOCATION_GRAVE,0,1,1,nil)
local tc=g:GetFirst() local tc=g:GetFirst()
local atk=tc:GetBaseAttack() local atk=tc:GetBaseAttack()
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.Remove(g,POS_FACEUP,REASON_COST)
e:SetLabel(atk) e:SetLabel(atk)
end end
function s.rectg1(e,tp,eg,ep,ev,re,r,rp,chk) function s.rectg1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
Duel.SetTargetPlayer(tp) Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(e:GetLabel()) Duel.SetTargetParam(e:GetLabel())
Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,0,tp,e:GetLabel()) Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,0,tp,e:GetLabel())
end end
function s.recop1(e,tp,eg,ep,ev,re,r,rp) function s.recop1(e,tp,eg,ep,ev,re,r,rp)
local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER) local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER)
local d=e:GetLabel() local d=e:GetLabel()
if d>0 then if d>0 then
Duel.Recover(p,d,REASON_EFFECT) Duel.Recover(p,d,REASON_EFFECT)
end end
end end
function s.reccon2(e,tp,eg,ep,ev,re,r,rp) function s.reccon2(e,tp,eg,ep,ev,re,r,rp)
local a=Duel.GetAttacker() local a=Duel.GetAttacker()
local d=Duel.GetAttackTarget() local d=Duel.GetAttackTarget()
if not a or not d then return false end if not a or not d then return false end
local opp_monster=nil local opp_monster=nil
if a:IsControler(1-tp) then if a:IsControler(1-tp) then
opp_monster=a opp_monster=a
elseif d:IsControler(1-tp) then elseif d:IsControler(1-tp) then
opp_monster=d opp_monster=d
end end
return opp_monster~=nil and Duel.IsExistingMatchingCard(s.fieldfilter,tp,LOCATION_MZONE,0,1,nil) return opp_monster~=nil and Duel.IsExistingMatchingCard(s.fieldfilter,tp,LOCATION_MZONE,0,1,nil)
end end
function s.fieldfilter(c) function s.fieldfilter(c)
return c:IsFaceup() and c:IsSetCard(0xce9) and c:IsType(TYPE_MONSTER) return c:IsFaceup() and c:IsSetCard(0xce9) and c:IsType(TYPE_MONSTER)
end end
function s.reccost2(e,tp,eg,ep,ev,re,r,rp,chk) function s.reccost2(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return c:IsAbleToRemoveAsCost() end if chk==0 then return c:IsAbleToRemoveAsCost() end
Duel.Remove(c,POS_FACEUP,REASON_COST) Duel.Remove(c,POS_FACEUP,REASON_COST)
end end
function s.rectg2(e,tp,eg,ep,ev,re,r,rp,chk) function s.rectg2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
local a=Duel.GetAttacker() local a=Duel.GetAttacker()
local d=Duel.GetAttackTarget() local d=Duel.GetAttackTarget()
local opp_monster=nil local opp_monster=nil
if a:IsControler(1-tp) then if a:IsControler(1-tp) then
opp_monster=a opp_monster=a
elseif d:IsControler(1-tp) then elseif d:IsControler(1-tp) then
opp_monster=d opp_monster=d
end end
local atk=opp_monster:GetAttack() local atk=opp_monster:GetAttack()
if atk<0 then atk=0 end if atk<0 then atk=0 end
e:SetLabel(atk) e:SetLabel(atk)
Duel.SetTargetPlayer(tp) Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(atk) Duel.SetTargetParam(atk)
Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,0,tp,atk) Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,0,tp,atk)
end end
function s.recop2(e,tp,eg,ep,ev,re,r,rp) function s.recop2(e,tp,eg,ep,ev,re,r,rp)
local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER) local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER)
local d=e:GetLabel() local d=e:GetLabel()
if d>0 then if d>0 then
Duel.Recover(p,d,REASON_EFFECT) Duel.Recover(p,d,REASON_EFFECT)
end end
end
function s.regop(e,tp,eg,ep,ev,re,r,rp)
e:GetHandler():RegisterFlagEffect(id+2,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,0,1)
end
function s.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetFlagEffect(id+2)>0
end
function s.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,e:GetHandler(),1,0,0)
end
function s.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
Duel.SendtoHand(c,nil,REASON_EFFECT)
end
end end
\ No newline at end of file
--光之战士 诺亚 --光之战士 诺亚
function c16400500.initial_effect(c) function c16400500.initial_effect(c)
--spirit return
aux.EnableSpiritReturn(c,EVENT_SPSUMMON_SUCCESS)
--fusion material --fusion material
c:EnableReviveLimit() c:EnableReviveLimit()
aux.AddFusionProcCode3(c,16400325,16400325,16400325,true,true) aux.AddFusionProcCode3(c,16400325,16400325,16400325,true,true)
...@@ -15,27 +17,6 @@ function c16400500.initial_effect(c) ...@@ -15,27 +17,6 @@ function c16400500.initial_effect(c)
e1:SetTarget(c16400500.settg) e1:SetTarget(c16400500.settg)
e1:SetOperation(c16400500.setop) e1:SetOperation(c16400500.setop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--return
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_TOEXTRA)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetCountLimit(1)
e2:SetCondition(c16400500.retcon)
e2:SetTarget(c16400500.rettg)
e2:SetOperation(c16400500.retop)
c:RegisterEffect(e2)
if not c16400500.global_check then
c16400500.global_check=true
local ge1=Effect.CreateEffect(c)
ge1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge1:SetCode(EVENT_SPSUMMON_SUCCESS)
ge1:SetLabel(16400500)
ge1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
ge1:SetOperation(aux.sumreg)
Duel.RegisterEffect(ge1,0)
end
end end
function c16400500.costfilter(c) function c16400500.costfilter(c)
return c:IsSetCard(0xce9) and c:IsAbleToRemoveAsCost() return c:IsSetCard(0xce9) and c:IsAbleToRemoveAsCost()
...@@ -63,17 +44,4 @@ function c16400500.setop(e,tp,eg,ep,ev,re,r,rp) ...@@ -63,17 +44,4 @@ function c16400500.setop(e,tp,eg,ep,ev,re,r,rp)
Duel.SSet(tp,sg) Duel.SSet(tp,sg)
end end
end end
end
function c16400500.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetFlagEffect(16400500)~=0
end
function c16400500.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,e:GetHandler(),1,0,0)
end
function c16400500.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) then
Duel.SendtoDeck(c,nil,0,REASON_EFFECT)
end
end end
\ No newline at end of file
--来自未来的巨人 银河 --来自未来的巨人 银河
function c16400650.initial_effect(c) function c16400650.initial_effect(c)
--spirit return
aux.EnableSpiritReturn(c,EVENT_SPSUMMON_SUCCESS)
--fusion --fusion
c:EnableReviveLimit() c:EnableReviveLimit()
aux.AddFusionProcCodeFun(c,16400315,aux.FilterBoolFunction(Card.IsFusionSetCard,0xce9),5,true,true) aux.AddFusionProcCodeFun(c,16400315,aux.FilterBoolFunction(Card.IsFusionSetCard,0xce9),5,true,true)
...@@ -13,38 +15,4 @@ function c16400650.initial_effect(c) ...@@ -13,38 +15,4 @@ function c16400650.initial_effect(c)
e1:SetTargetRange(LOCATION_SZONE,0) e1:SetTargetRange(LOCATION_SZONE,0)
e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE) e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--return
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_TOEXTRA)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetCountLimit(1)
e2:SetCondition(c16400650.retcon)
e2:SetTarget(c16400650.rettg)
e2:SetOperation(c16400650.retop)
c:RegisterEffect(e2)
if not c16400650.global_check then
c16400650.global_check=true
local ge1=Effect.CreateEffect(c)
ge1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge1:SetCode(EVENT_SPSUMMON_SUCCESS)
ge1:SetLabel(16400650)
ge1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
ge1:SetOperation(aux.sumreg)
Duel.RegisterEffect(ge1,0)
end
end
function c16400650.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetFlagEffect(16400650)~=0
end
function c16400650.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,e:GetHandler(),1,0,0)
end
function c16400650.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) then
Duel.SendtoDeck(c,nil,0,REASON_EFFECT)
end
end end
\ No newline at end of file
--奥特之王 --奥特之王
function c16400710.initial_effect(c) function c16400710.initial_effect(c)
--spirit return
aux.EnableSpiritReturn(c,EVENT_SPSUMMON_SUCCESS)
--fusion summon --fusion summon
c:EnableReviveLimit() c:EnableReviveLimit()
aux.AddFusionProcFunRep(c,c16400710.ffilter,3,true) aux.AddFusionProcFunRep(c,c16400710.ffilter,3,true)
...@@ -16,27 +18,6 @@ function c16400710.initial_effect(c) ...@@ -16,27 +18,6 @@ function c16400710.initial_effect(c)
e1:SetTarget(c16400710.sptg) e1:SetTarget(c16400710.sptg)
e1:SetOperation(c16400710.spop) e1:SetOperation(c16400710.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--return
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_TOEXTRA)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetCountLimit(1)
e2:SetCondition(c16400710.retcon)
e2:SetTarget(c16400710.rettg)
e2:SetOperation(c16400710.retop)
c:RegisterEffect(e2)
if not c16400710.global_check then
c16400710.global_check=true
local ge1=Effect.CreateEffect(c)
ge1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge1:SetCode(EVENT_SPSUMMON_SUCCESS)
ge1:SetLabel(16400710)
ge1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
ge1:SetOperation(aux.sumreg)
Duel.RegisterEffect(ge1,0)
end
end end
function c16400710.ffilter(c,fc,sub,mg,sg) function c16400710.ffilter(c,fc,sub,mg,sg)
return c:IsFusionSetCard(0xce9) and c:IsLevelAbove(8) return c:IsFusionSetCard(0xce9) and c:IsLevelAbove(8)
...@@ -70,17 +51,4 @@ function c16400710.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -70,17 +51,4 @@ function c16400710.spop(e,tp,eg,ep,ev,re,r,rp)
if sg and #sg>0 then if sg and #sg>0 then
Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP)
end end
end
function c16400710.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetFlagEffect(16400710)~=0
end
function c16400710.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,e:GetHandler(),1,0,0)
end
function c16400710.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) then
Duel.SendtoDeck(c,nil,0,REASON_EFFECT)
end
end end
\ No newline at end of file
--光之战士 捷德 --光之战士 捷德
local s,id=GetID() local s,id=GetID()
function s.initial_effect(c) function s.initial_effect(c)
--spirit return
local e1=Effect.CreateEffect(c) aux.EnableSpiritReturn(c,EVENT_SUMMON_SUCCESS,EVENT_SPSUMMON_SUCCESS)
e1:SetDescription(aux.Stringid(id,0)) --
e1:SetCategory(CATEGORY_DISABLE) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e1:SetDescription(aux.Stringid(id,0))
e1:SetCode(EVENT_SUMMON_SUCCESS) e1:SetCategory(CATEGORY_DISABLE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCountLimit(1,id) e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetTarget(s.distg) e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY)
e1:SetOperation(s.disop) e1:SetCountLimit(1,id)
c:RegisterEffect(e1) e1:SetTarget(s.distg)
local e2=e1:Clone() e1:SetOperation(s.disop)
e2:SetCode(EVENT_SPSUMMON_SUCCESS) c:RegisterEffect(e1)
c:RegisterEffect(e2) local e2=e1:Clone()
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
local e3=Effect.CreateEffect(c) c:RegisterEffect(e2)
e3:SetDescription(aux.Stringid(id,1)) --
e3:SetCategory(CATEGORY_ATKCHANGE) local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F) e3:SetDescription(aux.Stringid(id,1))
e3:SetCode(EVENT_PRE_DAMAGE_CALCULATE) e3:SetCategory(CATEGORY_ATKCHANGE)
e3:SetCountLimit(1,id+1) e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
e3:SetCondition(s.atkcon) e3:SetCode(EVENT_PRE_DAMAGE_CALCULATE)
e3:SetOperation(s.atkop) e3:SetCountLimit(1,id+1)
c:RegisterEffect(e3) e3:SetCondition(s.atkcon)
e3:SetOperation(s.atkop)
local e4=Effect.CreateEffect(c) c:RegisterEffect(e3)
e4:SetDescription(aux.Stringid(id,2))
e4:SetCategory(CATEGORY_TOHAND)
e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e4:SetCode(EVENT_PHASE+PHASE_END)
e4:SetRange(LOCATION_MZONE)
e4:SetCondition(s.retcon)
e4:SetTarget(s.rettg)
e4:SetOperation(s.retop)
c:RegisterEffect(e4)
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e5:SetCode(EVENT_SUMMON_SUCCESS)
e5:SetOperation(s.regop)
c:RegisterEffect(e5)
local e6=e5:Clone()
e6:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e6)
end end
function s.distg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function s.distg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsFaceup() end 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 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)
end end
function s.disop(e,tp,eg,ep,ev,re,r,rp) function s.disop(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 tc and tc:IsRelateToEffect(e) and tc:IsFaceup() then if tc and tc:IsRelateToEffect(e) and tc:IsFaceup() then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE) e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1) tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE) e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT) e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e2) tc:RegisterEffect(e2)
end end
end end
function s.atkcon(e,tp,eg,ep,ev,re,r,rp) function s.atkcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local bc=c:GetBattleTarget() local bc=c:GetBattleTarget()
return bc and bc:IsControler(1-tp) return bc and bc:IsControler(1-tp)
end end
function s.atkop(e,tp,eg,ep,ev,re,r,rp) function s.atkop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then if c:IsRelateToEffect(e) and c:IsFaceup() then
local ct=Duel.GetMatchingGroupCount(Card.IsSetCard,tp,LOCATION_GRAVE,0,nil,0xce9)
local ct=Duel.GetMatchingGroupCount(Card.IsSetCard,tp,LOCATION_GRAVE,0,nil,0xce9) local atk=ct*100
local atk=ct*100 if atk>0 then
if atk>0 then local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
local e1=Effect.CreateEffect(c) e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetValue(atk)
e1:SetCode(EFFECT_UPDATE_ATTACK) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_DAMAGE_CAL)
e1:SetValue(atk) c:RegisterEffect(e1)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_DAMAGE_CAL) end
c:RegisterEffect(e1) end
end
end
end
function s.regop(e,tp,eg,ep,ev,re,r,rp)
e:GetHandler():RegisterFlagEffect(id+2,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,0,1)
end
function s.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetFlagEffect(id+2)>0
end
function s.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,e:GetHandler(),1,0,0)
end
function s.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
Duel.SendtoHand(c,nil,REASON_EFFECT)
end
end end
\ No newline at end of file
--光之战士 特利迦 --光之战士 特利迦
local s,id=GetID() local s,id=GetID()
function s.initial_effect(c) function s.initial_effect(c)
--spirit return
local e1=Effect.CreateEffect(c) aux.EnableSpiritReturn(c,EVENT_SUMMON_SUCCESS,EVENT_SPSUMMON_SUCCESS)
e1:SetDescription(aux.Stringid(id,0)) --
e1:SetCategory(CATEGORY_DRAW) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_QUICK_O) e1:SetDescription(aux.Stringid(id,0))
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCategory(CATEGORY_DRAW)
e1:SetRange(LOCATION_MZONE) e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCountLimit(1,id) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER_E) e1:SetRange(LOCATION_MZONE)
e1:SetCost(s.drawcost) e1:SetCountLimit(1,id)
e1:SetTarget(s.drawtg) e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER_E)
e1:SetOperation(s.drawop) e1:SetCost(s.drawcost)
c:RegisterEffect(e1) e1:SetTarget(s.drawtg)
e1:SetOperation(s.drawop)
local e2=Effect.CreateEffect(c) c:RegisterEffect(e1)
e2:SetDescription(aux.Stringid(id,1)) --
e2:SetCategory(CATEGORY_SPECIAL_SUMMON) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_QUICK_O) e2:SetDescription(aux.Stringid(id,1))
e2:SetCode(EVENT_BATTLE_START) e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetRange(LOCATION_GRAVE) e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCountLimit(1,id+100) e2:SetCode(EVENT_BATTLE_START)
e2:SetCondition(s.spcon) e2:SetRange(LOCATION_GRAVE)
e2:SetCost(s.spcost) e2:SetCountLimit(1,id+1)
e2:SetTarget(s.sptg) e2:SetCondition(s.spcon)
e2:SetOperation(s.spop) e2:SetCost(s.spcost)
c:RegisterEffect(e2) e2:SetTarget(s.sptg)
e2:SetOperation(s.spop)
local e3=Effect.CreateEffect(c) c:RegisterEffect(e2)
e3:SetDescription(aux.Stringid(id,2))
e3:SetCategory(CATEGORY_TOHAND)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e3:SetCode(EVENT_PHASE+PHASE_END)
e3:SetRange(LOCATION_MZONE)
e3:SetCondition(s.retcon)
e3:SetTarget(s.rettg)
e3:SetOperation(s.retop)
c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e4:SetCode(EVENT_SUMMON_SUCCESS)
e4:SetOperation(s.regop)
c:RegisterEffect(e4)
local e5=e4:Clone()
e5:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e5)
end end
function s.banfilter(c) function s.banfilter(c)
return c:IsSetCard(0xce9) and c:IsType(TYPE_MONSTER) and c:IsAbleToRemoveAsCost() return c:IsSetCard(0xce9) and c:IsType(TYPE_MONSTER) and c:IsAbleToRemoveAsCost()
end end
function s.drawcost(e,tp,eg,ep,ev,re,r,rp,chk) function s.drawcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.banfilter,tp,LOCATION_GRAVE,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(s.banfilter,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,s.banfilter,tp,LOCATION_GRAVE,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,s.banfilter,tp,LOCATION_GRAVE,0,1,1,nil)
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.Remove(g,POS_FACEUP,REASON_COST)
end end
function s.drawtg(e,tp,eg,ep,ev,re,r,rp,chk) function s.drawtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end
Duel.SetTargetPlayer(tp) Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(1) Duel.SetTargetParam(1)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1) Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
end end
function s.drawop(e,tp,eg,ep,ev,re,r,rp) function s.drawop(e,tp,eg,ep,ev,re,r,rp)
local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER) local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER)
Duel.Draw(p,1,REASON_EFFECT) Duel.Draw(p,1,REASON_EFFECT)
end end
function s.spcon(e,tp,eg,ep,ev,re,r,rp) function s.spcon(e,tp,eg,ep,ev,re,r,rp)
local a=Duel.GetAttacker() local a=Duel.GetAttacker()
local d=Duel.GetAttackTarget() local d=Duel.GetAttackTarget()
if not a or not d then return false end if not a or not d then return false end
local opp_monster=nil local opp_monster=nil
if a:IsControler(1-tp) then if a:IsControler(1-tp) then
opp_monster=a opp_monster=a
elseif d:IsControler(1-tp) then elseif d:IsControler(1-tp) then
opp_monster=d opp_monster=d
end end
return opp_monster~=nil and Duel.IsExistingMatchingCard(s.fieldfilter,tp,LOCATION_MZONE,0,1,nil) return opp_monster~=nil and Duel.IsExistingMatchingCard(s.fieldfilter,tp,LOCATION_MZONE,0,1,nil)
end end
function s.fieldfilter(c) function s.fieldfilter(c)
return c:IsFaceup() and c:IsSetCard(0xce9) and c:IsType(TYPE_MONSTER) return c:IsFaceup() and c:IsSetCard(0xce9) and c:IsType(TYPE_MONSTER)
end end
function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk) function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return c:IsAbleToRemoveAsCost() end if chk==0 then return c:IsAbleToRemoveAsCost() end
Duel.Remove(c,POS_FACEUP,REASON_COST) Duel.Remove(c,POS_FACEUP,REASON_COST)
end end
function s.spfilter(c,e,tp) function s.spfilter(c,e,tp)
return c:IsSetCard(0xce9) and c:IsType(TYPE_MONSTER) and c:IsLevel(4) return c:IsSetCard(0xce9) and c:IsType(TYPE_MONSTER) and c:IsLevel(4)
and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function s.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
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil,e,tp) end and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK+LOCATION_GRAVE) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK+LOCATION_GRAVE)
end end
function s.spop(e,tp,eg,ep,ev,re,r,rp) function s.spop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.spfilter),tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil,e,tp) local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.spfilter),tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil,e,tp)
if #g>0 then if #g>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end end
end
function s.regop(e,tp,eg,ep,ev,re,r,rp)
e:GetHandler():RegisterFlagEffect(id+2,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,0,1)
end
function s.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetFlagEffect(id+2)>0
end
function s.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,e:GetHandler(),1,0,0)
end
function s.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
Duel.SendtoHand(c,nil,REASON_EFFECT)
end
end end
\ No newline at end of file
--光之战士 布鲁 跃水 --光之战士 布鲁 跃水
function c16400750.initial_effect(c) function c16400750.initial_effect(c)
--spirit return
aux.EnableSpiritReturn(c,EVENT_SPSUMMON_SUCCESS)
--link summon --link summon
aux.AddLinkProcedure(c,c16400750.matfilter,1,1) aux.AddLinkProcedure(c,c16400750.matfilter,1,1)
c:EnableReviveLimit() c:EnableReviveLimit()
...@@ -15,30 +17,6 @@ function c16400750.initial_effect(c) ...@@ -15,30 +17,6 @@ function c16400750.initial_effect(c)
e1:SetTarget(c16400750.settg) e1:SetTarget(c16400750.settg)
e1:SetOperation(c16400750.setop) e1:SetOperation(c16400750.setop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--return
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(16400750,1))
e2:SetCategory(CATEGORY_TOEXTRA)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetCondition(c16400750.retcon)
e2:SetTarget(c16400750.rettg)
e2:SetOperation(c16400750.retop)
c:RegisterEffect(e2)
end
function c16400750.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsStatus(STATUS_SPSUMMON_TURN)
end
function c16400750.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,e:GetHandler(),1,0,0)
end
function c16400750.retop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
Duel.SendtoDeck(c,nil,2,REASON_EFFECT)
end
end end
function c16400750.matfilter(c) function c16400750.matfilter(c)
return c:IsLinkSetCard(0xce9) and not c:IsLinkType(TYPE_LINK) return c:IsLinkSetCard(0xce9) and not c:IsLinkType(TYPE_LINK)
......
...@@ -16,7 +16,7 @@ function c16400925.spfilter(c,e,tp) ...@@ -16,7 +16,7 @@ function c16400925.spfilter(c,e,tp)
return c:IsSetCard(0xce9) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsSetCard(0xce9) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function c16400925.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c16400925.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local g=Duel.GetMatchingGroup(c16400925.spfilter,tp,LOCATION_DECK,0,nil) local g=Duel.GetMatchingGroup(c16400925.spfilter,tp,LOCATION_DECK,0,nil,e,tp)
if chkc then return chkc:IsLocation(0x4) and c16400925.desfilter(chkc) end if chkc then return chkc:IsLocation(0x4) and c16400925.desfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c16400925.desfilter,tp,LOCATION_MZONE,0,1,nil) if chk==0 then return Duel.IsExistingTarget(c16400925.desfilter,tp,LOCATION_MZONE,0,1,nil)
and Duel.IsExistingMatchingCard(c16400925.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end and Duel.IsExistingMatchingCard(c16400925.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end
......
...@@ -87,7 +87,7 @@ end ...@@ -87,7 +87,7 @@ end
function cm.filter(c) function cm.filter(c)
return c:IsSetCard(0x3822) and c:IsLocation(LOCATION_GRAVE) return c:IsSetCard(0x822) and c:IsLocation(LOCATION_GRAVE)
end end
function cm.ovtg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.ovtg(e,tp,eg,ep,ev,re,r,rp,chk)
......
...@@ -87,10 +87,18 @@ function s.op1(e,tp,eg,ep,ev,re,r,rp) ...@@ -87,10 +87,18 @@ function s.op1(e,tp,eg,ep,ev,re,r,rp)
end end
function s.con2(e,tp,eg,ep,ev,re,r,rp) function s.con2(e,tp,eg,ep,ev,re,r,rp)
if re:GetActivateLocation()==LOCATION_HAND then
e:SetLabel(1)
elseif re:GetActivateLocation()==LOCATION_GRAVE then
e:SetLabel(2)
elseif re:GetActivateLocation()==LOCATION_REMOVED then
e:SetLabel(3)
end
local q=e:GetLabel()
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 ((re:GetActivateLocation()==LOCATION_HAND and Duel.GetFlagEffect(tp,id)==0) and ((q==1 and Duel.GetFlagEffect(tp,id)==0)
or (re:GetActivateLocation()==LOCATION_GRAVE and Duel.GetFlagEffect(tp,id+o)==0) or (q==2 and Duel.GetFlagEffect(tp,id+o)==0)
or (re:GetActivateLocation()==LOCATION_REMOVED and Duel.GetFlagEffect(tp,id+o*2)==0)) or (q==3 and Duel.GetFlagEffect(tp,id+o*2)==0))
end end
function s.cost2(e,tp,eg,ep,ev,re,r,rp,chk) function s.cost2(e,tp,eg,ep,ev,re,r,rp,chk)
...@@ -104,8 +112,9 @@ end ...@@ -104,8 +112,9 @@ end
function s.tg2(e,tp,eg,ep,ev,re,r,rp,chk) function s.tg2(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return true end if chk==0 then return true end
local q=e:GetLabel()
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0) Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
if re:GetActivateLocation()==LOCATION_HAND then if q==1 then
Duel.RegisterFlagEffect(tp,id,RESET_PHASE+PHASE_END,0,1) Duel.RegisterFlagEffect(tp,id,RESET_PHASE+PHASE_END,0,1)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,2)) e1:SetDescription(aux.Stringid(id,2))
...@@ -114,7 +123,7 @@ function s.tg2(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -114,7 +123,7 @@ function s.tg2(e,tp,eg,ep,ev,re,r,rp,chk)
e1:SetReset(RESET_PHASE+PHASE_END) e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetTargetRange(1,0) e1:SetTargetRange(1,0)
Duel.RegisterEffect(e1,tp) Duel.RegisterEffect(e1,tp)
elseif re:GetActivateLocation()==LOCATION_GRAVE then elseif q==2 then
Duel.RegisterFlagEffect(tp,id+o,RESET_PHASE+PHASE_END,0,1) Duel.RegisterFlagEffect(tp,id+o,RESET_PHASE+PHASE_END,0,1)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,3)) e1:SetDescription(aux.Stringid(id,3))
...@@ -122,7 +131,7 @@ function s.tg2(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -122,7 +131,7 @@ function s.tg2(e,tp,eg,ep,ev,re,r,rp,chk)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT)
e1:SetReset(RESET_PHASE+PHASE_END) e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetTargetRange(1,0) e1:SetTargetRange(1,0)
elseif re:GetActivateLocation()==LOCATION_REMOVED then elseif q==3 then
Duel.RegisterFlagEffect(tp,id+o*2,RESET_PHASE+PHASE_END,0,1) Duel.RegisterFlagEffect(tp,id+o*2,RESET_PHASE+PHASE_END,0,1)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,4)) e1:SetDescription(aux.Stringid(id,4))
......
...@@ -93,23 +93,25 @@ function s.cost3(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -93,23 +93,25 @@ function s.cost3(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD)
Duel.DiscardHand(tp,s.f2,1,1,REASON_COST,nil) Duel.DiscardHand(tp,s.f2,1,1,REASON_COST,nil)
e:SetLabel(1) e:SetLabel(1)
else
e:SetLabel(0)
end end
Duel.SendtoGrave(c,REASON_COST) Duel.SendtoGrave(c,REASON_COST+REASON_RETURN)
end end
function s.tg3(e,tp,eg,ep,ev,re,r,rp,chk) function s.tg3(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
local s=e:GetLabel() local q=e:GetLabel()
if s==1 then if q==1 then
if Duel.IsExistingMatchingCard(s.f4,tp,LOCATION_MZONE,0,1,nil) then if Duel.IsExistingMatchingCard(s.f4,tp,LOCATION_MZONE,0,1,nil) then
s=2 q=2
end end
else elseif q==0 then
if Duel.IsExistingMatchingCard(s.f3,tp,LOCATION_MZONE,0,1,nil) then if Duel.IsExistingMatchingCard(s.f3,tp,LOCATION_MZONE,0,1,nil) then
s=2 q=2
end end
end end
if chk==0 then return s==2 end if chk==0 then return q==2 end
end end
function s.op3(e,tp,eg,ep,ev,re,r,rp) function s.op3(e,tp,eg,ep,ev,re,r,rp)
......
...@@ -62,10 +62,6 @@ function s.f5(c) ...@@ -62,10 +62,6 @@ function s.f5(c)
return c:IsType(TYPE_LINK) or (c:GetDefense()==0 and c:IsFaceup()) return c:IsType(TYPE_LINK) or (c:GetDefense()==0 and c:IsFaceup())
end end
function s.f6(c)
return c:IsDestructable()
end
function s.f7(c,e,tp) function s.f7(c,e,tp)
return c:IsSetCard(0x3480) and c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsSetCard(0x3480) and c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
...@@ -90,22 +86,21 @@ function s.va2(e,c) ...@@ -90,22 +86,21 @@ function s.va2(e,c)
end end
function s.tg3(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function s.tg3(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local ag=Duel.GetMatchingGroup(s.f2,tp,LOCATION_ONFIELD,0,nil) local c=e:GetHandler()
local bg=Duel.GetMatchingGroup(s.f3,tp,0,LOCATION_ONFIELD,nil) if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsDestructable() and chkc:IsFaceup() and chkc:IsControler(tp) end
if chkc then return ag:GetCount()>0 end if chk==0 then return Duel.IsExistingTarget(s.f2,tp,LOCATION_ONFIELD,0,1,nil) and c:IsDestructable() end
if chk==0 then return Duel.IsExistingTarget(s.f2,tp,LOCATION_ONFIELD,0,1,nil) and e:GetHandler():IsDestructable() end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectTarget(tp,s.f2,tp,LOCATION_ONFIELD,0,1,1,nil) local g=Duel.SelectTarget(tp,s.f2,tp,LOCATION_ONFIELD,0,1,1,nil)
g:AddCard(e:GetHandler()) Duel.SetOperationInfo(0,CATEGORY_DESTROY,0,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
end end
function s.op3(e,tp,eg,ep,ev,re,r,rp) function s.op3(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
local bg=Duel.GetMatchingGroup(s.f3,tp,0,LOCATION_ONFIELD,nil) local bg=Duel.GetMatchingGroup(s.f3,tp,0,LOCATION_ONFIELD,nil)
if tc:IsRelateToEffect(e) and e:GetHandler():IsRelateToEffect(e) then if tc:IsRelateToEffect(e) and c:IsRelateToEffect(e) then
Duel.Destroy(tc,REASON_EFFECT,nil,1-tp) Duel.Destroy(tc,REASON_EFFECT)
Duel.Destroy(e:GetHandler(),REASON_EFFECT,nil,1-tp) Duel.Destroy(c,REASON_EFFECT)
if bg:GetCount()>0 then if bg:GetCount()>0 then
local lbg=bg:Filter(s.f4,nil) local lbg=bg:Filter(s.f4,nil)
local ng=Group.CreateGroup() local ng=Group.CreateGroup()
...@@ -127,8 +122,7 @@ function s.op3(e,tp,eg,ep,ev,re,r,rp) ...@@ -127,8 +122,7 @@ function s.op3(e,tp,eg,ep,ev,re,r,rp)
else else
ng=bg:Filter(s.f5,nil) ng=bg:Filter(s.f5,nil)
end end
local fg=ng:Filter(s.f6,nil) Duel.Destroy(ng,REASON_EFFECT)
Duel.Destroy(fg,REASON_EFFECT,nil,tp)
end end
end end
end end
......
...@@ -78,7 +78,7 @@ function s.tg1(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -78,7 +78,7 @@ function s.tg1(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel.SelectTarget(tp,s.f1,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil) Duel.SelectTarget(tp,s.f1,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0)
end end
function s.op1(e,tp,eg,ep,ev,re,r,rp) function s.op1(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if e:GetHandler():IsRelateToEffect(e) and tc:IsRelateToEffect(e) and tc:IsFaceup() then if e:GetHandler():IsRelateToEffect(e) and tc:IsRelateToEffect(e) and tc:IsFaceup() then
...@@ -93,7 +93,7 @@ end ...@@ -93,7 +93,7 @@ end
function s.con3(e,tp,eg,ep,ev,re,r,rp) function s.con3(e,tp,eg,ep,ev,re,r,rp)
return re:IsActiveType(TYPE_TRAP) and Duel.IsChainDisablable(ev) return re:IsActiveType(TYPE_TRAP) and Duel.IsChainDisablable(ev)
end end
function s.cost3(e,tp,eg,ep,ev,re,r,rp,chk) function s.cost3(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
local g1=Duel.GetMatchingGroup(s.f2,tp,LOCATION_HAND,0,c) local g1=Duel.GetMatchingGroup(s.f2,tp,LOCATION_HAND,0,c)
...@@ -125,7 +125,7 @@ function s.cost3(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -125,7 +125,7 @@ function s.cost3(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.Remove(g,POS_FACEUP,REASON_COST)
end end
end end
function s.tg3(e,tp,eg,ep,ev,re,r,rp,chk) function s.tg3(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)
......
...@@ -103,22 +103,27 @@ function s.tg3(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -103,22 +103,27 @@ function s.tg3(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then if chk==0 then
return c:IsDestructable() return c:IsDestructable()
end end
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
if re:GetHandler():IsDestructable() and re:GetHandler():IsRelateToEffect(re)then if re:GetHandler():IsDestructable() and re:GetHandler():IsRelateToEffect(re)then
Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,1,0,0) Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,1,0,0)
end end
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
end end
function s.op3(e,tp,eg,ep,ev,re,r,rp) function s.op3(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateEffect(ev) local c=e:GetHandler()
if Duel.NegateActivation(ev) and re:GetHandler():IsRelateToEffect(re) then if c:IsDestructable() then
Duel.Destroy(eg,REASON_EFFECT) if Duel.Destroy(c,REASON_EFFECT)>0 then
local g=Duel.GetMatchingGroup(s.f2,tp,nil,LOCATION_SZONE,nil,e) Duel.NegateEffect(ev)
if g:GetCount()>0 then if Duel.NegateActivation(ev) and re:GetHandler():IsRelateToEffect(re) then
if Duel.SelectYesNo(tp,aux.Stringid(id,1)) then Duel.Destroy(eg,REASON_EFFECT)
Duel.Destroy(g,REASON_EFFECT) local g=Duel.GetMatchingGroup(s.f2,tp,nil,LOCATION_SZONE,nil,e)
end if g:GetCount()>0 then
end if Duel.SelectYesNo(tp,aux.Stringid(id,1)) then
Duel.Destroy(g,REASON_EFFECT)
end
end
end
end
end end
end end
......
...@@ -74,19 +74,19 @@ end ...@@ -74,19 +74,19 @@ end
function s.op1(e,tp,eg,ep,ev,re,r,rp) function s.op1(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local g=Duel.GetMatchingGroup(aux.NecroValleyFilter(s.f2),tp,LOCATION_GRAVE,0,nil)
if c:IsRelateToEffect(e) if c:IsRelateToEffect(e)
and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0
and Duel.SelectYesNo(tp,aux.Stringid(id,1)) and Duel.SelectYesNo(tp,aux.Stringid(id,1))
and Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,nil) then and Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,nil) then
Duel.BreakEffect() Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD) if Duel.DiscardHand(tp,nil,1,1,REASON_EFFECT+REASON_DISCARD,nil)>0 then
if Duel.DiscardHand(tp,nil,1,1,REASON_EFFECT+REASON_DISCARD,nil)>0 and g:GetCount()>0 then local g=Duel.GetMatchingGroup(s.f2,tp,LOCATION_GRAVE,0,nil)
Duel.BreakEffect() if g:GetCount()>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local sg=g:Select(tp,1,1,nil) local sg=g:Select(tp,1,1,nil)
Duel.SendtoDeck(sg,nil,SEQ_DECKTOP,REASON_EFFECT) Duel.SendtoDeck(sg,nil,SEQ_DECKTOP,REASON_EFFECT)
end end
end
end end
end end
......
...@@ -21,7 +21,6 @@ function s.initial_effect(c) ...@@ -21,7 +21,6 @@ function s.initial_effect(c)
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(id,0)) e3:SetDescription(aux.Stringid(id,0))
e3:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_REMOVE) e3:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_REMOVE)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e3:SetType(EFFECT_TYPE_IGNITION) e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetRange(LOCATION_SZONE) e3:SetRange(LOCATION_SZONE)
e3:SetCountLimit(1,id) e3:SetCountLimit(1,id)
......
...@@ -69,6 +69,9 @@ end ...@@ -69,6 +69,9 @@ end
function s.tg1(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function s.tg1(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return s.f1(chkc) and chkc:IsControler(tp) end if chkc then return s.f1(chkc) and chkc:IsControler(tp) end
if chk==0 then return Duel.IsExistingTarget(s.f1,tp,LOCATION_MZONE,0,1,nil) end if chk==0 then return Duel.IsExistingTarget(s.f1,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
local g=aux.SelectTargetFromFieldFirst(tp,s.f1,tp,LOCATION_MZONE,0,1,1,nil)
Duel.SetOperationInfo(0,0,g,1,0,0)
end end
function s.op1(e,tp,eg,ep,ev,re,r,rp) function s.op1(e,tp,eg,ep,ev,re,r,rp)
......
...@@ -31,7 +31,7 @@ function c82000635.tg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -31,7 +31,7 @@ function c82000635.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
end end
function c82000635.filter(c) function c82000635.filter(c)
return c:IsSetCard(0xf59) return c:IsSetCard(0xf59) and c:IsType(TYPE_MONSTER)
end end
function c82000635.op(e,tp,eg,ep,ev,re,r,rp) function c82000635.op(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c82000635.filter,tp,LOCATION_HAND,0,nil) local g=Duel.GetMatchingGroup(c82000635.filter,tp,LOCATION_HAND,0,nil)
......
...@@ -538,8 +538,8 @@ ...@@ -538,8 +538,8 @@
!setname 0x3dc7 ADR !setname 0x3dc7 ADR
!setname 0x3dc1 花信 !setname 0x3dc1 花信
!setname 0x5dc1 启灵元神 !setname 0x5dc1 启灵元神
!setname 5dc7 旋风战士 !setname 0x5dc7 旋风战士
!setname 6dc7 魔法骑士 !setname 0x6dc7 魔法骑士
!counter 0x3dc1 神印指示物 !counter 0x3dc1 神印指示物
!counter 0xdc0 神耀指示物 !counter 0xdc0 神耀指示物
!counter 0xdc1 辛指示物 !counter 0xdc1 辛指示物
......
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