Commit 66d028cc authored by TanakaKotoha's avatar TanakaKotoha

888

parent 6b4d721a
No preview for this file type
...@@ -5,45 +5,51 @@ xpcall(function() require("expansions/script/c81000000") end,function() require( ...@@ -5,45 +5,51 @@ xpcall(function() require("expansions/script/c81000000") end,function() require(
function cm.initial_effect(c) function cm.initial_effect(c)
--special summon --special summon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetType(EFFECT_TYPE_IGNITION) e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_HAND) e1:SetRange(LOCATION_HAND)
e1:SetCondition(cm.spcon) e1:SetCondition(cm.hspcon)
e1:SetTarget(cm.sptg) e1:SetValue(SUMMON_VALUE_SELF)
e1:SetOperation(cm.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--to grave --spsummon limit
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_TOGRAVE) e2:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e2:SetType(EFFECT_TYPE_IGNITION) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e2:SetRange(LOCATION_MZONE) e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetCountLimit(1,m) e2:SetCondition(cm.hspcon2)
e2:SetTarget(cm.drtg) e2:SetOperation(cm.hspop)
e2:SetOperation(cm.drop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--to grave
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_TOGRAVE)
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,m)
e3:SetTarget(cm.drtg)
e3:SetOperation(cm.drop)
c:RegisterEffect(e3)
end end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp) function cm.hspcon(e,c)
return Duel.GetFieldGroupCount(tp,LOCATION_MZONE,0)==0 if c==nil then return true end
local tp=c:GetControler()
return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.GetFieldGroupCount(c:GetControler(),LOCATION_MZONE,0)==0
end end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.hspcon2(e,tp,eg,ep,ev,re,r,rp)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 return e:GetHandler():GetSummonType()==SUMMON_TYPE_SPECIAL+SUMMON_VALUE_SELF
and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end end
function cm.spop(e,tp,eg,ep,ev,re,r,rp) function cm.hspop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local e1=Effect.CreateEffect(e:GetHandler())
if not c:IsRelateToEffect(e) then return end e1:SetType(EFFECT_TYPE_FIELD)
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
local e3=Effect.CreateEffect(c) e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e3:SetType(EFFECT_TYPE_FIELD) e1:SetTargetRange(1,0)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e1:SetTarget(cm.splimit)
e3:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) e1:SetReset(RESET_PHASE+PHASE_END)
e3:SetTargetRange(1,0) Duel.RegisterEffect(e1,tp)
e3:SetTarget(cm.splimit)
e3:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e3,tp)
end end
function cm.splimit(e,c) function cm.splimit(e,c,sump,sumtype,sumpos,targetp,se)
return not c:IsRace(RACE_CYBERSE) return not c:IsRace(RACE_CYBERSE)
end end
function cm.filter(c) function cm.filter(c)
......
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