diff --git a/TwosideKeeper.jar b/TwosideKeeper.jar index 9562c89..938d6f9 100644 Binary files a/TwosideKeeper.jar and b/TwosideKeeper.jar differ diff --git a/src/sig/plugin/TwosideKeeper/Drops/SigDrop.java b/src/sig/plugin/TwosideKeeper/Drops/SigDrop.java index 2ada84b..3461021 100644 --- a/src/sig/plugin/TwosideKeeper/Drops/SigDrop.java +++ b/src/sig/plugin/TwosideKeeper/Drops/SigDrop.java @@ -115,25 +115,11 @@ public class SigDrop extends Drop{ switch (isWeapon) { case ARMOR: { item = new ItemStack(Material.valueOf(armorprefix+"_"+armorsuffix)); - if (isSet) { - ItemSet set = MonsterDifficulty.PickAnItemSet(PlayerMode.getPlayerMode(p)); //This is the set we have to generate. - //Turn it into the appropriate piece if necessary. - item = MonsterDifficulty.ConvertSetPieceIfNecessary(item, set); - item = Loot.GenerateSetPiece(item, set, isHardened, 0); - } else { - item = Loot.GenerateMegaPiece(item.getType(), isHardened); - } + item = CreateModifiedLootPiece(p, item); }break; case WEAPON: { item = new ItemStack(Material.valueOf(toolprefix+"_SWORD")); - if (isSet) { - ItemSet set = MonsterDifficulty.PickAnItemSet(PlayerMode.getPlayerMode(p)); //This is the set we have to generate. - //Turn it into the appropriate piece if necessary. - item = MonsterDifficulty.ConvertSetPieceIfNecessary(item, set); - item = Loot.GenerateSetPiece(item, set, isHardened, 0); - } else { - item = Loot.GenerateMegaPiece(item.getType(), isHardened); - } + item = CreateModifiedLootPiece(p, item); }break; case TOOL: { item = new ItemStack(Material.valueOf(toolprefix+"_"+toolsuffix)); @@ -146,7 +132,54 @@ public class SigDrop extends Drop{ } return item; } + + public ItemStack CreateModifiedLootPiece(Player p, ItemStack item) { + if (isSet) { + ItemSet set = MonsterDifficulty.PickAnItemSet(PlayerMode.getPlayerMode(p)); //This is the set we have to generate. + //Turn it into the appropriate piece if necessary. + item = MonsterDifficulty.ConvertSetPieceIfNecessary(item, set); + + int tierbonus = GetTierBonusBasedOnDifficulty(diff); + + item = Loot.GenerateSetPiece(item, set, isHardened, tierbonus); + } else { + item = Loot.GenerateMegaPiece(item.getType(), isHardened); + } + return item; + } + private int GetTierBonusBasedOnDifficulty(MonsterDifficulty dif) { + switch (dif) { + case DANGEROUS:{ + if (Math.random()<=1/3d) { + return 1; + } else { + return 0; + } + } + case DEADLY:{ + if (Math.random()<=2/3d) { + return 1; + } else { + return 0; + } + } + case HELLFIRE:{ + return 1; + } + case END:{ + if (Math.random()<=1/3d) { + return 2; + } else { + return 1; + } + } + default:{ + return 0; + } + } + } + @Override public ItemStack getItemStack() { TwosideKeeper.log("Something went terribly wrong with getItemStack() call. Check to make sure you are using getSingleDrop(Player) and not getSingleDrop()!!!", 0); diff --git a/src/sig/plugin/TwosideKeeper/HelperStructures/Loot.java b/src/sig/plugin/TwosideKeeper/HelperStructures/Loot.java index cc091eb..de16be1 100644 --- a/src/sig/plugin/TwosideKeeper/HelperStructures/Loot.java +++ b/src/sig/plugin/TwosideKeeper/HelperStructures/Loot.java @@ -33,7 +33,7 @@ public class Loot { public static void DefineLootChests() { aPlugin.API.Chests.LOOT_NORMAL.addDrop(new DropMaterial(Material.STONE_SWORD,8)); aPlugin.API.Chests.LOOT_NORMAL.addDrop(new DropItem(Artifact.createArtifactItem(ArtifactItem.MYSTERIOUS_ESSENCE),11)); - aPlugin.API.Chests.LOOT_NORMAL.addDrop(new DropMaterial(Material.COAL,1000)); + aPlugin.API.Chests.LOOT_NORMAL.addDrop(new DropMaterial(Material.COAL,101)); aPlugin.API.Chests.LOOT_NORMAL.addDrop(new DropMaterial(Material.IRON_INGOT,1,17)); aPlugin.API.Chests.LOOT_NORMAL.addDrop(new DropMaterial(Material.DIAMOND,1,18)); aPlugin.API.Chests.LOOT_NORMAL.addDrop(new DropMaterial(Material.GOLD_NUGGET,1,17)); @@ -45,11 +45,11 @@ public class Loot { aPlugin.API.Chests.LOOT_NORMAL.addDrop(new SigDrop(1,1,"[Normal] Mega Tool",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.NORMAL)); aPlugin.API.Chests.LOOT_NORMAL.addDrop(new SigDrop(1,1,"[Normal] Mega Weapon",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.NORMAL)); aPlugin.API.Chests.LOOT_NORMAL.addDrop(new SigDrop(1,2,"[Normal] Mega Set Weapon",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.WEAPON,MonsterDifficulty.NORMAL)); - aPlugin.API.Chests.LOOT_NORMAL.addDrop(new SigDrop(1,1,"[Normal] Hardened Mega Armor",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.NORMAL)); + /*aPlugin.API.Chests.LOOT_NORMAL.addDrop(new SigDrop(1,1,"[Normal] Hardened Mega Armor",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.NORMAL)); aPlugin.API.Chests.LOOT_NORMAL.addDrop(new SigDrop(1,2,"[Normal] Hardened Mega Set Armor",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.NORMAL)); aPlugin.API.Chests.LOOT_NORMAL.addDrop(new SigDrop(1,1,"[Normal] Hardened Mega Tool",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.NORMAL)); aPlugin.API.Chests.LOOT_NORMAL.addDrop(new SigDrop(1,1,"[Normal] Hardened Mega Weapon",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.NORMAL)); - aPlugin.API.Chests.LOOT_NORMAL.addDrop(new SigDrop(1,1,"[Normal] Hardened Mega Set Weapon",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.NORMAL)); + aPlugin.API.Chests.LOOT_NORMAL.addDrop(new SigDrop(1,1,"[Normal] Hardened Mega Set Weapon",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.NORMAL));*/ /*//LOOT TEMPLATE. Cut Normal loot to 25% of this. Dangerous loot to 50% of this. Deadly to 75% of this. And Hellfires at 100% of this. aPlugin.API.Chests.LOOT_NORMAL.addDrop(new SigDrop(1,18,"Mega Armor",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.ARMOR)); @@ -73,72 +73,72 @@ public class Loot { aPlugin.API.Chests.LOOT_NORMAL.addDrop(new DropMaterial(Material.SKULL_ITEM,8));*/ aPlugin.API.Chests.LOOT_NORMAL.printDrops(); - aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new DropMaterial(Material.IRON_INGOT,1000)); - aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new DropMaterial(Material.IRON_BLOCK,78)); - aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,18,"[Dangerous] Mega Armor",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.DANGEROUS)); - aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,78,"[Dangerous] Mega Set Armor",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.DANGEROUS)); - aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,2,"[Dangerous] Mega Tool",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.DANGEROUS)); - aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,2,"[Dangerous] Mega Weapon",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.DANGEROUS)); - aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,6,"[Dangerous] Mega Set Weapon",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.WEAPON,MonsterDifficulty.DANGEROUS)); - aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,1,"[Dangerous] Hardened Mega Armor",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.DANGEROUS)); - aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,8,"[Dangerous] Hardened Mega Set Armor",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.DANGEROUS)); - aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,1,"[Dangerous] Hardened Mega Tool",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.DANGEROUS)); - aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,1,"[Dangerous] Hardened Mega Weapon",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.DANGEROUS)); - aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,1,"[Dangerous] Hardened Mega Set Weapon",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.DANGEROUS)); - aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new DropItem(Artifact.createArtifactItem(ArtifactItem.ANCIENT_CORE),4)); + aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new DropMaterial(Material.IRON_INGOT,91800)); + aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new DropMaterial(Material.IRON_BLOCK,7800)); + aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,1800,"[Dangerous] Mega Armor",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.DANGEROUS)); + aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,7800,"[Dangerous] Mega Set Armor",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.DANGEROUS)); + aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,200,"[Dangerous] Mega Tool",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.DANGEROUS)); + aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,200,"[Dangerous] Mega Weapon",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.DANGEROUS)); + aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,600,"[Dangerous] Mega Set Weapon",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.WEAPON,MonsterDifficulty.DANGEROUS)); + aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,180,"[Dangerous] Hardened Mega Armor",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.DANGEROUS)); + aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,780,"[Dangerous] Hardened Mega Set Armor",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.DANGEROUS)); + aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,20,"[Dangerous] Hardened Mega Tool",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.DANGEROUS)); + aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,20,"[Dangerous] Hardened Mega Weapon",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.DANGEROUS)); + aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new SigDrop(1,60,"[Dangerous] Hardened Mega Set Weapon",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.DANGEROUS)); + aPlugin.API.Chests.LOOT_DANGEROUS.addDrop(new DropItem(Artifact.createArtifactItem(ArtifactItem.ANCIENT_CORE),400)); aPlugin.API.Chests.LOOT_DANGEROUS.printDrops(); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropMaterial(Material.IRON_INGOT,1,2,1000)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropMaterial(Material.DIAMOND,1000)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropMaterial(Material.GOLD_NUGGET,1,3,1000)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropMaterial(Material.IRON_BLOCK,1,2,78)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropMaterial(Material.DIAMOND_BLOCK,78)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropMaterial(Material.GOLD_INGOT,78)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropMaterial(Material.DIAMOND_SWORD,8)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,18,"[Deadly] Mega Armor",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.DEADLY)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,78,"[Deadly] Mega Set Armor",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.DEADLY)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,2,"[Deadly] Mega Tool",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.DEADLY)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,2,"[Deadly] Mega Weapon",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.DEADLY)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,6,"[Deadly] Mega Set Weapon",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.WEAPON,MonsterDifficulty.DEADLY)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,1,"[Deadly] Hardened Mega Armor",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.DEADLY)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,8,"[Deadly] Hardened Mega Set Armor",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.DEADLY)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,1,"[Deadly] Hardened Mega Tool",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.DEADLY)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,1,"[Deadly] Hardened Mega Weapon",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.DEADLY)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,1,"[Deadly] Hardened Mega Set Weapon",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.DEADLY)); - aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropItem(Artifact.createArtifactItem(ArtifactItem.LOST_CORE),4)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropMaterial(Material.IRON_INGOT,1,2,59800)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropMaterial(Material.DIAMOND,7800)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropMaterial(Material.GOLD_NUGGET,1,3,7800)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropMaterial(Material.IRON_BLOCK,1,2,7800)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropMaterial(Material.DIAMOND_BLOCK,7800)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropMaterial(Material.GOLD_INGOT,7800)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropMaterial(Material.DIAMOND_SWORD,800)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,1800,"[Deadly] Mega Armor",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.DEADLY)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,7800,"[Deadly] Mega Set Armor",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.DEADLY)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,200,"[Deadly] Mega Tool",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.DEADLY)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,200,"[Deadly] Mega Weapon",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.DEADLY)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,600,"[Deadly] Mega Set Weapon",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.WEAPON,MonsterDifficulty.DEADLY)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,360,"[Deadly] Hardened Mega Armor",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.DEADLY)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,1560,"[Deadly] Hardened Mega Set Armor",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.DEADLY)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,40,"[Deadly] Hardened Mega Tool",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.DEADLY)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,40,"[Deadly] Hardened Mega Weapon",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.DEADLY)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new SigDrop(1,120,"[Deadly] Hardened Mega Set Weapon",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.DEADLY)); + aPlugin.API.Chests.LOOT_DEADLY.addDrop(new DropItem(Artifact.createArtifactItem(ArtifactItem.LOST_CORE),400)); aPlugin.API.Chests.LOOT_DEADLY.printDrops(); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropMaterial(Material.EMERALD,1,3,1000)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropMaterial(Material.DIAMOND,1,3,1000)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropMaterial(Material.GOLD_INGOT,1,3,1000)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropMaterial(Material.EMERALD_BLOCK,78)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropMaterial(Material.DIAMOND_BLOCK,1,2,78)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropMaterial(Material.GOLD_BLOCK,78)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,18,"[Hellfire] Mega Armor",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.HELLFIRE)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,78,"[Hellfire] Mega Set Armor",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.HELLFIRE)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,2,"[Hellfire] Mega Tool",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.HELLFIRE)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,2,"[Hellfire] Mega Weapon",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.HELLFIRE)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,6,"[Hellfire] Mega Set Weapon",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.WEAPON,MonsterDifficulty.HELLFIRE)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,1,"[Hellfire] Hardened Mega Armor",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.HELLFIRE)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,8,"[Hellfire] Hardened Mega Set Armor",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.HELLFIRE)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,1,"[Hellfire] Hardened Mega Tool",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.HELLFIRE)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,1,"[Hellfire] Hardened Mega Weapon",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.HELLFIRE)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,1,"[Hellfire] Hardened Mega Set Weapon",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.HELLFIRE)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropItem(Artifact.createArtifactItem(ArtifactItem.DIVINE_CORE),4)); - aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropItem(TwosideKeeper.HUNTERS_COMPASS.getItemStack(),4)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropMaterial(Material.EMERALD,1,3,60200)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropMaterial(Material.DIAMOND,1,3,7800)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropMaterial(Material.GOLD_INGOT,1,3,7800)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropMaterial(Material.EMERALD_BLOCK,7800)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropMaterial(Material.DIAMOND_BLOCK,1,2,7800)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropMaterial(Material.GOLD_BLOCK,7800)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,1800,"[Hellfire] Mega Armor",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.HELLFIRE)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,7800,"[Hellfire] Mega Set Armor",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.HELLFIRE)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,200,"[Hellfire] Mega Tool",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.HELLFIRE)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,200,"[Hellfire] Mega Weapon",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.HELLFIRE)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,600,"[Hellfire] Mega Set Weapon",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.WEAPON,MonsterDifficulty.HELLFIRE)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,540,"[Hellfire] Hardened Mega Armor",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.HELLFIRE)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,2340,"[Hellfire] Hardened Mega Set Armor",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.HELLFIRE)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,60,"[Hellfire] Hardened Mega Tool",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.HELLFIRE)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,60,"[Hellfire] Hardened Mega Weapon",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.HELLFIRE)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new SigDrop(1,180,"[Hellfire] Hardened Mega Set Weapon",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.HELLFIRE)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropItem(Artifact.createArtifactItem(ArtifactItem.DIVINE_CORE),400)); + aPlugin.API.Chests.LOOT_HELLFIRE.addDrop(new DropItem(TwosideKeeper.HUNTERS_COMPASS.getItemStack(),400)); aPlugin.API.Chests.LOOT_HELLFIRE.printDrops(); - aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,18,"[End] Mega Armor",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.END)); - aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,78,"[End] Mega Set Armor",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.END)); - aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,2,"[End] Mega Tool",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.END)); - aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,2,"[End] Mega Weapon",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.END)); - aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,6,"[End] Mega Set Weapon",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.WEAPON,MonsterDifficulty.END)); - aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,1,"[End] Hardened Mega Armor",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.END)); - aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,8,"[End] Hardened Mega Set Armor",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.END)); - aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,1,"[End] Hardened Mega Tool",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.END)); - aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,1,"[End] Hardened Mega Weapon",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.END)); - aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,1,"[End] Hardened Mega Set Weapon",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.END)); - aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new DropItem(Artifact.createArtifactItem(ArtifactItem.DIVINE_CORE),4)); + aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,1800,"[End] Mega Armor",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.END)); + aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,7800,"[End] Mega Set Armor",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.END)); + aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,200,"[End] Mega Tool",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.END)); + aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,200,"[End] Mega Weapon",SigDrop.NONHARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.END)); + aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,600,"[End] Mega Set Weapon",SigDrop.NONHARDENED,SigDrop.SET,SigDrop.WEAPON,MonsterDifficulty.END)); + aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,540,"[End] Hardened Mega Armor",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.ARMOR,MonsterDifficulty.END)); + aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,2340,"[End] Hardened Mega Set Armor",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.END)); + aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,60,"[End] Hardened Mega Tool",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.TOOL,MonsterDifficulty.END)); + aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,60,"[End] Hardened Mega Weapon",SigDrop.HARDENED,SigDrop.NONSET,SigDrop.WEAPON,MonsterDifficulty.END)); + aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new SigDrop(1,180,"[End] Hardened Mega Set Weapon",SigDrop.HARDENED,SigDrop.SET,SigDrop.ARMOR,MonsterDifficulty.END)); + aPlugin.API.Chests.LOOT_CUSTOM.addDrop(new DropItem(Artifact.createArtifactItem(ArtifactItem.DIVINE_CORE),400)); aPlugin.API.Chests.LOOT_CUSTOM.printDrops(); //aPlugin.API.Chests..addDrop(new DropItem(TwosideKeeper.HUNTERS_COMPASS.getItemStack(),10)); diff --git a/src/sig/plugin/TwosideKeeper/MonsterController.java b/src/sig/plugin/TwosideKeeper/MonsterController.java index 01152d4..ba7bbac 100644 --- a/src/sig/plugin/TwosideKeeper/MonsterController.java +++ b/src/sig/plugin/TwosideKeeper/MonsterController.java @@ -57,9 +57,6 @@ public class MonsterController { return false; } } else - if (!meetsConditionsToSpawn(ent)) { - return false; - } if (isZombieLeader(ent)) { //Zombie leaders have faster movement. ent.addPotionEffect(new PotionEffect(PotionEffectType.SPEED,Integer.MAX_VALUE,1)); @@ -76,6 +73,9 @@ public class MonsterController { TwosideKeeper.log(ChatColor.DARK_PURPLE+"Converting to Elite.", 2); convertMonster(m,md); return true; + } else + if (!meetsConditionsToSpawn(ent)) { + return false; } if (ent.getWorld().getName().equalsIgnoreCase("world_the_end")) { Monster m = (Monster)ent; @@ -153,8 +153,10 @@ public class MonsterController { for (Player p : Bukkit.getOnlinePlayers()) { if (ent.getWorld().equals(p.getWorld()) && !aPlugin.API.isAFK(p)) { double temp = ent.getLocation().distanceSquared(p.getLocation()); - if (temp<4096) {nearbyplayers++;} - dist = (temp