Commit 541fcdba authored by Tachibana's avatar Tachibana

得得得得得

parent 68d5f313
Pipeline #12666 passed with stages
in 25 minutes and 20 seconds
No preview for this file type
......@@ -109,7 +109,7 @@ function cm.tdfilter(c)
end
function cm.spfilter1(c,el,e,tp)
return tama.tamas_isExistElement(c,TAMA_ELEMENT_LIFE)
and c:IsCanBeSpecialSummoned(e,0,tp,true,true) and (((not c:IsLocation(LOCATION_EXTRA) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0) or Duel.GetLocationCountFromEx(tp,tp,nil,c)>0)) and tama.tamas_isAllElementsNotAbove(tama.tamas_getElements(c),el)
and c:IsCanBeSpecialSummoned(e,0,tp,true,true) and c:IsType(TYPE_MONSTER) and (((not c:IsLocation(LOCATION_EXTRA) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0) or Duel.GetLocationCountFromEx(tp,tp,nil,c)>0)) and tama.tamas_isAllElementsNotAbove(tama.tamas_getElements(c),el)
end
--[[
function cm.spfilter1(c,el,e,tp)
......
......@@ -30,28 +30,33 @@ function cm.initial_effect(c)
c:RegisterEffect(e2)
end
--special summon rule
function cm.setfilter1(c)
function cm.setfilter1(c,tp)
local lv=c:GetLevel()
return c:IsFaceup() and c:IsSetCard(0x470) and c:IsAbleToGraveAsCost() and c:IsType(TYPE_TUNER)
and Duel.IsExistingMatchingCard(cm.setfilter2,tp,LOCATION_MZONE,0,1,lv)
and Duel.IsExistingMatchingCard(cm.setfilter2,tp,LOCATION_MZONE,0,1,nil,lv)
end
function cm.setfilter2(c,lv)
return c:IsAbleToGraveAsCost() and not (c:IsLevel(lv) or c:IsType(TYPE_TUNER))
return not c:IsType(TYPE_TUNER) and c:IsAbleToGraveAsCost() and not c:IsLevel(lv)
end
function cm.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
local g=Duel.GetMatchingGroup(cm.setfilter1,tp,LOCATION_MZONE,0,nil,tp)
return Duel.GetLocationCountFromEx(tp,tp,nil,c)>0
and ft>0 and Duel.IsExistingMatchingCard(cm.setfilter1,tp,LOCATION_MZONE,0,1,nil)
and ft>0 and g:GetCount()>0
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp,c)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g1=Duel.SelectMatchingCard(tp,cm.setfilter1,tp,LOCATION_MZONE,0,1,1,nil,c:GetLevel())
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g2=Duel.SelectMatchingCard(tp,cm.setfilter2,tp,LOCATION_MZONE,0,1,1,g1:GetFirst(),g1:GetFirst():GetLevel())
g1:Merge(g2)
Duel.SendtoGrave(g1,REASON_COST)
local g=Duel.GetMatchingGroup(cm.setfilter1,tp,LOCATION_MZONE,0,nil,tp)
if g:GetCount()>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g1=g:Select(tp,1,1,nil)
local lv=g1:GetFirst():GetLevel()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g2=Duel.SelectMatchingCard(tp,cm.setfilter2,tp,LOCATION_MZONE,0,1,1,g1:GetFirst(),lv)
g1:Merge(g2)
Duel.SendtoGrave(g1,REASON_COST)
end
end
--Effect 1
function cm.eqfilter(c,tp)
......
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