Commit 8a82b82a authored by xiaoye's avatar xiaoye

Update VgFuncLib.lua

parent 18f6925f
...@@ -1016,8 +1016,7 @@ function VgF.CheckPrison(p) ...@@ -1016,8 +1016,7 @@ function VgF.CheckPrison(p)
return og:IsExists(Card.IsSetCard,1,nil,0x3040) return og:IsExists(Card.IsSetCard,1,nil,0x3040)
end end
--重置Effect --重置Effect
function VgF.EffectReset(c,e,code,con,...) function VgF.EffectReset(c,e,code,con)
local label={...}
if VgF.GetValueType(e)=="Effect" then if VgF.GetValueType(e)=="Effect" then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
...@@ -1025,7 +1024,6 @@ function VgF.EffectReset(c,e,code,con,...) ...@@ -1025,7 +1024,6 @@ function VgF.EffectReset(c,e,code,con,...)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetRange(LOCATION_ALL) e1:SetRange(LOCATION_ALL)
e1:SetLabelObject(e) e1:SetLabelObject(e)
if VgF.GetValueType(label)=="table" then e1:SetLabel(table.unpack(label)) end
if VgF.GetValueType(con)=="function" then e1:SetCondition(con) end if VgF.GetValueType(con)=="function" then e1:SetCondition(con) end
e1:SetOperation(VgF.EffectResetOperation) e1:SetOperation(VgF.EffectResetOperation)
c:RegisterEffect(e1) c:RegisterEffect(e1)
...@@ -1037,7 +1035,6 @@ function VgF.EffectReset(c,e,code,con,...) ...@@ -1037,7 +1035,6 @@ function VgF.EffectReset(c,e,code,con,...)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetRange(LOCATION_ALL) e1:SetRange(LOCATION_ALL)
e1:SetLabelObject(v) e1:SetLabelObject(v)
if VgF.GetValueType(label)=="table" then e1:SetLabel(table.unpack(label)) end
if VgF.GetValueType(con)=="function" then e1:SetCondition(con) end if VgF.GetValueType(con)=="function" then e1:SetCondition(con) end
e1:SetOperation(VgF.EffectResetOperation) e1:SetOperation(VgF.EffectResetOperation)
c:RegisterEffect(e1) c:RegisterEffect(e1)
......
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