mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-18 19:58:00 +00:00
- Simplified the code for random set codes in generated decks.
This commit is contained in:
@@ -116,7 +116,7 @@ public abstract class GenerateColoredDeckBase {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Card tCard = c.toForgeCard();
|
Card tCard = c.toForgeCard();
|
||||||
tCard.setCurSetCode(Aggregates.random(c.toForgeCard().getSets()).getCode());
|
tCard.setRandomSetCode();
|
||||||
|
|
||||||
tDeck.add(CardDb.instance().getCard(tCard));
|
tDeck.add(CardDb.instance().getCard(tCard));
|
||||||
final int n = this.cardCounts.get(c.getName());
|
final int n = this.cardCounts.get(c.getName());
|
||||||
@@ -137,7 +137,7 @@ public abstract class GenerateColoredDeckBase {
|
|||||||
// not an error if looped too much - could play singleton mode, with 6 slots for 3 non-basic lands.
|
// not an error if looped too much - could play singleton mode, with 6 slots for 3 non-basic lands.
|
||||||
|
|
||||||
Card tCard = CardDb.instance().getCard(s).toForgeCard();
|
Card tCard = CardDb.instance().getCard(s).toForgeCard();
|
||||||
tCard.setCurSetCode(Aggregates.random(tCard.getSets()).getCode());
|
tCard.setRandomSetCode();
|
||||||
|
|
||||||
tDeck.add(CardDb.instance().getCard(tCard));
|
tDeck.add(CardDb.instance().getCard(tCard));
|
||||||
final int n = this.cardCounts.get(s);
|
final int n = this.cardCounts.get(s);
|
||||||
@@ -174,7 +174,7 @@ public abstract class GenerateColoredDeckBase {
|
|||||||
this.cardCounts.put(color, nLand);
|
this.cardCounts.put(color, nLand);
|
||||||
|
|
||||||
Card tCard = CardDb.instance().getCard(color).toForgeCard();
|
Card tCard = CardDb.instance().getCard(color).toForgeCard();
|
||||||
tCard.setCurSetCode(Aggregates.random(tCard.getSets()).getCode());
|
tCard.setRandomSetCode();
|
||||||
for (int j = 0; j <= nLand; j++) {
|
for (int j = 0; j <= nLand; j++) {
|
||||||
tDeck.add(CardDb.instance().getCard(tCard));
|
tDeck.add(CardDb.instance().getCard(tCard));
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user