diff --git a/TwosideKeeper.jar b/TwosideKeeper.jar index 5cb0c5c..7e800e7 100644 Binary files a/TwosideKeeper.jar and b/TwosideKeeper.jar differ diff --git a/src/sig/plugin/TwosideKeeper/HelperStructures/Common/GenericFunctions.java b/src/sig/plugin/TwosideKeeper/HelperStructures/Common/GenericFunctions.java index d143253..ea05d31 100644 --- a/src/sig/plugin/TwosideKeeper/HelperStructures/Common/GenericFunctions.java +++ b/src/sig/plugin/TwosideKeeper/HelperStructures/Common/GenericFunctions.java @@ -80,6 +80,7 @@ import sig.plugin.TwosideKeeper.HelperStructures.EliteMonsterLocationFinder; import sig.plugin.TwosideKeeper.HelperStructures.ItemSet; import sig.plugin.TwosideKeeper.HelperStructures.PlayerMode; import sig.plugin.TwosideKeeper.HelperStructures.WorldShop; +import sig.plugin.TwosideKeeper.HelperStructures.Utils.ItemUtils; import sig.plugin.TwosideKeeper.HelperStructures.Utils.SoundUtils; public class GenericFunctions { @@ -755,40 +756,40 @@ public class GenericFunctions { return "Rabbit's Foot"; } case GOLD_RECORD:{ - return "Music Disc"; + return "Music Disc - 13"; } case GREEN_RECORD:{ - return "Music Disc"; + return "Music Disc - cat"; } case RECORD_10:{ - return "Music Disc"; + return "Music Disc - ward"; } case RECORD_11:{ - return "Music Disc"; + return "Music Disc - 11"; } case RECORD_12:{ - return "Music Disc"; + return "Music Disc - wait"; } case RECORD_3:{ - return "Music Disc"; + return "Music Disc - blocks"; } case RECORD_4:{ - return "Music Disc"; + return "Music Disc - chirp"; } case RECORD_5:{ - return "Music Disc"; + return "Music Disc - far"; } case RECORD_6:{ - return "Music Disc"; + return "Music Disc - mall"; } case RECORD_7:{ - return "Music Disc"; + return "Music Disc - mellohi"; } case RECORD_8:{ - return "Music Disc"; + return "Music Disc - stal"; } case RECORD_9:{ - return "Music Disc"; + return "Music Disc - strad"; } case REDSTONE_COMPARATOR:{ return "Comparator"; @@ -4715,5 +4716,16 @@ public class GenericFunctions { PopulatePlayerBlockList(p,15,15,2,5,false); return PlayerStructure.GetPlayerStructure(p).blockscanlist; } + + public static boolean itemCanBeSuckedUp(Item ent) { + ItemStack item = ent.getItemStack(); + //TwosideKeeper.log(item.toString()+": "+ent.getTicksLived()+".."+ent.getPickupDelay()+".."+((Item)ent).getName()+".."+((Item)ent).isCustomNameVisible()+".."+((Item)ent).getCustomName(), 0); + if (ItemUtils.isValidLoreItem(item) || + ent.isGlowing() || + ent.getPickupDelay()>=6000) { + return false; + } + return true; + } } diff --git a/src/sig/plugin/TwosideKeeper/HelperStructures/Common/RecipeLinker.java b/src/sig/plugin/TwosideKeeper/HelperStructures/Common/RecipeLinker.java index 7b59513..99ef865 100644 --- a/src/sig/plugin/TwosideKeeper/HelperStructures/Common/RecipeLinker.java +++ b/src/sig/plugin/TwosideKeeper/HelperStructures/Common/RecipeLinker.java @@ -31,6 +31,12 @@ public enum RecipeLinker { new ItemStack(Material.EMERALD),new ItemStack(Material.CHEST),new ItemStack(Material.EMERALD), new ItemStack(Material.OBSIDIAN),new ItemStack(Material.OBSIDIAN),new ItemStack(Material.OBSIDIAN), }), + vacuumcube(RecipeCategory.CONTAINERS,ChatColor.YELLOW,"Vacuum Cube",new ItemStack[]{ + CustomItem.VacuumCube(), + new ItemStack(Material.DIAMOND_BLOCK),new ItemStack(Material.ELYTRA),new ItemStack(Material.DIAMOND_BLOCK), + new ItemStack(Material.DIAMOND_BLOCK),new ItemStack(Material.ENDER_CHEST),new ItemStack(Material.DIAMOND_BLOCK), + new ItemStack(Material.ENDER_PEARL),new ItemStack(Material.REDSTONE_BLOCK),new ItemStack(Material.ENDER_PEARL) + }), dc(RecipeCategory.CONTAINERS,ChatColor.YELLOW,"Duplicate Ender Item Cube",new ItemStack[]{ CustomItem.EnderItemCube(2), CustomItem.EnderItemCube(),new ItemStack(Material.NETHER_STAR) diff --git a/src/sig/plugin/TwosideKeeper/HelperStructures/CustomItem.java b/src/sig/plugin/TwosideKeeper/HelperStructures/CustomItem.java index d74f41d..f87ff1b 100644 --- a/src/sig/plugin/TwosideKeeper/HelperStructures/CustomItem.java +++ b/src/sig/plugin/TwosideKeeper/HelperStructures/CustomItem.java @@ -117,7 +117,7 @@ public class CustomItem { TwosideKeeper.WORLD_SHOP2_RECIPE = WorldShop2Recipe(); } - private static ItemStack VacuumCube() { + public static ItemStack VacuumCube() { ItemStack item_VacuumCube = new ItemStack(Material.ENDER_CHEST); List item_VacuumCube_lore = new ArrayList(); item_VacuumCube_lore.add("A storage container that sucks"); diff --git a/src/sig/plugin/TwosideKeeper/HelperStructures/WorldShop.java b/src/sig/plugin/TwosideKeeper/HelperStructures/WorldShop.java index 31efd20..7e348c0 100644 --- a/src/sig/plugin/TwosideKeeper/HelperStructures/WorldShop.java +++ b/src/sig/plugin/TwosideKeeper/HelperStructures/WorldShop.java @@ -140,7 +140,7 @@ public class WorldShop { price = pricelist.get(item.getType().name()); } if (TwosideKeeper.DEAL_OF_THE_DAY_ITEM.isSimilar(item)) { - return price; + return price*0.8; } return ModifyPriceBasedOnLocation(price); } diff --git a/src/sig/plugin/TwosideKeeper/Recipes.java b/src/sig/plugin/TwosideKeeper/Recipes.java index b73a2e0..41f585d 100644 --- a/src/sig/plugin/TwosideKeeper/Recipes.java +++ b/src/sig/plugin/TwosideKeeper/Recipes.java @@ -35,6 +35,8 @@ public class Recipes { Bukkit.addRecipe(TwosideKeeper.DUPLICATE_ENDER_ITEM_CUBE_RECIPE); Bukkit.addRecipe(TwosideKeeper.VACUUM_CUBE_RECIPE); + + Bukkit.addRecipe(TwosideKeeper.FILTER_CUBE_RECIPE); } public static void Initialize_ArrowQuiver_Recipe() { Bukkit.addRecipe(TwosideKeeper.ARROW_QUIVER_RECIPE); diff --git a/src/sig/plugin/TwosideKeeper/TwosideKeeper.java b/src/sig/plugin/TwosideKeeper/TwosideKeeper.java index 03bae33..17f04b3 100644 --- a/src/sig/plugin/TwosideKeeper/TwosideKeeper.java +++ b/src/sig/plugin/TwosideKeeper/TwosideKeeper.java @@ -298,6 +298,7 @@ public class TwosideKeeper extends JavaPlugin implements Listener { public static ShapedRecipe ENDER_ITEM_CUBE_RECIPE; public static ShapelessRecipe DUPLICATE_ENDER_ITEM_CUBE_RECIPE; public static ShapelessRecipe VACUUM_CUBE_RECIPE; + public static ShapelessRecipe FILTER_CUBE_RECIPE; public static ShapedRecipe ARROW_QUIVER_RECIPE; public static ShapedRecipe HARDENED_IRON_HELMET_RECIPE; public static ShapedRecipe HARDENED_IRON_CHESTPLATE_RECIPE; @@ -7338,6 +7339,7 @@ public class TwosideKeeper extends JavaPlugin implements Listener { int color1=0,color2=1; double health=pd2.target.getHealth(); double maxhealth=pd2.target.getMaxHealth(); + final double orghealth = health; if (health>20) { while (health>20) { color1++; @@ -7346,15 +7348,21 @@ public class TwosideKeeper extends JavaPlugin implements Listener { } } for (int i=0;i20) { - for (int i=0;i<10;i++) { - heartdisplay+=Character.toString((char)0x2665); + if (orghealth>20) { + for (int i=0;i<10;i++) { + heartdisplay+=Character.toString('♥'); + } + } else { + for (int i=0;i<10;i++) { + heartdisplay+=Character.toString('♡'); + } } } else { for (int i=0;i ents = p.getNearbyEntities(8, 8, 8); + List ents = p.getNearbyEntities(6, 6, 6); for (Entity ent : ents) { - if (ent instanceof Item) { + if (ent instanceof Item && GenericFunctions.itemCanBeSuckedUp((Item)ent)) { //Pull towards the player. double SPD = 0.2; double deltax = ent.getLocation().getX()-p.getLocation().getX();