Commit fd2da4d8 authored by DailyShana's avatar DailyShana

fix

parent de993ae1
...@@ -14,7 +14,6 @@ function c21250202.initial_effect(c) ...@@ -14,7 +14,6 @@ function c21250202.initial_effect(c)
e2:SetCode(EVENT_CHAIN_SOLVED) e2:SetCode(EVENT_CHAIN_SOLVED)
e2:SetRange(LOCATION_PZONE) e2:SetRange(LOCATION_PZONE)
e2:SetOperation(c21250202.regop2) e2:SetOperation(c21250202.regop2)
e2:SetLabelObject(e1)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--spsummon --spsummon
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
...@@ -41,26 +40,30 @@ function c21250202.initial_effect(c) ...@@ -41,26 +40,30 @@ function c21250202.initial_effect(c)
e4:SetOperation(c21250202.disop) e4:SetOperation(c21250202.disop)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c21250202.regfilter(c) function c21250202.regfilter(c,tp)
return c:IsType(TYPE_PENDULUM) and c:IsType(TYPE_MONSTER) and c:IsFaceup() and c:IsSetCard(0x99) return c:IsLocation(LOCATION_MZONE) and c:IsControler(tp)
and c:IsType(TYPE_PENDULUM) and c:IsFaceup() and c:IsSetCard(0x99)
end end
function c21250202.regop1(e,tp,eg,ep,ev,re,r,rp) function c21250202.regop1(e,tp,eg,ep,ev,re,r,rp)
if rp==tp or not re:IsHasProperty(EFFECT_FLAG_CARD_TARGET) or eg:GetCount()~=1 if rp~=tp and eg:GetCount()==1 and eg:IsExists(c21250202.regfilter,1,nil,tp) then
or not eg:IsExists(c21250202.regfilter,1,nil) then e:GetHandler():RegisterFlagEffect(21250202,RESET_EVENT+0x1fe0000+RESET_CHAIN,0,1,ev)
e:SetLabelObject(nil) end
else e:SetLabelObject(re) end
end end
function c21250202.regop2(e,tp,eg,ep,ev,re,r,rp) function c21250202.regop2(e,tp,eg,ep,ev,re,r,rp)
local pe=e:GetLabelObject():GetLabelObject() local c=e:GetHandler()
if pe and pe==re then local chain_ct={c:GetFlagEffectLabel(21250202)}
e:GetHandler():RegisterFlagEffect(21250202,RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END,0,1) for i=1,#chain_ct do
if chain_ct[i]==ev then
c:RegisterFlagEffect(21250203,RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END,0,1)
return
end
end end
end end
function c21250202.penfilter(c) function c21250202.penfilter(c)
return c:IsSetCard(0x99) and c:IsType(TYPE_PENDULUM) and c:IsFaceup() and not c:IsCode(21250202) and not c:IsForbidden() return c:IsFaceup() and c:IsSetCard(0x99) and c:IsType(TYPE_PENDULUM) and not c:IsCode(21250202) and not c:IsForbidden()
end end
function c21250202.spcon(e,tp,eg,ep,ev,re,r,rp) function c21250202.spcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetFlagEffect(21250202)~=0 return e:GetHandler():GetFlagEffect(21250203)~=0
end end
function c21250202.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function c21250202.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
...@@ -82,7 +85,7 @@ function c21250202.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -82,7 +85,7 @@ function c21250202.spop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c21250202.disfilter(c) function c21250202.disfilter(c)
return c:IsFaceup() and c:GetSummonLocation()==LOCATION_EXTRA and not c:IsDisabled() return aux.disfilter1(c) and c:GetSummonLocation()==LOCATION_EXTRA
end end
function c21250202.distg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c21250202.distg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and c21250202.disfilter(chkc) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and c21250202.disfilter(chkc) 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