diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md index 145814a37..e7ecd5e8d 100644 --- a/.github/ISSUE_TEMPLATE.md +++ b/.github/ISSUE_TEMPLATE.md @@ -6,7 +6,7 @@ What you expected to happen: ... Steps to reproduce: ... -Version (Make sure you are on the latest version before reporting) +Version (Make sure you are on the latest version before reporting) Minecraft: ... 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 50ecc32a0..d8f18dab1 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/InitBooklet.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/InitBooklet.java @@ -128,7 +128,7 @@ public final class InitBooklet{ private static void initChapters(){ //Getting Started 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(); + 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"), new PageLinkButton(2, "https://www.youtube.com/playlist?list=PLJeFZ64pT89MrTRZYzD_rtHFajPVlt6cF")).setImportant(); new BookletChapter("intro", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(InitItems.itemBooklet), new PageTextOnly(1), new PageTextOnly(2), new PageTextOnly(3)); ArrayList crystalPages = new ArrayList(); crystalPages.addAll(Arrays.asList(new PageTextOnly(1).addTextReplacement("", TileEntityAtomicReconstructor.ENERGY_USE), new PageTextOnly(2), new PageTextOnly(3), new PagePicture(4, "page_atomic_reconstructor", 0).setNoText(), new PageTextOnly(5), new PageCrafting(6, BlockCrafting.recipeAtomicReconstructor).setWildcard())); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/page/PageLinkButton.java b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/page/PageLinkButton.java index 313878f61..8fce5bfc5 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/page/PageLinkButton.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/page/PageLinkButton.java @@ -20,19 +20,24 @@ import java.net.URI; public class PageLinkButton extends BookletPage{ - private static final int BUTTON_ID = -12782; + private static int nextButtonId = 23782; + private final int buttonId; + private final String link; public PageLinkButton(int localizationKey, String link){ super(localizationKey); this.link = link; + + this.buttonId = nextButtonId; + nextButtonId++; } @Override public void initGui(GuiBookletBase gui, int startX, int startY){ super.initGui(gui, startX, startY); - gui.getButtonList().add(new GuiButton(BUTTON_ID, startX+125/2-50, startY+130, 100, 20, StringUtil.localize("booklet."+ModUtil.MOD_ID+".chapter."+this.chapter.getIdentifier()+".button."+this.localizationKey))); + gui.getButtonList().add(new GuiButton(this.buttonId, startX+125/2-50, startY+130, 100, 20, StringUtil.localize("booklet."+ModUtil.MOD_ID+".chapter."+this.chapter.getIdentifier()+".button."+this.localizationKey))); } @Override @@ -43,7 +48,7 @@ public class PageLinkButton extends BookletPage{ @Override public void actionPerformed(GuiBookletBase gui, GuiButton button){ - if(button.id == BUTTON_ID){ + if(button.id == this.buttonId){ if(Desktop.isDesktopSupported()){ try{ Desktop.getDesktop().browse(new URI(this.link)); diff --git a/src/main/resources/assets/actuallyadditions/lang/en_US.lang b/src/main/resources/assets/actuallyadditions/lang/en_US.lang index fee6b60dc..6843e989f 100644 --- a/src/main/resources/assets/actuallyadditions/lang/en_US.lang +++ b/src/main/resources/assets/actuallyadditions/lang/en_US.lang @@ -1044,8 +1044,10 @@ booklet.actuallyadditions.chapter.itemFilter.name=Item Filter booklet.actuallyadditions.chapter.itemFilter.text.1=The Item Filter can be used in Advanced Item Laser Relays, ESDs and Ranged Collectors to enlargen the size of their whitelist. This can be done by right-clicking with the filter in hand and placing items to be filtered inside of it. The filter can then be placed into any whitelist slot in the desired machine. For more information on this, hover over the whitelist buttons in the GUIs of whitelistable machines! booklet.actuallyadditions.chapter.videoGuide.name=A Video Guide -booklet.actuallyadditions.chapter.videoGuide.text.1=If you want to have a visual introduction to see what Actually Additions has to offer, you can watch this really awesome video by a friend of mine, Booty Toast (yes, weird name, I know). His video covers most of the main stuff the mod has to offer, however it is a bit outdated and doesn't cover everything. It's still a great introduction to the mod though. -booklet.actuallyadditions.chapter.videoGuide.button.1=Watch Video +booklet.actuallyadditions.chapter.videoGuide.text.1=If you want to have a visual introduction to see what Actually Additions has to offer, you can watch this really awesome video by a friend of mine, Booty Toast (yes, weird name, I know). His video covers most of the main stuff the mod has to offer, however it is a bit outdated and doesn't cover everything. It's still a great introduction to the mod though. +booklet.actuallyadditions.chapter.videoGuide.button.1=BootyToast's Video +booklet.actuallyadditions.chapter.videoGuide.text.2=There is also the second option, a playlist consisting of a spotlight by Direwolf20. It is a bit more recent than the other video, however, it is substantially longer and provides a more detailed overview. So you have the choice: The quicker introduction on the left or the longer, more in-depth introduction down below. +booklet.actuallyadditions.chapter.videoGuide.button.2=Direwolf's Playlist booklet.actuallyadditions.chapter.shockSuppressor.name=Shock Absorber booklet.actuallyadditions.chapter.shockSuppressor.text.1=The Shock Absorber is a block that, when supplied with CF, it will protect an area of up to blocks around it from any type of Explosion, be it ghasts, TNT or creepers. Every block that is protected will result in a loss of CF.