Commit 57082f2d authored by nanahira's avatar nanahira Committed by GitHub

clean checks of EFFECT_KAISER_COLOSSEUM (#2574)

parent 79740c40
...@@ -33,13 +33,6 @@ function c27204311.checkop(e,tp,eg,ep,ev,re,r,rp) ...@@ -33,13 +33,6 @@ function c27204311.checkop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c27204311.spcon(e,tp,eg,ep,ev,re,r,rp) function c27204311.spcon(e,tp,eg,ep,ev,re,r,rp)
if Duel.IsPlayerAffectedByEffect(tp,EFFECT_KAISER_COLOSSEUM) then
local t1=Duel.GetFieldGroupCount(tp,LOCATION_MZONE,0)
local t2=Duel.GetFieldGroupCount(tp,0,LOCATION_MZONE)
local c1=Duel.GetMatchingGroupCount(c27204311.relfilter,tp,LOCATION_MZONE,0,nil)
local c2=Duel.GetMatchingGroupCount(c27204311.relfilter,tp,0,LOCATION_MZONE,nil)
if t1-c1 >= t2-c2 then return false end
end
return Duel.GetFlagEffect(1-tp,27204311)>=5 and (Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2) return Duel.GetFlagEffect(1-tp,27204311)>=5 and (Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2)
end end
function c27204311.relfilter(c) function c27204311.relfilter(c)
......
...@@ -54,13 +54,6 @@ function s.sprcon(e,c) ...@@ -54,13 +54,6 @@ function s.sprcon(e,c)
if c==nil then return true end if c==nil then return true end
local tp=c:GetControler() local tp=c:GetControler()
local rg=Duel.GetMatchingGroup(s.rfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil,1-tp) local rg=Duel.GetMatchingGroup(s.rfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil,1-tp)
if Duel.IsPlayerAffectedByEffect(tp,EFFECT_KAISER_COLOSSEUM) then
local t1=Duel.GetFieldGroupCount(tp,LOCATION_MZONE,0)
local t2=Duel.GetFieldGroupCount(tp,0,LOCATION_MZONE)
local r1=Duel.GetMatchingGroupCount(s.rfilter,tp,LOCATION_MZONE,0,nil,1-tp)
local r2=Duel.GetMatchingGroupCount(s.rfilter,tp,0,LOCATION_MZONE,nil,1-tp)
if t1-r1+1 > t2-r2 then return false end
end
return rg:GetCount()>0 and rg:FilterCount(Card.IsReleasable,nil,REASON_SPSUMMON)==rg:GetCount() and aux.mzctcheck(rg,tp) return rg:GetCount()>0 and rg:FilterCount(Card.IsReleasable,nil,REASON_SPSUMMON)==rg:GetCount() and aux.mzctcheck(rg,tp)
end end
function s.sprop(e,tp,eg,ep,ev,re,r,rp,c) function s.sprop(e,tp,eg,ep,ev,re,r,rp,c)
......
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