Skip to content

Commit

Permalink
Correction is MessageBoard.withScoredHuntingTrap
Browse files Browse the repository at this point in the history
  • Loading branch information
balthaB committed May 8, 2024
1 parent a0e170d commit 8282190
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/ch/epfl/chacun/MessageBoard.java
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,7 @@ public MessageBoard withScoredRiver(Area<Zone.River> river) {
*/
public MessageBoard withScoredHuntingTrap(PlayerColor scorer, Area<Zone.Meadow> adjacentMeadow,
Set<Animal> cancelledAnimals) {
Set<Animal> animals = Area.animals(adjacentMeadow, new HashSet<>());
animals.retainAll(cancelledAnimals);
Set<Animal> animals = Area.animals(adjacentMeadow, cancelledAnimals);
ArrayList<Message> messages = new ArrayList<>(this.messages);
// Calculate the data needed
Map<Animal.Kind, Integer> animalCount = countAnimals(animals);
Expand Down

0 comments on commit 8282190

Please sign in to comment.