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.

[FIXED][1.4.2] [6.0.1] Custom pickaxe refuses to break obsidian

Featured Replies

Posted

Im new to modding and I have no clue why this still wont work

 

package archangel.emeraldtools.item;

 

import net.minecraft.src.Block;

import net.minecraft.src.EnumToolMaterial;

import net.minecraft.src.Item;

import net.minecraft.src.ItemStack;

import net.minecraftforge.common.EnumHelper;

import archangel.emeraldtools.lib.ItemIds;

import cpw.mods.fml.common.registry.GameRegistry;

import cpw.mods.fml.common.registry.LanguageRegistry;

 

public class ModItems {

//The tool material

public static EnumToolMaterial emeraldT = EnumHelper.addToolMaterial("emeraldT", 5, 1800, 11F, 3, 11);

    /* Item name constants */

    public static final String EMERALD_PICKAXE_NAME = "pickaxeEmerald";

   

    /* Mod item instances */

    public static void init() {

   

        /* Initialize each mod item individually */

pickaxeEmerald = new EmeraldPickaxe(ItemIds.EMERALDPICKAXE, emeraldT).setIconIndex(4).setItemName("EmeraldPickaxe");

 

 

 

package archangel.emeraldtools.item;

 

import net.minecraft.src.CreativeTabs;

import net.minecraft.src.EnumToolMaterial;

import net.minecraft.src.ItemPickaxe;

import archangel.emeraldtools.CommonProxy;

 

public class EmeraldPickaxe extends ItemPickaxe {

public EmeraldPickaxe(int id, EnumToolMaterial par2EnumToolMaterial) {

super(id, par2EnumToolMaterial);

maxStackSize = 64;

this.setCreativeTab(CreativeTabs.tabTools);

}

 

public String getTextureFile() {

return CommonProxy.ITEMS_PNG;

}

}

 

 

 

I have even copied the same material setup for diamond and it still doesnt work

Try to change the maxStackSize to 1, that could be the problem and change the 5 to a 3, because i think the game does not handle anything over a 3!

If this helps, please leave a Thanks!

The Korecraft Mod

Try to change the maxStackSize to 1, that could be the problem and change the 5 to a 3, because i think the game does not handle anything over a 3!

If this helps, please leave a Thanks!

 

I have a 5 on one of my items and it works, so it must be the maxstacksize!

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

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.