Commit d180be66 authored by 未闻皂名's avatar 未闻皂名

2023/3/17 新增:大霸道王的新卡

parent 2592fc32
No preview for this file type
local m=120239001
local cm=_G["c"..m]
cm.name="超魔轨道 大霸道王[L]"
function cm.initial_effect(c)
--To Deck (Normal)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCondition(cm.condition)
e1:SetTarget(cm.target)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
--To Deck (MaximumMode)
local e2=e1:Clone()
e2:SetDescription(aux.Stringid(m,2))
e2:SetType(EFFECT_TYPE_IGNITION+EFFECT_TYPE_XMATERIAL)
e2:SetLabel(m)
c:RegisterEffect(e2)
end
--To Deck
function cm.filter(c)
return c:IsType(TYPE_MONSTER) and c:IsAbleToDeck()
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetFieldGroupCount(tp,LOCATION_DECK,0)>9 and Duel.GetFieldGroupCount(tp,LOCATION_MZONE,0)<=1
end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_GRAVE,LOCATION_GRAVE,3,nil) end
local g=Duel.GetMatchingGroup(cm.filter,tp,LOCATION_GRAVE,LOCATION_GRAVE,nil)
Duel.SetOperationInfo(0,CATEGORY_TODECK,g,3,0,0)
if RD.IsMaximumMode(e:GetHandler()) then
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
end
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
RD.SelectAndDoAction(HINTMSG_TODECK,aux.NecroValleyFilter(cm.filter),tp,LOCATION_GRAVE,LOCATION_GRAVE,3,3,nil,function(g)
if RD.SendToDeckAndExists(g) and RD.IsMaximumMode(c)
and c:IsAbleToDeck() and Duel.IsPlayerCanDraw(tp,3) and Duel.SelectYesNo(tp,aux.Stringid(m,1)) then
if RD.SendToDeckAndExists(c) then
Duel.ShuffleDeck(tp)
Duel.Draw(tp,3,REASON_EFFECT)
end
end
end)
end
\ No newline at end of file
local m=120239002
local list={120239001,120239003}
local cm=_G["c"..m]
cm.name="超魔轨道 大霸道王"
function cm.initial_effect(c)
RD.AddCodeList(c,list)
--Maximum Summon
RD.AddMaximumProcedure(c,3500,list[1],list[2])
--Atk Up
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_ATKCHANGE)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCost(cm.cost)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
end
--Atk Up
cm.indval=RD.ValueEffectIndesType(0,TYPE_MONSTER+TYPE_SPELL+TYPE_TRAP)
cm.cost=RD.CostSendDeckTopToGrave(1)
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsFaceup() and c:IsRelateToEffect(e) then
RD.AttachAtkDef(e,c,600,0,RESET_EVENT+RESETS_STANDARD+RESET_DISABLE+RESET_PHASE+PHASE_END)
if RD.IsMaximumMode(c) then
RD.AttachEffectIndes(e,c,cm.indval,aux.Stringid(m,1),RESET_EVENT+RESETS_STANDARD+RESET_DISABLE+RESET_PHASE+PHASE_END+RESET_OPPO_TURN)
end
end
end
\ No newline at end of file
local m=120239003
local cm=_G["c"..m]
cm.name="超魔轨道 大霸道王[R]"
function cm.initial_effect(c)
--Damage (Normal)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_DAMAGE)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetRange(LOCATION_MZONE)
e1:SetCost(cm.cost)
e1:SetTarget(cm.target)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
--Damage (MaximumMode)
local e2=e1:Clone()
e2:SetDescription(aux.Stringid(m,1))
e2:SetType(EFFECT_TYPE_IGNITION+EFFECT_TYPE_XMATERIAL)
e2:SetLabel(m)
c:RegisterEffect(e2)
end
--Atk & Def Down
function cm.costfilter(c)
return c:IsType(TYPE_MONSTER) and c:IsAbleToGraveAsCost()
end
cm.cost=RD.CostSendHandToGrave(cm.costfilter,1,1,function(g)
return g:GetFirst():GetLevel()
end)
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
RD.TargetDamage(1-tp,500)
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
if RD.Damage()~=0 and RD.IsMaximumMode(e:GetHandler()) then
Duel.Damage(1-tp,e:GetLabel()*100,REASON_EFFECT)
end
end
\ No newline at end of file
local m=120239004
local cm=_G["c"..m]
cm.name="超魔辉兽 大霸道王[L]"
function cm.initial_effect(c)
--Atk Up
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_XMATERIAL)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetCondition(RD.MaximumMode)
e1:SetValue(cm.atkval)
c:RegisterEffect(e1)
--Pierce
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,1))
e2:SetType(EFFECT_TYPE_XMATERIAL)
e2:SetCode(EFFECT_PIERCE)
e2:SetProperty(EFFECT_FLAG_CLIENT_HINT)
e2:SetCondition(cm.prccon)
c:RegisterEffect(e2)
end
--Atk Up
function cm.atkval(e,c)
return Duel.GetFieldGroupCount(c:GetControler(),0,LOCATION_MZONE)*500
end
--Pierce
function cm.prccon(e)
return RD.MaximumMode(e)
and Duel.IsExistingMatchingCard(Card.IsType,e:GetHandlerPlayer(),LOCATION_GRAVE,0,10,nil,TYPE_MONSTER)
end
\ No newline at end of file
local m=120239005
local list={120217001,120217003}
local cm=_G["c"..m]
cm.name="超魔辉兽 大霸道王"
function cm.initial_effect(c)
RD.AddCodeList(c,list)
--Maximum Summon
RD.AddMaximumProcedure(c,3500,list[1],list[2])
--Indes
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_MZONE)
e1:SetCondition(RD.MaximumMode)
e1:SetValue(cm.indval)
c:RegisterEffect(e1)
end
--Indes
cm.indval=RD.ValueEffectIndesType(0,TYPE_TRAP)
\ No newline at end of file
local m=120239006
local cm=_G["c"..m]
cm.name="超魔辉兽 大霸道王[R]"
function cm.initial_effect(c)
--Activate Limit
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,1))
e1:SetType(EFFECT_TYPE_XMATERIAL+EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_ACTIVATE)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT)
e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(0,1)
e1:SetCondition(cm.actcon)
e1:SetValue(cm.actlimit)
c:RegisterEffect(e1)
--Special Summon Check
if not cm.global_check then
cm.global_check=true
local ge=Effect.CreateEffect(c)
ge:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge:SetCode(EVENT_SPSUMMON_SUCCESS)
ge:SetOperation(cm.spcheckop)
Duel.RegisterEffect(ge,0)
end
end
--Activate Limit
function cm.actcon(e)
return RD.MaximumMode(e) and Duel.GetFlagEffect(1-e:GetHandlerPlayer(),m)~=0
end
function cm.actlimit(e,re,tp)
local tc=re:GetHandler()
return tc:IsLocation(LOCATION_MZONE) and tc:IsFaceup() and tc:IsLevelBelow(10) and re:IsActiveType(TYPE_MONSTER)
end
--Special Summon Check
function cm.spfilter(c,tp)
return c:IsSummonPlayer(tp) and c:IsFaceup() and c:IsLevelAbove(5)
end
function cm.spcheckop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetFlagEffect(0,m)==0 and eg:IsExists(cm.spfilter,1,nil,0) then
Duel.RegisterFlagEffect(0,m,RESET_PHASE+PHASE_END,0,1)
end
if Duel.GetFlagEffect(1,m)==0 and eg:IsExists(cm.spfilter,1,nil,1) then
Duel.RegisterFlagEffect(1,m,RESET_PHASE+PHASE_END,0,1)
end
end
\ No newline at end of file
local m=120239007
local cm=_G["c"..m]
cm.name="超魔旗舰 大霸道王[L]"
function cm.initial_effect(c)
--Damage
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_DAMAGE+CATEGORY_TOHAND+CATEGORY_GRAVE_ACTION)
e1:SetType(EFFECT_TYPE_XMATERIAL+EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetLabel(m)
e1:SetCondition(RD.MaximumMode)
e1:SetCost(cm.cost)
e1:SetTarget(cm.target)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
end
--Damage
function cm.costfilter(c,e,tp)
return c:IsType(TYPE_MONSTER) and c:IsAbleToDeckOrExtraAsCost()
and Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_GRAVE,0,1,c)
end
function cm.filter(c)
return c:IsLevelAbove(1)
end
cm.cost=RD.CostSendGraveToDeck(cm.costfilter,1,1)
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,100)
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
RD.SelectAndDoAction(aux.Stringid(m,1),aux.NecroValleyFilter(cm.filter),tp,LOCATION_GRAVE,0,1,1,nil,function(g)
local tc=g:GetFirst()
if Duel.Damage(1-tp,tc:GetLevel()*100,REASON_EFFECT)~=0
and tc:IsAbleToHand()
and Duel.SelectYesNo(tp,aux.Stringid(m,2)) then
RD.SendToHandAndExists(tc,1-tp)
end
end)
end
\ No newline at end of file
local m=120239008
local list={120151001,120151003}
local cm=_G["c"..m]
cm.name="超魔旗舰 大霸道王"
function cm.initial_effect(c)
RD.AddCodeList(c,list)
--Maximum Summon
RD.AddMaximumProcedure(c,3500,list[1],list[2])
--Special Summon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCondition(RD.MaximumMode)
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 RD.IsCanBeSpecialSummoned(c,e,tp,POS_FACEUP)
end
function cm.desfilter(c)
return c:IsType(TYPE_SPELL+TYPE_TRAP)
end
cm.cost=RD.CostSendSelfToGrave()
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetMZoneCount(tp,e:GetHandler())>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)
if RD.SelectAndSpecialSummon(cm.spfilter,tp,LOCATION_HAND,0,1,2,nil,e,POS_FACEUP)~=0 then
RD.CanSelectAndDoAction(aux.Stringid(m,1),HINTMSG_DESTROY,cm.desfilter,tp,0,LOCATION_ONFIELD,1,1,nil,function(g)
Duel.BreakEffect()
Duel.Destroy(g,REASON_EFFECT)
end)
end
end
\ No newline at end of file
local m=120239009
local cm=_G["c"..m]
cm.name="超魔旗舰 大霸道王[R]"
function cm.initial_effect(c)
--Multiple Attack
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_ATKCHANGE)
e1:SetType(EFFECT_TYPE_XMATERIAL+EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetLabel(m)
e1:SetCondition(RD.MaximumMode)
e1:SetCost(cm.cost)
e1:SetTarget(cm.target)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
end
--Multiple Attack
cm.cost=RD.CostSendDeckTopToGrave(2)
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsFaceup() and c:IsRelateToEffect(e) then
local reset=RESET_EVENT+RESETS_STANDARD+RESET_DISABLE+RESET_PHASE+PHASE_END
RD.AttachAtkDef(e,c,-1000,0,reset)
RD.AttachCannotDirectAttack(e,c,aux.Stringid(m,1),reset)
RD.AttachAttackAll(e,c,1,aux.Stringid(m,2),reset)
RD.AttachPierce(e,c,aux.Stringid(m,3),reset)
end
end
\ No newline at end of file
local m=120239024
local cm=_G["c"..m]
cm.name="超电磁极大"
function cm.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_GRAVE_ACTION)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCondition(cm.condition)
e1:SetCost(cm.cost)
e1:SetTarget(cm.target)
e1:SetOperation(cm.activate)
c:RegisterEffect(e1)
end
--Activate
function cm.costfilter(c,e,tp)
return not c:IsPublic() and c:IsLevel(10) and c:IsRace(RACE_MACHINE)
end
function cm.thfilter(c)
return c:IsRace(RACE_MACHINE) and c:IsAbleToHand()
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetFieldGroupCount(tp,0,LOCATION_MZONE)>0
end
cm.cost=RD.CostShowHand(cm.costfilter,1,1)
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_GRAVE,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_GRAVE)
end
function cm.activate(e,tp,eg,ep,ev,re,r,rp)
RD.SelectAndDoAction(HINTMSG_ATOHAND,aux.NecroValleyFilter(cm.thfilter),tp,LOCATION_GRAVE,0,1,2,nil,function(g)
if RD.SendToHandAndExists(g,1-tp) and Duel.GetFlagEffect(tp,m)==0 then
RD.CreateCannotSummonEffect(e,aux.Stringid(m,1),cm.sumlimit,tp,1,0,RESET_PHASE+PHASE_END)
RD.CreateCannotSetMonsterEffect(e,aux.Stringid(m,2),cm.sumlimit,tp,1,0,RESET_PHASE+PHASE_END)
Duel.RegisterFlagEffect(tp,m,RESET_PHASE+PHASE_END,0,1)
end
end)
end
function cm.sumlimit(e,c)
return c:IsLocation(LOCATION_HAND)
end
\ No newline at end of file
local m=120239026
local cm=_G["c"..m]
cm.name="野兽勇气挥舞"
function cm.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DRAW)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
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_MAXIMUM) and c:IsAbleToDeckOrExtraAsCost()
end
function cm.exfilter(c)
return c:IsFaceup() and RD.IsMaximumMode(c) and RD.IsCanAttachPierce(c)
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.IsPlayerCanDraw(tp,1) end
RD.TargetDraw(tp,1)
end
function cm.activate(e,tp,eg,ep,ev,re,r,rp)
if RD.Draw()~=0 then
RD.CanSelectAndDoAction(aux.Stringid(m,1),aux.Stringid(m,2),cm.exfilter,tp,LOCATION_MZONE,0,1,1,nil,function(g)
Duel.BreakEffect()
RD.AttachPierce(e,g:GetFirst(),aux.Stringid(m,3),RESET_EVENT+RESETS_STANDARD)
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