mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 12:48:00 +00:00
- Re-enabled the option "Remove Artifacts" from generate decks.
- Little cleanups.
This commit is contained in:
@@ -128,7 +128,9 @@ public class Generate2ColorDeck {
|
||||
|
||||
// reduce to cards that match the colors
|
||||
CardList cl1 = allCards.getColor(this.color1);
|
||||
if(!Singletons.getModel().getPreferences().isDeckGenRmvArtifacts()) {
|
||||
cl1.addAll(allCards.getColor(Constant.Color.COLORLESS));
|
||||
}
|
||||
CardList cl2 = allCards.getColor(this.color2);
|
||||
|
||||
// remove multicolor cards that don't match the colors
|
||||
|
||||
@@ -262,6 +262,7 @@ public class OldGuiNewGame extends JFrame {
|
||||
final JMenu generatedDeck = new JMenu(ForgeProps.getLocalized(NewConstants.Lang.OldGuiNewGame.MenuBar.Options.Generate.TITLE));
|
||||
|
||||
generatedDeck.add(OldGuiNewGame.singletons);
|
||||
OldGuiNewGame.singletons.setSelected(Singletons.getModel().getPreferences().isDeckGenSingletons());
|
||||
OldGuiNewGame.singletons.addActionListener(new ActionListener() {
|
||||
@Override
|
||||
public void actionPerformed(final ActionEvent arg0) {
|
||||
@@ -271,15 +272,7 @@ public class OldGuiNewGame extends JFrame {
|
||||
});
|
||||
|
||||
generatedDeck.add(OldGuiNewGame.removeSmallCreatures);
|
||||
OldGuiNewGame.removeSmallCreatures.addActionListener(new ActionListener() {
|
||||
@Override
|
||||
public void actionPerformed(final ActionEvent arg0) {
|
||||
Singletons.getModel().getPreferences()
|
||||
.setDeckGenRmvSmall(OldGuiNewGame.removeSmallCreatures.isSelected());
|
||||
}
|
||||
});
|
||||
|
||||
generatedDeck.add(OldGuiNewGame.removeSmallCreatures);
|
||||
OldGuiNewGame.removeSmallCreatures.setSelected(Singletons.getModel().getPreferences().isDeckGenRmvSmall());
|
||||
OldGuiNewGame.removeSmallCreatures.addActionListener(new ActionListener() {
|
||||
@Override
|
||||
public void actionPerformed(final ActionEvent arg0) {
|
||||
@@ -289,6 +282,7 @@ public class OldGuiNewGame extends JFrame {
|
||||
});
|
||||
|
||||
generatedDeck.add(OldGuiNewGame.removeArtifacts);
|
||||
OldGuiNewGame.removeArtifacts.setSelected(Singletons.getModel().getPreferences().isDeckGenRmvArtifacts());
|
||||
OldGuiNewGame.removeArtifacts.addActionListener(new ActionListener() {
|
||||
@Override
|
||||
public void actionPerformed(final ActionEvent arg0) {
|
||||
|
||||
Reference in New Issue
Block a user