Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -742,7 +742,7 @@ public void giveRewards() {
rewards[3].minWins = 3;
rewards[3].maxWins = 3;
rewardDeck.setName("Drafted Deck");
rewardDeck.setComment("Prize for placing 1st overall in draft event");
rewardDeck.setComment(Forge.getLocalizer().getMessage("advPrizeDraftFirst"));
rewards[3].cardRewards = new Deck[]{rewardDeck};

} else if (format == AdventureEventController.EventFormat.Sealed) {
Expand All @@ -751,7 +751,7 @@ public void giveRewards() {
rewards[3].minWins = 3;
rewards[3].maxWins = 3;
rewardDeck.setName("Sealed Card Pool");
rewardDeck.setComment("Prize for placing 1st overall in sealed event");
rewardDeck.setComment(Forge.getLocalizer().getMessage("advPrizeSealedFirst"));
rewards[3].cardRewards = new Deck[]{rewardDeck};

} else if (format == AdventureEventController.EventFormat.Jumpstart) {
Expand Down Expand Up @@ -854,7 +854,7 @@ public void giveRewards() {
public String getDescription(PointOfInterestChanges changes) {
float townPriceModifier = changes == null ? 1f : changes.getTownPriceModifier();
if (format == AdventureEventController.EventFormat.Draft) {
description = "Event Type: Booster Draft\n";
description = Forge.getLocalizer().getMessage("advEventTypeBoosterDraft");
description += "Block: " + getCardBlock() + "\n";
description += "Boosters: " + String.join(", ", packConfiguration) + "\n";
description += "Competition Style: " + participants.length + " players, matches played as best of " + eventRules.gamesPerMatch + ", " + (eventRules.getPairingDescription()) + "\n\n";
Expand Down Expand Up @@ -886,8 +886,8 @@ public String getDescription(PointOfInterestChanges changes) {
} else {
description += "\n";
}
description += "Prizes\n3 round wins: 500 gold\n2 round wins: 200 gold\n1 round win: 100 gold\n";
description += "Participating in this event will award a valueless copy of each card in your Jumpstart deck.";
description += Forge.getLocalizer().getMessage("advDraftPrizesDesc");
description += Forge.getLocalizer().getMessage("advJumpstartParticipationPrize");
} else if (format == AdventureEventController.EventFormat.Sealed) {
description = "Event Type: Sealed Deck\n";
description += "Block: " + getCardBlock() + "\n";
Expand All @@ -909,7 +909,7 @@ public String getDescription(PointOfInterestChanges changes) {
}

description += "Prizes\n";
description += "Champion (3 wins): Keep your Sealed pool (all " + packConfiguration.length + " boosters)\n";
description += Forge.getLocalizer().getMessage("advSealedChampionPrize", packConfiguration.length);
description += "2+ wins: Silver Challenge Coin\n";
description += String.format("1+ wins: %s Booster, %s Booster\n", rewardPacks[1].getComment(), rewardPacks[2].getComment());
description += String.format("0 wins: %s Booster", rewardPacks[0].getComment());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import com.badlogic.gdx.math.Vector2;
import com.badlogic.gdx.utils.Array;
import forge.Forge;
import forge.adventure.character.EnemySprite;
import forge.adventure.pointofintrest.PointOfInterest;
import forge.adventure.scene.GameScene;
Expand Down Expand Up @@ -107,7 +108,7 @@ public AdventureQuestData(AdventureQuestData data){
public AdventureQuestData()
{
declinedDialog = new DialogData();
declinedDialog.text = "Come back tomorrow and perhaps I'll have something that you'll actually be willing to do.";
declinedDialog.text = Forge.getLocalizer().getMessage("advDefaultDeclinedDialog");
DialogData dismiss = new DialogData();
dismiss.name = "(Catching the not so subtle hint, you leave.)";
declinedDialog.options = new DialogData[1];
Expand Down
3 changes: 2 additions & 1 deletion forge-gui-mobile/src/forge/adventure/data/EffectData.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package forge.adventure.data;

import com.badlogic.gdx.utils.Array;
import forge.Forge;
import forge.item.IPaperCard;
import forge.item.PaperCard;
import forge.item.PaperToken;
Expand Down Expand Up @@ -109,7 +110,7 @@ public String getDescription() {
if(goldModifier > 0.0f)
description+="Shop discount: x" + (goldModifier) + "\n";
if(cardRewardBonus > 0)
description += "Bonus enemy deck rewards: +" + (cardRewardBonus) + "\n";
description += Forge.getLocalizer().getMessage("advBonusEnemyDeckRewards", cardRewardBonus);
if(this.opponent != null) {
String oppEffect = this.opponent.getDescription();
description += "Gives Opponent:\n";
Expand Down
3 changes: 2 additions & 1 deletion forge-gui-mobile/src/forge/adventure/scene/DuelScene.java
Original file line number Diff line number Diff line change
Expand Up @@ -437,7 +437,8 @@ public void enter() {
if (deck == null) {
isDeckMissing = true;
boolean canUseGeneticAI = Config.instance().getConfigData().enableGeneticAI;
isDeckMissingMsg = "Deck for " + currentEnemy.getName() + " is missing! " + (this.eventData == null ? (canUseGeneticAI ? "Genetic AI deck will be used." : "Player deck will be used.") : "Player deck will be used.");
isDeckMissingMsg = Forge.getLocalizer().getMessage("advDeckMissingForEnemy", currentEnemy.getName())
+ (this.eventData == null ? (canUseGeneticAI ? Forge.getLocalizer().getMessage("advGeneticAiDeckWillBeUsed") : Forge.getLocalizer().getMessage("advPlayerDeckWillBeUsed")) : Forge.getLocalizer().getMessage("advPlayerDeckWillBeUsed"));
System.err.println(isDeckMissingMsg);
deck = this.eventData == null && canUseGeneticAI ? Aggregates.random(DeckProxy.getAllGeneticAIDecks()).getDeck() : this.playerDeck;
}
Expand Down
9 changes: 4 additions & 5 deletions forge-gui-mobile/src/forge/adventure/scene/EventScene.java
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ private EventScene() {
enterWithShards.condition = new DialogData.ConditionData[]{hasShards};

if (currentEvent.eventRules.acceptsChallengeCoin) {
enterWithCoin.name = "Redeem a Challenge Coin [+ChallengeCoin]";
enterWithCoin.name = Forge.getLocalizer().getMessage("advRedeemChallengeCoin");

DialogData.ConditionData hasCoin = new DialogData.ConditionData();
hasCoin.item = "Challenge Coin";
Expand All @@ -88,7 +88,7 @@ private EventScene() {
giveCoin.removeItem = hasCoin.item;
enterWithCoin.action = new DialogData.ActionData[]{giveCoin};
} else if (currentEvent.eventRules.acceptsSilverChallengeCoin) {
enterWithCoin.name = "Redeem a Challenge Coin [+SilverChallengeCoin]";
enterWithCoin.name = Forge.getLocalizer().getMessage("advRedeemSilverChallengeCoin");
DialogData.ConditionData hasCoin = new DialogData.ConditionData();
hasCoin.item = "Silver Challenge Coin";
enterWithCoin.condition = new DialogData.ConditionData[]{hasCoin};
Expand All @@ -97,7 +97,7 @@ private EventScene() {
giveCoin.removeItem = hasCoin.item;
enterWithCoin.action = new DialogData.ActionData[]{giveCoin};
} else if (currentEvent.eventRules.acceptsBronzeChallengeCoin) {
enterWithCoin.name = "Redeem a Challenge Coin [+BronzeChallengeCoin]";
enterWithCoin.name = Forge.getLocalizer().getMessage("advRedeemBronzeChallengeCoin");
DialogData.ConditionData hasCoin = new DialogData.ConditionData();
hasCoin.item = "Bronze Challenge Coin";
enterWithCoin.condition = new DialogData.ConditionData[]{hasCoin};
Expand Down Expand Up @@ -246,8 +246,7 @@ private void refresh() {
List<AdventureEventData.AdventureEventMatch> matches = currentEvent.getMatches(i + 1);

if (matches == null) {
//todo: add translation
round.add(Controls.newTextraLabel("Pairings not yet generated"));
round.add(Controls.newTextraLabel(Forge.getLocalizer().getMessage("advPairingsNotGenerated")));
} else {
Table roundScrollContainer = new Table(Controls.getSkin());
for (AdventureEventData.AdventureEventMatch match : matches) {
Expand Down
58 changes: 29 additions & 29 deletions forge-gui-mobile/src/forge/adventure/scene/NewGameScene.java
Original file line number Diff line number Diff line change
Expand Up @@ -464,98 +464,98 @@ private void showModeHelp() {
boolean enableGeneticAI = Config.instance().getConfigData().enableGeneticAI;

modeSummary = new DialogData();
modeSummary.name = "Summary";
modeSummary.name = Forge.getLocalizer().getMessage("lblSummary");

StringBuilder summaryText = new StringBuilder();
switch (selectedMode) {
case Standard:
summaryText.append("Mode: Standard\n\nYour starting deck is built from 2-3 Jumpstart packs of twenty cards each.\n\n");
summaryText.append(Forge.getLocalizer().getMessage("advModeStandardSummary"));
switch (selectedDifficulty.name) {
case "Easy":
summaryText.append("On your currently selected difficulty, Easy, you will receive three jumpstart packs of your chosen color.");
summaryText.append(Forge.getLocalizer().getMessage("advDiffEasyStandard"));
break;
case "Normal":
summaryText.append("On your currently selected difficulty, Normal, you will receive two jumpstart packs of your chosen color and one of an allied color.");
summaryText.append(Forge.getLocalizer().getMessage("advDiffNormalStandard"));
break;
case "Hard":
summaryText.append("On your currently selected difficulty, Hard, you will receive one jumpstart pack of your chosen color and one of an allied color.");
summaryText.append(Forge.getLocalizer().getMessage("advDiffHardStandard"));
break;
case "Insane":
summaryText.append("On your currently selected difficulty, Insane, you will receive one jumpstart pack of your chosen color and one of an allied color.");
summaryText.append(Forge.getLocalizer().getMessage("advDiffInsaneStandard"));
break;
default:
difficultySummary.text = "((Cannot determine starter deck based on custom difficulty settings))";
difficultySummary.text = Forge.getLocalizer().getMessage("advCannotDetermineStarterDeck");
break;
}
break;
case Constructed:
summaryText.append("Mode: Constructed\n\nYou will receive a specific preconstructed deck based on your chosen color and difficulty.\n\n");
summaryText.append(Forge.getLocalizer().getMessage("advModeConstructedSummary"));
switch (selectedDifficulty.name) {
case "Easy":
summaryText.append("On your currently selected difficulty, Easy, your deck will only contain your chosen color.");
summaryText.append(Forge.getLocalizer().getMessage("advDiffEasyConstructed"));
break;
case "Normal":
summaryText.append("On your currently selected difficulty, Normal, your deck will contain your chosen color and one allied color.");
summaryText.append(Forge.getLocalizer().getMessage("advDiffNormalConstructed"));
break;
case "Hard":
summaryText.append("On your currently selected difficulty, Hard, your deck will contain your chosen color and one opposing color.");
summaryText.append(Forge.getLocalizer().getMessage("advDiffHardConstructed"));
break;
case "Insane":
summaryText.append("On your currently selected difficulty, Insane, your deck will contain your chosen color and one opposing color.");
summaryText.append(Forge.getLocalizer().getMessage("advDiffInsaneConstructed"));
break;
default:
difficultySummary.text = "((Cannot determine starter deck based on custom difficulty settings))";
difficultySummary.text = Forge.getLocalizer().getMessage("advCannotDetermineStarterDeck");
break;
}
break;
case Pile:
summaryText.append("Mode: Pile\n\nYou will receive a random pile of cards based on your chosen color and difficulty.\n\n");
summaryText.append(Forge.getLocalizer().getMessage("advModePileSummary"));
switch (selectedDifficulty.name) {
case "Easy":
summaryText.append("On your currently selected difficulty, Easy, your deck will only contain your chosen color and one allied color.");
summaryText.append(Forge.getLocalizer().getMessage("advDiffEasyPile"));
break;
case "Normal":
summaryText.append("On your currently selected difficulty, Normal, your deck will contain your chosen color and two allied colors.");
summaryText.append(Forge.getLocalizer().getMessage("advDiffNormalPile"));
break;
case "Hard":
summaryText.append("On your currently selected difficulty, Hard, your deck will contain your chosen color and two allied colors.\n\n");
summaryText.append("You will receive less uncommon and rare cards than on Normal difficulty.");
summaryText.append(Forge.getLocalizer().getMessage("advDiffHardPile"));
summaryText.append(Forge.getLocalizer().getMessage("advPileLessRareReward"));
break;
case "Insane":
summaryText.append("On your currently selected difficulty, Insane, your deck will contain your chosen color and two allied colors.\n\n");
summaryText.append("You will receive less uncommon and rare cards than on Normal difficulty.");
summaryText.append(Forge.getLocalizer().getMessage("advDiffInsanePile"));
summaryText.append(Forge.getLocalizer().getMessage("advPileLessRareReward"));
break;
default:
difficultySummary.text = "((Cannot determine starter deck based on custom difficulty settings))";
difficultySummary.text = Forge.getLocalizer().getMessage("advCannotDetermineStarterDeck");
break;
}
break;
case Chaos:
summaryText.append("Mode: Chaos\n\nYou (and all enemies) will receive a random preconstructed deck.\n\nWarning: This will make encounter difficulty vary wildly from the developers' intent");
summaryText.append(Forge.getLocalizer().getMessage("advModeChaosSummary"));
break;
case Custom:
if (enableGeneticAI) {
summaryText.append("Mode: Custom\n\nChoose your own preconstructed deck. Enemies can receive a random genetic AI deck (difficult).\n\nWarning: This will make encounter difficulty vary wildly from the developers' intent");
summaryText.append(Forge.getLocalizer().getMessage("advModeCustomGeneticSummary"));
} else {
summaryText.append("Mode: Custom\n\nChoose your own preconstructed deck.");
summaryText.append(Forge.getLocalizer().getMessage("advModeCustomSummary"));
}
break;
case Precon:
summaryText.append("Mode: Precon\n\nYou will receive a specific preconstructed deck. You can choose a random or a specific preconstructed deck from an edition of your choice.\n\n");
summaryText.append(Forge.getLocalizer().getMessage("advModePreconSummary"));
break;
case Commander:
summaryText.append("Mode: Commander\n\nYou will be given a preconstructed commander deck based on the chosen color theme to start the playthrough.\n\nGood luck on your quest of creating a coherent deck that can win consistently and defeat the bosses.");
summaryText.append(Forge.getLocalizer().getMessage("advModeCommanderSummary"));
break;
case CommanderPrecon:
summaryText.append("Mode: Commander Precon\n\nChoose a named commander preconstructed deck to start the playthrough.\n\nThis uses Commander deckbuilding and game rules, but lets you pick from the curated commander precon folder.");
summaryText.append(Forge.getLocalizer().getMessage("advModeCommanderPreconSummary"));
break;
default:
summaryText.append("No summary available for this game mode.");
summaryText.append(Forge.getLocalizer().getMessage("advNoModeSummaryAvailable"));
break;
}

DialogData dismiss = new DialogData();
dismiss.name = "OK";
dismiss.name = Forge.getLocalizer().getMessage("lblOK");
modeSummary.text = summaryText.toString();
modeSummary.options = new DialogData[1];
modeSummary.options[0] = dismiss;
Expand Down
8 changes: 4 additions & 4 deletions forge-gui-mobile/src/forge/adventure/scene/SettingsScene.java
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ public void clicked(InputEvent event, float x, float y) {
Config.instance().saveSettings();
return null;
});
addLabel("Reward/Shop Card Display Ratio");
addLabel(Forge.getLocalizer().getMessage("advRewardShopCardDisplayRatio"));
settingGroup.add(rewardCardAdjLandscape).align(Align.right).pad(2);
SelectBox<Float> tooltipAdjLandscape = Controls.newComboBox(new Float[]{0.6f, 0.65f, 0.7f, 0.75f, 0.8f, 0.85f, 0.9f, 0.95f, 1f, 1.05f, 1.1f, 1.15f, 1.2f, 1.25f, 1.3f, 1.35f, 1.4f, 1.45f, 1.5f, 1.55f, 1.6f}, Config.instance().getSettingData().cardTooltipAdjLandscape, o -> {
Float val = (Float) o;
Expand All @@ -162,7 +162,7 @@ public void clicked(InputEvent event, float x, float y) {
Config.instance().saveSettings();
return null;
});
addLabel("Reward/Shop Card Tooltip Ratio");
addLabel(Forge.getLocalizer().getMessage("advRewardShopCardTooltipRatio"));
settingGroup.add(tooltipAdjLandscape).align(Align.right).pad(2);
} else {
//portrait adjustment
Expand All @@ -174,7 +174,7 @@ public void clicked(InputEvent event, float x, float y) {
Config.instance().saveSettings();
return null;
});
addLabel("Reward/Shop Card Display Ratio");
addLabel(Forge.getLocalizer().getMessage("advRewardShopCardDisplayRatio"));
settingGroup.add(rewardCardAdj).align(Align.right).pad(2);
SelectBox<Float> tooltipAdj = Controls.newComboBox(new Float[]{0.5f, 0.6f, 0.7f, 0.8f, 0.9f, 1f, 1.1f, 1.2f, 1.3f, 1.4f, 1.5f, 1.6f, 1.8f, 1.9f, 2f}, Config.instance().getSettingData().cardTooltipAdj, o -> {
Float val = (Float) o;
Expand All @@ -184,7 +184,7 @@ public void clicked(InputEvent event, float x, float y) {
Config.instance().saveSettings();
return null;
});
addLabel("Reward/Shop Card Tooltip Ratio");
addLabel(Forge.getLocalizer().getMessage("advRewardShopCardTooltipRatio"));
settingGroup.add(tooltipAdj).align(Align.right).pad(2);
}
if (!GuiBase.isAndroid()) {
Expand Down
Loading
Loading