From c983836f8d4f782bba459ada94ad3318839f8d71 Mon Sep 17 00:00:00 2001 From: Ellpeck Date: Sat, 12 Nov 2016 15:09:30 +0100 Subject: [PATCH] Finished up the new booklet. Woo-hoo! --- .../mod/booklet/InitBooklet.java | 7 +- .../mod/booklet/button/BookmarkButton.java | 7 +- .../mod/booklet/gui/GuiBooklet.java | 69 +++++++++-- .../mod/booklet/gui/GuiEntry.java | 7 +- .../mod/booklet/gui/GuiMainPage.java | 113 ++++++++++++++++-- .../mod/booklet/gui/GuiPage.java | 8 +- .../mod/data/PlayerData.java | 3 + .../mod/inventory/gui/TexturedButton.java | 13 +- .../mod/network/PacketHandler.java | 2 +- .../assets/actuallyadditions/lang/en_US.lang | 8 +- 10 files changed, 198 insertions(+), 39 deletions(-) diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/InitBooklet.java b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/InitBooklet.java index 1843eefa1..ca76d91aa 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/InitBooklet.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/InitBooklet.java @@ -48,7 +48,6 @@ import java.util.List; public final class InitBooklet{ - public static BookletChapter chapterIntro; public static BookletChapter[] chaptersIntroduction = new BookletChapter[8]; public static void preInit(){ @@ -100,10 +99,10 @@ public final class InitBooklet{ private static void initChapters(){ //Getting Started - chapterIntro = new BookletChapter("intro", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(InitItems.itemBooklet), new PageTextOnly(1), new PageTextOnly(2), new PageTextOnly(3)); - new BookletChapter("reviews", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(Items.BOOK), new PageTextOnly(1)); - chaptersIntroduction[1] = new BookletChapter("videoGuide", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(InitItems.itemMisc, 1, TheMiscItems.YOUTUBE_ICON.ordinal()), new PageLinkButton(1, "https://www.youtube.com/watch?v=fhjz0Ew56pM")).setImportant(); chaptersIntroduction[0] = new BookletChapter("bookTutorial", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(InitItems.itemBooklet), new PageTextOnly(1), new PageTextOnly(2), new PageTextOnly(3), new PageCrafting(4, ItemCrafting.recipeBook).setNoText()); + chaptersIntroduction[1] = new BookletChapter("videoGuide", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(InitItems.itemMisc, 1, TheMiscItems.YOUTUBE_ICON.ordinal()), new PageLinkButton(1, "https://www.youtube.com/watch?v=fhjz0Ew56pM")).setImportant(); + new BookletChapter("intro", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(InitItems.itemBooklet), new PageTextOnly(1), new PageTextOnly(2), new PageTextOnly(3)); + new BookletChapter("reviews", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(Items.BOOK), new PageTextOnly(1)); ArrayList crystalPages = new ArrayList(); crystalPages.addAll(Arrays.asList(new PageTextOnly(1).addTextReplacement("", TileEntityAtomicReconstructor.ENERGY_USE), new PageTextOnly(2), new PageTextOnly(3), new PagePicture(4, "pageAtomicReconstructor", 0).setNoText(), new PageTextOnly(5), new PageCrafting(6, BlockCrafting.recipeAtomicReconstructor).setWildcard())); for(int i = 0; i < LensRecipeHandler.MAIN_PAGE_RECIPES.size(); i++){ diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/button/BookmarkButton.java b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/button/BookmarkButton.java index 164f13f8d..6f807240c 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/button/BookmarkButton.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/button/BookmarkButton.java @@ -98,10 +98,13 @@ public class BookmarkButton extends GuiButton{ list.add(TextFormatting.ITALIC+"Shift-Click to remove"); } else{ - list.add(TextFormatting.GOLD+"None"); + list.add(TextFormatting.GOLD+"No Bookmark"); if(this.booklet instanceof GuiPage){ - list.add("Click to save current page"); + list.add("Click to bookmark current page"); + } + else{ + list.add("Open a page to bookmark it"); } } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiBooklet.java b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiBooklet.java index 4a928bd48..cbd797186 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiBooklet.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiBooklet.java @@ -16,6 +16,7 @@ import de.ellpeck.actuallyadditions.mod.booklet.button.BookmarkButton; import de.ellpeck.actuallyadditions.mod.data.PlayerData; import de.ellpeck.actuallyadditions.mod.data.PlayerData.PlayerSave; import de.ellpeck.actuallyadditions.mod.inventory.gui.TexturedButton; +import de.ellpeck.actuallyadditions.mod.network.PacketHandlerHelper; import de.ellpeck.actuallyadditions.mod.util.AssetUtil; import de.ellpeck.actuallyadditions.mod.util.StringUtil; import net.minecraft.client.gui.GuiButton; @@ -28,8 +29,10 @@ import net.minecraftforge.fml.relauncher.Side; import net.minecraftforge.fml.relauncher.SideOnly; import org.apache.commons.lang3.ArrayUtils; import org.lwjgl.input.Keyboard; +import org.lwjgl.input.Mouse; import java.io.IOException; +import java.util.Arrays; import java.util.List; @SideOnly(Side.CLIENT) @@ -45,7 +48,7 @@ public abstract class GuiBooklet extends GuiBookletBase{ private GuiButton buttonLeft; private GuiButton buttonRight; private GuiButton buttonBack; - private final BookmarkButton[] bookmarkButtons = new BookmarkButton[12]; + protected final BookmarkButton[] bookmarkButtons = new BookmarkButton[12]; public GuiTextField searchField; @@ -70,17 +73,20 @@ public abstract class GuiBooklet extends GuiBookletBase{ this.guiTop = (this.height-this.ySize)/2; if(this.hasPageLeftButton()){ - this.buttonLeft = new TexturedButton(RES_LOC_GADGETS, -2000, this.guiLeft-12, this.guiTop+this.ySize-8, 18, 54, 18, 10); + List hoverText = Arrays.asList(TextFormatting.GOLD+"Previous Page", TextFormatting.ITALIC+"Or scroll up"); + this.buttonLeft = new TexturedButton(RES_LOC_GADGETS, -2000, this.guiLeft-12, this.guiTop+this.ySize-8, 18, 54, 18, 10, hoverText); this.buttonList.add(this.buttonLeft); } if(this.hasPageRightButton()){ - this.buttonRight = new TexturedButton(RES_LOC_GADGETS, -2001, this.guiLeft+this.xSize-6, this.guiTop+this.ySize-8, 0, 54, 18, 10); + List hoverText = Arrays.asList(TextFormatting.GOLD+"Next Page", TextFormatting.ITALIC+"Or scroll down"); + this.buttonRight = new TexturedButton(RES_LOC_GADGETS, -2001, this.guiLeft+this.xSize-6, this.guiTop+this.ySize-8, 0, 54, 18, 10, hoverText); this.buttonList.add(this.buttonRight); } if(this.hasBackButton()){ - this.buttonBack = new TexturedButton(RES_LOC_GADGETS, -2002, this.guiLeft-15, this.guiTop-3, 36, 54, 18, 10); + List hoverText = Arrays.asList(TextFormatting.GOLD+"Go Back", TextFormatting.ITALIC+"Or right-click", TextFormatting.ITALIC.toString()+TextFormatting.GRAY+"Hold Shift for Main Page"); + this.buttonBack = new TexturedButton(RES_LOC_GADGETS, -2002, this.guiLeft-15, this.guiTop-3, 36, 54, 18, 10, hoverText); this.buttonList.add(this.buttonBack); } @@ -92,8 +98,10 @@ public abstract class GuiBooklet extends GuiBookletBase{ if(this.hasBookmarkButtons()){ PlayerSave data = PlayerData.getDataFromPlayer(this.mc.thePlayer); + + int xStart = this.guiLeft+this.xSize/2-16*this.bookmarkButtons.length/2; for(int i = 0; i < this.bookmarkButtons.length; i++){ - this.bookmarkButtons[i] = new BookmarkButton(1337+i, this.guiLeft+12+i*16, this.guiTop+this.ySize, this); + this.bookmarkButtons[i] = new BookmarkButton(1337+i, xStart+i*16, this.guiTop+this.ySize, this); this.buttonList.add(this.bookmarkButtons[i]); if(data.bookmarks[i] != null){ @@ -109,11 +117,18 @@ public abstract class GuiBooklet extends GuiBookletBase{ PlayerSave data = PlayerData.getDataFromPlayer(this.mc.thePlayer); + boolean change = false; for(int i = 0; i < this.bookmarkButtons.length; i++){ - data.bookmarks[i] = this.bookmarkButtons[i].assignedPage; + if(data.bookmarks[i] != this.bookmarkButtons[i].assignedPage){ + data.bookmarks[i] = this.bookmarkButtons[i].assignedPage; + change = true; + } } - data.lastOpenBooklet = this; + + if(change){ + PacketHandlerHelper.sendPlayerDataPacket(this.mc.thePlayer, true, false); + } } @Override @@ -146,9 +161,12 @@ public abstract class GuiBooklet extends GuiBookletBase{ } public void drawScreenPost(int mouseX, int mouseY, float partialTicks){ - if(this.hasBookmarkButtons()){ - for(BookmarkButton button : this.bookmarkButtons){ - button.drawHover(mouseX, mouseY); + for(GuiButton button : this.buttonList){ + if(button instanceof BookmarkButton){ + ((BookmarkButton)button).drawHover(mouseX, mouseY); + } + else if(button instanceof TexturedButton){ + ((TexturedButton)button).drawHover(mouseX, mouseY); } } } @@ -160,6 +178,28 @@ public abstract class GuiBooklet extends GuiBookletBase{ if(this.hasSearchBar()){ this.searchField.mouseClicked(mouseX, mouseY, mouseButton); } + + if(mouseButton == 1 && this.hasBackButton()){ + this.onBackButtonPressed(); + } + } + + @Override + public void handleMouseInput() throws IOException{ + int wheel = Mouse.getEventDWheel(); + if(wheel != 0){ + if(wheel < 0){ + if(this.hasPageRightButton()){ + this.onPageRightButtonPressed(); + } + } + else if(wheel > 0){ + if(this.hasPageLeftButton()){ + this.onPageLeftButtonPressed(); + } + } + } + super.handleMouseInput(); } @Override @@ -197,7 +237,7 @@ public abstract class GuiBooklet extends GuiBookletBase{ } public void onBackButtonPressed(){ - + this.mc.displayGuiScreen(new GuiMainPage(this.previousScreen)); } public boolean hasSearchBar(){ @@ -241,8 +281,13 @@ public abstract class GuiBooklet extends GuiBookletBase{ this.mc.displayGuiScreen(this.previousScreen); } else if(this.hasSearchBar() & this.searchField.isFocused()){ + String lastText = this.searchField.getText(); + this.searchField.textboxKeyTyped(typedChar, key); - this.onSearchBarChanged(this.searchField.getText()); + + if(!lastText.equals(this.searchField.getText())){ + this.onSearchBarChanged(this.searchField.getText()); + } } else{ super.keyTyped(typedChar, key); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiEntry.java b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiEntry.java index 5ac48ce75..7ccbbd670 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiEntry.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiEntry.java @@ -138,6 +138,11 @@ public class GuiEntry extends GuiBooklet{ @Override public void onBackButtonPressed(){ - this.mc.displayGuiScreen(this.parentPage); + if(!isShiftKeyDown()){ + this.mc.displayGuiScreen(this.parentPage); + } + else{ + super.onBackButtonPressed(); + } } } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiMainPage.java b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiMainPage.java index 2676c7735..989e0cf40 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiMainPage.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiMainPage.java @@ -12,10 +12,20 @@ package de.ellpeck.actuallyadditions.mod.booklet.gui; import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI; import de.ellpeck.actuallyadditions.api.booklet.IBookletEntry; +import de.ellpeck.actuallyadditions.mod.booklet.InitBooklet; import de.ellpeck.actuallyadditions.mod.booklet.button.EntryButton; +import de.ellpeck.actuallyadditions.mod.data.PlayerData; +import de.ellpeck.actuallyadditions.mod.data.PlayerData.PlayerSave; +import de.ellpeck.actuallyadditions.mod.network.PacketHandlerHelper; +import de.ellpeck.actuallyadditions.mod.util.ModUtil; +import de.ellpeck.actuallyadditions.mod.util.StringUtil; +import de.ellpeck.actuallyadditions.mod.util.Util; +import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiButton; import net.minecraft.client.gui.GuiScreen; import net.minecraft.item.ItemStack; +import net.minecraft.util.math.MathHelper; +import net.minecraft.util.text.TextFormatting; import net.minecraftforge.fml.relauncher.Side; import net.minecraftforge.fml.relauncher.SideOnly; @@ -24,6 +34,10 @@ import java.io.IOException; @SideOnly(Side.CLIENT) public class GuiMainPage extends GuiBooklet{ + private GuiButton tutorialButton; + private String bookletName; + private boolean showTutorial; + public GuiMainPage(GuiScreen previousScreen){ super(previousScreen, null); } @@ -32,15 +46,29 @@ public class GuiMainPage extends GuiBooklet{ public void initGui(){ super.initGui(); - for(int i = 0; i < BUTTONS_PER_PAGE; i++){ - if(ActuallyAdditionsAPI.BOOKLET_ENTRIES.size() > i){ - IBookletEntry entry = ActuallyAdditionsAPI.BOOKLET_ENTRIES.get(i); - this.buttonList.add(new EntryButton(i, this.guiLeft+156, this.guiTop+11+i*13, 115, 10, "- "+entry.getLocalizedNameWithFormatting(), null)); - } - else{ - return; - } + int flavor = 1; + if(this.mc.theWorld.rand.nextFloat() <= 0.1){ + flavor = MathHelper.getRandomIntegerInRange(this.mc.theWorld.rand, 2, 7); + } + this.bookletName = "info."+ModUtil.MOD_ID+".booklet.manualName.1."+flavor; + + PlayerSave data = PlayerData.getDataFromPlayer(this.mc.thePlayer); + if(!data.didBookTutorial){ + this.showTutorial = true; + + this.tutorialButton = new GuiButton(666666, this.guiLeft+140/2-50, this.guiTop+146, 100, 20, "Please click me <3"); + this.buttonList.add(this.tutorialButton); + } + + for(int i = 0; i < BUTTONS_PER_PAGE; i++){ + if(ActuallyAdditionsAPI.BOOKLET_ENTRIES.size() > i){ + IBookletEntry entry = ActuallyAdditionsAPI.BOOKLET_ENTRIES.get(i); + this.buttonList.add(new EntryButton(i, this.guiLeft+156, this.guiTop+11+i*13, 115, 10, "- "+entry.getLocalizedNameWithFormatting(), null)); } + else{ + return; + } + } } @Override @@ -53,11 +81,80 @@ public class GuiMainPage extends GuiBooklet{ } } } + else if(this.showTutorial && button == this.tutorialButton){ + if(this.hasBookmarkButtons()){ + if(!isShiftKeyDown()){ + for(int i = 0; i < InitBooklet.chaptersIntroduction.length; i++){ + this.bookmarkButtons[i].assignedPage = InitBooklet.chaptersIntroduction[i].getAllPages()[0]; + } + } + this.showTutorial = false; + this.tutorialButton.visible = false; + + PlayerSave data = PlayerData.getDataFromPlayer(this.mc.thePlayer); + data.didBookTutorial = true; + PacketHandlerHelper.sendPlayerDataPacket(this.mc.thePlayer, true, false); + } + } else{ super.actionPerformed(button); } } + @Override + public void drawScreenPre(int mouseX, int mouseY, float partialTicks){ + super.drawScreenPre(mouseX, mouseY, partialTicks); + + String strg = TextFormatting.DARK_GREEN+StringUtil.localize(this.bookletName); + this.fontRendererObj.drawString(strg, this.guiLeft+72-this.fontRendererObj.getStringWidth(strg)/2-3, this.guiTop+19, 0); + strg = TextFormatting.DARK_GREEN+StringUtil.localize("info."+ModUtil.MOD_ID+".booklet.manualName.2"); + this.fontRendererObj.drawString(strg, this.guiLeft+72-this.fontRendererObj.getStringWidth(strg)/2-3, this.guiTop+19+this.fontRendererObj.FONT_HEIGHT, 0); + + String versionStrg; + String playerName = Minecraft.getMinecraft().thePlayer.getName(); + + if(Util.isDevVersion()){ + versionStrg = "Dev's Edition"; + } + else{ + String modVersion = Util.getMajorModVersion(); + if(playerName.equalsIgnoreCase("dqmhose")){ + versionStrg = "Pants Edition"; + } + else if(playerName.equalsIgnoreCase("TwoOfEight") || playerName.equalsIgnoreCase("BootyToast")){ + versionStrg = "Illustrator's Edition"; + } + else if(playerName.equalsIgnoreCase("KittyVanCat")){ + versionStrg = "Cat's Edition"; + } + else if(playerName.equalsIgnoreCase("canitzp")){ + versionStrg = "P's Edition"; + } + else if(playerName.equalsIgnoreCase("Ellpeck")){ + versionStrg = "Editor's Edition"; + } + else if(playerName.equalsIgnoreCase("direwolf20")){ + versionStrg = "Edition 20"; + } + else if(playerName.equalsIgnoreCase("dannydjdk") || playerName.equalsIgnoreCase("andrew_period")){ + versionStrg = "Derp's Edition"; + } + else if(playerName.equalsIgnoreCase("mezz")){ + versionStrg = "Just Enough Editions"; + } + else{ + versionStrg = StringUtil.localize("info."+ModUtil.MOD_ID+".booklet.edition")+" "+modVersion; + } + } + strg = TextFormatting.GOLD+TextFormatting.ITALIC.toString()+"-"+versionStrg+"-"; + this.fontRendererObj.drawString(strg, this.guiLeft+72-this.fontRendererObj.getStringWidth(strg)/2-3, this.guiTop+40, 0); + + if(this.showTutorial){ + String text = TextFormatting.BLUE+"It looks like this is the first time you are using this manual. \nIf you click the button below, some useful bookmarks will be stored at the bottom of the GUI. You should definitely check them out to get started with "+ModUtil.NAME+"! \nIf you don't want this, shift-click the button."; + this.renderSplitScaledAsciiString(text, this.guiLeft+11, this.guiTop+55, 0, false, 0.75F, 120); + } + } + @Override public void addOrModifyItemRenderer(ItemStack renderedStack, int x, int y, float scale, boolean shouldTryTransfer){ diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiPage.java b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiPage.java index 6ed441d9a..40ad9267d 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiPage.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/gui/GuiPage.java @@ -19,7 +19,6 @@ import net.minecraft.client.gui.GuiButton; import net.minecraft.client.gui.GuiScreen; import net.minecraft.client.renderer.GlStateManager; import net.minecraft.item.ItemStack; -import net.minecraft.nbt.NBTTagCompound; import net.minecraftforge.fml.relauncher.Side; import net.minecraftforge.fml.relauncher.SideOnly; @@ -225,6 +224,11 @@ public class GuiPage extends GuiBooklet{ @Override public void onBackButtonPressed(){ - this.mc.displayGuiScreen(this.parentPage); + if(!isShiftKeyDown()){ + this.mc.displayGuiScreen(this.parentPage); + } + else{ + super.onBackButtonPressed(); + } } } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/data/PlayerData.java b/src/main/java/de/ellpeck/actuallyadditions/mod/data/PlayerData.java index bbedc08e8..25589e0ed 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/data/PlayerData.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/data/PlayerData.java @@ -50,6 +50,7 @@ public final class PlayerData{ public boolean displayTesla; public boolean bookGottenAlready; + public boolean didBookTutorial; public IBookletPage[] bookmarks = new IBookletPage[12]; @@ -63,6 +64,7 @@ public final class PlayerData{ public void readFromNBT(NBTTagCompound compound){ this.displayTesla = compound.getBoolean("DisplayTesla"); this.bookGottenAlready = compound.getBoolean("BookGotten"); + this.didBookTutorial = compound.getBoolean("DidTutorial"); NBTTagList bookmarks = compound.getTagList("Bookmarks", 8); for(int i = 0; i < bookmarks.tagCount(); i++){ @@ -77,6 +79,7 @@ public final class PlayerData{ public void writeToNBT(NBTTagCompound compound){ compound.setBoolean("DisplayTesla", this.displayTesla); compound.setBoolean("BookGotten", this.bookGottenAlready); + compound.setBoolean("DidTutorial", this.didBookTutorial); NBTTagList bookmarks = new NBTTagList(); for(IBookletPage bookmark : this.bookmarks){ diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/inventory/gui/TexturedButton.java b/src/main/java/de/ellpeck/actuallyadditions/mod/inventory/gui/TexturedButton.java index 419c45677..7da75b69b 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/inventory/gui/TexturedButton.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/inventory/gui/TexturedButton.java @@ -14,6 +14,7 @@ import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiButton; import net.minecraft.client.renderer.GlStateManager; import net.minecraft.util.ResourceLocation; +import net.minecraftforge.fml.client.config.GuiUtils; import net.minecraftforge.fml.relauncher.Side; import net.minecraftforge.fml.relauncher.SideOnly; @@ -40,11 +41,6 @@ public class TexturedButton extends GuiButton{ this.textList.addAll(hoverTextList); } - public void setTexturePos(int x, int y){ - this.texturePosX = x; - this.texturePosY = y; - } - @Override public void drawButton(Minecraft minecraft, int x, int y){ if(this.visible){ @@ -63,4 +59,11 @@ public class TexturedButton extends GuiButton{ this.mouseDragged(minecraft, x, y); } } + + public void drawHover(int x, int y){ + if(this.isMouseOver()){ + Minecraft mc = Minecraft.getMinecraft(); + GuiUtils.drawHoveringText(this.textList, x, y, mc.displayWidth, mc.displayHeight, -1, mc.fontRendererObj); + } + } } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/network/PacketHandler.java b/src/main/java/de/ellpeck/actuallyadditions/mod/network/PacketHandler.java index 35695dd83..a191ee7cb 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/network/PacketHandler.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/network/PacketHandler.java @@ -122,7 +122,7 @@ public final class PacketHandler{ UUID id = compound.getUniqueId("UUID"); PlayerData.getDataFromPlayer(id).readFromNBT(data); if(compound.getBoolean("Log")){ - ModUtil.LOGGER.info("Receiving (new or changed) Player Data for current player with UUID "+id+"."); + ModUtil.LOGGER.info("Receiving (new or changed) Player Data for player with UUID "+id+"."); } } }; diff --git a/src/main/resources/assets/actuallyadditions/lang/en_US.lang b/src/main/resources/assets/actuallyadditions/lang/en_US.lang index d12660730..58c3e45cc 100644 --- a/src/main/resources/assets/actuallyadditions/lang/en_US.lang +++ b/src/main/resources/assets/actuallyadditions/lang/en_US.lang @@ -750,7 +750,7 @@ booklet.actuallyadditions.clickToSeeRecipe=Click to see more Information booklet.actuallyadditions.amountOfWordsAndChars=Total: %s words, %s characters #Booklet Chapters -booklet.actuallyadditions.chapter.intro.name=An Introduction to ActAdd +booklet.actuallyadditions.chapter.intro.name=A story about ActAdd booklet.actuallyadditions.chapter.intro.text.1=For too long have the people of Minecraftia toiled under a relentless whip. A whip more hurtful and more injurious than that of any slave-master: inconvenience. Aye, the thousand million inconveniences that make up the grind, that force players to waste hours- nay, days!- chopping wood and farming wheat and other such mundane tasks, just to momentarily escape the remorseless tedium and experience the true joys of Minecraftia, building, caving and adventuring into the beautiful uncharted abundance booklet.actuallyadditions.chapter.intro.text.2=of the world. Yet no sooner has one immersed oneself in this creative enterprise than the inconveniences return, like millions of furious bees pestering, stinging, swarming all over you until the game ceases to be enjoyable, and you are driven away from it forever. To that end, a certain Ellpeck has created this Actual Addition to the world of Minecraft, that will allow the player to better engage with the core experiences of the game- building and adventuring- by automating and streamlining the monotony that booklet.actuallyadditions.chapter.intro.text.3=is grinding in Minecraft. Therefore, Ellpeck humbly presents to you this Actually Additions Manual, that shall teach you the ways of this modification and, ultimately, allow you to transcend inconvenience and attain enlightenment. ~by Tulkas @@ -935,9 +935,9 @@ booklet.actuallyadditions.chapter.crystals.text.5=When you have crafted a couple booklet.actuallyadditions.chapter.crystals.text.6=Molecular Transformilator booklet.actuallyadditions.chapter.bookTutorial.name=Intro to the Manual -booklet.actuallyadditions.chapter.bookTutorial.text.1=The Actually Additions Manual is the place to get information about the mod in lots of different ways. It contains in-depth descriptions of features and more. Here is a quick overview: The orange buttons on the bottom of the page, from left to right, can be used to go a page to the left in the current chapter, go back one level, and to go a page to the right in the current chapter. Press the button on the right to turn the page. -booklet.actuallyadditions.chapter.bookTutorial.text.2=The manual is split into three main parts of hierarchy. There is the front page, multiple overwiew pages for specific topics or chapters and chapters themselves. As said before, the orange button in the middle can be used to go back a level. There are also a variety of other functions. In the bottom right, you can see a search bar. Once clicked on, this will allow you to search for items and chapters via key words. Turn the page again now. -booklet.actuallyadditions.chapter.bookTutorial.text.3=The bookmarks on the bottom can store different pages and chapters for later use. Hover over them to see how they work. At the top, there is a variety of buttons linking to other things. Mainly, on the top right, there is a config button and an achievement button. These can be used to quickly access said things. Once you are done reading this chapter, press the middle orange button on the bottom twice to reach the index. +booklet.actuallyadditions.chapter.bookTutorial.text.1=The Actually Additions Manual, the book you are looking at right now, contains a variety of useful information about all of the items. Once you get the hang of it, it is very easy to navigate. Here is a quick rundown: While you are in a chapter, like this one, you can use the white buttons at the bottom to turn the page back or forwards. This can also be done by using the scroll wheel. Chapters, however, aren't the only thing that this book consists of. +booklet.actuallyadditions.chapter.bookTutorial.text.2=Were you to go back a level via the buttom on the top left or via right-clicking, you would find yourself inside an entry. Entries contain all chapters that are related to a specific topic. Here, you can also turn pages and click the items on the page. Were you to go back another level (again, via the button on the top left or right-clicking), you would find yourself on the main page of the manual. Turn the page now via the button on the bottom right. +booklet.actuallyadditions.chapter.bookTutorial.text.3=On the main page, you can see (and click on!) a list of all of the entries. The bookmarks are placed at the bottom of the booklet. While you are in a chapter, you can bookmark the page you are currently on for later viewing. The booklet also has a lot of other functions, though. Look around in the GUI to explore them all! Now press the back button on the top left or right-click to leave this chapter. booklet.actuallyadditions.chapter.reconstructorLenses.name=Intro to Lenses booklet.actuallyadditions.chapter.reconstructorLenses.text.1=The Atomic Reconstructor, by default, can only convert some blocks. This can be changed, however, with Lenses. They can be attached to the Reconstructor via right-clicking with them in hand. To remove them, right-click with an empty hand. They all use a different amount of power and will only activate once they have it. Lenses have lots of different features and uses, as you can see in this chapter. However, there is also some other useful recipes too.