mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-17 03:08:02 +00:00
- CheckStyle.
This commit is contained in:
@@ -101,7 +101,7 @@ public class TriggerHandler {
|
|||||||
public final void clearDelayedTrigger() {
|
public final void clearDelayedTrigger() {
|
||||||
this.delayedTriggers.clear();
|
this.delayedTriggers.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <p>
|
* <p>
|
||||||
* clearDelayedTrigger.
|
* clearDelayedTrigger.
|
||||||
@@ -111,7 +111,7 @@ public class TriggerHandler {
|
|||||||
*/
|
*/
|
||||||
public final void clearDelayedTrigger(Card card) {
|
public final void clearDelayedTrigger(Card card) {
|
||||||
ArrayList<Trigger> deltrigs = new ArrayList<Trigger>(this.delayedTriggers);
|
ArrayList<Trigger> deltrigs = new ArrayList<Trigger>(this.delayedTriggers);
|
||||||
|
|
||||||
for (Trigger trigger : deltrigs) {
|
for (Trigger trigger : deltrigs) {
|
||||||
if (trigger.getHostCard().equals(card)) {
|
if (trigger.getHostCard().equals(card)) {
|
||||||
this.delayedTriggers.remove(trigger);
|
this.delayedTriggers.remove(trigger);
|
||||||
|
|||||||
@@ -297,7 +297,7 @@ public final class DeckEditorShop extends DeckEditorBase {
|
|||||||
} else if (card instanceof BoosterPack) {
|
} else if (card instanceof BoosterPack) {
|
||||||
return 395;
|
return 395;
|
||||||
} else if (card instanceof PreconDeck) {
|
} else if (card instanceof PreconDeck) {
|
||||||
return ((PreconDeck)card).getRecommendedDeals().getCost();
|
return ((PreconDeck) card).getRecommendedDeals().getCost();
|
||||||
}
|
}
|
||||||
return 1337;
|
return 1337;
|
||||||
}
|
}
|
||||||
@@ -314,14 +314,14 @@ public final class DeckEditorShop extends DeckEditorBase {
|
|||||||
|
|
||||||
if (item instanceof CardPrinted) {
|
if (item instanceof CardPrinted) {
|
||||||
this.getTopTableWithCards().removeCard(item);
|
this.getTopTableWithCards().removeCard(item);
|
||||||
|
|
||||||
final CardPrinted card = (CardPrinted) item;
|
final CardPrinted card = (CardPrinted) item;
|
||||||
this.getBottomTableWithCards().addCard(card);
|
this.getBottomTableWithCards().addCard(card);
|
||||||
this.questData.getCards().buyCard(card, value);
|
this.questData.getCards().buyCard(card, value);
|
||||||
|
|
||||||
} else if (item instanceof BoosterPack) {
|
} else if (item instanceof BoosterPack) {
|
||||||
this.getTopTableWithCards().removeCard(item);
|
this.getTopTableWithCards().removeCard(item);
|
||||||
|
|
||||||
final BoosterPack booster = (BoosterPack) ((BoosterPack) item).clone();
|
final BoosterPack booster = (BoosterPack) ((BoosterPack) item).clone();
|
||||||
this.questData.getCards().buyBooster(booster, value);
|
this.questData.getCards().buyBooster(booster, value);
|
||||||
final List<CardPrinted> newCards = booster.getCards();
|
final List<CardPrinted> newCards = booster.getCards();
|
||||||
@@ -331,18 +331,18 @@ public final class DeckEditorShop extends DeckEditorBase {
|
|||||||
final CardListViewer c = new CardListViewer(booster.getName(),
|
final CardListViewer c = new CardListViewer(booster.getName(),
|
||||||
"You have found the following cards inside:", newCards);
|
"You have found the following cards inside:", newCards);
|
||||||
c.show();
|
c.show();
|
||||||
} else if ( item instanceof PreconDeck ) {
|
} else if (item instanceof PreconDeck) {
|
||||||
this.getTopTableWithCards().removeCard(item);
|
this.getTopTableWithCards().removeCard(item);
|
||||||
final PreconDeck deck = (PreconDeck)item;
|
final PreconDeck deck = (PreconDeck) item;
|
||||||
this.questData.getCards().buyPreconDeck(deck, value);
|
this.questData.getCards().buyPreconDeck(deck, value);
|
||||||
|
|
||||||
for (final CardPrinted card : deck.getDeck().getMain().toFlatList()) {
|
for (final CardPrinted card : deck.getDeck().getMain().toFlatList()) {
|
||||||
this.getBottomTableWithCards().addCard(card);
|
this.getBottomTableWithCards().addCard(card);
|
||||||
}
|
}
|
||||||
JOptionPane.showMessageDialog(null, String.format("Deck '%s' was added to youd decklist.%n%nCards from it were also added to your pool.", deck.getName()), "Thanks for purchase!", JOptionPane.INFORMATION_MESSAGE);
|
JOptionPane.showMessageDialog(null, String.format("Deck '%s' was added to youd decklist.%n%nCards from it were also added to your pool.", deck.getName()), "Thanks for purchase!", JOptionPane.INFORMATION_MESSAGE);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
this.creditsLabel.setText("Total credits: " + this.questData.getCredits());
|
this.creditsLabel.setText("Total credits: " + this.questData.getCredits());
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user