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.

MCrafterzz

Members
  • Joined

  • Last visited

Everything posted by MCrafterzz

  1. So how can I fix it then. You can download the full sourcecode here: https://github.com/MCrafterzz/minecraft-mod/blob/master/src.zip
  2. I'm using I18n for my config: String worldCategory = I18n.format("worldgen"); String craftingCategory = I18n.format("crafting"); But I18n doesn't work serverside, so what is the replacement?
  3. Crash log maybe? Eclipse log?
  4. That's why we will add more advanced things to, I plan on adding flowers. I will also add a chest and a furnace when I get it working
  5. Added code for a wall, but I don't know where I should create a new wall
  6. Nice, I'll proberly come back to it and add some stuff. I Think it will be very helpful for the comunity
  7. Thank you very much, it worked perfectly!
  8. Hello, I've sucessfully created a config file. I've also managed to make so that you could open a gui in game from the mod screen. I've made two cattegories but don't know how to add the options in there. My code: Config: http://pastebin.com/Z1Yykgvx ModGuiFactory: http://pastebin.com/0Q5kBUQ2 GuiConfig: http://pastebin.com/J8XTdMWG CommonProxy: http://pastebin.com/tJGehBRW Config file that it creates: http://pastebin.com/0jb31F6W
  9. I mean this code: @SubscribeEvent public void attackEvent(LivingAttackEvent e) { float damage = e.getAmount(); ItemStack activeItemStack; EntityPlayer player; if (!(e.getEntityLiving() instanceof EntityPlayer)) { return; } player = (EntityPlayer) e.getEntityLiving(); if (player.getActiveItemStack() == null) { return; } activeItemStack = player.getActiveItemStack(); if (damage > 0.0F && activeItemStack != null && activeItemStack.getItem() instanceof ItemShield) { int i = 1 + MathHelper.floor_float(damage); activeItemStack.damageItem(i, player); if (activeItemStack.stackSize <= 0) { EnumHand enumhand = player.getActiveHand(); net.minecraftforge.event.ForgeEventFactory.onPlayerDestroyItem(player, activeItemStack, enumhand); if (enumhand == EnumHand.MAIN_HAND) { player.setItemStackToSlot(EntityEquipmentSlot.MAINHAND, (ItemStack) null); } else { player.setItemStackToSlot(EntityEquipmentSlot.OFFHAND, (ItemStack) null); } activeItemStack = null; if (FMLCommonHandler.instance().getSide() == Side.CLIENT) { player.playSound(SoundEvents.ITEM_SHIELD_BREAK, 0.8F, 0.8F + player.worldObj.rand.nextFloat() * 0.4F); } } } }
  10. Copy your whole mod folder that contains eclipse, run, scr and etc. Then open it with eclipse on a other computer when you have imported that code to the computer. I think this works, try
  11. Thank you but my shield still don't gets damages? Can you double check that all the code is correct
  12. And how do you implement a methoud? I can't implement EntityLivingBase because it's not a interface
  13. I don't know what the world gen code but it is proberly name something like WorldGenBedrock check in the forge src or wait for someone else that knows more
  14. I'm sorry but I don't think it's possible to make bedrock breakeble without editing base files, so a better solution is to add you own bedrock (can use the same texture if you wany). Then you can spawn your bedrock in the world
  15. 1.7.10 is no longer supported update to 1.9.4 for better support
  16. This is the code I have so far: http://pastebin.com/HYMQZ5yq Everything works except that it takes damage every second when blocking, how should I do so it only takes damage when the shield has been attacked. I've looked in the vanilla code but I can't find what makes it take damage
  17. I checked in Item.java and the thing he had missed was @Nullable

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.