Commit 323215af authored by nanahira's avatar nanahira

Merge branch 'patch-1' into 'master'

fix special-fh-20201208.lua

See merge request !1
parents 1457c089 7afb7ae8
--FH special [Warp Point] --FH special [Warp Point]
function Auxiliary.PreloadUds() function Auxiliary.PreloadUds()
--adjust --adjust
local e1=Effect.GlobalEffect() local e1=Effect.GlobalEffect()
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE) e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetCode(EVENT_ADJUST) e1:SetCode(EVENT_ADJUST)
e1:SetOperation(aux.AdjustOperation) e1:SetOperation(aux.AdjustOperation)
Duel.RegisterEffect(e1,0) Duel.RegisterEffect(e1,0)
end end
function aux.AdjustOperation(e,tp,eg,ep,ev,re,r,rp) function aux.AdjustOperation(e,tp,eg,ep,ev,re,r,rp)
local e1 = Effect.GlobalEffect() local e1 = Effect.GlobalEffect()
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetOperation(aux.LPDecrease) e1:SetOperation(aux.LPDecrease)
Duel.RegisterEffect(e1,0) Duel.RegisterEffect(e1,0)
--atk up --atk up
local e2= Effect.GlobalEffect() local e2= Effect.GlobalEffect()
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_UPDATE_ATTACK) e2:SetCode(EFFECT_UPDATE_ATTACK)
e2:SetRange(LOCATION_SZONE) e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e2:SetTargetRange(LOCATION_MZONE,0) e2:SetTarget(aux.AtkUpFilter)
e2:SetTarget(aux.AtkUpFilter) e2:SetValue(2000)
e2:SetValue(2000) Duel.RegisterEffect(e2,0)
Duel.RegisterEffect(e2,0) e:Reset()
e:Reset() end
end function aux.LPDecrease(e,tp,eg,ep,ev,re,r,rp)
function aux.LPDecrease(e,tp,eg,ep,ev,re,r,rp) if Duel.GetActivityCount(rp,ACTIVITY_SPSUMMON)>2 then
if Duel.GetActivityCount(rp,ACTIVITY_SPSUMMON)>2 then local lp = Duel.GetLP(rp)-800
local lp = Duel.GetLP(rp)-800 if lp < 0 then lp = 0 end
if lp < 0 then lp = 0 end Duel.SetLP(rp,lp)
Duel.SetLP(rp,lp) end
end end
end function aux.AtkUpFilter(e,c)
function aux.AtkUpFilter(e,c) local code = c:GetOriginalCode()
local code = c:GetOriginalCode() return code == 69884162 or code == 40044918 or code == 71564252 or code == 48092532 or code == 83986578
return code == 69884162 or code == 40044918 or code == 71564252 or code == 48092532 or code == 83986578
end end
\ No newline at end of file
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