Commit 0da15785 authored by Huangnan's avatar Huangnan

fix

parent 53264aa8
Pipeline #40417 failed with stages
in 7 minutes and 28 seconds
......@@ -32,6 +32,7 @@ function s.operation(e,tp,eg,ep,ev,re,r,rp)
e0:SetOperation(s.costop)
e0:SetReset(RESET_PHASE+PHASE_END)
tc:RegisterEffect(e0)
end
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_ADJUST)
......@@ -47,7 +48,6 @@ function s.operation(e,tp,eg,ep,ev,re,r,rp)
local e4=e1:Clone()
e4:SetOperation(s.op4)
Duel.RegisterEffect(e4,tp)
end
end
function s.actarget(e,te,tp)
e:SetLabelObject(te)
......
......@@ -65,7 +65,7 @@ function cm.w(c)
return c:IsFaceup() and c:IsSetCard(0x590c)
end
function cm.con2(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cm.w,tp,LOCATION_MZONE,0,1,nil)
return Duel.IsExistingMatchingCard(cm.w,tp,LOCATION_MZONE,0,1,nil) and Duel.GetTurnPlayer()==tp
end
function cm.e(c)
return c:IsSetCard(0x590c) and c:IsAbleToHand() and not c:IsCode(m)
......
......@@ -39,8 +39,9 @@ end
function s.sfliter(c)
return c.MoJin==true and c:IsType(TYPE_MONSTER)
end
function s.cfilter(c) --2025.8.23 雪
return Duel.GetFlagEffect(tp,id)>0 and c:IsAbleToRemoveAsCost()
function s.cfilter(c,fc)--2025.8.23 雪
local tp=fc:GetControler()
return Duel.GetFlagEffect(tp,id)~=0 and c:IsAbleToRemoveAsCost()
end
function s.regop(e,tp,eg,ep,ev,re,r,rp)
......
......@@ -3,6 +3,12 @@ local s,id,o=GetID()
function s.initial_effect(c)
c:EnableReviveLimit()
--spsummon condition
local e1=Effect.CreateEffect(c)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SPSUMMON_CONDITION)
e1:SetValue(aux.FALSE)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
......
......@@ -46,12 +46,10 @@ function c50224275.spfilter1(c,e,tp,attr)
end
function c50224275.sptg1(e,tp,eg,ep,ev,re,r,rp,chk)
local sg=eg:Filter(Card.IsSummonPlayer,e:GetHandler(),1-tp)
if #sg<1 then return end
local attr=0
local sc=sg:GetFirst()
while sc do
Debug.Message(sc:GetCode())
attr=attr|sc:GetAttribute()
sc=sg:GetNext()
end
......
......@@ -2,97 +2,97 @@
function c62699835.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(62699835,0))
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,62699835)
e1:SetTarget(c62699835.target)
e1:SetOperation(c62699835.activate)
c:RegisterEffect(e1)
--special summon
--draw
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(62699835,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_DESTROY)
e2:SetType(EFFECT_TYPE_ACTIVATE)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetCountLimit(1,62699835+1)
e2:SetTarget(c62699835.sptg)
e2:SetOperation(c62699835.spop)
e2:SetCategory(CATEGORY_DRAW+CATEGORY_DESTROY)
e2:SetType(EFFECT_TYPE_TRIGGER_O+EFFECT_TYPE_FIELD)
e2:SetCode(EVENT_DESTROYED)
e2:SetRange(LOCATION_GRAVE)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCountLimit(1,62699835+2)
e2:SetCondition(c62699835.drcon)
e2:SetCost(aux.bfgcost)
e2:SetTarget(c62699835.drtg)
e2:SetOperation(c62699835.drop)
c:RegisterEffect(e2)
--draw
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_DRAW+CATEGORY_DESTROY)
e3:SetType(EFFECT_TYPE_TRIGGER_O+EFFECT_TYPE_FIELD)
e3:SetCode(EVENT_DESTROYED)
e3:SetRange(LOCATION_GRAVE)
e3:SetProperty(EFFECT_FLAG_DELAY)
e3:SetCountLimit(1,62699835+2)
e3:SetCondition(c62699835.drcon)
e3:SetCost(aux.bfgcost)
e3:SetTarget(c62699835.drtg)
e3:SetOperation(c62699835.drop)
c:RegisterEffect(e3)
end
function c62699835.filter(c)
return c:IsSetCard(0x6df) and not c:IsCode(62699835) and c:IsType(0x6) and c:IsAbleToHand()
end
function c62699835.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c62699835.filter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,nil,1,tp,LOCATION_HAND+LOCATION_ONFIELD)
function c62699835.spfilter(c,e,tp)
return c:IsSetCard(0x6df) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c62699835.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE+LOCATION_REMOVED) and c62699835.spfilter(chkc,e,tp) end
local b1=Duel.IsExistingMatchingCard(c62699835.filter,tp,LOCATION_DECK,0,1,nil)
and (Duel.GetFlagEffect(tp,62699835)==0 or not e:IsCostChecked())
local b2=Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingTarget(c62699835.spfilter,tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,nil,e,tp)
and (Duel.GetFlagEffect(tp,62699835+1)==0 or not e:IsCostChecked())
if chk==0 then return b1 or b2 end
local op=aux.SelectFromOptions(tp,{b1,aux.Stringid(62699835,0)},{b2,aux.Stringid(62699835,1)})
e:SetLabel(op)
if op==1 and e:IsCostChecked() then
e:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_DESTROY)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,nil,1,tp,LOCATION_HAND+LOCATION_ONFIELD)
Duel.RegisterFlagEffect(tp,62699835,RESET_PHASE+PHASE_END,0,1)
elseif op==2 and e:IsCostChecked() then
e:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_DESTROY)
e:SetProperty(EFFECT_FLAG_CARD_TARGET)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c62699835.spfilter,tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,nil,1,tp,LOCATION_HAND+LOCATION_ONFIELD)
Duel.RegisterFlagEffect(tp,62699835+1,RESET_PHASE+PHASE_END,0,1)
end
end
function c62699835.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c62699835.filter,tp,LOCATION_DECK,0,1,1,nil)
if #g==0 then return false end
local tc=g:GetFirst()
if Duel.SendtoHand(tc,nil,REASON_EFFECT)>0 and tc:IsLocation(LOCATION_HAND) then
Duel.ConfirmCards(1-tp,tc)
Duel.BreakEffect()
Duel.ShuffleHand(tp)
local op=e:GetLabel()
if op==1 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c62699835.filter,tp,LOCATION_DECK,0,1,1,nil)
if #g==0 then return false end
local tc=g:GetFirst()
if Duel.SendtoHand(tc,nil,REASON_EFFECT)>0 and tc:IsLocation(LOCATION_HAND) then
Duel.ConfirmCards(1-tp,tc)
Duel.BreakEffect()
Duel.ShuffleHand(tp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local dg=Duel.SelectMatchingCard(tp,nil,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,1,aux.ExceptThisCard(e))
Duel.BreakEffect()
Duel.Destroy(dg,REASON_EFFECT)
end
elseif op==2 then
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if not tc:IsRelateToEffect(e) then return end
local res=Duel.SpecialSummonStep(tc,0,tp,tp,false,false,POS_FACEUP)
if res then
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:SetValue(RESET_TURN_SET)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e2)
end
Duel.SpecialSummonComplete()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local dg=Duel.SelectMatchingCard(tp,nil,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,1,aux.ExceptThisCard(e))
Duel.BreakEffect()
Duel.Destroy(dg,REASON_EFFECT)
end
end
function c62699835.spfilter(c,e,tp)
return c:IsSetCard(0x6df) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c62699835.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE+LOCATION_REMOVED) and c62699835.spfilter(chkc,e,tp) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingTarget(c62699835.spfilter,tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c62699835.spfilter,tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,nil,1,tp,LOCATION_HAND+LOCATION_ONFIELD)
end
function c62699835.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if not tc:IsRelateToEffect(e) then return end
local res=Duel.SpecialSummonStep(tc,0,tp,tp,false,false,POS_FACEUP)
if res then
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:SetValue(RESET_TURN_SET)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e2)
end
Duel.SpecialSummonComplete()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local dg=Duel.SelectMatchingCard(tp,nil,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,1,aux.ExceptThisCard(e))
Duel.BreakEffect()
Duel.Destroy(dg,REASON_EFFECT)
end
function c62699835.drfilter(c,tp)
return c:IsPreviousControler(tp) and c:IsSetCard(0x6df)
end
......
......@@ -53,7 +53,7 @@ function c62699945.spop(e,tp,eg,ep,ev,re,r,rp)
e1:SetValue(LOCATION_REMOVED)
c:RegisterEffect(e1,true)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,c62699945.tgfilter,tp,LOCATION_DECK,0,1,1,nil)
local g=Duel.SelectMatchingCard(tp,c62699945.tgfilter,tp,0xf,0,1,1,nil)
if g:GetCount()>0 then
Duel.BreakEffect()
Duel.SendtoGrave(g,REASON_EFFECT)
......
......@@ -18,6 +18,15 @@ function s.initial_effect(c)
e2:SetCost(s.accost)
e2:SetOperation(s.acop)
c:RegisterEffect(e2)
--act limit
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_FIELD)
e0:SetRange(LOCATION_FZONE)
e0:SetCode(EFFECT_CANNOT_ACTIVATE)
e0:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_IGNORE_IMMUNE)
e0:SetTargetRange(1,1)
e0:SetValue(s.aclimit)
c:RegisterEffect(e0)
--spsummon limit
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
......@@ -29,6 +38,14 @@ function s.initial_effect(c)
c:RegisterEffect(e3)
end
function s.aclimit(e,re,tp)
local tc=re:GetHandler()
local tp=tc:GetControler()
local seq=tc:GetSequence()
return tc and tp and seq and ((seq==5 and not Duel.CheckLocation(tp,LOCATION_MZONE,1)) or (seq==6 and not Duel.CheckLocation(tp,LOCATION_MZONE,3)))
end
function s.accon(e)
s[0]=false
return true
......@@ -42,7 +59,7 @@ function s.accost(e,te)
local tc=te:GetHandler()
local tp=tc:GetControler()
local seq=tc:GetSequence()
return tc:IsLocation(LOCATION_MZONE) and ((seq>0 and Duel.CheckLocation(tp,LOCATION_MZONE,seq-1)) or (seq<4 and Duel.CheckLocation(tp,LOCATION_MZONE,seq+1)) or (seq==5 and Duel.CheckLocation(tp,LOCATION_MZONE,1)) or (seq==6 and Duel.CheckLocation(tp,LOCATION_MZONE,3))) or tc:IsLocation(LOCATION_SZONE) and ((seq>0 and Duel.CheckLocation(tp,LOCATION_SZONE,seq-1)) or (seq<4 and Duel.CheckLocation(tp,LOCATION_SZONE,seq+1)))
return (tc:IsLocation(LOCATION_MZONE) and ((seq>0 and Duel.CheckLocation(tp,LOCATION_MZONE,seq-1)) or (seq<4 and Duel.CheckLocation(tp,LOCATION_MZONE,seq+1)) or (seq==5 and Duel.CheckLocation(tp,LOCATION_MZONE,1)) or (seq==6 and Duel.CheckLocation(tp,LOCATION_MZONE,3)))) or (tc:IsLocation(LOCATION_SZONE) and ((seq>0 and Duel.CheckLocation(tp,LOCATION_SZONE,seq-1)) or (seq<4 and Duel.CheckLocation(tp,LOCATION_SZONE,seq+1))))
end
function s.acop(e,eg,ep,ev,re,r,rp)
if s[0] then return end
......
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