forked from External/mage
[AVR] Second Guest + tests. Refactored filters.
This commit is contained in:
parent
3fac42fc3c
commit
32e29392d2
184 changed files with 823 additions and 562 deletions
|
|
@ -112,7 +112,7 @@ public class CardsImpl extends LinkedHashSet<UUID> implements Cards, Serializabl
|
|||
public int count(FilterCard filter, Game game) {
|
||||
int result = 0;
|
||||
for (UUID card: this) {
|
||||
if (filter.match(game.getCard(card)))
|
||||
if (filter.match(game.getCard(card), game))
|
||||
result++;
|
||||
}
|
||||
return result;
|
||||
|
|
@ -132,7 +132,7 @@ public class CardsImpl extends LinkedHashSet<UUID> implements Cards, Serializabl
|
|||
public Set<Card> getCards(FilterCard filter, Game game) {
|
||||
Set<Card> cards = new LinkedHashSet<Card>();
|
||||
for (UUID card: this) {
|
||||
boolean match = filter.match(game.getCard(card));
|
||||
boolean match = filter.match(game.getCard(card), game);
|
||||
if (match)
|
||||
cards.add(game.getCard(card));
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue