Commit 31796ebe authored by Tachibana's avatar Tachibana

ndyd

parent e8e111f1
......@@ -16,6 +16,7 @@ function cm.initial_effect(c)
e2:SetCode(EVENT_SUMMON)
e2:SetCountLimit(1,m)
e2:SetCondition(cm.discon)
e2:SetCost(cm.discost)
e2:SetTarget(cm.distg)
e2:SetOperation(cm.disop)
c:RegisterEffect(e2)
......@@ -46,6 +47,14 @@ end
function cm.discon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetCurrentChain()==0
end
function cm.costfilter(c)
return (c:IsControler(tp) or c:IsFaceup()) and c:IsSetCard(0x381f) and not c:IsStatus(STATUS_BATTLE_DESTROYED) and c:IsLevel(4)
end
function cm.discost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckReleaseGroup(tp,cm.costfilter,1,nil) end
local sg=Duel.SelectReleaseGroup(tp,cm.costfilter,1,1,nil)
Duel.Release(sg,REASON_COST)
end
function cm.distg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_DISABLE_SUMMON,eg,eg:GetCount(),0,0)
......
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