Commit 72f98174 authored by 未闻皂名's avatar 未闻皂名

2022/6/20 新增:包裹圆柱

parent afdd41a2
Pipeline #14115 passed with stages
in 4 minutes and 48 seconds
No preview for this file type
local m=120222059
local cm=_G["c"..m]
cm.name="包裹圆柱"
function cm.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_ATKCHANGE)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_ATTACK_ANNOUNCE)
e1:SetCondition(cm.condition)
e1:SetOperation(cm.activate)
c:RegisterEffect(e1)
end
--Activate
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetAttacker()
local c=Duel.GetAttackTarget()
return tc:IsControler(1-tp) and tc:IsLevelAbove(1)
and c and c:IsControler(tp) and c:IsPosition(POS_FACEUP_ATTACK) and c:IsAttribute(ATTRIBUTE_LIGHT)
end
function cm.activate(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetAttacker()
if tc and tc:IsRelateToBattle() and tc:IsFaceup() then
local atk=tc:GetLevel()*-100
RD.AttachAtkDef(e,tc,atk,0,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
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