mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-16 10:48:00 +00:00
Display up to 2 + (wins/50) (max 8) options when unlocking sets.
This commit is contained in:
@@ -119,8 +119,7 @@ public class QuestUtilUnlockSets {
|
||||
return emptyEditions;
|
||||
}
|
||||
|
||||
final int nrChoices = qData.getUnlocksTokens();
|
||||
if (nrChoices < 1) { // Should never happen if we made it this far but better safe than sorry...
|
||||
if (qData.getUnlocksTokens() < 1) { // Should never happen if we made it this far but better safe than sorry...
|
||||
throw new RuntimeException("BUG? Could not find unlockable sets even though we should.");
|
||||
}
|
||||
List<CardEdition> options = new ArrayList<CardEdition>();
|
||||
@@ -162,7 +161,13 @@ public class QuestUtilUnlockSets {
|
||||
}
|
||||
Collections.reverse(options);
|
||||
|
||||
return Collections.unmodifiableList(options);
|
||||
final int nrChoices = Math.min(8, 2 + ((qData.getAchievements().getWin()) / 50));
|
||||
List<CardEdition> choices = new ArrayList<CardEdition>();
|
||||
|
||||
for (int i = 0; i < nrChoices; i++) {
|
||||
choices.add(options.get(i));
|
||||
}
|
||||
return Collections.unmodifiableList(choices);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user