Commit ac3349ea authored by wyykak's avatar wyykak

fix 25349

Signed-off-by: wyykak's avatarwyykak <wyy_1414@126.com>
parent 164a2b69
...@@ -80,7 +80,7 @@ function c25349.atkfilter(c) ...@@ -80,7 +80,7 @@ function c25349.atkfilter(c)
return c:IsFaceup() and c:IsSetCard(0x778) return c:IsFaceup() and c:IsSetCard(0x778)
end end
function c25349.con(e,tp,eg,ep,ev,re,r,rp) function c25349.con(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c25349.atkfilter,e:GetHandlerPlayer(),LOCATION_ONFIELD+LOCATION_GRAVE,0,nil) local g=Duel.GetMatchingGroup(c25349.atkfilter,e:GetHandlerPlayer(),LOCATION_ONFIELD+LOCATION_GRAVE,LOCATION_ONFIELD,nil)
return g:GetClassCount(Card.GetCode)>=e:GetLabel() return g:GetClassCount(Card.GetCode)>=e:GetLabel()
end end
function c25349.filter(c) function c25349.filter(c)
...@@ -88,7 +88,7 @@ function c25349.filter(c) ...@@ -88,7 +88,7 @@ function c25349.filter(c)
end end
function c25349.activate(e,tp,eg,ep,ev,re,r,rp) function c25349.activate(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end if not e:GetHandler():IsRelateToEffect(e) then return end
local g=Duel.GetMatchingGroup(c25349.atkfilter,tp,LOCATION_ONFIELD+LOCATION_GRAVE,0,nil) local g=Duel.GetMatchingGroup(c25349.atkfilter,tp,LOCATION_ONFIELD+LOCATION_GRAVE,LOCATION_ONFIELD,nil)
if g:GetClassCount(Card.GetCode)>=e:GetLabel() and Duel.IsExistingMatchingCard(c25349.filter,tp,LOCATION_DECK,0,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(25349,1)) then if g:GetClassCount(Card.GetCode)>=e:GetLabel() and Duel.IsExistingMatchingCard(c25349.filter,tp,LOCATION_DECK,0,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(25349,1)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c25349.filter,tp,LOCATION_DECK,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c25349.filter,tp,LOCATION_DECK,0,1,1,nil)
...@@ -102,7 +102,7 @@ function c25349.gfilter(c,tp) ...@@ -102,7 +102,7 @@ function c25349.gfilter(c,tp)
return c:GetPreviousControler()==tp return c:GetPreviousControler()==tp
end end
function c25349.thcon(e,tp,eg,ep,ev,re,r,rp) function c25349.thcon(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c25349.atkfilter,e:GetHandlerPlayer(),LOCATION_ONFIELD+LOCATION_GRAVE,0,nil) local g=Duel.GetMatchingGroup(c25349.atkfilter,e:GetHandlerPlayer(),LOCATION_ONFIELD+LOCATION_GRAVE,LOCATION_ONFIELD,nil)
return (Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2) and Duel.GetTurnPlayer()==tp return (Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2) and Duel.GetTurnPlayer()==tp
and eg:IsExists(c25349.gfilter,1,nil,tp) and g:GetClassCount(Card.GetCode)>=e:GetLabel() and eg:IsExists(c25349.gfilter,1,nil,tp) and g:GetClassCount(Card.GetCode)>=e:GetLabel()
end end
...@@ -157,7 +157,7 @@ function c25349.kfilter(c,tp) ...@@ -157,7 +157,7 @@ function c25349.kfilter(c,tp)
return c:GetSummonPlayer()==1-tp and c:IsControlerCanBeChanged() return c:GetSummonPlayer()==1-tp and c:IsControlerCanBeChanged()
end end
function c25349.condition(e,tp,eg,ep,ev,re,r,rp) function c25349.condition(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c25349.atkfilter,e:GetHandlerPlayer(),LOCATION_ONFIELD+LOCATION_GRAVE,0,nil) local g=Duel.GetMatchingGroup(c25349.atkfilter,e:GetHandlerPlayer(),LOCATION_ONFIELD+LOCATION_GRAVE,LOCATION_ONFIELD,nil)
local fg=eg:Filter(c25349.kfilter,nil,tp) local fg=eg:Filter(c25349.kfilter,nil,tp)
return g:GetClassCount(Card.GetCode)>=e:GetLabel() and fg:GetCount()>0 and Duel.GetLocationCount(tp,LOCATION_MZONE)>=fg:GetCount()-1 return g:GetClassCount(Card.GetCode)>=e:GetLabel() and fg:GetCount()>0 and Duel.GetLocationCount(tp,LOCATION_MZONE)>=fg:GetCount()-1
end end
......
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