Commit 091670b4 authored by 聖園ミカ's avatar 聖園ミカ 🐟

vme50

parent 03d0fa8c
...@@ -24,34 +24,36 @@ end ...@@ -24,34 +24,36 @@ end
function cm.syncheck(g) function cm.syncheck(g)
return not g:IsExists(Card.IsSynchroType,1,nil,TYPE_TUNER) return not g:IsExists(Card.IsSynchroType,1,nil,TYPE_TUNER)
end end
function cm.filter(c,e,tp) function cm.filter(c,att)
return c:IsRace(RACE_REPTILE) and c:IsLevelBelow(4) and not c:IsType(TYPE_TUNER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE)
and not Duel.IsExistingMatchingCard(cm.filter1,tp,LOCATION_MZONE,0,1,c,c:GetAttribute())
end
function cm.filter1(c,att)
return c:IsFaceup() and c:IsAttribute(att) return c:IsFaceup() and c:IsAttribute(att)
end end
function cm.spfilter(c,e,tp)
return c:IsRace(RACE_REPTILE) and c:IsLevelBelow(4) and not c:IsType(TYPE_TUNER) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
and not Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_MZONE,0,1,nil,c:GetAttribute())
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end and Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE)
end end
function cm.spop(e,tp,eg,ep,ev,re,r,rp) function cm.spop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(cm.filter),tp,LOCATION_GRAVE,0,1,1,nil,e,tp) local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(cm.spfilter),tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
if g:GetCount()>0 then if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP_DEFENSE) Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP_DEFENSE)
end
end end
local e3=Effect.CreateEffect(e:GetHandler()) local c=e:GetHandler()
e3:SetType(EFFECT_TYPE_FIELD) local e1=Effect.CreateEffect(c)
e3:SetCode(EFFECT_CANNOT_BE_SYNCHRO_MATERIAL) e1:SetType(EFFECT_TYPE_FIELD)
e3:SetProperty(EFFECT_FLAG_SET_AVAILABLE+EFFECT_FLAG_IGNORE_IMMUNE) e1:SetCode(EFFECT_CANNOT_BE_SYNCHRO_MATERIAL)
e3:SetTargetRange(0xff,0xff) e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE+EFFECT_FLAG_IGNORE_IMMUNE)
e3:SetTarget(aux.TargetBoolFunction(Card.IsType,TYPE_TUNER)) e1:SetTargetRange(0xff,0xff)
e3:SetValue(cm.sumlimit) e1:SetTarget(aux.TargetBoolFunction(Card.IsType,TYPE_TUNER)
e3:SetReset(RESET_PHASE+PHASE_END) e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e3,tp) e1:SetValue(cm.sumlimit)
Duel.RegisterEffect(e1,tp)
end end
function cm.sumlimit(e,c) function cm.sumlimit(e,c)
if not c then return false end if not c then return 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