79
While I'm at it! Here's the comment necessary to automatically enchant items once crafted instead of separately!
You would put this in the item folder. Not the output folder.
"
/** Makes your Item Enchanted when it is crafted */
public void onCreated(ItemStack item, World world, EntityPlayer player)
{
item.addEnchantment(Enchantment.knockback, 5);
// Replace the "." after "Enchantment" to see options
// The number is the Enchantment Level
}
"
Bạn đang đọc truyện trên: AzTruyen.Top