Commit 0aac38e5 authored by 未闻皂名's avatar 未闻皂名

2024/12/21 新增:元素英雄 涡流翼侠,融合召唤调整

parent 06df4796
Pipeline #31905 passed with stages
in 9 minutes and 29 seconds
No preview for this file type
-- Rush Duel 融合
RushDuel = RushDuel or {}
-- 当前的融合效果
RushDuel.CurrentFusionEffect = nil
-- 内部方法: 生成融合素材的函数
function RushDuel._private_make_fusion_material(card, sub, insf, mat, codes, ...)
......@@ -257,8 +259,11 @@ function RushDuel.FusionMaterialFilter(c, filter, e)
end
-- 融合效果 - 融合召唤的怪兽过滤
function RushDuel.FusionSpecialSummonFilter(c, e, tp, m, f, gc, chkf, filter)
return c:IsType(TYPE_FUSION) and (not filter or filter(c, e, tp, m, f, chkf)) and (not f or f(c)) and c:IsCanBeSpecialSummoned(e, SUMMON_TYPE_FUSION, tp, false, false) and
c:CheckFusionMaterial(m, gc, chkf)
RushDuel.CurrentFusionEffect = e
local res = c:IsType(TYPE_FUSION) and (not filter or filter(c, e, tp, m, f, chkf)) and (not f or f(c)) and c:IsCanBeSpecialSummoned(e, SUMMON_TYPE_FUSION, tp, false, false) and
c:CheckFusionMaterial(m, gc, chkf)
RushDuel.CurrentFusionEffect = nil
return res
end
-- 融合效果 - 确认素材过滤
function RushDuel.ConfirmCardFilter(c)
......@@ -328,7 +333,9 @@ function RushDuel.ExecuteFusionSummon(e, tp, list, chkf, gc, mat_move)
data = aux.SelectFromOptions(tp, table.unpack(options))
end
local ce, mg = data[1], data[2]
RushDuel.CurrentFusionEffect = e
local mat = Duel.SelectFusionMaterial(tp, fc, mg, gc, chkf)
RushDuel.CurrentFusionEffect = nil
if #mat < 2 then
goto cancel
end
......
......@@ -21,7 +21,7 @@ function cm.spfilter(c)
return c:IsAttribute(ATTRIBUTE_WIND) and c:IsRace(RACE_WARRIOR)
end
function cm.exfilter(c)
return c:IsAbleToDeck()
return c:IsCanBeFusionMaterial() and c:IsAbleToDeck()
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cm.confilter,tp,LOCATION_GRAVE,0,5,nil)
......
......@@ -20,6 +20,6 @@ function cm.spfilter(c)
end
function cm.costfilter(c,e,tp)
return c:IsFaceup() and c:IsRace(RACE_GALAXY) and c:IsAbleToGraveAsCost()
and RD.IsCanFusionSummon(e,tp,cm.matfilter,cm.spfilter,nil,0,0,nil,true,c)
and RD.IsCanFusionSummon(e,tp,cm.matfilter,cm.spfilter,nil,0,0,nil,true,false,c)
end
cm.cost=RD.CostSendMZoneToGrave(cm.costfilter,1,1,true)
\ No newline at end of file
......@@ -31,17 +31,19 @@ function cm.operation(e,tp,eg,ep,ev,re,r,rp)
local ac=Duel.GetChainInfo(0,CHAININFO_TARGET_PARAM)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then
c:SetHint(CHINT_CARD,ac)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,1))
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_ADD_FUSION_CODE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CLIENT_HINT)
e1:SetLabel(ac)
e1:SetValue(cm.value)
e1:SetCondition(cm.fucon)
e1:SetValue(ac)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
c:RegisterEffect(e1)
end
end
function cm.value(e,c)
return e:GetLabel()
function cm.fucon(e)
local fe=RD.CurrentFusionEffect
return fe and fe:GetHandler():IsCode(list[1])
end
\ No newline at end of file
local m=120277065
local list={120263005,120263008}
local cm=_G["c"..m]
cm.name="元素英雄 涡流翼侠"
function cm.initial_effect(c)
RD.AddCodeList(c,list)
--Fusion Material
RD.AddFusionProcedure(c,list[1],list[2])
--Only Fusion Summon
RD.OnlyFusionSummon(c)
--Fusion Summon
local e1=RD.CreateFusionEffect(c,cm.matfilter,cm.spfilter,cm.exfilter,LOCATION_GRAVE,0,nil,RD.FusionToDeck)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_FUSION_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCondition(cm.condition)
c:RegisterEffect(e1)
end
--Fusion Summon
function cm.matfilter(c)
return false
end
function cm.spfilter(c)
return c:IsHasEffect(EFFECT_ONLY_FUSION_SUMMON) and c:IsLevel(6,7,8) and c:IsRace(RACE_WARRIOR)
end
function cm.exfilter(c)
return c:IsCanBeFusionMaterial() and c:IsAbleToDeck()
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return RD.IsSpecialSummonTurn(e:GetHandler())
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