mirror of
https://github.com/GTNewHorizons/Botania.git
synced 2026-11-20 04:09:40 +00:00
Fix issues associated with last commit
This commit is contained in:
30 files changed
+67
-66
No files matched your search
@@ -171,7 +171,7 @@ public class RenderLexicon {
|
||||
font.drawString(font.trimStringToWidth(title, 80), 0, 0, 0xD69700);
|
||||
GlStateManager.translate(0F, 10F, 0F);
|
||||
GlStateManager.scale(0.6F, 0.6F, 0.6F);
|
||||
font.drawString(TextFormatting.ITALIC + "" + TextFormatting.BOLD + String.format(I18n.format("botaniamisc.edition"), ItemLexicon.getEdition()), 0, 0, 0xA07100);
|
||||
font.drawString(TextFormatting.ITALIC + "" + TextFormatting.BOLD + I18n.format("botaniamisc.edition", ItemLexicon.getEdition()), 0, 0, 0xA07100);
|
||||
|
||||
GlStateManager.translate(0F, 15F, 0F);
|
||||
font.drawString(I18n.format("botaniamisc.lexiconcover0"), 0, 0, 0x79ff92);
|
||||
|
||||
@@ -340,7 +340,7 @@ public class GuiLexicon extends GuiScreen {
|
||||
boolean unicode = fontRendererObj.getUnicodeFlag();
|
||||
fontRendererObj.drawString(title, left + 18, top + 13, color);
|
||||
fontRendererObj.setUnicodeFlag(true);
|
||||
fontRendererObj.drawString(String.format(I18n.format("botaniamisc.edition"), ItemLexicon.getEdition()), left + 24, top + 22, color);
|
||||
fontRendererObj.drawString(I18n.format("botaniamisc.edition", ItemLexicon.getEdition()), left + 24, top + 22, color);
|
||||
|
||||
String s = TextFormatting.BOLD + categoryHighlight;
|
||||
fontRendererObj.drawString(s, left + guiWidth / 2 - fontRendererObj.getStringWidth(s) / 2, top + 36, 0);
|
||||
|
||||
@@ -29,7 +29,7 @@ public class GuiButtonBookmark extends GuiButtonLexicon {
|
||||
if(displayString.equals("+"))
|
||||
tooltip.add(I18n.format("botaniamisc.clickToAdd"));
|
||||
else {
|
||||
tooltip.add(String.format(I18n.format("botaniamisc.bookmark"), id - GuiLexicon.BOOKMARK_START + 1));
|
||||
tooltip.add(I18n.format("botaniamisc.bookmark", id - GuiLexicon.BOOKMARK_START + 1));
|
||||
tooltip.add(TextFormatting.GRAY + I18n.format("botaniamisc.clickToSee"));
|
||||
tooltip.add(TextFormatting.GRAY + I18n.format("botaniamisc.shiftToRemove"));
|
||||
}
|
||||
|
||||
@@ -46,7 +46,7 @@ public class GuiButtonUpdateWarning extends GuiButtonLexicon {
|
||||
List<String> tooltip = new ArrayList<>();
|
||||
String version = PersistentVariableHelper.lastBotaniaVersion;
|
||||
for(int i = 0; i < 6; i++) {
|
||||
tooltip.add(TextFormatting.GRAY + String.format(I18n.format("botaniamisc.changes" + i), version).replaceAll("&", "\u00a7"));
|
||||
tooltip.add(TextFormatting.GRAY + I18n.format("botaniamisc.changes" + i, version).replaceAll("&", "\u00a7"));
|
||||
if(i == 3)
|
||||
tooltip.add("");
|
||||
}
|
||||
|
||||
@@ -46,7 +46,7 @@ public class ThreadDownloadMod extends Thread {
|
||||
@Override
|
||||
public void run() {
|
||||
try {
|
||||
ITextComponent component = ITextComponent.Serializer.jsonToComponent(String.format(I18n.format("botania.versioning.startingDownload"), fileName));
|
||||
ITextComponent component = ITextComponent.Serializer.jsonToComponent(I18n.format("botania.versioning.startingDownload", fileName));
|
||||
if(Minecraft.getMinecraft().thePlayer != null)
|
||||
Minecraft.getMinecraft().thePlayer.addChatMessage(component);
|
||||
|
||||
|
||||
@@ -15,6 +15,7 @@ import net.minecraft.client.resources.I18n;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.util.text.ITextComponent;
|
||||
import net.minecraft.util.text.Style;
|
||||
import net.minecraft.util.text.TextComponentString;
|
||||
import net.minecraft.util.text.TextComponentTranslation;
|
||||
import net.minecraft.util.text.TextFormatting;
|
||||
import net.minecraftforge.common.MinecraftForge;
|
||||
@@ -50,7 +51,7 @@ public final class VersionChecker {
|
||||
player.addChatComponentMessage(new TextComponentTranslation("botania.versioning.flavour" + player.worldObj.rand.nextInt(FLAVOUR_MESSAGES)).setStyle(new Style().setColor(TextFormatting.LIGHT_PURPLE)));
|
||||
player.addChatComponentMessage(new TextComponentTranslation("botania.versioning.outdated", clientBuild, onlineBuild));
|
||||
|
||||
ITextComponent component = ITextComponent.Serializer.jsonToComponent(I18n.format("botania.versioning.updateMessage").replaceAll("%version%", onlineVersion));
|
||||
ITextComponent component = ITextComponent.Serializer.jsonToComponent(I18n.format("botania.versioning.updateMessage", onlineVersion));
|
||||
player.addChatComponentMessage(component);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -81,7 +81,7 @@ public class ItemLaputaShard extends ItemMod implements ILensEffect, ITinyPlanet
|
||||
@SideOnly(Side.CLIENT)
|
||||
@Override
|
||||
public void addInformation(ItemStack stack, EntityPlayer player, List<String> list, boolean adv) {
|
||||
list.add(String.format(I18n.format("botaniamisc.shardLevel"), I18n.format("botania.roman" + (stack.getItemDamage() + 1))));
|
||||
list.add(I18n.format("botaniamisc.shardLevel", I18n.format("botania.roman" + (stack.getItemDamage() + 1))));
|
||||
}
|
||||
|
||||
@Nonnull
|
||||
|
||||
@@ -107,7 +107,7 @@ public class ItemLexicon extends ItemMod implements ILexicon, IElvenItem {
|
||||
@Override
|
||||
public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List<String> par3List, boolean par4) {
|
||||
if(GuiScreen.isShiftKeyDown()) {
|
||||
String edition = TextFormatting.GOLD + String.format(I18n.format("botaniamisc.edition"), getEdition());
|
||||
String edition = TextFormatting.GOLD + I18n.format("botaniamisc.edition", getEdition());
|
||||
if(!edition.isEmpty())
|
||||
par3List.add(edition);
|
||||
|
||||
@@ -119,7 +119,7 @@ public class ItemLexicon extends ItemMod implements ILexicon, IElvenItem {
|
||||
}
|
||||
|
||||
String format = typesKnown.size() == 1 ? "botaniamisc.knowledgeTypesSingular" : "botaniamisc.knowledgeTypesPlural";
|
||||
addStringToTooltip(String.format(I18n.format(format), typesKnown.size()), par3List);
|
||||
addStringToTooltip(I18n.format(format, typesKnown.size()), par3List);
|
||||
|
||||
for(KnowledgeType type : typesKnown)
|
||||
addStringToTooltip(" \u2022 " + I18n.format(type.getUnlocalizedName()), par3List);
|
||||
|
||||
@@ -107,7 +107,7 @@ public class ItemSignalFlare extends ItemMod implements IColorable {
|
||||
@Override
|
||||
public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List<String> par3List, boolean par4) {
|
||||
int storedColor = getColor(par1ItemStack);
|
||||
par3List.add(String.format(I18n.format("botaniamisc.flareColor"), I18n.format("botania.color" + storedColor)));
|
||||
par3List.add(I18n.format("botaniamisc.flareColor", I18n.format("botania.color" + storedColor)));
|
||||
}
|
||||
|
||||
public static ItemStack forColor(int color) {
|
||||
|
||||
@@ -82,7 +82,7 @@ public class ItemIncenseStick extends ItemMod implements IBrewItem, IBrewContain
|
||||
return;
|
||||
}
|
||||
|
||||
addStringToTooltip(TextFormatting.LIGHT_PURPLE + String.format(I18n.format("botaniamisc.brewOf"), I18n.format(brew.getUnlocalizedName(stack))), list);
|
||||
addStringToTooltip(TextFormatting.LIGHT_PURPLE + I18n.format("botaniamisc.brewOf", I18n.format(brew.getUnlocalizedName(stack))), list);
|
||||
for(PotionEffect effect : brew.getPotionEffects(stack)) {
|
||||
TextFormatting format = effect.getPotion().isBadEffect() ? TextFormatting.RED : TextFormatting.GRAY;
|
||||
PotionEffect longEffect = new PotionEffect(effect.getPotion(), effect.getDuration() * TIME_MULTIPLIER, effect.getAmplifier(), false, true);
|
||||
|
||||
@@ -102,11 +102,11 @@ public abstract class ItemBauble extends ItemMod implements IBauble, ICosmeticAt
|
||||
String key = vazkii.botania.client.core.helper.RenderHelper.getKeyDisplayString("Baubles Inventory");
|
||||
|
||||
if(key != null)
|
||||
addStringToTooltip(I18n.format("botania.baubletooltip").replaceAll("%key%", key), par3List);
|
||||
addStringToTooltip(I18n.format("botania.baubletooltip", key), par3List);
|
||||
|
||||
ItemStack cosmetic = getCosmeticItem(par1ItemStack);
|
||||
if(cosmetic != null)
|
||||
addStringToTooltip(String.format(I18n.format("botaniamisc.hasCosmetic"), cosmetic.getDisplayName()), par3List);
|
||||
addStringToTooltip(I18n.format("botaniamisc.hasCosmetic", cosmetic.getDisplayName()), par3List);
|
||||
|
||||
if(hasPhantomInk(par1ItemStack))
|
||||
addStringToTooltip(I18n.format("botaniamisc.hasPhantomInk"), par3List);
|
||||
|
||||
@@ -97,7 +97,7 @@ public class ItemBloodPendant extends ItemBauble implements IBrewContainer, IBre
|
||||
return;
|
||||
}
|
||||
|
||||
addStringToTooltip(TextFormatting.LIGHT_PURPLE + String.format(I18n.format("botaniamisc.brewOf"), I18n.format(brew.getUnlocalizedName(stack))), list);
|
||||
addStringToTooltip(TextFormatting.LIGHT_PURPLE + I18n.format("botaniamisc.brewOf", I18n.format(brew.getUnlocalizedName(stack))), list);
|
||||
for(PotionEffect effect : brew.getPotionEffects(stack)) {
|
||||
TextFormatting format = effect.getPotion().isBadEffect() ? TextFormatting.RED : TextFormatting.GRAY;
|
||||
addStringToTooltip(" " + format + I18n.format(effect.getEffectName()) + (effect.getAmplifier() == 0 ? "" : " " + I18n.format("botania.roman" + (effect.getAmplifier() + 1))), list);
|
||||
|
||||
+2
-2
@@ -107,9 +107,9 @@ public class ItemTerraPick extends ItemManasteelPick implements IManaItem, ISequ
|
||||
@SideOnly(Side.CLIENT)
|
||||
@Override
|
||||
public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List<String> par3List, boolean par4) {
|
||||
String rankFormat = I18n.format("botaniamisc.toolRank");
|
||||
String rank = I18n.format("botania.rank" + getLevel(par1ItemStack));
|
||||
par3List.add(String.format(rankFormat, rank).replaceAll("&", "\u00a7"));
|
||||
String rankFormat = I18n.format("botaniamisc.toolRank", rank);
|
||||
par3List.add(rankFormat.replaceAll("&", "\u00a7"));
|
||||
if(getMana(par1ItemStack) == Integer.MAX_VALUE)
|
||||
par3List.add(TextFormatting.RED + I18n.format("botaniamisc.getALife"));
|
||||
}
|
||||
|
||||
@@ -166,10 +166,10 @@ public class ItemLens extends ItemMod implements ILensControl, ICompositableLens
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@Override
|
||||
public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List par3List, boolean par4) {
|
||||
public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List<String> par3List, boolean par4) {
|
||||
int storedColor = getStoredColor(par1ItemStack);
|
||||
if(storedColor != -1)
|
||||
par3List.add(String.format(I18n.format("botaniamisc.color"), I18n.format("botania.color" + storedColor)));
|
||||
par3List.add(I18n.format("botaniamisc.color", I18n.format("botania.color" + storedColor)));
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -63,9 +63,9 @@ public class ItemRelic extends ItemMod implements IRelic {
|
||||
if(!hasUUID(stack)) {
|
||||
addStringToTooltip(I18n.format("botaniamisc.relicUnbound"), list);
|
||||
} else {
|
||||
addStringToTooltip(String.format(I18n.format("botaniamisc.relicSoulbound"), getSoulbindUsername(stack)), list);
|
||||
addStringToTooltip(I18n.format("botaniamisc.relicSoulbound", getSoulbindUsername(stack)), list);
|
||||
if(!getSoulbindUUID(stack).equals(player.getUniqueID()))
|
||||
addStringToTooltip(String.format(I18n.format("botaniamisc.notYourSagittarius"), getSoulbindUsername(stack)), list);
|
||||
addStringToTooltip(I18n.format("botaniamisc.notYourSagittarius", getSoulbindUsername(stack)), list);
|
||||
}
|
||||
|
||||
if(stack.getItem() == ModItems.aesirRing)
|
||||
|
||||
@@ -53,7 +53,7 @@ public class PageBrew extends PageRecipe implements ITwoNamedPage {
|
||||
FontRenderer renderer = Minecraft.getMinecraft().fontRendererObj;
|
||||
boolean unicode = renderer.getUnicodeFlag();
|
||||
renderer.setUnicodeFlag(true);
|
||||
String s = TextFormatting.BOLD + String.format(I18n.format("botaniamisc.brewOf"), I18n.format(brew.getUnlocalizedName()));
|
||||
String s = TextFormatting.BOLD + I18n.format("botaniamisc.brewOf", I18n.format(brew.getUnlocalizedName()));
|
||||
renderer.drawString(s, gui.getLeft() + gui.getWidth() / 2 - renderer.getStringWidth(s) / 2, y, 0x222222);
|
||||
renderer.setUnicodeFlag(unicode);
|
||||
PageText.renderText(x, y + 22, width, height, text);
|
||||
|
||||
@@ -106,7 +106,7 @@ public class PageManaInfusionRecipe extends PageRecipe {
|
||||
|
||||
HUDHandler.renderManaBar(x, y, 0x0000FF, 0.75F, recipe.getManaToConsume(), TilePool.MAX_MANA / ratio);
|
||||
|
||||
String ratioString = String.format(I18n.format("botaniamisc.ratio"), ratio);
|
||||
String ratioString = I18n.format("botaniamisc.ratio", ratio);
|
||||
String dropString = I18n.format("botaniamisc.drop") + " " + TextFormatting.BOLD + "(?)";
|
||||
|
||||
boolean hoveringOverDrop = false;
|
||||
@@ -136,8 +136,8 @@ public class PageManaInfusionRecipe extends PageRecipe {
|
||||
|
||||
if(hoveringOverDrop) {
|
||||
String key = RenderHelper.getKeyDisplayString("key.drop");
|
||||
String tip0 = I18n.format("botaniamisc.dropTip0").replaceAll("%key%", TextFormatting.GREEN + key + TextFormatting.WHITE);
|
||||
String tip1 = I18n.format("botaniamisc.dropTip1").replaceAll("%key%", TextFormatting.GREEN + key + TextFormatting.WHITE);
|
||||
String tip0 = I18n.format("botaniamisc.dropTip0", TextFormatting.GREEN + key + TextFormatting.WHITE);
|
||||
String tip1 = I18n.format("botaniamisc.dropTip1", TextFormatting.GREEN + key + TextFormatting.WHITE);
|
||||
RenderHelper.renderTooltip(mx, my, Arrays.asList(tip0, tip1));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -59,7 +59,7 @@ public class PageRuneRecipe extends PagePetalRecipe<RecipeRuneAltar> {
|
||||
|
||||
HUDHandler.renderManaBar(x, y, 0x0000FF, 0.75F, recipe.getManaUsage(), TilePool.MAX_MANA / ratio);
|
||||
|
||||
String ratioString = String.format(I18n.format("botaniamisc.ratio"), ratio);
|
||||
String ratioString = I18n.format("botaniamisc.ratio", ratio);
|
||||
String stopStr = I18n.format("botaniamisc.shiftToStopSpin");
|
||||
|
||||
boolean unicode = font.getUnicodeFlag();
|
||||
|
||||
Reference in new issue
Block a user