Commit 4becfe8d authored by mercury233's avatar mercury233 Committed by GitHub

fix null SUMMON_INFO_REASON_EFFECT (#2356)

parent 90f7fbba
......@@ -37,6 +37,7 @@ function c13735899.atkval(e)
end
function c13735899.cfilter(c,e)
local typ,se=c:GetSpecialSummonInfo(SUMMON_INFO_TYPE,SUMMON_INFO_REASON_EFFECT)
if not se then return false end
local sc=se:GetHandler()
return typ&TYPE_MONSTER~=0 and se:IsActivated()
and c:IsFaceup() and (c:GetOriginalRace()==sc:GetOriginalRace() or c==sc)
......
......@@ -53,7 +53,7 @@ function s.tgop(e,tp,eg,ep,ev,re,r,rp)
end
function s.cfilter(c,tp)
local typ,se,sp=c:GetSpecialSummonInfo(SUMMON_INFO_TYPE,SUMMON_INFO_REASON_EFFECT,SUMMON_INFO_REASON_PLAYER)
return typ&TYPE_MONSTER~=0 and se:IsActivated() and sp==1-tp
return se and typ&TYPE_MONSTER~=0 and se:IsActivated() and sp==1-tp
end
function s.spcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(s.cfilter,1,nil,tp)
......
......@@ -81,7 +81,7 @@ function c95886782.eqlimit(e,c)
end
function c95886782.cfilter(c,e,tp)
local se,sp=c:GetSpecialSummonInfo(SUMMON_INFO_REASON_EFFECT,SUMMON_INFO_REASON_PLAYER)
return sp==1-tp and se:IsActivated() and e:GetOwnerPlayer()==1-se:GetOwnerPlayer()
return se and sp==1-tp and se:IsActivated() and e:GetOwnerPlayer()==1-se:GetOwnerPlayer()
end
function c95886782.atkcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetEquipTarget()
......
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