Commit 8b61cd2b authored by Tachibana's avatar Tachibana

ndyd

parent fd305ce7
Pipeline #4919 passed with stages
in 28 minutes and 8 seconds
......@@ -31,15 +31,14 @@ function cm.initial_effect(c)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,m+12)
e3:SetCondition(function(e,c)
if c==nil then return true end
e3:SetCondition(function(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(Card.IsSetCard,tp,LOCATION_MZONE,0,1,e:GetHandler(),0x388)
end)
e3:SetTarget(function(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) and chkc:IsType(TYPE_MONSTER) end
if chk==0 then return Duel.IsExistingTarget(nil,tp,0,LOCATION_MZONE,1,nil) end
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) and chkc:IsAbleToDeck() end
if chk==0 then return Duel.IsExistingTarget(Card.IsAbleToDeck,tp,0,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectTarget(tp,nil,tp,0,LOCATION_MZONE,1,1,nil)
local g=Duel.SelectTarget(tp,Card.IsAbleToDeck,tp,0,LOCATION_MZONE,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_TODECK,g,1,0,0)
end)
e3:SetOperation(function(e,tp,eg,ep,ev,re,r,rp)
......
......@@ -51,7 +51,7 @@ function cm.initial_effect(c)
e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetRange(LOCATION_GRAVE)
e4:SetCountLimit(1,m+14)
e4:SetCondition(function(e,c)
e4:SetCondition(function(e,tp,eg,ep,ev,re,r,rp)
if c==nil then return true end
return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(cm.cf4,tp,LOCATION_MZONE,0,1,nil)
......
......@@ -54,18 +54,18 @@ function cm.initial_effect(c)
c:RegisterEffect(e2)
--e3
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_TRIGGER_O+EFFECT_TYPE_SINGLE)
e3:SetCategory(CATEGORY_SPECIAL_SUMMON)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_DESTROYED)
e3:SetTarget(function(e,tp,eg,ep,ev,re,r,rp)
e3:SetTarget(function(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(Card.IsSetCard,tp,LOCATION_GRAVE,0,1,e:GetHandler(),0x388,e,tp) end
and Duel.IsExistingMatchingCard(cm.tf3,tp,LOCATION_GRAVE,0,1,e:GetHandler(),e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE)
end)
e3:SetOperation(function(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(Card.IsSetCard),tp,LOCATION_GRAVE,0,1,1,e:GetHandler(),0x388,e,tp)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(cm.tf3),tp,LOCATION_GRAVE,0,1,1,e:GetHandler(),e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
......@@ -81,5 +81,8 @@ end
function cm.cf2(c,lg)
return lg:IsContains(c)
end
--e3
function cm.tf3(c,e,tp)
return c:IsSetCard(0x388) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
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