That is up to NEI author to decide which value is written here, and what it represents. You shouldn't assume it is a vanilla value, unless it is an Item damage value, which are different from Block.
So you don't render it into the inventory.
This is probably the reason of your issue.
So, remove
@Override
public int getRenderType() {
return -1;
or use a custom renderer.
A TileEntity NBTcompound can save and load most data used in programming, boolean, short, long, int...
Then whatever your data is, you can access it like any field in any class. Direct reference (with an instance of the object if not static) or getters.
Well first, delete the GuiHandler class.
You already made it in the proxies.
Then register the proxy.
Finally, getServerGuiElement(args) should return a Container, not a GUI.
You have to register the entire class, so it could be:
MinecraftForge.EVENT_BUS.register(new ItemKatana());
But you'd better create a new class containing all event you need, instead of putting into your item class.
public class MyEventHandler()
{
@ForgeSubscribe
*first event
@ForgeSuscribe
*second event
etc
}
then
MinecraftForge.EVENT_BUS.register(new MyEventHandler());
Correct icons in world, but not in inventory...
How do you render in the inventory ?
You have
@Override
public int getRenderType() {
return -1;
}
you have a custom renderer, right ?
Man, this is a forum, anyone can chose to answer or not.
progress = 0;
ItemStack par1 = new ItemStack(Item.diamond, 1);
modulStack[0] = null;
modulStack[0] = par1.copy();
can't you just do instead:
setInventorySlotContents(0, new ItemStack(Item.diamond));
You can store a boolean for the key pressed.
public boolean alreadyPressed = false;
*in your method*
if(!alreadyPressed)
{
*cancel event
}
else
{
*uncancel event*
}
Yes, from 1.6.2 onward, Mojang replaced Minecraft.jar with <mcversion>.jar.
The files you are looking for are in the libraries folder.
Obviously the guide is a bit outdated, but you can still work it out with a little search ?
No, each block is rendered first then comes the tile entities.
Doing both may induce rendering glitch. (or at worst, crash with "Already tessellating"/"Not tessellating")
You can use this mechanism to render partly block / partly tile entity, if you are careful enough.