Commit ed78f908 authored by Satty's avatar Satty

fix

parent 1c5a9ea2
Pipeline #36340 passed with stages
in 28 minutes and 59 seconds
......@@ -4,23 +4,22 @@ function s.initial_effect(c)
--Synchro summon
aux.AddSynchroProcedure(c,nil,aux.NonTuner(nil),1)
c:EnableReviveLimit()
if not s.global_flag then
s.global_flag=true
--act limit
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_TRIGGER)
e1:SetTargetRange(0xff,0xff)
e1:SetTarget(s.disable)
Duel.RegisterEffect(e1,0)
--disable
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetTargetRange(0xff,0xff)
e2:SetTarget(s.disable)
e2:SetCode(EFFECT_DISABLE)
Duel.RegisterEffect(e2,0)
end
--act limit
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE)
e1:SetCode(EFFECT_CANNOT_TRIGGER)
e1:SetRange(0xff)
e1:SetCondition(s.actcon)
c:RegisterEffect(e1)
--disable
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EFFECT_DISABLE)
e2:SetCondition(s.actcon)
c:RegisterEffect(e2)
--
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(id,0))
......@@ -42,17 +41,10 @@ function s.initial_effect(c)
e4:SetOperation(s.thop)
c:RegisterEffect(e4)
end
s.limt_name_hpk=id
function s.actcon(e)
local tp=e:GetHandlerPlayer()
return Duel.IsExistingMatchingCard(s.ndcfilter,tp,LOCATION_MZONE,0,1,nil)
end
function s.disable(e,c)
if c.limt_name_hpk~=id then return end
local tp=c:GetControler()
return (c:IsType(TYPE_EFFECT) or c:GetOriginalType()&TYPE_EFFECT~=0)
and Duel.IsExistingMatchingCard(s.ndcfilter,tp,LOCATION_MZONE,0,1,nil)
end
function s.ndcfilter(c)
return c:IsFacedown() or not c:IsSetCard(0x5a71)
end
......@@ -91,7 +83,7 @@ end
function s.thfilter(c)
local b1=c:IsAbleToHand()
local b2=c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsSSetable()
return c:IsFaceupEx() and c:IsSetCard(0x6a71) and (b1 or b2)
return c:IsSetCard(0x6a71) and (b1 or b2) and c:IsFaceupEx()
end
function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_REMOVED,0,1,nil) end
......
......@@ -11,7 +11,7 @@ function s.initial_effect(c)
e1:SetRange(LOCATION_HAND+LOCATION_MZONE)
e1:SetCountLimit(1,id)
e1:SetCost(s.spcost)
e1:SetCondition(s.spcon)
e1:SetCondition(s.spcon)
e1:SetTarget(s.sptg)
e1:SetOperation(s.spop)
c:RegisterEffect(e1)
......
......@@ -93,7 +93,7 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp)
e11:SetCode(EFFECT_LEAVE_FIELD_REDIRECT)
e11:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e11:SetReset(RESET_EVENT+RESETS_REDIRECT)
e11:SetValue(LOCATION_DECK)
e11:SetValue(LOCATION_REMOVED)
c:RegisterEffect(e11)
end
if a:IsAttackable() and not a:IsImmuneToEffect(e) then
......
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