public static void addNames() { Pixelmon.proxy.registerBossDropItem(moonStone); PixelmonItemsPokeballs.addNames(); PixelmonItemsApricorns.addNames(); PixelmonItemsBadges.addNames(); PixelmonItemsTMs.addNames(); PixelmonItemsFossils.addNames(); PixelmonItemsHeld.addNames(); try { for (Field field : PixelmonItems.class.getFields()) { if (field.isAnnotationPresent(Mod.Item.class)) { Item item = (Item) field.get(null); LanguageRegistry.addName(item, field.getAnnotation(Mod.Item.class).name()); if (item instanceof ItemPotion || item instanceof ItemStatusAilmentHealer || item instanceof ItemHammer || item instanceof ItemEther || item instanceof ItemEvolutionStone) Pixelmon.proxy.registerBossDropItem(item); } } } catch (Exception e) { e.printStackTrace(); } }
public static void load(Configuration cfg) { PixelmonItemsPokeballs.load(cfg); PixelmonItemsApricorns.load(cfg); PixelmonItemsBadges.load(cfg); PixelmonItemsTMs.load(cfg); PixelmonItemsFossils.load(cfg); PixelmonItemsHeld.load(cfg); pokeDexID = cfg.get("item", "PokeDex", 10027).getInt(); rareCandyID = cfg.get("item", "RareCandy", 10005).getInt(); potionID = cfg.get("item", "Potion", 10006).getInt(); superPotionID = cfg.get("item", "SuperPotion", 10050).getInt(); hyperPotionID = cfg.get("item", "HyperPotion", 10051).getInt(); maxPotionID = cfg.get("item", "MaxPotion", 10052).getInt(); etherID = cfg.get("item", "Ether", 10053).getInt(); maxEtherID = cfg.get("item", "MaxEther", 10054).getInt(); elixirID = cfg.get("item", "Elixir", 10055).getInt(); maxElixirID = cfg.get("item", "MaxElixir", 10056).getInt(); fullRestoreID = cfg.get("item", "FullRestore", 10057).getInt(); antidoteID = cfg.get("item", "Antidote", 10058).getInt(); parlyzHealID = cfg.get("item", "ParlyzHeal", 10059).getInt(); awakeningID = cfg.get("item", "Awakening", 10060).getInt(); burnHealID = cfg.get("item", "BurnHeal", 10061).getInt(); iceHealID = cfg.get("item", "IceHeal", 10062).getInt(); fullHealID = cfg.get("item", "FullHeal", 10063).getInt(); pcItemID = cfg.get("item", "PCItem", 10013).getInt(); healerItemID = cfg.get("item", "HealerItem", 10014).getInt(); anvilItemID = cfg.get("item", "AnvilItem", 10015).getInt(); tradeMachineItemID = cfg.get("item", "TradeMachineItem", 10016).getInt(); fireStoneID = cfg.get("evolutionStone", "FireStone", 10008).getInt(); waterStoneID = cfg.get("evolutionStone", "WaterStone", 10009).getInt(); moonStoneID = cfg.get("evolutionStone", "MoonStone", 10010).getInt(); thunderStoneID = cfg.get("evolutionStone", "ThunderStone", 10011).getInt(); leafStoneID = cfg.get("evolutionStone", "LeafStone", 10012).getInt(); thunderStoneShardID = cfg.get("evolutionStone", "ThunderStoneShard", 10021).getInt(); leafStoneShardID = cfg.get("evolutionStone", "LeafStoneShard", 10022).getInt(); waterStoneShardID = cfg.get("evolutionStone", "WaterStoneShard", 10023).getInt(); fireStoneShardID = cfg.get("evolutionStone", "FireStoneShard", 10024).getInt(); // everStoneShardID = cfg.get("EverStoneShard", "item", 10025).getInt(); hammerWoodID = cfg.get("item", "Wood Hammer", 10107).getInt(); hammerStoneID = cfg.get("item", "Stone Hammer", 10108).getInt(); hammerIronID = cfg.get("item", "Iron Hammer", 10109).getInt(); hammerGoldID = cfg.get("item", "Gold Hammer", 10110).getInt(); hammerDiamondID = cfg.get("item", "Diamond Hammer", 10111).getInt(); hammerAluminiumID = cfg.get("item", "Aluminium Hammer", 10122).getInt(); aluminiumIngotID = cfg.get("item", "AluminiumIngot", 10120).getInt(); aluminiumPlateID = cfg.get("item", "AluminiumPlate", 10121).getInt(); swordAluminiumID = cfg.get("item", "Aluminium Sword", 10123).getInt(); axeAluminiumID = cfg.get("item", "Aluminium Axe", 10124).getInt(); shovelAluminiumID = cfg.get("item", "Aluminium Shovel", 10125).getInt(); pickaxeAluminiumID = cfg.get("item", "Aluminium Pickaxe", 10126).getInt(); hoeAluminiumID = cfg.get("item", "Aluminium Hoe", 10127).getInt(); helmetAluminiumID = cfg.get("item", "Aluminium Helmet", 10128).getInt(); torsoAluminiumID = cfg.get("item", "Aluminium Chestplate", 10129).getInt(); leggingsAluminiumID = cfg.get("item", "Aluminium Leggings", 10130).getInt(); bootsAluminiumID = cfg.get("item", "Aluminium Boots", 10131).getInt(); mossyRockID = cfg.get("item", "Mossy Rock", 10132).getInt(); icyRockID = cfg.get("item", "Icy Rock", 10133).getInt(); newRunningShoesID = cfg.get("item", "New Running Boots", 10134).getInt(); oldRunningShoesID = cfg.get("item", "Old Running Boots", 10135).getInt(); wailmerPailID = cfg.get("item", "Wailmer Pail", 10136).getInt(); oldRodID = cfg.get("item", "Old Rod", 10137).getInt(); goodRodID = cfg.get("item", "Good Rod", 10138).getInt(); superRodID = cfg.get("item", "Super Rod", 10139).getInt(); tradeMonitorID = cfg.get("item", "Trade Monitor", 10140).getInt(); tradeHolderRightID = cfg.get("item", "Trade Holder Right", 10141).getInt(); LtradeHolderLeftID = cfg.get("item", "Trade Holder Left", 10143).getInt(); tradePanelID = cfg.get("item", "Trade Panel", 10144).getInt(); pokeDex = new ItemPokedex(pokeDexID).setMaxStackSize(1); rareCandy = new PixelmonItem(rareCandyID, "healingitems/rarecandy", "Rare Candy") .setCreativeTab(PixelmonCreativeTabs.restoration); potion = new ItemPotion(potionID, EnumPotions.Potion, "Potion"); superPotion = new ItemPotion(superPotionID, EnumPotions.SuperPotion, "Super Potion"); hyperPotion = new ItemPotion(hyperPotionID, EnumPotions.HyperPotion, "Hyper Potion"); maxPotion = new ItemPotion(maxPotionID, EnumPotions.MaxPotion, "Max Potion"); ether = new ItemEther(etherID, EnumEthers.Ether, "Ether"); maxEther = new ItemEther(maxEtherID, EnumEthers.MaxEther, "Max Ether"); elixir = new ItemEther(elixirID, EnumEthers.Elixir, "Elixir"); maxElixir = new ItemEther(maxElixirID, EnumEthers.MaxElixir, "Max Elixir"); fullRestore = new ItemStatusAilmentHealer( fullRestoreID, EnumStatusAilmentHealers.FullRestore, "Full Restore"); antidote = new ItemStatusAilmentHealer(antidoteID, EnumStatusAilmentHealers.Antidote, "Antidote"); parlyzHeal = new ItemStatusAilmentHealer( parlyzHealID, EnumStatusAilmentHealers.ParlyzHeal, "Paralyze Heal"); awakening = new ItemStatusAilmentHealer(awakeningID, EnumStatusAilmentHealers.Awakening, "Awakening"); burnHeal = new ItemStatusAilmentHealer(burnHealID, EnumStatusAilmentHealers.BurnHeal, "Burn Heal"); iceHeal = new ItemStatusAilmentHealer(iceHealID, EnumStatusAilmentHealers.IceHeal, "Ice Heal"); fullHeal = new ItemStatusAilmentHealer(fullHealID, EnumStatusAilmentHealers.FullHeal, "Full Heal"); fireStone = new ItemEvolutionStone(fireStoneID, EnumEvolutionStone.Firestone, "Fire Stone") .setCreativeTab(PixelmonCreativeTabs.natural); waterStone = new ItemEvolutionStone(waterStoneID, EnumEvolutionStone.Waterstone, "Water Stone") .setCreativeTab(PixelmonCreativeTabs.natural); moonStone = new ItemEvolutionStone(moonStoneID, EnumEvolutionStone.Moonstone, "Moon Stone") .setCreativeTab(PixelmonCreativeTabs.natural); thunderStone = new ItemEvolutionStone(thunderStoneID, EnumEvolutionStone.Thunderstone, "Thunder Stone") .setCreativeTab(PixelmonCreativeTabs.natural); leafStone = new ItemEvolutionStone(leafStoneID, EnumEvolutionStone.Leafstone, "Leaf Stone") .setCreativeTab(PixelmonCreativeTabs.natural); pcItem = new ItemBlock(pcItemID, PixelmonBlocks.pc, "pc", "PC"); healerItem = new ItemBlock(healerItemID, PixelmonBlocks.healer, "healer", "Healer"); anvilItem = new ItemBlock(anvilItemID, PixelmonBlocks.anvil, "anvil", "Anvil"); tradeMachineItem = new ItemBlock( tradeMachineItemID, PixelmonBlocks.tradeMachine, "trademachine", "Trade Machine"); thunderStoneShard = new PixelmonItem( thunderStoneShardID, "evolutionstones/thunderstoneshard", "Thunder Stone Shard") .setCreativeTab(PixelmonCreativeTabs.natural); leafStoneShard = new PixelmonItem(leafStoneShardID, "evolutionstones/leafstoneshard", "Leaf Stone Shard") .setCreativeTab(PixelmonCreativeTabs.natural); waterStoneShard = new PixelmonItem(waterStoneShardID, "evolutionstones/waterstoneshard", "Water Stone Shard") .setCreativeTab(PixelmonCreativeTabs.natural); fireStoneShard = new PixelmonItem(fireStoneShardID, "evolutionstones/firestoneshard", "Fire Stone Shard") .setCreativeTab(PixelmonCreativeTabs.natural); aluminiumIngot = new PixelmonItem(aluminiumIngotID, "aluminiumingot", "Aluminium Ingot") .setCreativeTab(CreativeTabs.tabMaterials); aluminiumPlate = new PixelmonItem(aluminiumPlateID, "aluminiumplate", "Aluminium Plate") .setCreativeTab(CreativeTabs.tabMaterials); hammerWood = new ItemHammer(hammerWoodID, EnumToolMaterial.WOOD, "hammerwood", "Wood Hammer"); hammerStone = new ItemHammer(hammerStoneID, EnumToolMaterial.STONE, "hammerstone", "Stone Hammer"); hammerIron = new ItemHammer(hammerIronID, EnumToolMaterial.IRON, "hammeriron", "Iron Hammer"); hammerGold = new ItemHammer(hammerGoldID, EnumToolMaterial.GOLD, "hammergold", "Gold Hammer"); hammerDiamond = new ItemHammer( hammerDiamondID, EnumToolMaterial.EMERALD, "hammerdiamond", "Diamond Hammer"); hammerAluminium = new ItemHammer( hammerAluminiumID, Pixelmon.ALUMINIUM, "hammeraluminium", "Aluminium Hammer"); swordAluminium = new PixelmonItemSword(swordAluminiumID, Pixelmon.ALUMINIUM, "pixelmon:aluminiumsword"); axeAluminium = new PixelmonItemAxe(axeAluminiumID, Pixelmon.ALUMINIUM, "pixelmon:aluminiumaxe"); spadeAluminium = new PixelmonItemSpade(shovelAluminiumID, Pixelmon.ALUMINIUM, "pixelmon:aluminiumspade"); pickaxeAluminium = new PixelmonItemPickAxe( pickaxeAluminiumID, Pixelmon.ALUMINIUM, "pixelmon:aluminiumpickaxe"); hoeAluminium = new PixelmonItemHoe(hoeAluminiumID, Pixelmon.ALUMINIUM, "pixelmon:aluminiumhoe"); helmetAluminium = new ItemPixelmonArmor( helmetAluminiumID, 14, Pixelmon.ALUMINIUMARMOR, 0, 0, "pixelmon:aluminiumhelmet", "Aluminium Helmet"); torsoAluminium = new ItemPixelmonArmor( torsoAluminiumID, 8, Pixelmon.ALUMINIUMARMOR, 0, 1, "pixelmon:aluminiumtorso", "Aluminium Torso"); leggingsAluminium = new ItemPixelmonArmor( leggingsAluminiumID, 9, Pixelmon.ALUMINIUMARMOR, 0, 2, "pixelmon:aluminiumleggings", "Aluminium Leggings"); bootsAluminium = new ItemPixelmonArmor( bootsAluminiumID, 7, Pixelmon.ALUMINIUMARMOR, 0, 3, "pixelmon:aluminiumboots", "Aluminium Boots"); newRunningShoes = new ItemPixelmonBoots( newRunningShoesID, 6, Pixelmon.RUNNINGARMOR, 0, 3, "pixelmon:runningboots", "New Running Boots"); oldRunningShoes = new ItemPixelmonBoots( oldRunningShoesID, 6, Pixelmon.OLDRUNNINGARMOR, 0, 3, "pixelmon:oldrunningboots", "Old Running Boots"); wailmerPail = new ItemWailmerPail(wailmerPailID, "pixelmon:wailmerpail", "Wailmer Pail"); oldRod = new ItemFishingRod(oldRodID, EnumRodType.OldRod, "Old Rod"); goodRod = new ItemFishingRod(goodRodID, EnumRodType.GoodRod, "Good Rod"); superRod = new ItemFishingRod(superRodID, EnumRodType.SuperRod, "Super Rod"); tradeMonitor = new PixelmonItem(tradeMonitorID, "tradingmachinepieces/tradingMonitor", "Trade Monitor"); tradeHolderRight = new PixelmonItem( tradeHolderRightID, "tradingmachinepieces/tradingHolderR", "Trade Holder Right"); LtradeHolderLeft = new PixelmonItem( LtradeHolderLeftID, "tradingmachinepieces/tradingHolderL", "Trade Holder Left"); tradePanel = new PixelmonItem(tradePanelID, "tradingmachinepieces/tradingPanel", "Trade Panel"); // TODO make correct icons for mossyrock and icyrock, instead of using // anvil mossyRock = new ItemBlock(mossyRockID, PixelmonBlocks.mossyRock, "mossyrock", "Mossy Rock"); mossyRock.setCreativeTab(PixelmonCreativeTabs.natural); icyRock = new ItemBlock(icyRockID, PixelmonBlocks.icyRock, "icyrock", "Icy Rock"); icyRock.setCreativeTab(PixelmonCreativeTabs.natural); }