Commit 6ed528f2 authored by 未闻皂名's avatar 未闻皂名

2025/3/22 新增:黑混沌之魔术师预组新卡,5周年包新卡

parent efd84506
Pipeline #34044 passed with stages
in 12 minutes and 37 seconds
No preview for this file type
local m=120280001
local list={120130000}
local cm=_G["c"..m]
cm.name="黑混沌之魔术师"
function cm.initial_effect(c)
--Change Code
RD.EnableChangeCode(c,list[1],LOCATION_GRAVE)
end
\ No newline at end of file
local m=120280006
local list={120280030}
local cm=_G["c"..m]
cm.name="混沌翼龙"
function cm.initial_effect(c)
RD.AddCodeList(c,list)
--Set
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_GRAVE_ACTION)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCondition(cm.condition)
e1:SetTarget(cm.target)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
-- Draw Check
if not cm.global_check then
cm.global_check=true
local ge1=Effect.CreateEffect(c)
ge1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge1:SetCode(EVENT_DRAW)
ge1:SetOperation(cm.regop)
Duel.RegisterEffect(ge1,0)
end
end
--Set
function cm.setfilter(c)
return c:IsCode(list[1]) and c:IsSSetable()
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return RD.IsSummonTurn(c) or RD.IsSpecialSummonTurn(c)
end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0
and Duel.IsExistingMatchingCard(cm.setfilter,tp,LOCATION_GRAVE,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,nil,1,tp,LOCATION_GRAVE)
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
if RD.SelectAndSet(aux.NecroValleyFilter(cm.setfilter),tp,LOCATION_GRAVE,0,1,1,nil,e)~=0 then
if Duel.GetFlagEffect(tp,m)==0 then
RD.CanDraw(aux.Stringid(m,1),tp,1)
end
end
end
-- Draw Check
function cm.regop(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase()
if ph==PHASE_MAIN1 or ph==PHASE_MAIN2 then
Duel.RegisterFlagEffect(rp,m,RESET_PHASE+PHASE_MAIN1+PHASE_MAIN2,0,1)
end
end
\ No newline at end of file
local m=120280010
local cm=_G["c"..m]
cm.name="祭殿探求者"
function cm.initial_effect(c)
--Special Summon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCost(cm.cost)
e1:SetTarget(cm.target)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
end
--Special Summon
function cm.costfilter(c)
return c:IsType(TYPE_MONSTER) and c:IsAbleToDeckOrExtraAsCost()
end
function cm.spfilter(c,e,tp)
return c:IsType(TYPE_RITUAL) and c:IsLevel(7) and c:IsAttack(2300) and RD.IsDefense(c,2500)
and RD.IsCanBeSpecialSummoned(c,e,tp,POS_FACEUP)
end
function cm.costcheck(g,e,tp)
return Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_GRAVE,0,1,g,e,tp)
end
cm.cost=RD.CostSendGraveSubToDeck(cm.costfilter,cm.costcheck,2,2)
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetMZoneCount(tp)>0
and Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_HAND,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND)
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
RD.SelectAndSpecialSummon(aux.NecroValleyFilter(cm.spfilter),tp,LOCATION_GRAVE,0,1,1,nil,e,POS_FACEUP)
end
\ No newline at end of file
local m=120277101
local list={120277102}
local m=120280030
local list={120280001}
local cm=_G["c"..m]
cm.name="探索业力仪式"
cm.name="混沌-黑魔术的仪式"
function cm.initial_effect(c)
RD.AddCodeList(c,list)
--Activate
local e1=RD.CreateRitualEffect(c,RITUAL_LEVEL_GREATER,cm.matfilter,cm.spfilter)
local e1=RD.CreateRitualEffect(c,RITUAL_LEVEL_GREATER,nil,cm.spfilter)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
c:RegisterEffect(e1)
end
--Activate
function cm.matfilter(c)
return c:IsFaceup() and c:IsOnField()
end
function cm.spfilter(c)
return c:IsCode(list[1])
end
\ No newline at end of file
local m=120283038
local list={120252001}
local cm=_G["c"..m]
cm.name="究极爆风弹"
function cm.initial_effect(c)
RD.AddCodeList(c,list)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCondition(cm.condition)
e1:SetTarget(cm.target)
e1:SetOperation(cm.activate)
c:RegisterEffect(e1)
end
--Activate
function cm.filter(c)
return c:IsFaceup() and c:IsCode(list[1])
and (RD.IsCanAttachAttackNotChainTrap(c) or RD.IsCanAttachExtraAttackMonster(c,2))
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsAbleToEnterBP()
end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_MZONE,0,1,nil) end
end
function cm.activate(e,tp,eg,ep,ev,re,r,rp)
RD.SelectAndDoAction(aux.Stringid(m,1),cm.filter,tp,LOCATION_MZONE,0,1,1,nil,function(g)
local tc=g:GetFirst()
RD.AttachAttackNotChainTrap(e,m,tc,aux.Stringid(m,2),RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
RD.AttachExtraAttackMonster(e,tc,2,aux.Stringid(m,3),RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
end)
end
\ No newline at end of file
local m=120277102
local m=120283044
local cm=_G["c"..m]
cm.name="穿越侍·探索业力线性海牛侍"
cm.name="魔导异想天开"
function cm.initial_effect(c)
--Ritual
RD.AddRitualProcedure(c)
--Atk Down
--Special Summon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_ATKCHANGE)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_GRAVE_SPSUMMON)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCondition(cm.condition)
e1:SetCost(cm.cost)
e1:SetTarget(cm.target)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
end
--Cannot Activate
--Special Summon
function cm.spfilter(c,e,tp)
return (c:IsAttack(100) or RD.IsDefense(c,100)) and c:IsRace(RACE_PSYCHO)
and RD.IsCanBeSpecialSummoned(c,e,tp,POS_FACEUP)
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsSummonType(SUMMON_TYPE_RITUAL) and RD.IsSpecialSummonTurn(c)
return RD.IsSummonTurn(e:GetHandler())
end
cm.cost=RD.CostSendDeckTopToGrave(1)
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsFaceup,tp,0,LOCATION_MZONE,1,nil) end
if chk==0 then return Duel.GetMZoneCount(tp)>0
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)
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,0,LOCATION_MZONE,nil)
local ct=c:GetMaterialCount()
local atk=ct*-1000
g:ForEach(function(tc)
RD.AttachAtkDef(e,tc,atk,0,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
end)
if c:IsFaceup() and c:IsRelateToEffect(e) and ct>1 then
RD.AttachExtraAttackMonster(e,c,ct-1,aux.Stringid(m,ct-1),RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
end
RD.SelectAndSpecialSummon(aux.NecroValleyFilter(cm.spfilter),tp,LOCATION_GRAVE,0,1,1,nil,e,POS_FACEUP)
if Duel.GetFlagEffect(tp,m)~=0 then return end
RD.CreateCannotSummonEffect(e,aux.Stringid(m,1),cm.sumlimit,tp,1,0,RESET_PHASE+PHASE_END)
Duel.RegisterFlagEffect(tp,m,RESET_PHASE+PHASE_END,0,1)
end
function cm.sumlimit(e,c,sump,sumtype,sumpos,targetp,se)
return c:IsLevel(2)
end
\ No newline at end of file
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