Commit cd37ac84 authored by 未闻皂名's avatar 未闻皂名

2022/02/20 新增:魔导龙骑士 - 七星齿车戒

parent a2f48855
No preview for this file type
No preview for this file type
local m=120208037
local list={120105001,120110001}
local cm=_G["c"..m]
cm.name="魔导龙骑士 - 七星齿车戒"
function cm.initial_effect(c)
aux.AddCodeList(c,list[1],list[2])
--Fusion Material
aux.AddFusionProcCode2(c,list[1],list[2],true,true)
--Select Effect
local e1=RushDuel.BaseSelectEffect(c,aux.Stringid(m,1),cm.eff1con,cm.eff1op,aux.Stringid(m,2),cm.eff2con,cm.eff2op)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_ATKCHANGE+CATEGORY_DESTROY)
e1:SetCondition(cm.condition)
e1:SetCost(cm.cost)
c:RegisterEffect(e1)
end
--Select Effect
function cm.confilter(c)
return c:IsFaceup() and c:IsLevelAbove(7)
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cm.confilter,tp,0,LOCATION_MZONE,1,nil)
end
cm.cost=RD.CostSendDeckTopToGrave(1)
--Atk Up
function cm.filter(c)
return c:IsType(TYPE_MONSTER)
end
function cm.eff1con(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_GRAVE,0,1,nil)
end
function cm.eff1op(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsFaceup() and c:IsRelateToEffect(e) then
local g=Duel.GetMatchingGroup(cm.filter,tp,LOCATION_GRAVE,0,nil)
local atk=g:GetClassCount(Card.GetRace)*700
RD.AttachAtkDef(e,c,atk,0,RESET_EVENT+RESETS_STANDARD+RESET_DISABLE+RESET_PHASE+PHASE_END)
RD.AttachExtraAttackMonster(e,c,1,aux.Stringid(m,3),RESET_EVENT+RESETS_STANDARD+RESET_DISABLE+RESET_PHASE+PHASE_END)
end
end
--Destroy
function cm.eff2con(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
end
function cm.eff2op(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil)
if g:GetCount()>0 then
Duel.Destroy(g,REASON_EFFECT)
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