Commit 7de8f557 authored by 未闻皂名's avatar 未闻皂名

2025/2/21 新增:超可爱执行者·花草女 开拓

parent 29016b7e
Pipeline #33313 passed with stages
in 11 minutes and 3 seconds
No preview for this file type
......@@ -34,27 +34,26 @@ function RushDuel.AttachAttackNotChainTrapLimit(e, rp, tp)
return not (rp ~= tp and e:IsHasType(EFFECT_TYPE_ACTIVATE) and e:IsActiveType(TYPE_TRAP))
end
-- 永续效果: 战斗破坏怪兽送去墓地时, 造成效果伤害
function RushDuel.ContinuousBattleDestroyingDamage(card)
-- 永续效果: 战斗破坏怪兽送去墓地时的处理
function RushDuel.ContinuousBattleDestroyToGrave(card, condition, operation)
local e1 = Effect.CreateEffect(card)
e1:SetType(EFFECT_TYPE_SINGLE + EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_BATTLE_DESTROYING)
e1:SetLabel(card:GetOriginalCode())
e1:SetCondition(RushDuel.BattleDestroyingDamageCondition)
e1:SetOperation(RushDuel.BattleDestroyingDamageOperation)
e1:SetCondition(RushDuel.BattleDestroyToGraveCondition(condition))
e1:SetOperation(RushDuel.BattleDestroyToGraveOperation(operation))
card:RegisterEffect(e1)
return e1
end
function RushDuel.BattleDestroyingDamageCondition(e, tp, eg, ep, ev, re, r, rp)
local c = e:GetHandler()
local tc = c:GetBattleTarget()
return c:IsRelateToBattle() and tc:IsLocation(LOCATION_GRAVE) and tc:IsType(TYPE_MONSTER)
function RushDuel.BattleDestroyToGraveCondition(condition)
return function(e, tp, eg, ep, ev, re, r, rp)
local c = e:GetHandler()
local tc = c:GetBattleTarget()
return c:IsRelateToBattle() and tc:IsLocation(LOCATION_GRAVE) and tc:IsType(TYPE_MONSTER) and (not condition or condition(e, tp, eg, ep, ev, re, r, rp))
end
end
function RushDuel.BattleDestroyingDamageOperation(e, tp, eg, ep, ev, re, r, rp)
local tc = e:GetHandler():GetBattleTarget()
if tc then
local damage = RD.GetBaseAttackOnDestroy(tc)
Duel.Hint(HINT_CARD, 0, e:GetLabel())
Duel.Damage(1 - tp, damage, REASON_EFFECT)
function RushDuel.BattleDestroyToGraveOperation(operation)
return function(e, tp, eg, ep, ev, re, r, rp)
local tc = e:GetHandler():GetBattleTarget()
operation(e, tp, eg, ep, ev, re, r, rp, tc)
end
end
......@@ -9,18 +9,12 @@ function cm.initial_effect(c)
--Only Fusion Summon
RD.OnlyFusionSummon(c)
--Damage
local e1=RD.ContinuousBattleDestroyingDamage(c)
local e1=RD.ContinuousBattleDestroyToGrave(c,nil,cm.damop)
--Continuous Effect
RD.AddContinuousEffect(c,e1)
end
--Damage
function cm.damcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local bc=c:GetBattleTarget()
return c:IsRelateToBattle() and bc:IsLocation(LOCATION_GRAVE) and bc:IsType(TYPE_MONSTER)
end
function cm.damop(e,tp,eg,ep,ev,re,r,rp)
local tc=e:GetHandler():GetBattleTarget()
function cm.damop(e,tp,eg,ep,ev,re,r,rp,tc)
if tc then
local dam=RD.GetBaseAttackOnDestroy(tc)
Duel.Hint(HINT_CARD,0,m)
......
......@@ -17,7 +17,7 @@ function cm.initial_effect(c)
e1:SetValue(cm.atkval)
c:RegisterEffect(e1)
--Damage
local e2=RD.ContinuousBattleDestroyingDamage(c)
local e2=RD.ContinuousBattleDestroyToGrave(c,nil,cm.damop)
--Continuous Effect
RD.AddContinuousEffect(c,e1,e2)
end
......@@ -29,13 +29,7 @@ function cm.atkval(e,c)
return Duel.GetMatchingGroupCount(cm.filter,c:GetControler(),LOCATION_GRAVE,0,nil)*300
end
--Damage
function cm.damcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local bc=c:GetBattleTarget()
return c:IsRelateToBattle() and bc:IsLocation(LOCATION_GRAVE) and bc:IsType(TYPE_MONSTER)
end
function cm.damop(e,tp,eg,ep,ev,re,r,rp)
local tc=e:GetHandler():GetBattleTarget()
function cm.damop(e,tp,eg,ep,ev,re,r,rp,tc)
if tc then
local dam=RD.GetBaseAttackOnDestroy(tc)
Duel.Hint(HINT_CARD,0,m)
......
......@@ -15,12 +15,8 @@ function cm.initial_effect(c)
e2:SetType(EFFECT_TYPE_XMATERIAL)
c:RegisterEffect(e2)
--Damage
local e3=Effect.CreateEffect(c)
local e3=RD.ContinuousBattleDestroyToGrave(c,cm.damcon,cm.damop)
e3:SetType(EFFECT_TYPE_XMATERIAL+EFFECT_TYPE_CONTINUOUS)
e3:SetCode(EVENT_BATTLE_DESTROYING)
e3:SetCondition(cm.damcon)
e3:SetOperation(cm.damop)
c:RegisterEffect(e3)
--Continuous Effect
RD.AddContinuousEffect(c,e1,e2,e3)
end
......@@ -28,7 +24,7 @@ end
cm.indval=RD.ValueEffectIndesType(TYPE_MONSTER+TYPE_SPELL+TYPE_TRAP,TYPE_MONSTER+TYPE_SPELL+TYPE_TRAP)
--Damage
function cm.damcon(e,tp,eg,ep,ev,re,r,rp)
return aux.bdogcon(e) and RD.MaximumMode(e)
return RD.MaximumMode(e)
end
function cm.damop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,0,m)
......
local m=120283033
local list={120231037,120231032}
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])
--Contact Fusion
RD.EnableContactFusion(c,aux.Stringid(m,0))
--Atk & Def
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(0,LOCATION_MZONE)
e1:SetTarget(cm.downtg)
e1:SetValue(-600)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e2)
--Recover
local e3=RD.ContinuousBattleDestroyToGrave(c,nil,cm.recop)
--Continuous Effect
RD.AddContinuousEffect(c,e1,e2,e3)
end
--Atk & Def
function cm.downtg(e,c)
return c:IsFaceup() and not c:IsLevel(6)
end
--Recover
function cm.recop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,0,m)
Duel.Recover(tp,600,REASON_EFFECT)
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