Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package me.Bryan.LegendaryArmour;
- import java.util.ArrayList;
- import java.util.List;
- import org.bukkit.ChatColor;
- import org.bukkit.Material;
- import org.bukkit.command.Command;
- import org.bukkit.command.CommandSender;
- import org.bukkit.entity.Player;
- import org.bukkit.inventory.ItemStack;
- import org.bukkit.inventory.meta.ItemMeta;
- import org.bukkit.plugin.java.JavaPlugin;
- import org.bukkit.potion.PotionEffect;
- import org.bukkit.potion.PotionEffectType;
- public class Main extends JavaPlugin
- {
- public void onEnable()
- {
- }
- public void onDisable()
- {
- }
- public boolean onCommand(CommandSender sender, Command cmd, String label, String[] args)
- {
- Player player = (Player) sender;
- ItemStack AegisHelm = new ItemStack(Material.GOLD_HELMET);
- ItemStack AegisChestPlate = new ItemStack(Material.GOLD_CHESTPLATE);
- ItemStack AegisLeggings = new ItemStack(Material.GOLD_LEGGINGS);
- ItemStack AegisBoots = new ItemStack(Material.GOLD_BOOTS);
- ItemMeta AegisHelmMeta = AegisHelm.getItemMeta();
- ItemMeta AegisChestMeta = AegisChestPlate.getItemMeta();
- ItemMeta AegisLeggingsMeta = AegisLeggings.getItemMeta();
- ItemMeta AegisBootsMeta = AegisBoots.getItemMeta();
- ItemStack ApolloHelm = new ItemStack(Material.IRON_HELMET);
- ItemStack ApolloChestPlate = new ItemStack(Material.IRON_CHESTPLATE);
- ItemStack ApolloLeggings = new ItemStack(Material.IRON_LEGGINGS);
- ItemStack ApolloBoots = new ItemStack(Material.IRON_BOOTS);
- ItemMeta ApolloHelmMeta = ApolloHelm.getItemMeta();
- ItemMeta ApolloChestMeta = ApolloChestPlate.getItemMeta();
- ItemMeta ApolloLeggingsMeta = ApolloLeggings.getItemMeta();
- ItemMeta ApolloBootsMeta = ApolloBoots.getItemMeta();
- ItemStack EtherealsHelm = new ItemStack(Material.IRON_HELMET);
- ItemStack EtherealsPlate = new ItemStack(Material.IRON_CHESTPLATE);
- ItemStack EtherealsLeggings = new ItemStack(Material.IRON_LEGGINGS);
- ItemStack EtherealsBoots = new ItemStack(Material.IRON_BOOTS);
- ItemMeta EtherealsHelmMeta = EtherealsHelm.getItemMeta();
- ItemMeta EtherealsChestMeta = EtherealsPlate.getItemMeta();
- ItemMeta EtherealsLeggingsMeta = EtherealsLeggings.getItemMeta();
- ItemMeta EtherealsBootsMeta = EtherealsBoots.getItemMeta();
- ItemStack HermesHelm = new ItemStack(Material.DIAMOND_HELMET);
- ItemStack HermesPlate = new ItemStack(Material.DIAMOND_CHESTPLATE);
- ItemStack HermesLeggings = new ItemStack(Material.DIAMOND_LEGGINGS);
- ItemStack HermesBoots = new ItemStack(Material.DIAMOND_BOOTS);
- ItemMeta HermesHelmMeta = HermesHelm.getItemMeta();
- ItemMeta HermesChestMeta = HermesPlate.getItemMeta();
- ItemMeta HermesLeggingsMeta = HermesLeggings.getItemMeta();
- ItemMeta HermesBootsMeta = HermesBoots.getItemMeta();
- ApolloHelmMeta.setDisplayName(ChatColor.AQUA + "Apollo Helmet");
- List<String> lore = AegisHelmMeta.getLore();
- lore.add(ChatColor.GREEN + "This is the helmet of Apollo Crest");
- ApolloHelmMeta.setLore(lore);
- ApolloChestMeta.setDisplayName(ChatColor.AQUA + "Apollo Chestplate");
- List<String> lore2 = AegisChestMeta.getLore();
- lore2.add(ChatColor.GREEN + "This is the chestplate of Apollo Crest");
- ApolloChestMeta.setLore(lore2);
- ApolloLeggingsMeta.setDisplayName(ChatColor.AQUA + "Apollo Leggings");
- List<String> lore3 = AegisChestMeta.getLore();
- lore3.add(ChatColor.GREEN + "This is the leggings of Apollo Crest");
- ApolloLeggingsMeta.setLore(lore3);
- ApolloBootsMeta.setDisplayName(ChatColor.AQUA + "Apollo Boots");
- List<String> lore4 = AegisChestMeta.getLore();
- lore4.add(ChatColor.GREEN + "This is the boots of Apollo Crest");
- ApolloBootsMeta.setLore(lore4);
- //END
- AegisHelmMeta.setDisplayName(ChatColor.GOLD + "Aegis Helmet");
- List<String> lore5 = AegisHelmMeta.getLore();
- lore5.add(ChatColor.GREEN + "This is the helmet of Aegis");
- AegisHelmMeta.setLore(lore5);
- AegisChestMeta.setDisplayName(ChatColor.GOLD + "Aegis Chestplate");
- List<String> lore6 = AegisChestMeta.getLore();
- lore6.add(ChatColor.GREEN + "This is the chestplate of Aegis");
- AegisChestMeta.setLore(lore6);
- AegisLeggingsMeta.setDisplayName(ChatColor.GOLD + "Aegis Leggings");
- List<String> lore7 = AegisChestMeta.getLore();
- lore7.add(ChatColor.GREEN + "This is the leggings of Aegis");
- AegisLeggingsMeta.setLore(lore7);
- AegisBootsMeta.setDisplayName(ChatColor.GOLD + "Aegis Boots");
- List<String> lore8 = AegisChestMeta.getLore();
- lore8.add(ChatColor.GREEN + "This is the boots of Aegis");
- AegisBootsMeta.setLore(lore8);
- //END
- EtherealsHelmMeta.setDisplayName(ChatColor.AQUA + "Ethereals Helmet");
- List<String> lore9 = AegisHelmMeta.getLore();
- lore9.add(ChatColor.GREEN + "This is the helmet of Ethereals");
- EtherealsHelmMeta.setLore(lore9);
- EtherealsChestMeta.setDisplayName(ChatColor.AQUA + "Ethereals Chestplate");
- List<String> lore10 = AegisChestMeta.getLore();
- lore10.add(ChatColor.GREEN + "This is the chestplate of Ethereals");
- EtherealsChestMeta.setLore(lore10);
- EtherealsLeggingsMeta.setDisplayName(ChatColor.AQUA + "Ethereals Leggings");
- List<String> lore11 = AegisChestMeta.getLore();
- lore11.add(ChatColor.GREEN + "This is the leggings of Ethereals");
- EtherealsLeggingsMeta.setLore(lore11);
- EtherealsBootsMeta.setDisplayName(ChatColor.AQUA + "Ethereals Boots");
- List<String> lore12 = AegisChestMeta.getLore();
- lore12.add(ChatColor.GREEN + "This is the boots of Ethereals");
- EtherealsBootsMeta.setLore(lore12);
- //END
- HermesHelmMeta.setDisplayName(ChatColor.AQUA + "Hermes Helmet");
- List<String> lore13 = AegisHelmMeta.getLore();
- lore13.add(ChatColor.GREEN + "This is the helmet of Hermes");
- HermesHelmMeta.setLore(lore13);
- HermesChestMeta.setDisplayName(ChatColor.AQUA + "Hermes Chestplate");
- List<String> lore14 = AegisChestMeta.getLore();
- lore14.add(ChatColor.GREEN + "This is the chestplate of Hermes");
- HermesChestMeta.setLore(lore14);
- HermesLeggingsMeta.setDisplayName(ChatColor.AQUA + "Hermes Leggings");
- List<String> lore15 = AegisChestMeta.getLore();
- lore15.add(ChatColor.GREEN + "This is the leggings of Hermes");
- HermesLeggingsMeta.setLore(lore15);
- HermesBootsMeta.setDisplayName(ChatColor.AQUA + "Hermes Boots");
- List<String> lore16 = AegisChestMeta.getLore();
- lore16.add(ChatColor.GREEN + "This is the boots of Hermes");
- HermesBootsMeta.setLore(lore16);
- if(cmd.getName().equalsIgnoreCase("legend"))
- {
- if(args.length == 0)
- {
- sender.sendMessage("Please specify what kit you want");
- }
- if(args.length == 1)
- {
- if (args[1].equalsIgnoreCase("Aegis"))
- {
- player.getInventory().addItem(AegisHelm);
- player.getInventory().addItem(AegisChestPlate);
- player.getInventory().addItem(AegisLeggings);
- player.getInventory().addItem(AegisBoots);
- if(player.getInventory().getChestplate().equals(AegisChestPlate))
- {
- player.addPotionEffect(new PotionEffect(PotionEffectType.INCREASE_DAMAGE, Integer.MAX_VALUE, 2));
- }
- }
- if(args[1].equalsIgnoreCase("Crest"))
- {
- player.getInventory().addItem(ApolloHelm);
- player.getInventory().addItem(ApolloChestPlate);
- player.getInventory().addItem(ApolloLeggings);
- player.getInventory().addItem(ApolloBoots);
- if(player.getInventory().getChestplate().equals(ApolloChestPlate))
- {
- player.addPotionEffect(new PotionEffect(PotionEffectType.NIGHT_VISION, Integer.MAX_VALUE, 1));
- }
- }
- if(args[1].equalsIgnoreCase("Ethereals"))
- {
- player.getInventory().addItem(EtherealsHelm);
- player.getInventory().addItem(EtherealsPlate);
- player.getInventory().addItem(EtherealsLeggings);
- player.getInventory().addItem(EtherealsBoots);
- if(player.getInventory().getChestplate().equals(EtherealsPlate))
- {
- player.addPotionEffect(new PotionEffect(PotionEffectType.INVISIBILITY, Integer.MAX_VALUE, 1));
- }
- }
- if(args[1].equalsIgnoreCase("Hermes"))
- {
- player.getInventory().addItem(HermesHelm);
- player.getInventory().addItem(HermesPlate);
- player.getInventory().addItem(HermesLeggings);
- player.getInventory().addItem(ApolloBoots);
- if(player.getInventory().getChestplate().equals(HermesPlate))
- {
- player.addPotionEffect(new PotionEffect(PotionEffectType.SPEED, Integer.MAX_VALUE, 2));
- }
- }
- }
- }
- return false;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement