Jump to content

(SLOVED)[1.7.10]Hiding item from NEI


FLUFFY2

Recommended Posts

  • 2 months later...
  • 1 month later...

Here's an example of the class you need to include in your mod to hide items from NEI:

 

package the_fireplace.unlogic.compat.nei;

import net.minecraft.item.ItemStack;
import net.minecraftforge.oredict.OreDictionary;
import the_fireplace.unlogic.unbase;
import the_fireplace.unlogic.config.UnLogicConfigValues;
import codechicken.nei.api.API;
import codechicken.nei.api.IConfigureNEI;
import codechicken.nei.api.ItemInfo;
import cpw.mods.fml.common.Mod;
import cpw.mods.fml.common.Optional;

@Optional.Interface(iface = "codechicken.nei.api.API", modid = "NotEnoughItems")
public class NEIUnLogicConfig implements IConfigureNEI {

@Optional.Method(modid="NotEnoughItems")
@Override
public String getName() {
	return unbase.class.getAnnotation(Mod.class).name();
}

@Optional.Method(modid="NotEnoughItems")
@Override
public String getVersion() {
	return unbase.class.getAnnotation(Mod.class).version();
}

@Optional.Method(modid="NotEnoughItems")
@Override
public void loadConfig() {
	API.hideItem(new ItemStack(unbase.BlazeCake));
	API.hideItem(new ItemStack(unbase.ChocolateCake));
	API.hideItem(new ItemStack(unbase.QCrop, 1, OreDictionary.WILDCARD_VALUE));
	API.hideItem(new ItemStack(unbase.DepletionFurnaceOn));
}
}

 

It is important that the class name be NEI[insert mod name here]Config

If I helped please press the Thank You button.

 

Check out my mods at http://www.curse.com/users/The_Fireplace/projects

Link to comment
Share on other sites

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...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

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