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

2021/12/20 根据konami的调整修改处理

parent 5afa2dbe
......@@ -7,6 +7,7 @@ function cm.initial_effect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCondition(cm.condition)
e1:SetCost(cm.cost)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
......@@ -15,6 +16,9 @@ end
function cm.costfilter(c)
return c:IsRace(RACE_DRAGON) and c:IsAbleToDeckOrExtraAsCost()
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return not e:GetHandler():IsHasEffect(EFFECT_UNRELEASABLE_SUM)
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.costfilter,tp,LOCATION_GRAVE,0,2,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
......
......@@ -37,6 +37,6 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.SelectMatchingCard(tp,cm.tdfilter,tp,0,LOCATION_ONFIELD,1,1,nil)
if g:GetCount()>0 then
Duel.HintSelection(g)
Duel.SendtoDeck(g,nil,0,REASON_EFFECT)
RushDuel.SendtoDeckTop(g:GetFirst(),tp,REASON_EFFECT)
end
end
\ No newline at end of file
......@@ -7,6 +7,7 @@ function cm.initial_effect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCondition(cm.condition)
e1:SetCost(cm.cost)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
......@@ -15,6 +16,9 @@ end
function cm.costfilter(c)
return c:IsType(TYPE_SPELL+TYPE_TRAP) and not c:IsPublic()
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return not e:GetHandler():IsHasEffect(EFFECT_UNRELEASABLE_SUM)
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.costfilter,tp,LOCATION_HAND,0,2,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CONFIRM)
......
......@@ -7,6 +7,7 @@ function cm.initial_effect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetCondition(cm.condition)
e1:SetCost(cm.cost)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
......@@ -15,6 +16,9 @@ end
function cm.costfilter(c)
return c:IsRace(RACE_MACHINE) and c:IsAbleToDeckOrExtraAsCost()
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return not e:GetHandler():IsHasEffect(EFFECT_UNRELEASABLE_SUM)
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.costfilter,tp,LOCATION_GRAVE,0,3,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
......
......@@ -45,8 +45,7 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.SelectMatchingCard(tp,cm.filter,tp,0,LOCATION_MZONE,1,1,nil)
if g:GetCount()>0 then
Duel.HintSelection(g)
Duel.SendtoDeck(g,nil,0,REASON_EFFECT)
Duel.ConfirmDecktop(1-tp,1)
RushDuel.SendtoDeckTop(g:GetFirst(),tp,REASON_EFFECT)
if e:GetLabel()==1
and Duel.IsExistingMatchingCard(aux.NecroValleyFilter(cm.tdfilter),tp,0,LOCATION_GRAVE,1,nil)
and Duel.SelectYesNo(tp,aux.Stringid(m,1)) then
......
......@@ -19,7 +19,8 @@ function cm.confilter(c)
return c:IsFaceup() and c:IsCode(list[1])
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cm.confilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
return not e:GetHandler():IsHasEffect(EFFECT_UNRELEASABLE_SUM)
and Duel.IsExistingMatchingCard(cm.confilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckLPCost(tp,500) end
......
......@@ -15,7 +15,7 @@ function cm.initial_effect(c)
end
--Activate
function cm.filter(c,tp)
return c:IsControler(tp) and c:IsPreviousLocation(LOCATION_DECK)
return c:IsPreviousControler(tp) and c:IsPreviousLocation(LOCATION_DECK)
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(cm.filter,1,nil,1-tp)
......
......@@ -314,9 +314,23 @@ function RushDuel.SelectEffectOperation(eff1hint,eff1con,eff1op,eff2hint,eff2con
end
--Special Summon Count
function RushDuel.GetSPCount(tp,max)
local ct=Duel.GetMZoneCount(tp)
if ct<1 then return 0 end
if ct>max then ct=max end
if Duel.IsPlayerAffectedByEffect(tp,59822133) then ct=1 end
return ct
local ct=Duel.GetMZoneCount(tp)
if ct<1 then return 0 end
if ct>max then ct=max end
if Duel.IsPlayerAffectedByEffect(tp,59822133) then ct=1 end
return ct
end
--Send To Deck Top (Maximun)
function RushDuel.SendtoDeckTop(c,rp,reason)
if c:IsSummonType(SUMMON_TYPE_MAXIMUM) and c:GetOverlayCount()>0 then
local g=c:GetOverlayGroup()
local ct=g:GetCount()+1
Duel.SendtoDeck(g,nil,0,reason)
Duel.SendtoDeck(c,nil,0,reason)
Duel.SortDecktop(rp,c:GetControler(),ct)
Duel.ConfirmDecktop(c:GetControler(),ct)
else
Duel.SendtoDeck(c,nil,0,reason)
Duel.ConfirmDecktop(c:GetControler(),1)
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