Commit 4b168380 authored by POLYMER's avatar POLYMER

fix

parent 56323a09
...@@ -57,7 +57,7 @@ function c10200026.op2(e,tp,eg,ep,ev,re,r,rp) ...@@ -57,7 +57,7 @@ function c10200026.op2(e,tp,eg,ep,ev,re,r,rp)
local ct=Duel.GetFlagEffect(tp,10200026) local ct=Duel.GetFlagEffect(tp,10200026)
ct=ct+1 ct=ct+1
Duel.RegisterFlagEffect(tp,10200026,RESET_PHASE+PHASE_END,0,1,ct) Duel.RegisterFlagEffect(tp,10200026,RESET_PHASE+PHASE_END,0,1,ct)
if Duel.SelectYesNo(tp, aux.Stringid(10200026,3)) then if Duel.SelectYesNo(tp,aux.Stringid(10200026,3)) then
if ct >= 1 then if ct >= 1 then
local g1=Duel.GetMatchingGroup(Card.IsFaceup,tp,0,LOCATION_MZONE,nil) local g1=Duel.GetMatchingGroup(Card.IsFaceup,tp,0,LOCATION_MZONE,nil)
for tc in aux.Next(g1) do for tc in aux.Next(g1) do
...@@ -68,9 +68,11 @@ function c10200026.op2(e,tp,eg,ep,ev,re,r,rp) ...@@ -68,9 +68,11 @@ function c10200026.op2(e,tp,eg,ep,ev,re,r,rp)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1) tc:RegisterEffect(e1)
end end
e:GetHandler():RegisterFlagEffect(0,RESET_PHASE+PHASE_END,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(10200026,4))
end end
if ct >= 2 then if ct >= 2 then
Duel.Damage(1-tp,500,REASON_EFFECT) Duel.Damage(1-tp,500,REASON_EFFECT)
e:GetHandler():RegisterFlagEffect(0,RESET_PHASE+PHASE_END,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(10200026,5))
end end
if ct >= 3 then if ct >= 3 then
local g2=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_MZONE,0,nil) local g2=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_MZONE,0,nil)
...@@ -82,9 +84,11 @@ function c10200026.op2(e,tp,eg,ep,ev,re,r,rp) ...@@ -82,9 +84,11 @@ function c10200026.op2(e,tp,eg,ep,ev,re,r,rp)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1) tc:RegisterEffect(e1)
end end
e:GetHandler():RegisterFlagEffect(0,RESET_PHASE+PHASE_END,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(10200026,6))
end end
if ct >= 4 then if ct >= 4 then
Duel.Draw(tp,1,REASON_EFFECT) Duel.Draw(tp,1,REASON_EFFECT)
e:GetHandler():RegisterFlagEffect(0,RESET_PHASE+PHASE_END,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(10200026,7))
end end
if ct >= 5 then if ct >= 5 then
local g3=Duel.GetMatchingGroup(nil,tp,0,LOCATION_ONFIELD,nil) local g3=Duel.GetMatchingGroup(nil,tp,0,LOCATION_ONFIELD,nil)
...@@ -93,6 +97,7 @@ function c10200026.op2(e,tp,eg,ep,ev,re,r,rp) ...@@ -93,6 +97,7 @@ function c10200026.op2(e,tp,eg,ep,ev,re,r,rp)
local sg=g3:Select(tp,1,1,nil) local sg=g3:Select(tp,1,1,nil)
Duel.Destroy(sg,REASON_EFFECT) Duel.Destroy(sg,REASON_EFFECT)
end end
e:GetHandler():RegisterFlagEffect(0,RESET_PHASE+PHASE_END,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(10200026,8))
end end
end end
end end
\ No newline at end of file
...@@ -12,7 +12,7 @@ function cm.initial_effect(c) ...@@ -12,7 +12,7 @@ function cm.initial_effect(c)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_SUMMON_SUCCESS) e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetOperation(cm.SpiritReturnReg) e1:SetOperation(cm.SpiritReturnReg)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=e1:Clone() local e2=e1:Clone()
......
...@@ -12,7 +12,7 @@ function cm.initial_effect(c) ...@@ -12,7 +12,7 @@ function cm.initial_effect(c)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_SUMMON_SUCCESS) e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetOperation(cm.SpiritReturnReg) e1:SetOperation(cm.SpiritReturnReg)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=e1:Clone() local e2=e1:Clone()
...@@ -65,20 +65,20 @@ function cm.SpiritReturnReg(e,tp,eg,ep,ev,re,r,rp) ...@@ -65,20 +65,20 @@ function cm.SpiritReturnReg(e,tp,eg,ep,ev,re,r,rp)
e2:SetTarget(Auxiliary.SpiritReturnTargetOptional) e2:SetTarget(Auxiliary.SpiritReturnTargetOptional)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function cm.cpfilter(c,tp) function cm.cpfilter(c,e,tp)
return c:IsFaceup() and c:IsAbleToHandAsCost() and Duel.IsExistingMatchingCard(cm.cpfilter2,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,c,tp,c) return c:IsFaceup() and c:IsAbleToHandAsCost() and Duel.IsExistingMatchingCard(cm.cpfilter2,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,c,e,tp,c)
end end
function cm.cpfilter2(c,tp,tc) function cm.cpfilter2(c,e,tp,tc)
local fg=Group.FromCards(c,tc) local fg=Group.FromCards(c,tc)
return c:IsFacedown() and c:IsAbleToHandAsCost() and Duel.IsExistingMatchingCard(cm.smfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,1,fg,e,tp,fg) return c:IsFacedown() and c:IsAbleToHandAsCost() and Duel.IsExistingMatchingCard(cm.smfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,1,fg,e,tp,fg)
end end
function cm.sumcost(e,tp,eg,ep,ev,re,r,rp,chk) function cm.sumcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.cpfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil,tp) and e:GetHandler():GetFlagEffect(m)==0 end if chk==0 then return Duel.IsExistingMatchingCard(cm.cpfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil,e,tp) and e:GetHandler():GetFlagEffect(m)==0 end
e:GetHandler():RegisterFlagEffect(m,RESET_EVENT+RESETS_STANDARD+RESET_CHAIN,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(m,3)) e:GetHandler():RegisterFlagEffect(m,RESET_EVENT+RESETS_STANDARD+RESET_CHAIN,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(m,3))
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local tc=Duel.SelectMatchingCard(tp,cm.cpfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil,tp):GetFirst() local tc=Duel.SelectMatchingCard(tp,cm.cpfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil,e,tp):GetFirst()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local tc2=Duel.SelectMatchingCard(tp,cm.cpfilter2,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil,tp,tc):GetFirst() local tc2=Duel.SelectMatchingCard(tp,cm.cpfilter2,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil,e,tp,tc):GetFirst()
local fg=Group.FromCards(tc,tc2) local fg=Group.FromCards(tc,tc2)
--Debug.Message(Duel.GetMatchingGroupCount(cm.smfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,fg,e,tp,fg)) --Debug.Message(Duel.GetMatchingGroupCount(cm.smfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,fg,e,tp,fg))
Duel.SendtoHand(fg,nil,REASON_COST) Duel.SendtoHand(fg,nil,REASON_COST)
......
...@@ -12,7 +12,7 @@ function cm.initial_effect(c) ...@@ -12,7 +12,7 @@ function cm.initial_effect(c)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_SUMMON_SUCCESS) e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetOperation(cm.SpiritReturnReg) e1:SetOperation(cm.SpiritReturnReg)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=e1:Clone() local e2=e1:Clone()
......
...@@ -12,7 +12,7 @@ function cm.initial_effect(c) ...@@ -12,7 +12,7 @@ function cm.initial_effect(c)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_SUMMON_SUCCESS) e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetOperation(cm.SpiritReturnReg) e1:SetOperation(cm.SpiritReturnReg)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=e1:Clone() local e2=e1:Clone()
......
...@@ -12,7 +12,7 @@ function cm.initial_effect(c) ...@@ -12,7 +12,7 @@ function cm.initial_effect(c)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_SUMMON_SUCCESS) e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetOperation(cm.SpiritReturnReg) e1:SetOperation(cm.SpiritReturnReg)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=e1:Clone() local e2=e1:Clone()
......
...@@ -45,7 +45,9 @@ end ...@@ -45,7 +45,9 @@ end
function cm.reop(e,tp,eg,ep,ev,re,r,rp) function cm.reop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local ct=e:GetLabel() local ct=e:GetLabel()
local rep=c:IsStatus(STATUS_EFFECT_REPLACED)
if c:IsRelateToEffect(e) and Duel.Remove(c,nil,REASON_EFFECT+REASON_TEMPORARY)~=0 and c:IsLocation(LOCATION_REMOVED) and not c:IsReason(REASON_REDIRECT) then if c:IsRelateToEffect(e) and Duel.Remove(c,nil,REASON_EFFECT+REASON_TEMPORARY)~=0 and c:IsLocation(LOCATION_REMOVED) and not c:IsReason(REASON_REDIRECT) then
if rep then c:RegisterFlagEffect(0,RESET_EVENT+RESETS_STANDARD,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(m,3)) end
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_MOVE) e2:SetCode(EVENT_MOVE)
......
...@@ -46,7 +46,9 @@ end ...@@ -46,7 +46,9 @@ end
function cm.reop(e,tp,eg,ep,ev,re,r,rp) function cm.reop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local ct=e:GetLabel() local ct=e:GetLabel()
local rep=c:IsStatus(STATUS_EFFECT_REPLACED)
if c:IsRelateToEffect(e) and Duel.Remove(c,nil,REASON_EFFECT+REASON_TEMPORARY)~=0 and c:IsLocation(LOCATION_REMOVED) and not c:IsReason(REASON_REDIRECT) then if c:IsRelateToEffect(e) and Duel.Remove(c,nil,REASON_EFFECT+REASON_TEMPORARY)~=0 and c:IsLocation(LOCATION_REMOVED) and not c:IsReason(REASON_REDIRECT) then
if rep then c:RegisterFlagEffect(0,RESET_EVENT+RESETS_STANDARD,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(m,3)) end
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_MOVE) e2:SetCode(EVENT_MOVE)
......
...@@ -44,7 +44,9 @@ end ...@@ -44,7 +44,9 @@ end
function cm.reop(e,tp,eg,ep,ev,re,r,rp) function cm.reop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local ct=e:GetLabel() local ct=e:GetLabel()
local rep=c:IsStatus(STATUS_EFFECT_REPLACED)
if c:IsRelateToEffect(e) and Duel.Remove(c,nil,REASON_EFFECT+REASON_TEMPORARY)~=0 and c:IsLocation(LOCATION_REMOVED) and not c:IsReason(REASON_REDIRECT) then if c:IsRelateToEffect(e) and Duel.Remove(c,nil,REASON_EFFECT+REASON_TEMPORARY)~=0 and c:IsLocation(LOCATION_REMOVED) and not c:IsReason(REASON_REDIRECT) then
if rep then c:RegisterFlagEffect(0,RESET_EVENT+RESETS_STANDARD,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(m,3)) end
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_MOVE) e2:SetCode(EVENT_MOVE)
......
...@@ -46,7 +46,9 @@ end ...@@ -46,7 +46,9 @@ end
function cm.reop(e,tp,eg,ep,ev,re,r,rp) function cm.reop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local ct=e:GetLabel() local ct=e:GetLabel()
local rep=c:IsStatus(STATUS_EFFECT_REPLACED)
if c:IsRelateToEffect(e) and Duel.Remove(c,nil,REASON_EFFECT+REASON_TEMPORARY)~=0 and c:IsLocation(LOCATION_REMOVED) and not c:IsReason(REASON_REDIRECT) then if c:IsRelateToEffect(e) and Duel.Remove(c,nil,REASON_EFFECT+REASON_TEMPORARY)~=0 and c:IsLocation(LOCATION_REMOVED) and not c:IsReason(REASON_REDIRECT) then
if rep then c:RegisterFlagEffect(0,RESET_EVENT+RESETS_STANDARD,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(m,3)) end
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_MOVE) e2:SetCode(EVENT_MOVE)
......
...@@ -46,7 +46,9 @@ end ...@@ -46,7 +46,9 @@ end
function cm.reop(e,tp,eg,ep,ev,re,r,rp) function cm.reop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local ct=e:GetLabel() local ct=e:GetLabel()
local rep=c:IsStatus(STATUS_EFFECT_REPLACED)
if c:IsRelateToEffect(e) and Duel.Remove(c,nil,REASON_EFFECT+REASON_TEMPORARY)~=0 and c:IsLocation(LOCATION_REMOVED) and not c:IsReason(REASON_REDIRECT) then if c:IsRelateToEffect(e) and Duel.Remove(c,nil,REASON_EFFECT+REASON_TEMPORARY)~=0 and c:IsLocation(LOCATION_REMOVED) and not c:IsReason(REASON_REDIRECT) then
if rep then c:RegisterFlagEffect(0,RESET_EVENT+RESETS_STANDARD,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(m,3)) end
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_MOVE) e2:SetCode(EVENT_MOVE)
...@@ -201,7 +203,8 @@ function cm.returntofield(tc,e) ...@@ -201,7 +203,8 @@ function cm.returntofield(tc,e)
if tc:GetPreviousTypeOnField()&TYPE_EQUIP>0 then if tc:GetPreviousTypeOnField()&TYPE_EQUIP>0 then
Duel.SendtoGrave(tc,REASON_RULE+REASON_RETURN) Duel.SendtoGrave(tc,REASON_RULE+REASON_RETURN)
else else
local rc=tc:GetReasonEffect():GetOwner() or tc local rc=tc
if tc:GetReasonEffect() then rc=tc:GetReasonEffect():GetOwner() end
local e1=Effect.CreateEffect(rc) local e1=Effect.CreateEffect(rc)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(m) e1:SetCode(m)
......
...@@ -41,7 +41,7 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -41,7 +41,7 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
if tc:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) then
tc:ResetFlagEffect(11451718) tc:ResetFlagEffect(11451718)
local rc=tc local rc=tc
if tc:GetReasonEffect() and tc:GetReasonEffect():GetOwner() then rc=tc:GetReasonEffect():GetOwner() end if tc:GetReasonEffect() then rc=tc:GetReasonEffect():GetOwner() end
local e1=Effect.CreateEffect(rc) local e1=Effect.CreateEffect(rc)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(m) e1:SetCode(m)
......
...@@ -58,7 +58,9 @@ end ...@@ -58,7 +58,9 @@ end
function cm.reop(e,tp,eg,ep,ev,re,r,rp) function cm.reop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local ct=e:GetLabel() local ct=e:GetLabel()
local rep=c:IsStatus(STATUS_EFFECT_REPLACED)
if c:IsRelateToEffect(e) and Duel.Remove(c,nil,REASON_EFFECT+REASON_TEMPORARY)~=0 and c:IsLocation(LOCATION_REMOVED) and not c:IsReason(REASON_REDIRECT) then if c:IsRelateToEffect(e) and Duel.Remove(c,nil,REASON_EFFECT+REASON_TEMPORARY)~=0 and c:IsLocation(LOCATION_REMOVED) and not c:IsReason(REASON_REDIRECT) then
if rep then c:RegisterFlagEffect(0,RESET_EVENT+RESETS_STANDARD,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(m,3)) end
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_MOVE) e2:SetCode(EVENT_MOVE)
......
...@@ -22,6 +22,7 @@ function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -22,6 +22,7 @@ function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return true end if chk==0 then return true end
Duel.SendtoHand(c,1-tp,REASON_COST) Duel.SendtoHand(c,1-tp,REASON_COST)
Duel.ShuffleHand(tp)
Duel.ShuffleHand(1-tp) Duel.ShuffleHand(1-tp)
end end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk) function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
......
...@@ -68,7 +68,7 @@ function cm.fil3(c) ...@@ -68,7 +68,7 @@ function cm.fil3(c)
return c:IsType(TYPE_CONTINUOUS) and c:IsType(TYPE_SPELL) and c:IsFaceup() return c:IsType(TYPE_CONTINUOUS) and c:IsType(TYPE_SPELL) and c:IsFaceup()
end end
function cm.fil4(c) function cm.fil4(c)
return c:IsOriginalCodeRule(60010252) and c:IsFaceup() and c:IsReleasable() and c:IsCanBeFusionMaterial() return c:IsOriginalCodeRule(60010252) and c:IsReleasable() and c:IsCanBeFusionMaterial()
end end
function cm.spcon(e,c) function cm.spcon(e,c)
local tp=e:GetHandlerPlayer() local tp=e:GetHandlerPlayer()
......
...@@ -55,6 +55,10 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp) ...@@ -55,6 +55,10 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp)
local fc=Duel.SelectMatchingCard(tp,cm.mfilter2,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil,re:GetHandler()):GetFirst() local fc=Duel.SelectMatchingCard(tp,cm.mfilter2,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil,re:GetHandler()):GetFirst()
local fg=Group.FromCards(re:GetHandler(),fc) local fg=Group.FromCards(re:GetHandler(),fc)
c:SetMaterial(fg) c:SetMaterial(fg)
if fg:IsExists(Card.IsFacedown,1,nil) then
Duel.ConfirmCards(1,fg:Filter(Card.IsFacedown,nil))
Duel.ConfirmCards(0,fg:Filter(Card.IsFacedown,nil))
end
if Duel.SendtoGrave(fg,REASON_SPSUMMON)==2 then if Duel.SendtoGrave(fg,REASON_SPSUMMON)==2 then
Duel.SpecialSummon(c,0,tp,tp,true,true,POS_FACEUP) Duel.SpecialSummon(c,0,tp,tp,true,true,POS_FACEUP)
end end
...@@ -66,7 +70,7 @@ function cm.mfilter2(c,tc) ...@@ -66,7 +70,7 @@ function cm.mfilter2(c,tc)
and #Group.FromCards(c,tc):Filter(cm.mfilter3,nil)>0 and #Group.FromCards(c,tc):Filter(cm.mfilter3,nil)>0
end end
function cm.mfilter3(c) function cm.mfilter3(c)
return c:IsCode(60010252) and c:IsFaceup() return c:IsCode(60010252) --and c:IsFaceup()
end end
function cm.uop(e,tp,eg,ep,ev,re,r,rp) function cm.uop(e,tp,eg,ep,ev,re,r,rp)
......
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