Commit 6276beb0 authored by 未闻皂名's avatar 未闻皂名

2024/1/24 新增:接合科技新卡

parent f1ca01b9
No preview for this file type
...@@ -278,11 +278,11 @@ function RushDuel.ExecuteFusionSummon(e, tp, ce, mg1, mg2, sg1, sg2, gc, chkf, m ...@@ -278,11 +278,11 @@ function RushDuel.ExecuteFusionSummon(e, tp, ce, mg1, mg2, sg1, sg2, gc, chkf, m
if #mat < 2 then if #mat < 2 then
goto cancel goto cancel
end end
fc:SetMaterial(mat)
local cg = mat:Filter(RushDuel.ConfirmCardFilter, nil) local cg = mat:Filter(RushDuel.ConfirmCardFilter, nil)
if #cg > 0 then if #cg > 0 then
Duel.ConfirmCards(1 - tp, cg) Duel.ConfirmCards(1 - tp, cg)
end end
fc:SetMaterial(mat)
mat_move(mat) mat_move(mat)
Duel.BreakEffect() Duel.BreakEffect()
Duel.SpecialSummon(fc, SUMMON_TYPE_FUSION, tp, tp, false, false, POS_FACEUP) Duel.SpecialSummon(fc, SUMMON_TYPE_FUSION, tp, tp, false, false, POS_FACEUP)
......
local m=120257017
local list={120257041}
local cm=_G["c"..m]
cm.name="接合科技嵌套骑士坦克"
function cm.initial_effect(c)
RD.AddCodeList(c,list)
--Special Summon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_GRAVE_SPSUMMON)
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.spfilter(c,e,tp)
return c:IsLevel(7,8) and c:IsAttribute(ATTRIBUTE_DARK) and RD.IsCanBeSpecialSummoned(c,e,tp,POS_FACEUP)
end
cm.cost=RD.CostSendHandToDeck(Card.IsAbleToDeckAsCost,2,2,false)
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_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)
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.CreateCannotSpecialSummonEffect(e,aux.Stringid(m,1),cm.sumlimit,tp,1,0,RESET_PHASE+PHASE_END)
RD.CreateCannotActivateEffect(e,aux.Stringid(m,2),cm.aclimit,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 not c:IsCode(list[1])
end
function cm.aclimit(e,re,tp)
local tc=re:GetHandler()
return re:IsActiveType(TYPE_MONSTER) and tc:IsAttribute(ATTRIBUTE_DARK)
end
\ No newline at end of file
local m=120257018
local list={120257017}
local cm=_G["c"..m]
cm.name="暗冥接合科技暴君"
function cm.initial_effect(c)
RD.AddCodeList(c,list)
Duel.AddCustomActivityCounter(m,ACTIVITY_CHAIN,cm.chainfilter)
--To Hand
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)
end
function cm.chainfilter(re,tp,cid)
return not re:IsActiveType(TYPE_MONSTER)
end
--To Hand
function cm.filter(c)
return c:IsLevel(7,8) and c:IsAttribute(ATTRIBUTE_DARK) and c:IsAbleToHand()
end
function cm.check(g)
return g:GetClassCount(Card.GetRace)==g:GetCount()
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetCustomActivityCount(m,tp,ACTIVITY_CHAIN)==0
end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
local g=Duel.GetMatchingGroup(cm.filter,tp,LOCATION_GRAVE,0,nil)
if chk==0 then return g:CheckSubGroup(cm.check,2,2) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,2,0,0)
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
RD.SelectGroupAndDoAction(HINTMSG_ATOHAND,aux.NecroValleyFilter(cm.filter),cm.check,tp,LOCATION_GRAVE,0,2,2,nil,function(g)
if RD.SendToHandAndExists(g,1-tp) and c:IsFaceup() and c:IsRelateToEffect(e) then
Duel.BreakEffect()
RD.ChangeCode(e,c,list[1],RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
end
end)
end
\ No newline at end of file
local m=120257041
local list={120257017,120222025,120249023}
local cm=_G["c"..m]
cm.name="接合科技三重恐龙基地"
function cm.initial_effect(c)
RD.AddCodeList(c,list)
--Fusion Material
RD.AddFusionProcedure(c,list[1],cm.matfilter,cm.matfilter)
--Pierce
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_PIERCE)
c:RegisterEffect(e1)
--Attack Thrice
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_EXTRA_ATTACK)
e2:SetCondition(cm.atkcon)
e2:SetValue(2)
c:RegisterEffect(e2)
--Fusion Success
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e3:SetCode(EVENT_SPSUMMON_SUCCESS)
e3:SetCondition(cm.regcon)
e3:SetOperation(cm.regop)
c:RegisterEffect(e3)
--Continuous Effect
RD.AddContinuousEffect(c,e1,e2)
end
--Fusion Material
cm.unspecified_funsion=true
function cm.matfilter(c)
return not c:IsRace(RACE_MACHINE)
end
--Attack Thrice
function cm.atkcon(e)
local c=e:GetHandler()
return RD.IsSpecialSummonTurn(c) and c:GetFlagEffect(20257041)~=0
end
--Fusion Success
function cm.regfilter(c,code)
return c:IsOriginalCodeRule(code) and c:IsLocation(LOCATION_GRAVE)
end
function cm.regcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_FUSION)
end
function cm.regop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local g=c:GetMaterial()
if g:IsExists(cm.regfilter,1,nil,list[2]) and g:IsExists(cm.regfilter,1,nil,list[3]) then
c:RegisterFlagEffect(20257041,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,0,1)
end
end
\ No newline at end of file
local m=120257058
local cm=_G["c"..m]
cm.name="接合科技接合"
function cm.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_POSITION+CATEGORY_SPECIAL_SUMMON+CATEGORY_FUSION_SUMMON)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCost(cm.cost)
e1:SetTarget(cm.target)
e1:SetOperation(cm.activate)
c:RegisterEffect(e1)
end
--Activate
function cm.costfilter(c)
return c:IsType(TYPE_MONSTER) and c:IsAbleToDeckOrExtraAsCost()
end
function cm.filter(c)
return RD.IsCanChangePosition(c) and (not c:IsPosition(POS_FACEUP_ATTACK) or c:IsCanTurnSet())
end
function cm.spfilter(c)
return c:IsLevelBelow(9) and c:IsAttribute(ATTRIBUTE_EARTH+ATTRIBUTE_DARK) and c:IsRace(RACE_MACHINE)
end
cm.cost=RD.CostSendGraveToDeck(cm.costfilter,2,2)
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.filter,tp,0,LOCATION_MZONE,1,nil) end
local g=Duel.GetMatchingGroup(cm.filter,tp,0,LOCATION_MZONE,nil)
Duel.SetOperationInfo(0,CATEGORY_POSITION,g,1,0,0)
end
function cm.activate(e,tp,eg,ep,ev,re,r,rp)
RD.SelectAndDoAction(HINTMSG_POSCHANGE,cm.filter,tp,0,LOCATION_MZONE,1,1,nil,function(g)
local tc=g:GetFirst()
local pos=POS_FACEUP_ATTACK+POS_FACEDOWN_DEFENSE
if tc:IsPosition(POS_FACEUP_ATTACK) then
pos=POS_FACEDOWN_DEFENSE
elseif tc:IsFacedown() or not tc:IsCanTurnSet() then
pos=POS_FACEUP_ATTACK
end
pos=Duel.SelectPosition(tp,tc,pos)
if RD.ChangePosition(tc,pos)~=0 then
RD.CanFusionSummon(aux.Stringid(m,1),nil,cm.spfilter,nil,0,0,nil,RD.FusionToGrave,e,tp,true)
end
end)
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