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

2024/4/2 bug修复

parent af0f8a24
Pipeline #26210 passed with stages
in 6 minutes and 57 seconds
...@@ -19,9 +19,12 @@ end ...@@ -19,9 +19,12 @@ end
function cm.costfilter2(c) function cm.costfilter2(c)
return c:IsLevelAbove(1) and c:IsRace(RACE_CYBERSE) and c:IsAbleToDeckOrExtraAsCost() return c:IsLevelAbove(1) and c:IsRace(RACE_CYBERSE) and c:IsAbleToDeckOrExtraAsCost()
end end
function cm.costcheck2(g)
return g:GetClassCount(Card.GetLevel)==g:GetCount()
end
function cm.costcheck(g) function cm.costcheck(g)
return RD.GroupAllCount(g,Card.IsLocation,1,LOCATION_HAND) return RD.GroupAllCount(g,Card.IsLocation,1,LOCATION_HAND)
or (g:GetClassCount(Card.GetLevel)==g:GetCount() and RD.GroupAllCount(g,Card.IsLocation,5,LOCATION_GRAVE)) or (RD.GroupAllCount(g,Card.IsLocation,5,LOCATION_GRAVE) and cm.costcheck2(g))
end end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk) function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
local g1=Duel.GetMatchingGroup(cm.costfilter1,tp,LOCATION_HAND,0,nil) local g1=Duel.GetMatchingGroup(cm.costfilter1,tp,LOCATION_HAND,0,nil)
...@@ -30,7 +33,7 @@ function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -30,7 +33,7 @@ function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
local sg local sg
if g1:GetCount()<1 then if g1:GetCount()<1 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
sg=g2:Select(tp,5,5,nil) sg=g2:SelectSubGroup(tp,cm.costcheck2,false,5,5)
elseif g2:GetClassCount(Card.GetLevel)<5 then elseif g2:GetClassCount(Card.GetLevel)<5 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
sg=g1:Select(tp,1,1,nil) sg=g1:Select(tp,1,1,nil)
......
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