Region number calculation.
This commit is contained in:
@@ -52,7 +52,7 @@ public class Card17_105 extends AbstractPermanent {
|
||||
@Override
|
||||
public boolean accepts(GameState gameState, ModifiersQuerying modifiersQuerying, PhysicalCard physicalCard) {
|
||||
PhysicalCard mountDoom = Filters.findFirstActive(gameState, modifiersQuerying, Filters.name("Mount Doom"));
|
||||
return mountDoom != null && ((mountDoom.getSiteNumber() - 1) / 3) == GameUtils.getRegion(gameState);
|
||||
return mountDoom != null && (1 + ((mountDoom.getSiteNumber() - 1) / 3)) == GameUtils.getRegion(gameState);
|
||||
}
|
||||
}), -2));
|
||||
return modifiers;
|
||||
|
||||
@@ -93,6 +93,6 @@ public class GameUtils {
|
||||
}
|
||||
|
||||
public static int getRegion(GameState gameState) {
|
||||
return (gameState.getCurrentSiteNumber() - 1) / 3;
|
||||
return 1 + ((gameState.getCurrentSiteNumber() - 1) / 3);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user