Commit 83b7e0af authored by POLYMER's avatar POLYMER

fix

parent 52f7c5de
...@@ -25,21 +25,25 @@ function cm.initial_effect(c) ...@@ -25,21 +25,25 @@ function cm.initial_effect(c)
end end
end end
function cm.checkop(e,tp,eg,ep,ev,re,r,rp) function cm.checkop(e,tp,eg,ep,ev,re,r,rp)
--local tp=e:GetHandlerPlayer()
Duel.RegisterFlagEffect(tp,m,RESET_CHAIN,0,1) Duel.RegisterFlagEffect(tp,m,RESET_CHAIN,0,1)
end end
function cm.filter(c,e,tp,s) function cm.filter(c,tp)
local mg=Duel.GetMatchingGroup(Card.IsType,tp,LOCATION_HAND+LOCATION_MZONE,0,nil,TYPE_MONSTER) local mg=Duel.GetMatchingGroup(Card.IsType,tp,LOCATION_HAND+LOCATION_MZONE,0,nil,TYPE_MONSTER)
return c:IsSynchroSummonable(nil,mg) return c:IsSynchroSummonable(nil,mg)
end end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp) function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
local num=Duel.GetFlagEffect(tp,m) local tp=e:GetHandlerPlayer()
local num=Duel.GetFlagEffect(0,m)
local g=Duel.GetDecktopGroup(tp,num) local g=Duel.GetDecktopGroup(tp,num)
local result=g:FilterCount(Card.IsAbleToHand,nil) Debug.Message(tp)
return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_EXTRA,0,1,nil) and g:GetCount()>=num and result>0 and Duel.GetMZoneCount(tp)>0 Debug.Message(g:IsExists(Card.IsAbleToHand,1,nil))
return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_EXTRA,0,1,nil,tp) and g:GetCount()>=num and g:IsExists(Card.IsAbleToHand,1,nil) and Duel.GetMZoneCount(tp)>0
end end
function cm.spop(e,tp,eg,ep,ev,re,r,rp) function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local num=Duel.GetFlagEffect(tp,m) local tp=e:GetHandlerPlayer()
local num=Duel.GetFlagEffect(0,m)
if Duel.GetMZoneCount(tp)>0 and Duel.SelectYesNo(tp,aux.Stringid(m,0)) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then if Duel.GetMZoneCount(tp)>0 and Duel.SelectYesNo(tp,aux.Stringid(m,0)) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then
Duel.ConfirmDecktop(tp,num) Duel.ConfirmDecktop(tp,num)
local g=Duel.GetDecktopGroup(tp,num):Filter(Card.IsSetCard,nil,0x62a) local g=Duel.GetDecktopGroup(tp,num):Filter(Card.IsSetCard,nil,0x62a)
...@@ -67,5 +71,6 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -67,5 +71,6 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function cm.bkop(e,tp,eg,ep,ev,re,r,rp) function cm.bkop(e,tp,eg,ep,ev,re,r,rp)
local tp=e:GetHandlerPlayer()
Duel.SendtoHand(e:GetHandler(),tp,REASON_EFFECT) Duel.SendtoHand(e:GetHandler(),tp,REASON_EFFECT)
end end
\ No newline at end of file
...@@ -25,21 +25,25 @@ function cm.initial_effect(c) ...@@ -25,21 +25,25 @@ function cm.initial_effect(c)
end end
end end
function cm.checkop(e,tp,eg,ep,ev,re,r,rp) function cm.checkop(e,tp,eg,ep,ev,re,r,rp)
--local tp=e:GetHandlerPlayer()
Duel.RegisterFlagEffect(tp,m,RESET_CHAIN,0,1) Duel.RegisterFlagEffect(tp,m,RESET_CHAIN,0,1)
end end
function cm.filter(c,e,tp,s) function cm.filter(c,tp)
local mg=Duel.GetMatchingGroup(Card.IsType,tp,LOCATION_HAND+LOCATION_MZONE,0,nil,TYPE_MONSTER) local mg=Duel.GetMatchingGroup(Card.IsType,tp,LOCATION_HAND+LOCATION_MZONE,0,nil,TYPE_MONSTER)
return c:IsSynchroSummonable(nil,mg) return c:IsSynchroSummonable(nil,mg)
end end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp) function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
local num=Duel.GetFlagEffect(tp,m) local tp=e:GetHandlerPlayer()
local num=Duel.GetFlagEffect(0,m)
local g=Duel.GetDecktopGroup(tp,num) local g=Duel.GetDecktopGroup(tp,num)
local result=g:FilterCount(Card.IsAbleToHand,nil) --Debug.Message(tp)
return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_EXTRA,0,1,nil) and g:GetCount()>=num and result>0 and Duel.GetMZoneCount(tp)>0 --Debug.Message(g:IsExists(Card.IsAbleToHand,1,nil))
return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_EXTRA,0,1,nil,tp) and g:GetCount()>=num and g:IsExists(Card.IsAbleToHand,1,nil) and Duel.GetMZoneCount(tp)>0
end end
function cm.spop(e,tp,eg,ep,ev,re,r,rp) function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local num=Duel.GetFlagEffect(tp,m) local tp=e:GetHandlerPlayer()
local num=Duel.GetFlagEffect(0,m)
if Duel.GetMZoneCount(tp)>0 and Duel.SelectYesNo(tp,aux.Stringid(m,0)) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then if Duel.GetMZoneCount(tp)>0 and Duel.SelectYesNo(tp,aux.Stringid(m,0)) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then
Duel.ConfirmDecktop(tp,num) Duel.ConfirmDecktop(tp,num)
local g=Duel.GetDecktopGroup(tp,num):Filter(Card.IsSetCard,nil,0x62a) local g=Duel.GetDecktopGroup(tp,num):Filter(Card.IsSetCard,nil,0x62a)
...@@ -67,5 +71,6 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -67,5 +71,6 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function cm.bkop(e,tp,eg,ep,ev,re,r,rp) function cm.bkop(e,tp,eg,ep,ev,re,r,rp)
local tp=e:GetHandlerPlayer()
Duel.SendtoHand(e:GetHandler(),tp,REASON_EFFECT) Duel.SendtoHand(e:GetHandler(),tp,REASON_EFFECT)
end end
\ No newline at end of file
...@@ -25,21 +25,25 @@ function cm.initial_effect(c) ...@@ -25,21 +25,25 @@ function cm.initial_effect(c)
end end
end end
function cm.checkop(e,tp,eg,ep,ev,re,r,rp) function cm.checkop(e,tp,eg,ep,ev,re,r,rp)
--local tp=e:GetHandlerPlayer()
Duel.RegisterFlagEffect(tp,m,RESET_CHAIN,0,1) Duel.RegisterFlagEffect(tp,m,RESET_CHAIN,0,1)
end end
function cm.filter(c,e,tp,s) function cm.filter(c,tp)
local mg=Duel.GetMatchingGroup(Card.IsType,tp,LOCATION_HAND+LOCATION_MZONE,0,nil,TYPE_MONSTER) local mg=Duel.GetMatchingGroup(Card.IsType,tp,LOCATION_HAND+LOCATION_MZONE,0,nil,TYPE_MONSTER)
return c:IsSynchroSummonable(nil,mg) return c:IsSynchroSummonable(nil,mg)
end end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp) function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
local num=Duel.GetFlagEffect(tp,m) local tp=e:GetHandlerPlayer()
local num=Duel.GetFlagEffect(0,m)
local g=Duel.GetDecktopGroup(tp,num) local g=Duel.GetDecktopGroup(tp,num)
local result=g:FilterCount(Card.IsAbleToHand,nil) --Debug.Message(tp)
return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_EXTRA,0,1,nil) and g:GetCount()>=num and result>0 and Duel.GetMZoneCount(tp)>0 --Debug.Message(g:IsExists(Card.IsAbleToHand,1,nil))
return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_EXTRA,0,1,nil,tp) and g:GetCount()>=num and g:IsExists(Card.IsAbleToHand,1,nil) and Duel.GetMZoneCount(tp)>0
end end
function cm.spop(e,tp,eg,ep,ev,re,r,rp) function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local num=Duel.GetFlagEffect(tp,m) local tp=e:GetHandlerPlayer()
local num=Duel.GetFlagEffect(0,m)
if Duel.GetMZoneCount(tp)>0 and Duel.SelectYesNo(tp,aux.Stringid(m,0)) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then if Duel.GetMZoneCount(tp)>0 and Duel.SelectYesNo(tp,aux.Stringid(m,0)) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then
Duel.ConfirmDecktop(tp,num) Duel.ConfirmDecktop(tp,num)
local g=Duel.GetDecktopGroup(tp,num):Filter(Card.IsSetCard,nil,0x62a) local g=Duel.GetDecktopGroup(tp,num):Filter(Card.IsSetCard,nil,0x62a)
...@@ -67,5 +71,6 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -67,5 +71,6 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function cm.bkop(e,tp,eg,ep,ev,re,r,rp) function cm.bkop(e,tp,eg,ep,ev,re,r,rp)
local tp=e:GetHandlerPlayer()
Duel.SendtoHand(e:GetHandler(),tp,REASON_EFFECT) Duel.SendtoHand(e:GetHandler(),tp,REASON_EFFECT)
end end
\ No newline at end of file
...@@ -25,21 +25,25 @@ function cm.initial_effect(c) ...@@ -25,21 +25,25 @@ function cm.initial_effect(c)
end end
end end
function cm.checkop(e,tp,eg,ep,ev,re,r,rp) function cm.checkop(e,tp,eg,ep,ev,re,r,rp)
--local tp=e:GetHandlerPlayer()
Duel.RegisterFlagEffect(tp,m,RESET_CHAIN,0,1) Duel.RegisterFlagEffect(tp,m,RESET_CHAIN,0,1)
end end
function cm.filter(c,e,tp,s) function cm.filter(c,tp)
local mg=Duel.GetMatchingGroup(Card.IsType,tp,LOCATION_HAND+LOCATION_MZONE,0,nil,TYPE_MONSTER) local mg=Duel.GetMatchingGroup(Card.IsType,tp,LOCATION_HAND+LOCATION_MZONE,0,nil,TYPE_MONSTER)
return c:IsSynchroSummonable(nil,mg) return c:IsSynchroSummonable(nil,mg)
end end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp) function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
local num=Duel.GetFlagEffect(tp,m) local tp=e:GetHandlerPlayer()
local num=Duel.GetFlagEffect(0,m)
local g=Duel.GetDecktopGroup(tp,num) local g=Duel.GetDecktopGroup(tp,num)
local result=g:FilterCount(Card.IsAbleToHand,nil) --Debug.Message(tp)
return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_EXTRA,0,1,nil) and g:GetCount()>=num and result>0 and Duel.GetMZoneCount(tp)>0 --Debug.Message(g:IsExists(Card.IsAbleToHand,1,nil))
return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_EXTRA,0,1,nil,tp) and g:GetCount()>=num and g:IsExists(Card.IsAbleToHand,1,nil) and Duel.GetMZoneCount(tp)>0
end end
function cm.spop(e,tp,eg,ep,ev,re,r,rp) function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local num=Duel.GetFlagEffect(tp,m) local tp=e:GetHandlerPlayer()
local num=Duel.GetFlagEffect(0,m)
if Duel.GetMZoneCount(tp)>0 and Duel.SelectYesNo(tp,aux.Stringid(m,0)) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then if Duel.GetMZoneCount(tp)>0 and Duel.SelectYesNo(tp,aux.Stringid(m,0)) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then
Duel.ConfirmDecktop(tp,num) Duel.ConfirmDecktop(tp,num)
local g=Duel.GetDecktopGroup(tp,num):Filter(Card.IsSetCard,nil,0x62a) local g=Duel.GetDecktopGroup(tp,num):Filter(Card.IsSetCard,nil,0x62a)
...@@ -67,5 +71,6 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -67,5 +71,6 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function cm.bkop(e,tp,eg,ep,ev,re,r,rp) function cm.bkop(e,tp,eg,ep,ev,re,r,rp)
local tp=e:GetHandlerPlayer()
Duel.SendtoHand(e:GetHandler(),tp,REASON_EFFECT) Duel.SendtoHand(e:GetHandler(),tp,REASON_EFFECT)
end end
\ No newline at end of file
...@@ -25,21 +25,25 @@ function cm.initial_effect(c) ...@@ -25,21 +25,25 @@ function cm.initial_effect(c)
end end
end end
function cm.checkop(e,tp,eg,ep,ev,re,r,rp) function cm.checkop(e,tp,eg,ep,ev,re,r,rp)
--local tp=e:GetHandlerPlayer()
Duel.RegisterFlagEffect(tp,m,RESET_CHAIN,0,1) Duel.RegisterFlagEffect(tp,m,RESET_CHAIN,0,1)
end end
function cm.filter(c,e,tp,s) function cm.filter(c,tp)
local mg=Duel.GetMatchingGroup(Card.IsType,tp,LOCATION_HAND+LOCATION_MZONE,0,nil,TYPE_MONSTER) local mg=Duel.GetMatchingGroup(Card.IsType,tp,LOCATION_HAND+LOCATION_MZONE,0,nil,TYPE_MONSTER)
return c:IsSynchroSummonable(nil,mg) return c:IsSynchroSummonable(nil,mg)
end end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp) function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
local num=Duel.GetFlagEffect(tp,m) local tp=e:GetHandlerPlayer()
local num=Duel.GetFlagEffect(0,m)
local g=Duel.GetDecktopGroup(tp,num) local g=Duel.GetDecktopGroup(tp,num)
local result=g:FilterCount(Card.IsAbleToHand,nil) --Debug.Message(tp)
return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_EXTRA,0,1,nil) and g:GetCount()>=num and result>0 and Duel.GetMZoneCount(tp)>0 --Debug.Message(g:IsExists(Card.IsAbleToHand,1,nil))
return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_EXTRA,0,1,nil,tp) and g:GetCount()>=num and g:IsExists(Card.IsAbleToHand,1,nil) and Duel.GetMZoneCount(tp)>0
end end
function cm.spop(e,tp,eg,ep,ev,re,r,rp) function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local num=Duel.GetFlagEffect(tp,m) local tp=e:GetHandlerPlayer()
local num=Duel.GetFlagEffect(0,m)
if Duel.GetMZoneCount(tp)>0 and Duel.SelectYesNo(tp,aux.Stringid(m,0)) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then if Duel.GetMZoneCount(tp)>0 and Duel.SelectYesNo(tp,aux.Stringid(m,0)) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then
Duel.ConfirmDecktop(tp,num) Duel.ConfirmDecktop(tp,num)
local g=Duel.GetDecktopGroup(tp,num):Filter(Card.IsSetCard,nil,0x62a) local g=Duel.GetDecktopGroup(tp,num):Filter(Card.IsSetCard,nil,0x62a)
...@@ -67,5 +71,6 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -67,5 +71,6 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function cm.bkop(e,tp,eg,ep,ev,re,r,rp) function cm.bkop(e,tp,eg,ep,ev,re,r,rp)
local tp=e:GetHandlerPlayer()
Duel.SendtoHand(e:GetHandler(),tp,REASON_EFFECT) Duel.SendtoHand(e:GetHandler(),tp,REASON_EFFECT)
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