Skip to content

Instantly share code, notes, and snippets.

@Alpvax
Created February 12, 2015 13:47
Show Gist options
  • Save Alpvax/78f4a2c776fccb7ae19f to your computer and use it in GitHub Desktop.
Save Alpvax/78f4a2c776fccb7ae19f to your computer and use it in GitHub Desktop.
Example mod (item would be registered as standard, and not rendered when equipped)
import net.minecraft.item.ItemArmor;
import net.minecraft.item.ItemStack;
/**
* @author Alpvax
*
*/
public class ItemInvisArmour extends ItemArmor
{
public ItemInvisArmour(ItemArmor.ArmorMaterial material, int renderIndex, int armorType)
{
super(material, renderIndex, armorType);
}
public String getName()
{
return "exampleArmour";
}
@Override
public float getItemVisibility(ItemStack stack)
{
return 0.0F;//Invisible to mobs
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment