Commit 4fb09f11 authored by 未闻皂名's avatar 未闻皂名

2023/2/28 新增:海龙Max新卡

parent f96edaa0
No preview for this file type
......@@ -112,6 +112,14 @@ function RushDuel.CostShowHand(filter, min, max, set_label, set_object)
Duel.ShuffleHand(tp)
end)
end
-- 代价: 把手卡给对方观看 (子卡片组)
function RushDuel.CostShowGroupHand(filter, check, min, max, set_label, set_object)
return RushDuel._private_cost_select_group(HINTMSG_CONFIRM, filter, check, LOCATION_HAND, 0, min, max, true, function(g, e, tp, eg, ep, ev, re, r, rp)
RushDuel.SetLabelAndObject(e, g, set_label, set_object)
Duel.ConfirmCards(1 - tp, g)
Duel.ShuffleHand(tp)
end)
end
-- 代价: 把额外卡组给对方观看 (子卡片组)
function RushDuel.CostShowGroupExtra(filter, check, min, max, set_label, set_object)
return RushDuel._private_cost_select_group(HINTMSG_CONFIRM, filter, check, LOCATION_EXTRA, 0, min, max, false, function(g, e, tp, eg, ep, ev, re, r, rp)
......
......@@ -21,7 +21,6 @@ function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetFieldGroupCount(tp,LOCATION_DECK,0)<5 then return end
Duel.BreakEffect()
local sg,g=RD.RevealDeckTopAndCanSelect(tp,5,aux.Stringid(m,1),HINTMSG_ATOHAND,cm.thfilter,1,1)
if sg:GetCount()>0 then
Duel.DisableShuffleCheck()
......
local m=120239013
local cm=_G["c"..m]
cm.name="深渊龙神 深渊海皇龍[L]"
function cm.initial_effect(c)
--Destroy (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:SetCost(cm.cost)
e1:SetTarget(cm.target)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
--Destroy (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
--Destroy
function cm.confilter(c)
return c:IsRace(RACE_SEASERPENT)
end
function cm.costfilter(c)
return c:IsType(TYPE_MONSTER) and c:IsAbleToDeckAsCost()
end
function cm.exfilter(c)
return c:IsType(TYPE_MAXIMUM) and c:IsLocation(LOCATION_DECK)
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cm.confilter,tp,LOCATION_GRAVE,0,5,nil)
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
local g=Duel.GetMatchingGroup(cm.costfilter,tp,LOCATION_GRAVE,0,nil)
if chk==0 then return g:GetCount()>0 end
local og,ct=RD.SendToDeckSort(g,SEQ_DECKBOTTOM,REASON_COST,tp,tp)
if og:IsExists(cm.exfilter,3,nil) then
e:SetValue(1)
else
e:SetValue(0)
end
end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(nil,tp,0,LOCATION_MZONE,1,nil) end
local g=Duel.GetMatchingGroup(nil,tp,0,LOCATION_MZONE,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,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)
RD.SelectAndDoAction(HINTMSG_DESTROY,nil,tp,0,LOCATION_MZONE,1,1,nil,function(g)
if Duel.Destroy(g,REASON_EFFECT)~=0 and RD.IsMaximumMode(e:GetHandler()) and e:GetValue()==1
and Duel.IsExistingMatchingCard(nil,tp,0,LOCATION_ONFIELD,1,nil)
and Duel.SelectYesNo(tp,aux.Stringid(m,1)) then
local sg=Duel.GetMatchingGroup(nil,tp,0,LOCATION_ONFIELD,nil)
Duel.Destroy(sg,REASON_EFFECT)
end
end)
end
\ No newline at end of file
local m=120239014
local list={120239013,120239015}
local cm=_G["c"..m]
cm.name="深渊龙神 深渊海皇龍"
function cm.initial_effect(c)
RD.AddCodeList(c,list)
--Maximum Summon
RD.AddMaximumProcedure(c,4000,list[1],list[2])
--Cannot Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_ATTACK_ANNOUNCE)
e1:SetCondition(cm.actcon)
e1:SetOperation(cm.actlimit)
c:RegisterEffect(e1)
--Indes
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetRange(LOCATION_MZONE)
e2:SetCondition(cm.indcon)
e2:SetValue(cm.indval)
c:RegisterEffect(e2)
end
--Cannot Activate
function cm.confilter(c)
return c:IsType(TYPE_MONSTER)
end
function cm.actcon(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsExistingMatchingCard(cm.confilter,tp,LOCATION_GRAVE,0,1,nil)
end
function cm.actlimit(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,0,m)
Duel.SetChainLimitTillChainEnd(cm.chainlimit)
end
function cm.chainlimit(e,rp,tp)
return not (rp~=tp and e:IsHasType(EFFECT_TYPE_ACTIVATE) and e:IsActiveType(TYPE_TRAP))
end
--Indes
cm.indval=RD.ValueEffectIndesType(0,TYPE_SPELL+TYPE_TRAP+TYPE_MONSTER)
function cm.indcon(e,tp,eg,ep,ev,re,r,rp)
return cm.actcon(e,tp,eg,ep,ev,re,r,rp) and RD.MaximumMode(e,tp,eg,ep,ev,re,r,rp)
end
\ No newline at end of file
local m=120239015
local cm=_G["c"..m]
cm.name="深渊龙神 深渊海皇龍[R]"
function cm.initial_effect(c)
--Cannot Set Monster
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_MSET)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetRange(LOCATION_MZONE)
e1:SetCondition(cm.setcon1)
e1:SetTarget(cm.setlimit)
e1:SetTargetRange(0,1)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetType(EFFECT_TYPE_XMATERIAL+EFFECT_TYPE_FIELD)
c:RegisterEffect(e2)
--Cannot Set Spell & Trap
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_XMATERIAL+EFFECT_TYPE_FIELD)
e3:SetCode(EFFECT_CANNOT_SSET)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e3:SetRange(LOCATION_MZONE)
e3:SetTargetRange(0,1)
e3:SetCondition(cm.setcon2)
e3:SetTarget(cm.setlimit)
c:RegisterEffect(e3)
end
--Cannot Set Monster
function cm.confilter1(c)
return c:IsType(TYPE_MONSTER)
end
function cm.setcon1(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsExistingMatchingCard(cm.confilter1,tp,LOCATION_GRAVE,0,1,nil)
end
function cm.setlimit(e,c,sump,sumtype,sumpos,targetp,se)
return c:IsLocation(LOCATION_HAND)
end
--Cannot Set Spell & Trap
function cm.confilter2(c)
return c:IsFacedown() and c:IsType(TYPE_SPELL+TYPE_TRAP)
end
function cm.setcon2(e,tp,eg,ep,ev,re,r,rp)
return cm.setcon1(e,tp,eg,ep,ev,re,r,rp) and RD.MaximumMode(e,tp,eg,ep,ev,re,r,rp)
and Duel.IsExistingMatchingCard(cm.confilter2,tp,0,LOCATION_ONFIELD,1,nil)
end
local m=120239016
local cm=_G["c"..m]
cm.name="深渊龙龙 深渊章鱼怪[L]"
function cm.initial_effect(c)
--Atk & Def Down (Normal)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_ATKCHANGE+CATEGORY_DEFCHANGE+CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCost(cm.cost)
e1:SetTarget(cm.target)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
--Atk & Def Down (MaximumMode)
local e2=e1:Clone()
e2:SetDescription(aux.Stringid(m,3))
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:IsAbleToDeckOrExtraAsCost()
end
function cm.exfilter(c)
return c:IsType(TYPE_MONSTER)
end
function cm.desfilter(c)
return c:IsType(TYPE_SPELL+TYPE_TRAP)
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
local g=Duel.GetMatchingGroup(cm.costfilter,tp,LOCATION_GRAVE,0,nil)
if chk==0 then return g:GetCount()>0 end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local sg=g:Select(tp,1,5,nil)
local ct=Duel.SendtoDeck(sg,nil,SEQ_DECKSHUFFLE,REASON_COST)
e:SetValue(ct)
end
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 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)
RD.SelectAndDoAction(aux.Stringid(m,1),Card.IsFaceup,tp,0,LOCATION_MZONE,1,1,nil,function(g)
local down=e:GetValue()*-300
RD.AttachAtkDef(e,g:GetFirst(),down,down,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
if RD.IsMaximumMode(e:GetHandler()) and not Duel.IsExistingMatchingCard(cm.exfilter,tp,LOCATION_GRAVE,0,1,nil) then
RD.CanSelectAndDoAction(aux.Stringid(m,2),HINTMSG_DESTROY,cm.desfilter,tp,0,LOCATION_ONFIELD,1,1,nil,function(sg)
Duel.Destroy(sg,REASON_EFFECT)
end)
end
end)
end
\ No newline at end of file
local m=120239017
local list={120239016,120239018}
local cm=_G["c"..m]
cm.name="深渊龙龙 深渊章鱼怪"
function cm.initial_effect(c)
RD.AddCodeList(c,list)
--Maximum Summon
RD.AddMaximumProcedure(c,4000,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(cm.indcon)
e1:SetValue(cm.indval)
c:RegisterEffect(e1)
--Cannot Activate
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_ATTACK_ANNOUNCE)
e2:SetCondition(cm.actcon)
e2:SetOperation(cm.actlimit)
c:RegisterEffect(e2)
end
--Indes
cm.indval=RD.ValueEffectIndesType(0,TYPE_SPELL+TYPE_TRAP+TYPE_MONSTER)
function cm.confilter(c)
return c:IsType(TYPE_MONSTER)
end
function cm.indcon(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsExistingMatchingCard(cm.confilter,tp,LOCATION_GRAVE,0,1,nil)
end
--Cannot Activate
function cm.actcon(e,tp,eg,ep,ev,re,r,rp)
return cm.indcon(e,tp,eg,ep,ev,re,r,rp) and RD.MaximumMode(e,tp,eg,ep,ev,re,r,rp)
end
function cm.actlimit(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,0,m)
Duel.SetChainLimitTillChainEnd(cm.chainlimit)
end
function cm.chainlimit(e,rp,tp)
return not (rp~=tp and e:IsHasType(EFFECT_TYPE_ACTIVATE) and e:IsActiveType(TYPE_TRAP))
end
\ No newline at end of file
local m=120239018
local cm=_G["c"..m]
cm.name="深渊龙龙 深渊章鱼怪[R]"
function cm.initial_effect(c)
--Position (Normal)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_POSITION)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCost(cm.cost)
e1:SetTarget(cm.target)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
--Position (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
--Position
cm.cost=RD.CostSendHandToGrave(Card.IsAbleToGraveAsCost,1,1)
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(RD.IsCanChangePosition,tp,0,LOCATION_MZONE,1,nil) end
local g=Duel.GetMatchingGroup(RD.IsCanChangePosition,tp,0,LOCATION_MZONE,nil)
Duel.SetOperationInfo(0,CATEGORY_POSITION,g,1,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)
RD.SelectAndDoAction(HINTMSG_POSCHANGE,RD.IsCanChangePosition,tp,0,LOCATION_MZONE,1,1,nil,function(g)
local c=e:GetHandler()
if RD.ChangePosition(g)~=0 and c:IsFaceup() and c:IsRelateToEffect(e) and RD.IsMaximumMode(c) then
RD.AttachPierce(e,c,aux.Stringid(m,1),RESET_EVENT+RESETS_STANDARD+RESET_DISABLE+RESET_PHASE+PHASE_END)
end
end)
end
\ No newline at end of file
local m=120239039
local cm=_G["c"..m]
cm.name="气升之波纹鲸"
function cm.initial_effect(c)
--To Hand
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND)
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
--To Hand
function cm.costfilter(c)
return c:IsType(TYPE_MONSTER) and c:IsAbleToDeckOrExtraAsCost()
end
function cm.thfilter(c)
return c:IsLevel(10) and c:IsAbleToHand()
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.GetFieldGroupCount(tp,LOCATION_DECK,0)>1 end
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetFieldGroupCount(tp,LOCATION_DECK,0)<2 then return end
local sg,g=RD.RevealDeckTopAndCanSelect(tp,2,aux.Stringid(m,1),HINTMSG_ATOHAND,cm.thfilter,1,1)
if sg:GetCount()>0 then
RD.SendToHandAndExists(sg,1-tp)
end
Duel.ShuffleDeck(tp)
end
\ No newline at end of file
local m=120239041
local cm=_G["c"..m]
cm.name="深海龙 蝙蝠海龙"
function cm.initial_effect(c)
--Draw
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_DRAW+CATEGORY_TODECK)
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)
end
--Draw
function cm.costfilter(c)
return c:IsLevel(10)
end
function cm.costcheck(g,e,tp)
return Duel.IsPlayerCanDraw(tp,g:GetCount())
end
cm.cost=RD.CostShowGroupHand(cm.costfilter,cm.costcheck,1,3,Group.GetCount)
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
RD.TargetDraw(tp,e:GetLabel())
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER)
local ct=RD.Draw()
if ct==0 then return end
RD.SelectAndDoAction(HINTMSG_TODECK,Card.IsAbleToDeck,p,LOCATION_HAND,0,ct,ct,nil,function(g)
Duel.BreakEffect()
RD.SendToDeckAndExists(g)
end)
end
\ No newline at end of file
local m=120239042
local cm=_G["c"..m]
cm.name="深渊闪光"
function cm.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_POSITION)
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.confilter(c)
return c:IsRace(RACE_SEASERPENT)
end
function cm.costfilter(c)
return c:IsType(TYPE_MONSTER) and c:IsAbleToDeckAsCost()
end
function cm.filter(c)
return RD.IsCanChangePosition(c)
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cm.confilter,tp,LOCATION_GRAVE,0,5,nil)
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
local g=Duel.GetMatchingGroup(cm.costfilter,tp,0,LOCATION_GRAVE,nil)
if chk==0 then return g:GetCount()>0 end
Duel.SendtoDeck(g,nil,SEQ_DECKSHUFFLE,REASON_COST)
end
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,g:GetCount(),0,0)
end
function cm.activate(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(cm.filter,tp,0,LOCATION_MZONE,nil)
if g:GetCount()>0 then
RD.ChangePosition(g)
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