Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Alesimula

Members
  • Joined

  • Last visited

Everything posted by Alesimula

  1. i need a new logo for my mod (and eventually new photos). i have never been a good logo maker and screenshotter i can't offer you anithing than giving you credits and my gratitude, but if you are interested anyway please tell me, and if you want give me your skype thanx -greenapple
  2. with a little bit effort if worked: public boolean shouldSideBeRendered(IBlockAccess blockAccess, int x, int y, int z, int side) { if (side == 0) { return (renderDownSide? true : renderSecond); } else if (side == 1) { return (renderUpSide? true : renderSecond); } else { Block nearBlock = blockAccess.getBlock(x, y, z); if (nearBlock == this) { if (renderUpBase && (blockAccess.getBlockMetadata(x, y, z) == 3 || blockAccess.getBlockMetadata(x, y, z) == 1)) { return !renderUpBase; } else if (renderDownBase && (blockAccess.getBlockMetadata(x, y, z) == 3 || blockAccess.getBlockMetadata(x, y, z) == 2)) { return !renderDownBase; } } else return true; } return true; }
  3. nope, the fact is i have a ISimpleBlockRenderingHandler, and some faces in the same side have to render
  4. I'm creating a block and i want a side to be invisible, how to make an invisible icon? BUT without creating a new png file, is there a premade invisible icon or a way to make it?
  5. After days of tryes and failures, i finally solved the problem and realised i'm a dumb
  6. So, i'm updating a dimension to 1.7.2 but when i enter in my dimension, my custom grass and dirt blocks anre not spawning; below i'll post the chunkprovider and biome ChunkProviderGlacia http://www.sourcepod.com/ooowcc24-22453 BiomeGenGlacia: http://www.sourcepod.com/efwklw10-22454
  7. Weel, never use func_ is not correct a correct way to do thing, you have just check that the func_ or field_ you are using is also in the class you extend or implement. BECAUSE: it could be a func that in a precedent version had its doebfuscation name, when in the new version got renamed, so it would work anly after reobfuscating, but, if you have the code that corresponds to that method but with its name given in the new version, then in your obfuscated class there will be two methods with the same name. JUST TO SAY TO PEOPLE: YES, YOU CAN USE func_ AND field_
  8. I want to check if there there isn't a block in specific coodinates Block block = world.getBlock(x, y, z); so have i to say if (block == null).... or if(block == Blocks.air).... ?? or is it the same?
  9. I'm adding a new ItemPickupEvent to take an achievement when an item is picked up, and i think, but not sure, it has to be registered only on my client proxy am i right?
  10. what's that name? also are you sure it has to have the obfuscated name also in forge (eclipse) ?
  11. Hi i'm using gradle forge for 1.7.2 in my forge i get the error NoSuchFieldException when do Field achPageCurrent = GuiAchievements.class.getDeclaredField("currentPage"); while currentPage is clearly there
  12. i added in the precedent version this in my client proxy public void addAchievementDesc(Achievement achievement, String name, String description) { String achName = achievement.getName(); LanguageRegistry.instance().addStringLocalization(achName, "en_US", name); LanguageRegistry.instance().addStringLocalization(achName+".desc", "en_US", description); } and i used it to add achievement name and descriprion, but now achievement.getName() doesn't exist anymore
  13. so you mean before calling tickevent, so public static class TickHandlerClient { Field achPageCurrent = GuiAchievements.class.getDeclaredField("currentPage"); achPageCurrent.setAccessible(true); @SubscribeEvent public void onTick(TickEvent.ClientTickEvent event) { ................
  14. and so where do i have to put getdeclaredfield? and also will this work if getdeclaredfield is called once and currentPage int changes?
  15. Yeah i was getting confused, anyway for anyone looking for the final code to add your custom GUI to your achievement pages (In your TickEvent Event), here it is: public static class TickHandlerClient { //private GuiScreen lastGuiOpen; @SubscribeEvent public void onTick(TickEvent.ClientTickEvent event) { //CLIENT TICK END if (event.phase == TickEvent.Phase.END) { Minecraft minecraft = Minecraft.getMinecraft(); GuiScreen CurrentGUI = minecraft.currentScreen; int PageToDisplay; if (CurrentGUI != null) { //GETTING THE PRIVATE CURRENTPAGE INT GuiAchievements AchievementGui = new GuiAchievements(CurrentGUI, minecraft.thePlayer.getStatFileWriter()); Field achPageCurrent = GuiAchievements.class.getDeclaredField("currentPage"); achPageCurrent.setAccessible(true); if (CurrentGUI instanceof GuiAchievements) { //PageToDisplay = ((GuiAchievements)CurrentGUI).currentPage; PageToDisplay = achPageCurrent.getInt((GuiAchievements)CurrentGUI); if (AchievementPage.getTitle(PageToDisplay).equals("Glacia")) { minecraft.thePlayer.openGui(mod_Glacia.instance, GlaciaCommonProxy.GUI_ID_ACHIEVEMENTS, minecraft.theWorld, PageToDisplay, 0, 0); } } if (CurrentGUI instanceof GuiAchievementsGlacia) { PageToDisplay = ((GuiAchievementsGlacia)CurrentGUI).currentPage; if (!AchievementPage.getTitle(PageToDisplay).equals("Glacia")) { GuiAchievements OldPageGUI = new GuiAchievements(CurrentGUI, minecraft.thePlayer.getStatFileWriter()); //var16.currentPage = PageToDisplay; achPageCurrent.setInt(OldPageGUI, PageToDisplay); FMLClientHandler.instance().displayGuiScreen(minecraft.thePlayer, OldPageGUI); } } } } } }
  16. nope mo probs: i'm setting the int on the new GuiAchievements i created, while i need to set the int on the already existent GuiAchievements, and so var15 casted to GuiAchievements, so (GuiAchievements)var15 .....
  17. okay but will setInt really set the protected int currentpage in GuiAchievement to another value?
  18. I understand but... Oh wait like this? GuiScreen var15 = minecraft.currentScreen; GuiAchievements GuiAchievements = new GuiAchievements(var15, minecraft.thePlayer.getStatFileWriter()); Field achPageCurrent = GuiAchievements.class.getDeclaredField("currentPage"); achPageCurrent.setAccessible(true); int achCurrentPage = achPageCurrent.getInt(GuiAchievements); and then achPageCurrent.setInt(GuiAchievements, 0);
  19. i am getting confused so can you please help me just with this? the value i want to get, and then set is currentPage in GuiAchievements.class, what are the codes to get and then set it PLEEEASE (SAD FACE) PS: forum buttons aren't working
  20. also as i am reading, access transformer modifies access to public only on forge, but in the game client accesses are still private or am i wrong?
  21. wait the problem is i have also to modify the int, i don't just have to get it, so this won't work anyway
  22. is this gonna work? GuiScreen var15 = minecraft.currentScreen; GuiAchievements GuiAchievements = new GuiAchievements(var15, minecraft.thePlayer.getStatFileWriter()); Field achPageCurrent = GuiAchievements.class.getDeclaredField("currentPage"); achPageCurrent.setAccessible(true); int achCurrentPage = Integer.parseInt((String) achPageCurrent.get(GuiAchievements));

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.