Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package me.binru.customcrafts;
- import org.bukkit.ChatColor;
- import org.bukkit.Material;
- import org.bukkit.NamespacedKey;
- import org.bukkit.enchantments.Enchantment;
- import org.bukkit.event.entity.ItemMergeEvent;
- import org.bukkit.inventory.ItemStack;
- import org.bukkit.inventory.ShapedRecipe;
- import org.bukkit.inventory.meta.ItemMeta;
- import org.bukkit.plugin.java.JavaPlugin;
- import sun.rmi.rmic.Names;
- public final class Main extends JavaPlugin {
- @Override
- public void onEnable() {
- // Plugin startup logic
- }
- @Override
- public void onDisable() {
- // Plugin shutdown logic
- }
- public ShapedRecipe getRecipe() {
- ItemStack item = new ItemStack(Material.STICK);
- ItemMeta meta = item.getItemMeta();
- meta.setDisplayName(ChatColor.GOLD + "God Staff");
- meta.addEnchant(Enchantment.DAMAGE_ALL, 999, true);
- item.setItemMeta(meta);
- NamespacedKey key = new NamespacedKey(this, "god_staff");
- ShapedRecipe recipe = new ShapedRecipe(key, item);
- recipe.shape("DSD","GEG","IEI");
- recipe.setIngredient('D', Material.DIAMOND_BLOCK);
- recipe.setIngredient('S', Material.NETHER_STAR);
- recipe.setIngredient('E', Material.EMERALD_BLOCK);
- recipe.setIngredient('G', Material.GOLD_BLOCK);
- recipe.setIngredient('I', Material.IRON_BLOCK);
- return recipe;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement