Commit d6436180 authored by yks's avatar yks

fix: fix the bug that can only search 1 card

parent 40fea7ee
Pipeline #27980 failed with stages
in 27 seconds
......@@ -51,9 +51,11 @@ function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function s.thop(e,tp,eg,ep,ev,re,r,rp)
local rg=Duel.GetMatchingGroup(s.filter,tp,LOCATION_DECK,0,nil)
if rg:GetCount()<2 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,s.filter,tp,LOCATION_DECK,0,2,2,nil)
if g:GetCount()>0 then
local g=rg:Select(tp,2,2,nil)
if g:GetCount()==2 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
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