Commit bae07c87 authored by mercury233's avatar mercury233 Committed by GitHub

remove empty wrap (#2567)

parent 156c66a8
......@@ -6,8 +6,8 @@ function c50907446.initial_effect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_FUSION_MATERIAL)
e1:SetCondition(c50907446.FShaddollCondition())
e1:SetOperation(c50907446.FShaddollOperation())
e1:SetCondition(c50907446.FShaddollCondition)
e1:SetOperation(c50907446.FShaddollOperation)
c:RegisterEffect(e1)
--cannot spsummon
local e2=Effect.CreateEffect(c)
......@@ -131,8 +131,7 @@ function c50907446.FShaddollSpFilter2(c,fc,tp,mc,chkf)
or (c50907446.FShaddollFilter1(mc,sg) and c50907446.FShaddollFilter2(c)))
and (chkf==PLAYER_NONE or Duel.GetLocationCountFromEx(tp,tp,sg,fc)>0)
end
function c50907446.FShaddollCondition()
return function(e,g,gc,chkf)
function c50907446.FShaddollCondition(e,g,gc,chkf)
if g==nil then return aux.MustMaterialCheck(nil,e:GetHandlerPlayer(),EFFECT_MUST_BE_FMATERIAL) end
local c=e:GetHandler()
local mg=g:Filter(c50907446.FShaddollFilter,nil,c)
......@@ -148,10 +147,8 @@ function c50907446.FShaddollCondition()
return c50907446.FShaddollSpFilter1(gc,c,tp,mg,exg,chkf)
end
return mg:IsExists(c50907446.FShaddollSpFilter1,1,nil,c,tp,mg,exg,chkf)
end
end
function c50907446.FShaddollOperation()
return function(e,tp,eg,ep,ev,re,r,rp,gc,chkf)
function c50907446.FShaddollOperation(e,tp,eg,ep,ev,re,r,rp,gc,chkf)
local c=e:GetHandler()
local mg=eg:Filter(c50907446.FShaddollFilter,nil,c)
local fc=Duel.GetFieldCard(tp,LOCATION_FZONE,0)
......@@ -181,5 +178,4 @@ function c50907446.FShaddollOperation()
g:Merge(sg)
end
Duel.SetFusionMaterial(g)
end
end
......@@ -1944,8 +1944,8 @@ function Auxiliary.EnablePendulumAttribute(c,reg)
e1:SetCode(EFFECT_SPSUMMON_PROC_G)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_PZONE)
e1:SetCondition(Auxiliary.PendCondition())
e1:SetOperation(Auxiliary.PendOperation())
e1:SetCondition(Auxiliary.PendCondition)
e1:SetOperation(Auxiliary.PendOperation)
e1:SetValue(SUMMON_TYPE_PENDULUM)
c:RegisterEffect(e1)
--register by default
......@@ -1985,8 +1985,7 @@ function Auxiliary.PConditionFilter(c,e,tp,lscale,rscale,eset)
and not c:IsForbidden()
and (Auxiliary.PendulumChecklist&(0x1<<tp)==0 or Auxiliary.PConditionExtraFilter(c,e,tp,lscale,rscale,eset))
end
function Auxiliary.PendCondition()
return function(e,c,og)
function Auxiliary.PendCondition(e,c,og)
if c==nil then return true end
local tp=c:GetControler()
local eset={Duel.IsPlayerAffectedByEffect(tp,EFFECT_EXTRA_PENDULUM_SUMMON)}
......@@ -2007,7 +2006,6 @@ function Auxiliary.PendCondition()
g=Duel.GetFieldGroup(tp,loc,0)
end
return g:IsExists(Auxiliary.PConditionFilter,1,nil,e,tp,lscale,rscale,eset)
end
end
function Auxiliary.PendOperationCheck(ft1,ft2,ft)
return function(g)
......@@ -2016,8 +2014,7 @@ function Auxiliary.PendOperationCheck(ft1,ft2,ft)
return #g<=ft and #exg<=ft2 and #mg<=ft1
end
end
function Auxiliary.PendOperation()
return function(e,tp,eg,ep,ev,re,r,rp,c,sg,og)
function Auxiliary.PendOperation(e,tp,eg,ep,ev,re,r,rp,c,sg,og)
local rpz=Duel.GetFieldCard(tp,LOCATION_PZONE,1)
local lscale=c:GetLeftScale()
local rscale=rpz:GetRightScale()
......@@ -2079,7 +2076,6 @@ function Auxiliary.PendOperation()
sg:Merge(g)
Duel.HintSelection(Group.FromCards(c))
Duel.HintSelection(Group.FromCards(rpz))
end
end
--enable revive limit for monsters that are also pendulum sumonable from certain locations (Odd-Eyes Revolution Dragon)
function Auxiliary.EnableReviveLimitPendulumSummonable(c, loc)
......
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