Commit c7d16b18 authored by Tachibana's avatar Tachibana

tnndx

parent 44897aba
expansions/pics/81044027.jpg

76 KB | W: | H:

expansions/pics/81044027.jpg

167 KB | W: | H:

expansions/pics/81044027.jpg
expansions/pics/81044027.jpg
expansions/pics/81044027.jpg
expansions/pics/81044027.jpg
  • 2-up
  • Swipe
  • Onion skin
......@@ -5,6 +5,7 @@ function cm.initial_effect(c)
--link summon
c:EnableReviveLimit()
aux.AddLinkProcedure(c,nil,2,2)
aux.EnableUnionAttribute(c,1)
--equip
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
......@@ -24,13 +25,6 @@ function cm.initial_effect(c)
e2:SetTarget(cm.sptg)
e2:SetOperation(cm.spop)
c:RegisterEffect(e2)
--destroy sub
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_EQUIP)
e3:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e3:SetCode(EFFECT_DESTROY_SUBSTITUTE)
e3:SetValue(cm.repval)
c:RegisterEffect(e3)
--direct attack
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_EQUIP)
......@@ -38,19 +32,11 @@ function cm.initial_effect(c)
c:RegisterEffect(e4)
--damage reduce
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e5:SetRange(LOCATION_SZONE)
e5:SetCode(EVENT_PRE_BATTLE_DAMAGE)
e5:SetType(EFFECT_TYPE_EQUIP)
e5:SetCode(EFFECT_CHANGE_BATTLE_DAMAGE)
e5:SetCondition(cm.rdcon)
e5:SetOperation(cm.rdop)
e5:SetValue(cm.rval)
c:RegisterEffect(e5)
--eqlimit
local e6=Effect.CreateEffect(c)
e6:SetType(EFFECT_TYPE_SINGLE)
e6:SetCode(EFFECT_EQUIP_LIMIT)
e6:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e6:SetValue(1)
c:RegisterEffect(e6)
end
function cm.filter(c)
local ct1,ct2=c:GetUnionCount()
......@@ -87,16 +73,19 @@ end
function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
Duel.SpecialSummon(c,0,tp,tp,true,false,POS_FACEUP)
end
function cm.repval(e,re,r,rp)
return bit.band(r,REASON_BATTLE)~=0 or bit.band(r,REASON_EFFECT)~=0
if Duel.SpecialSummon(c,0,tp,tp,true,false,POS_FACEUP)==0 and Duel.GetLocationCount(tp,LOCATION_MZONE)<=0
and c:IsCanBeSpecialSummoned(e,0,tp,true,false) then
Duel.SendtoGrave(c,REASON_RULE)
end
end
function cm.rdcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler():GetEquipTarget()
return ep~=tp and c==Duel.GetAttacker() and Duel.GetAttackTarget()==nil
function cm.rdcon(e)
local c=e:GetHandler()
local tp=e:GetHandlerPlayer()
return Duel.GetAttackTarget()==nil
and c:GetEffectCount(EFFECT_DIRECT_ATTACK)<2 and Duel.GetFieldGroupCount(tp,0,LOCATION_MZONE)>0
end
function cm.rdop(e,tp,eg,ep,ev,re,r,rp)
Duel.ChangeBattleDamage(ep,e:GetHandler():GetEquipTarget():GetBaseAttack())
function cm.rval(e,damp)
if damp==1-e:GetHandlerPlayer() then
return e:GetHandler():GetBaseAttack()
else return -1 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