Commit bb4f1d09 authored by salix5's avatar salix5

fix

parent 211e9f3b
......@@ -16,14 +16,13 @@ end
function c79997591.cbop(e,tp,eg,ep,ev,re,r,rp)
local at=Duel.GetAttacker()
local bt=Duel.GetAttackTarget()
if not (bt:IsRelateToBattle() and bt:IsControler(tp)) then return end
if at:IsAttackable() and not at:IsStatus(STATUS_ATTACK_CANCELED) and Duel.Damage(1-tp,bt:GetAttack(),REASON_EFFECT)>0 then
Duel.ChangeAttackTarget(nil)
end
if bt:IsRelateToBattle() and bt:IsControler(tp) then
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DIRECT_ATTACK)
e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+RESET_END+RESET_SELF_TURN)
bt:RegisterEffect(e1)
end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DIRECT_ATTACK)
e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+RESET_END+RESET_SELF_TURN)
bt:RegisterEffect(e1)
end
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