Commit 21012f26 authored by VanillaSalt's avatar VanillaSalt

fix

parent 0cf27e97
......@@ -38,7 +38,7 @@ function c60666820.filter(c)
return c:IsFaceup() and c:IsDestructable()
end
function c60666820.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsFaceup() end
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c60666820.filter(chkc) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>-1
and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false)
and Duel.IsExistingTarget(c60666820.filter,tp,LOCATION_MZONE,0,1,nil) end
......
......@@ -9,10 +9,12 @@ function c61692648.initial_effect(c)
end
function c61692648.atkop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SET_ATTACK_FINAL)
e1:SetValue(math.ceil(c:GetBaseAttack()/2))
e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+RESET_DAMAGE)
c:RegisterEffect(e1)
if c:IsRelateToEffect(e) and c:IsFaceup() then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SET_ATTACK_FINAL)
e1:SetValue(math.ceil(c:GetBaseAttack()/2))
e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+RESET_DAMAGE)
c:RegisterEffect(e1)
end
end
......@@ -3,7 +3,6 @@ function c65743242.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCode(EVENT_ATTACK_ANNOUNCE)
e1:SetCondition(c65743242.condition)
e1:SetTarget(c65743242.target)
......@@ -13,21 +12,20 @@ end
function c65743242.condition(e,tp,eg,ep,ev,re,r,rp)
return tp~=Duel.GetTurnPlayer()
end
function c65743242.filter(c,e)
return c:IsCanBeEffectTarget(e)
function c65743242.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
local ag=eg:GetFirst():GetAttackableTarget()
local at=Duel.GetAttackTarget()
return ag:IsExists(aux.TRUE,1,at)
end
end
function c65743242.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return false end
function c65743242.activate(e,tp,eg,ep,ev,re,r,rp)
local ag=eg:GetFirst():GetAttackableTarget()
local at=Duel.GetAttackTarget()
if chk==0 then return ag:IsExists(c65743242.filter,1,at,e) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
local g=ag:FilterSelect(tp,c65743242.filter,1,1,at,e)
Duel.SetTargetCard(g)
end
function c65743242.activate(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
local g=ag:Select(tp,1,1,at)
local tc=g:GetFirst()
if tc then
Duel.ChangeAttackTarget(tc)
end
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