Commit 7e07afd9 authored by salix5's avatar salix5
parent 06941fc2
......@@ -40,35 +40,6 @@ function c29951323.initial_effect(c)
e5:SetCondition(c29951323.countcon2)
e5:SetTargetRange(0,1)
c:RegisterEffect(e5)
if not c29951323.global_check then
c29951323.global_check=true
c29951323[0]=0
c29951323[1]=0
local ge1=Effect.CreateEffect(c)
ge1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge1:SetCode(EVENT_ATTACK_ANNOUNCE)
ge1:SetOperation(c29951323.checkop1)
Duel.RegisterEffect(ge1,0)
local ge2=ge1:Clone()
ge2:SetCode(EVENT_ATTACK_DISABLED)
ge2:SetOperation(c29951323.checkop2)
Duel.RegisterEffect(ge2,0)
local ge3=Effect.CreateEffect(c)
ge3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge3:SetCode(EVENT_PHASE_START+PHASE_DRAW)
ge3:SetOperation(c29951323.clear)
Duel.RegisterEffect(ge3,0)
end
end
function c29951323.checkop1(e,tp,eg,ep,ev,re,r,rp)
c29951323[ep]=c29951323[ep]+1
end
function c29951323.checkop2(e,tp,eg,ep,ev,re,r,rp)
c29951323[ep]=c29951323[ep]-1
end
function c29951323.clear(e,tp,eg,ep,ev,re,r,rp)
c29951323[0]=0
c29951323[1]=0
end
function c29951323.splimit(e,se,sp,st)
return se:IsHasType(EFFECT_TYPE_ACTIONS) and Duel.GetActivityCount(e:GetHandlerPlayer(),ACTIVITY_SPSUMMON)==0
......@@ -78,8 +49,7 @@ function c29951323.valcon(e,re,r,rp)
return bit.band(r,REASON_BATTLE)~=0
end
function c29951323.limittg(e,c,tp)
if Duel.GetTurnPlayer()~=tp then return false end
return Duel.GetActivityCount(tp,ACTIVITY_SPSUMMON)>=c29951323[tp]
return Duel.GetTurnPlayer()==tp and Duel.GetActivityCount(tp,ACTIVITY_SPSUMMON)>=Duel.GetBattledCount(tp)
end
function c29951323.countcon1(e)
return Duel.GetTurnPlayer()==e:GetHandlerPlayer()
......@@ -89,6 +59,6 @@ function c29951323.countcon2(e)
end
function c29951323.countval(e,tp)
local t1=Duel.GetActivityCount(tp,ACTIVITY_SPSUMMON)
local t2=c29951323[tp]
local t2=Duel.GetBattledCount(tp)
if t1>=t2 then return 0 else return t2-t1 end
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