From 6478656501c12190bde9f7c8ad86047b3374ea98 Mon Sep 17 00:00:00 2001 From: LCastr0 Date: Thu, 29 Dec 2016 16:25:20 -0200 Subject: [PATCH] Fixed armorstand balloon types --- .../mineplex/core/common/util/UtilEnt.java | 8 +- .../gadget/gadgets/balloons/BalloonItem.java | 94 +++++++++++-------- .../gadget/gadgets/balloons/BalloonType.java | 29 +++--- .../gadget/gadgets/item/ItemFootball.java | 2 +- .../gadgets/wineffect/WinEffectHalloween.java | 2 +- .../core/gadget/types/BalloonGadget.java | 38 ++++---- .../core/gadget/util/BalloonData.java | 61 +++++++----- .../mineplex/core/mavericks/DisplaySlot.java | 2 +- .../src/mineplex/core/mount/DragonData.java | 2 +- .../src/mineplex/core/npc/NpcManager.java | 4 +- .../src/mineplex/core/pet/PetManager.java | 4 +- .../game/clans/clans/siege/weapon/Cannon.java | 11 +-- .../gameplay/safelog/npc/CombatLogNPC.java | 2 +- .../clans/objective/AttackEnemyObjective.java | 2 +- .../modules/HalloweenSpookinessManager.java | 2 +- .../mineplex/hub/modules/SoccerManager.java | 2 +- .../mavericks/basketball/BasketballGame.java | 2 +- .../classcombat/Skill/Assassin/Illusion.java | 4 +- .../classcombat/Skill/Ranger/RopedArrow.java | 2 +- .../core/boss/broodmother/SpiderCreature.java | 5 +- .../broodmother/SpiderMinionCreature.java | 2 +- .../core/boss/ironwizard/GolemCreature.java | 3 +- .../boss/skeletonking/SkeletonCreature.java | 2 +- .../abilities/SkeletonArcherShield.java | 4 +- .../game/core/boss/snake/SnakeCreature.java | 5 +- .../games/baconbrawl/kits/KitSheepPig.java | 2 +- .../game/games/basketball/Basketball.java | 2 +- .../displays/IronWizardDisplay.java | 4 +- .../displays/SlimeKingDisplay.java | 5 +- .../bossbattles/displays/SnakeDisplay.java | 6 +- .../bossbattles/displays/SpiderDisplay.java | 2 +- .../arcade/game/games/bouncyballs/Ball.java | 2 +- .../arcade/game/games/build/BuildData.java | 2 +- .../arcade/game/games/christmas/Sleigh.java | 2 +- .../game/games/christmas/SleighHorse.java | 2 +- .../game/games/christmas/SleighPart.java | 6 +- .../christmas/content/BossSnowmanPattern.java | 8 +- .../games/christmas/content/CaveGiant.java | 3 +- .../games/christmas/content/PumpkinKing.java | 2 +- .../games/christmas/content/SnowmanBoss.java | 2 +- .../games/christmas/content/SnowmanMaze.java | 2 +- .../christmas/content/SnowmanMinion.java | 2 +- .../games/christmas/content/SnowmanWaveA.java | 2 +- .../games/christmas/content/SnowmanWaveB.java | 3 +- .../game/games/dragonriders/DragonData.java | 2 +- .../arcade/game/games/dragons/Dragons.java | 2 +- .../game/games/dragons/DragonsTeams.java | 2 +- .../game/games/gladiators/Gladiators.java | 2 +- .../arcade/game/games/gravity/Gravity.java | 6 +- .../game/games/gravity/GravityObject.java | 3 +- .../halloween/creatures/PumpkinKing.java | 5 +- .../games/halloween2016/Halloween2016.java | 2 +- .../halloween2016/creatures/MobGiant.java | 2 +- .../creatures/MobPumpkinPrince.java | 2 +- .../halloween2016/creatures/MobWitch.java | 2 +- .../games/halloween2016/wave/WaveBoss.java | 2 +- .../games/minecraftleague/data/Spawner.java | 2 +- .../variation/wither/data/PathfinderData.java | 2 +- .../wither/data/WitherMinionManager.java | 2 +- .../challenge/other/ZombieWrapper.java | 2 +- .../type/ChallengeRedLightGreenLight.java | 2 +- .../challenge/type/ChallengeVolleyPig.java | 2 +- .../arcade/game/games/monsterleague/Ball.java | 4 +- .../arcade/game/games/monstermaze/Maze.java | 4 +- .../games/paintball/PlayerCopyPaintball.java | 2 +- .../arcade/game/games/sheep/SheepData.java | 2 +- .../perks/chicken/PerkChickenRocket.java | 2 +- .../smash/perks/enderman/SmashEnderman.java | 2 +- .../smash/perks/pig/PerkPigBaconBomb.java | 2 +- .../smash/perks/snowman/SmashSnowman.java | 2 +- .../game/games/smash/perks/wolf/PerkWolf.java | 2 +- .../game/arcade/game/games/snake/Snake.java | 12 +-- .../games/sneakyassassins/npc/NpcManager.java | 2 +- .../sneakyassassins/powerups/PowerUpItem.java | 4 +- .../games/speedbuilders/SpeedBuilders.java | 4 +- .../speedbuilders/data/RecreationData.java | 2 +- .../arcade/game/games/typewars/Minion.java | 2 +- .../arcade/game/games/typewars/TypeWars.java | 2 +- .../game/games/valentines/Valentines.java | 5 +- .../tutorial/TutorialValentines.java | 7 +- .../game/games/wither/PlayerCopyWither.java | 2 +- .../game/modules/combatlog/CombatLogNPC.java | 6 +- .../src/nautilus/game/arcade/kit/Kit.java | 2 +- .../game/arcade/kit/perks/PerkHorsePet.java | 2 +- .../lobby/current/NewGameLobbyManager.java | 2 +- .../lobby/legacy/LegacyGameLobbyManager.java | 2 +- .../review/MavericksReviewManager.java | 2 +- 87 files changed, 227 insertions(+), 250 deletions(-) diff --git a/Plugins/Mineplex.Core.Common/src/mineplex/core/common/util/UtilEnt.java b/Plugins/Mineplex.Core.Common/src/mineplex/core/common/util/UtilEnt.java index 0d6393185..f39918d7d 100644 --- a/Plugins/Mineplex.Core.Common/src/mineplex/core/common/util/UtilEnt.java +++ b/Plugins/Mineplex.Core.Common/src/mineplex/core/common/util/UtilEnt.java @@ -88,7 +88,7 @@ public class UtilEnt ((CraftEntity)entity).getHandle().setInvisible(invisible); } - public static void Leash(LivingEntity leashed, Entity holder, boolean pull, boolean breakable) + public static void leash(LivingEntity leashed, Entity holder, boolean pull, boolean breakable) { leashed.setLeashHolder(holder); @@ -198,12 +198,12 @@ public class UtilEnt return box.b(box2); } - public static void Vegetate(Entity entity) + public static void vegetate(Entity entity) { - Vegetate(entity, false); + vegetate(entity, false); } - public static void Vegetate(Entity entity, boolean mute) + public static void vegetate(Entity entity, boolean mute) { try { diff --git a/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/balloons/BalloonItem.java b/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/balloons/BalloonItem.java index 9a80f69b0..aa6778ec5 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/balloons/BalloonItem.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/balloons/BalloonItem.java @@ -1,7 +1,13 @@ package mineplex.core.gadget.gadgets.balloons; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.UUID; + import org.bukkit.entity.Ageable; -import org.bukkit.entity.Bat; +import org.bukkit.entity.ArmorStand; import org.bukkit.entity.Entity; import org.bukkit.entity.EntityType; import org.bukkit.entity.LivingEntity; @@ -11,9 +17,6 @@ import org.bukkit.potion.PotionEffect; import org.bukkit.potion.PotionEffectType; import mineplex.core.common.util.UtilEnt; -import mineplex.core.creature.Creature; -import mineplex.core.disguise.disguises.DisguiseArmorStand; -import mineplex.core.disguise.disguises.DisguiseWither; import mineplex.core.gadget.GadgetManager; import mineplex.core.gadget.types.BalloonGadget; @@ -21,6 +24,7 @@ public class BalloonItem extends BalloonGadget { private BalloonType _balloonType; + private Map> _entities = new HashMap<>(); public BalloonItem(GadgetManager manager, BalloonType balloonType) { @@ -32,59 +36,69 @@ public class BalloonItem extends BalloonGadget } @Override - public Entity spawnEntity(Player player) + public Entity[] spawnEntity(Player player) { - if (_balloonType.equals(BalloonType.BABY_WIDDER)) + Entity[] ents = new Entity[2]; + if (_balloonType.getEntityType().equals(EntityType.ARMOR_STAND)) { - Creature creatureModule = Manager.getPetManager().getCreatureModule(); - creatureModule.SetForce(true); - Entity silverfish = player.getWorld().spawnEntity(player.getLocation(), _balloonType.getEntityType()); - UtilEnt.silence(silverfish, true); + ArmorStand armorStand = player.getWorld().spawn(player.getLocation(), ArmorStand.class); + armorStand.setSmall(_balloonType.isBaby()); + armorStand.setGravity(false); + armorStand.setVisible(false); + armorStand.setHelmet(_balloonType.getDisplayItem()); + addEntity(player, armorStand); - DisguiseWither witherDisguise = new DisguiseWither(silverfish); + ents[0] = armorStand; - witherDisguise.setInvulTime(530); + Entity cow = player.getWorld().spawnEntity(player.getLocation(), EntityType.COW); + ((LivingEntity) cow).addPotionEffect(new PotionEffect(PotionEffectType.INVISIBILITY, Integer.MAX_VALUE, 1, false, false)); + ((Ageable) cow).setBaby(); + ((LivingEntity) cow).addPotionEffect(new PotionEffect(PotionEffectType.SLOW, Integer.MAX_VALUE, 7, false, false)); + UtilEnt.vegetate(cow); + //UtilEnt.ghost(bat, true, true); + UtilEnt.silence(cow, true); + addEntity(player, cow); - org.bukkit.entity.Creature silver = (org.bukkit.entity.Creature) creatureModule.SpawnEntity(player.getLocation(), EntityType.SILVERFISH); - UtilEnt.Vegetate(silver, true); - UtilEnt.silence(silver, true); - silver.addPotionEffect(new PotionEffect(PotionEffectType.INVISIBILITY, Integer.MAX_VALUE, 0)); - silverfish.setPassenger(silver); + ents[1] = cow; - Manager.getDisguiseManager().disguise(witherDisguise); - - creatureModule.SetForce(false); - - return silver; - } - else if (_balloonType.getEntityType().equals(EntityType.ARMOR_STAND)) - { - Entity bat = player.getWorld().spawn(player.getLocation(), Bat.class); - ((LivingEntity) bat).addPotionEffect(new PotionEffect(PotionEffectType.INVISIBILITY, Integer.MAX_VALUE, 1, false, false)); - UtilEnt.silence(bat, true); - - DisguiseArmorStand disguiseArmorStand = new DisguiseArmorStand(bat); - disguiseArmorStand.setHelmet(_balloonType.getDisplayItem()); - disguiseArmorStand.setInvisible(true); - if (_balloonType.isBaby()) disguiseArmorStand.setSmall(); - disguiseArmorStand.setGravityEffected(); - - Manager.getDisguiseManager().disguise(disguiseArmorStand); - - return bat; + return ents; } else if (_balloonType.equals(BalloonType.BABY_ZOMBIE)) { Zombie zombie = player.getWorld().spawn(player.getLocation(), Zombie.class); zombie.setBaby(true); - return zombie; + UtilEnt.vegetate(zombie); + addEntity(player, zombie); + ents[0] = zombie; + return ents; } Entity entity = player.getWorld().spawnEntity(player.getLocation(), _balloonType.getEntityType()); if (_balloonType.isBaby() && entity instanceof Ageable) ((Ageable) entity).setBaby(); - return entity; + UtilEnt.vegetate(entity); + addEntity(player, entity); + ents[0] = entity; + return ents; + } + + private void addEntity(Player player, Entity entity) + { + _entities.computeIfAbsent(player.getUniqueId(), list -> new ArrayList<>()); + List entities = _entities.get(player.getUniqueId()); + entities.add(entity); + _entities.put(player.getUniqueId(), entities); + } + + @Override + public void removeEntities(Player player) + { + for (Entity entity : _entities.get(player.getUniqueId())) + { + entity.remove(); + } + _entities.remove(player.getUniqueId()); } } diff --git a/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/balloons/BalloonType.java b/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/balloons/BalloonType.java index 0008dbca5..aa0ed6242 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/balloons/BalloonType.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/balloons/BalloonType.java @@ -10,25 +10,28 @@ import mineplex.core.common.util.UtilText; public enum BalloonType { + // BABY BABY_COW (EntityType.COW, true, "Baby Cow Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), BABY_PIG (EntityType.PIG, true, "Baby Pig Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), BABY_ZOMBIE (EntityType.ZOMBIE, true, "Baby Zombie Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), BABY_MUSHROOM(EntityType.MUSHROOM_COW, true, "Baby Mushroom Cow Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), - // TODO BABY WIDDER SPAWN - BABY_WIDDER(EntityType.SILVERFISH, "Baby Widder Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), - BABY_OCELOT(EntityType.OCELOT, true, "Baby Ocelot Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), - BABY_WOLF(EntityType.WOLF, true, "Baby Wolf Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), - BABY_SHEEP(EntityType.SHEEP, true, "Baby Sheep Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), - BABY_VILLAGER(EntityType.VILLAGER, true, "Baby Villager Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), - SQUID(EntityType.SQUID, "Squid Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), - BAT(EntityType.BAT, "Bat Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), + BABY_OCELOT (EntityType.OCELOT, true, "Baby Ocelot Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), + BABY_WOLF (EntityType.WOLF, true, "Baby Wolf Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), + BABY_SHEEP (EntityType.SHEEP, true, "Baby Sheep Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), + BABY_VILLAGER(EntityType.VILLAGER, true, "Baby Villager Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), + BABY_SLIME (EntityType.SLIME, true, "Baby Slime Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), + + // NOT BABY + SQUID (EntityType.SQUID, "Squid Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), + BAT (EntityType.BAT, "Bat Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), SILVERFISH(EntityType.SILVERFISH, "Silverfish Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), - GUARDIAN(EntityType.GUARDIAN, "Guardian Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), - BABY_SLIME(EntityType.SLIME, true, "Baby Slime Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), - DRAGON_EGG(new ItemStack(Material.DRAGON_EGG), false, "Dragon Egg Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0), + GUARDIAN (EntityType.GUARDIAN, "Guardian Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0, new ItemStack(Material.GLASS)), + + // BLOCK + DRAGON_EGG (new ItemStack(Material.DRAGON_EGG), false, "Dragon Egg Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0), DIAMOND_BLOCK(new ItemStack(Material.DIAMOND_BLOCK), false, "Diamond Block Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0), - IRON_BLOCK(new ItemStack(Material.IRON_BLOCK), false, "Iron Block Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0), - GOLD_BLOCK(new ItemStack(Material.GOLD_BLOCK), false, "Gold Block Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0), + IRON_BLOCK (new ItemStack(Material.IRON_BLOCK), false, "Iron Block Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0), + GOLD_BLOCK (new ItemStack(Material.GOLD_BLOCK), false, "Gold Block Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0), EMERALD_BLOCK(new ItemStack(Material.EMERALD_BLOCK), false, "Emerald Block Balloon", UtilText.splitLinesToArray(new String[]{"Placeholder"}, LineFormat.LORE), 0); private EntityType _entityType; diff --git a/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/item/ItemFootball.java b/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/item/ItemFootball.java index a405ea02c..06a4178ff 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/item/ItemFootball.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/item/ItemFootball.java @@ -51,7 +51,7 @@ public class ItemFootball extends ItemGadget FallingBlock ball = player.getWorld().spawnFallingBlock(player.getLocation().add(0, 1, 0), Material.SKULL, (byte) 3); Bat bat = player.getWorld().spawn(player.getLocation(), Bat.class); - UtilEnt.Vegetate(bat); + UtilEnt.vegetate(bat); UtilEnt.ghost(bat, true, true); UtilEnt.silence(bat, true); diff --git a/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/wineffect/WinEffectHalloween.java b/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/wineffect/WinEffectHalloween.java index 49aaa7bbe..821a9daff 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/wineffect/WinEffectHalloween.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/gadget/gadgets/wineffect/WinEffectHalloween.java @@ -134,7 +134,7 @@ public class WinEffectHalloween extends WinEffectGadget skeleton.setCustomNameVisible(true); skeleton.getEquipment().setHelmet(new ItemStack(Material.JACK_O_LANTERN)); UtilEnt.ghost(skeleton, true, false); - UtilEnt.Vegetate(skeleton); + UtilEnt.vegetate(skeleton); for (int i = 0; i < 15; i++) { playFirework(skeleton.getLocation().clone().add(0, 2, 0), i, true); diff --git a/Plugins/Mineplex.Core/src/mineplex/core/gadget/types/BalloonGadget.java b/Plugins/Mineplex.Core/src/mineplex/core/gadget/types/BalloonGadget.java index d8fa19bc1..a0c33ea21 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/gadget/types/BalloonGadget.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/gadget/types/BalloonGadget.java @@ -1,18 +1,14 @@ package mineplex.core.gadget.types; -import java.util.ArrayList; import java.util.HashMap; -import java.util.List; import java.util.Map; import java.util.UUID; import org.bukkit.Material; -import org.bukkit.entity.Bat; import org.bukkit.entity.Entity; import org.bukkit.entity.EntityType; import org.bukkit.entity.Player; import org.bukkit.event.EventHandler; -import org.bukkit.event.player.PlayerJoinEvent; import mineplex.core.common.util.F; import mineplex.core.common.util.UtilPlayer; @@ -24,11 +20,8 @@ import mineplex.core.updater.event.UpdateEvent; public abstract class BalloonGadget extends Gadget { - private static final List ENTITY_LIST = new ArrayList<>(); private static final Map> PLAYER_BALLOONS = new HashMap<>(); - private Map _playerBalloons = new HashMap<>(); - private List _entities = new ArrayList<>(); private EntityType _balloon; public BalloonGadget(GadgetManager manager, String name, String[] desc, int cost, Material material, byte data, EntityType balloon, String... altNames) @@ -73,7 +66,18 @@ public abstract class BalloonGadget extends Gadget return false; PLAYER_BALLOONS.computeIfAbsent(player.getUniqueId(), map -> new HashMap<>()); - PLAYER_BALLOONS.get(player.getUniqueId()).put(_balloon, new BalloonData(player, spawnEntity(player))); + BalloonData balloonData; + Entity[] ents = spawnEntity(player); + if (ents[1] == null) + balloonData = new BalloonData(player, ents[0]); + else if (!_balloon.equals(EntityType.ARMOR_STAND)) + balloonData = new BalloonData(player, ents[0], ents[1]); + else + { + balloonData = new BalloonData(player, ents[0]); + balloonData.setLeash(ents[1]); + } + PLAYER_BALLOONS.get(player.getUniqueId()).put(_balloon, balloonData); return true; } @@ -84,17 +88,15 @@ public abstract class BalloonGadget extends Gadget { if (PLAYER_BALLOONS.get(player.getUniqueId()).containsKey(_balloon)) { - BalloonData balloonData = PLAYER_BALLOONS.get(player.getUniqueId()).get(_balloon); - Entity entity = balloonData.getBalloon(); - entity.remove(); - Bat bat = balloonData.getBat(); - bat.remove(); + removeEntities(player); PLAYER_BALLOONS.get(player.getUniqueId()).remove(_balloon); } } } - protected abstract Entity spawnEntity(Player player); + protected abstract Entity[] spawnEntity(Player player); + + protected abstract void removeEntities(Player player); @EventHandler public void onUpdate(UpdateEvent event) @@ -116,17 +118,9 @@ public abstract class BalloonGadget extends Gadget if (PLAYER_BALLOONS.containsKey(player.getUniqueId())) { Map balloonGadgets = PLAYER_BALLOONS.get(player.getUniqueId()); - if (balloonGadgets.containsKey(_balloon)) - return false; return balloonGadgets.size() < 10; } return true; } - @EventHandler - public void onPlayerJoin(PlayerJoinEvent event) - { - - } - } diff --git a/Plugins/Mineplex.Core/src/mineplex/core/gadget/util/BalloonData.java b/Plugins/Mineplex.Core/src/mineplex/core/gadget/util/BalloonData.java index 53a0eb46e..da817f426 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/gadget/util/BalloonData.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/gadget/util/BalloonData.java @@ -1,16 +1,12 @@ package mineplex.core.gadget.util; import org.bukkit.Location; -import org.bukkit.entity.Bat; import org.bukkit.entity.Entity; import org.bukkit.entity.LivingEntity; import org.bukkit.entity.Player; -import org.bukkit.potion.PotionEffect; -import org.bukkit.potion.PotionEffectType; import org.bukkit.util.Vector; import mineplex.core.common.util.UtilAlg; -import mineplex.core.common.util.UtilEnt; import mineplex.core.common.util.UtilMath; public class BalloonData @@ -22,12 +18,11 @@ public class BalloonData */ private Player _player; - private Entity _balloon; + private Entity _balloon, _passenger, _leash; private Location _balloonLoc, _target; private Vector _direction; private double _speed; private long _idleTime; - private Bat _bat; public BalloonData(Player player, Entity balloon) { @@ -38,16 +33,35 @@ public class BalloonData _speed = 0.2; _idleTime = 0; _direction = new Vector(1, 0, 0); - spawnBat(); + ((LivingEntity) _balloon).setLeashHolder(_player); + } + + // This exists for a possible widder balloon that could be added later + public BalloonData(Player player, Entity balloon, Entity passenger) + { + _player = player; + _balloon = balloon; + _passenger = passenger; + _balloonLoc = player.getEyeLocation(); + _target = getNewTarget(); + _speed = 0.2; + _idleTime = 0; + _direction = new Vector(1, 0, 0); + ((LivingEntity) _balloon).setLeashHolder(_player); } public void update() { - // Update bat - _bat.teleport(_player.getLocation()); - - if (((LivingEntity) _balloon).getLeashHolder() == null) - ((LivingEntity) _balloon).setLeashHolder(_bat); + if (_leash == null) + { + if (!((LivingEntity) _balloon).isLeashed()) + ((LivingEntity) _balloon).setLeashHolder(_player); + } + else + { + if (!((LivingEntity) _leash).isLeashed()) + ((LivingEntity) _leash).setLeashHolder(_player); + } //Update Target if (UtilMath.offset(_player.getEyeLocation(), _target) > 3 || UtilMath.offset(_balloonLoc, _target) < 1) @@ -89,6 +103,15 @@ public class BalloonData _balloon.teleport(_balloonLoc); _balloon.setVelocity(new Vector(0, .25, 0)); + if (_passenger != null) + { + _passenger.teleport(_balloonLoc); + _balloon.setPassenger(_passenger); + } + if (_leash != null) + { + _leash.teleport(_balloon.getLocation().add(0, 1.5, 0)); + } } private Location getNewTarget() @@ -101,18 +124,10 @@ public class BalloonData return _balloon; } - public Bat getBat() + public void setLeash(Entity leashedEntity) { - return _bat; - } - - private void spawnBat() - { - _bat = _player.getWorld().spawn(_player.getLocation(), Bat.class); - ((LivingEntity) _balloon).setLeashHolder(_bat); - _bat.addPotionEffect(new PotionEffect(PotionEffectType.INVISIBILITY, Integer.MAX_VALUE, 1, false, false)); - UtilEnt.silence(_bat, true); - ((LivingEntity) _balloon).setShouldBreakLeash(false); + _leash = leashedEntity; + ((LivingEntity) _leash).setLeashHolder(_player); } } diff --git a/Plugins/Mineplex.Core/src/mineplex/core/mavericks/DisplaySlot.java b/Plugins/Mineplex.Core/src/mineplex/core/mavericks/DisplaySlot.java index 8e38983f6..35f605f3f 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/mavericks/DisplaySlot.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/mavericks/DisplaySlot.java @@ -86,7 +86,7 @@ public class DisplaySlot } else { - UtilEnt.Vegetate(e, true); + UtilEnt.vegetate(e, true); UtilEnt.ghost(e, true, false); } _pastedEntities.add(e); diff --git a/Plugins/Mineplex.Core/src/mineplex/core/mount/DragonData.java b/Plugins/Mineplex.Core/src/mineplex/core/mount/DragonData.java index 1203bad95..a1d664e60 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/mount/DragonData.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/mount/DragonData.java @@ -44,7 +44,7 @@ public class DragonData extends MountData //Spawn Dragon Dragon = rider.getWorld().spawn(rider.getLocation(), EnderDragon.class); - UtilEnt.Vegetate(Dragon); + UtilEnt.vegetate(Dragon); UtilEnt.ghost(Dragon, true, false); rider.getWorld().playSound(rider.getLocation(), Sound.ENDERDRAGON_GROWL, 20f, 1f); diff --git a/Plugins/Mineplex.Core/src/mineplex/core/npc/NpcManager.java b/Plugins/Mineplex.Core/src/mineplex/core/npc/NpcManager.java index 73c160a68..4e76af53b 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/npc/NpcManager.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/npc/NpcManager.java @@ -341,7 +341,7 @@ public class NpcManager extends MiniPlugin if (npc.getDatabaseRecord().getRadius() == 0) { - UtilEnt.Vegetate(entity); + UtilEnt.vegetate(entity); UtilEnt.silence(entity, true); UtilEnt.ghost(entity, true, false); @@ -604,7 +604,7 @@ public class NpcManager extends MiniPlugin if (npc.getDatabaseRecord().getRadius() == 0) { - UtilEnt.Vegetate(entity); + UtilEnt.vegetate(entity); UtilEnt.ghost(entity, true, false); } } diff --git a/Plugins/Mineplex.Core/src/mineplex/core/pet/PetManager.java b/Plugins/Mineplex.Core/src/mineplex/core/pet/PetManager.java index 89d244c6f..ce38025e4 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/pet/PetManager.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/pet/PetManager.java @@ -218,7 +218,7 @@ public class PetManager extends MiniClientPlugin witherDisguise.setInvulTime(530); Creature silverfish = (Creature) _creatureModule.SpawnEntity(location, EntityType.SILVERFISH); - UtilEnt.Vegetate(silverfish, true); + UtilEnt.vegetate(silverfish, true); UtilEnt.silence(silverfish, true); silverfish.addPotionEffect(new PotionEffect(PotionEffectType.INVISIBILITY, Integer.MAX_VALUE, 0)); pet.setPassenger(silverfish); @@ -358,7 +358,7 @@ public class PetManager extends MiniClientPlugin ((Ageable)pet).setAgeLock(true); } - UtilEnt.Vegetate(pet); + UtilEnt.vegetate(pet); } public Creature getPet(Player player) diff --git a/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/clans/siege/weapon/Cannon.java b/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/clans/siege/weapon/Cannon.java index fab2296fb..9a558b8c5 100644 --- a/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/clans/siege/weapon/Cannon.java +++ b/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/clans/siege/weapon/Cannon.java @@ -1,14 +1,9 @@ package mineplex.game.clans.clans.siege.weapon; -import java.util.List; -import java.util.stream.Collectors; -import java.util.stream.Stream; - import org.bukkit.Bukkit; import org.bukkit.Location; import org.bukkit.Material; import org.bukkit.Sound; -import org.bukkit.block.Block; import org.bukkit.entity.ArmorStand; import org.bukkit.entity.Player; import org.bukkit.entity.Slime; @@ -41,13 +36,11 @@ import mineplex.game.clans.clans.ClanInfo; import mineplex.game.clans.clans.ClansGame; import mineplex.game.clans.clans.ClansManager; import mineplex.game.clans.clans.siege.SiegeManager; -import mineplex.game.clans.clans.siege.events.SiegeWeaponExplodeEvent; import mineplex.game.clans.clans.siege.repository.tokens.SiegeWeaponToken; import mineplex.game.clans.clans.siege.weapon.projectile.WeaponProjectile; import mineplex.game.clans.clans.siege.weapon.util.AccessRule; import mineplex.game.clans.clans.siege.weapon.util.AccessType; import mineplex.game.clans.clans.siege.weapon.util.WeaponStateInfo; -import mineplex.game.clans.core.repository.ClanTerritory; public class Cannon extends SiegeWeapon { @@ -324,7 +317,7 @@ public class Cannon extends SiegeWeapon Slime filler = _location.getWorld().spawn(_location.clone(), Slime.class); UtilEnt.silence(filler, true); - UtilEnt.Vegetate(filler); + UtilEnt.vegetate(filler); filler.setSize(-1); filler.addPotionEffect(new PotionEffect(PotionEffectType.INVISIBILITY, 99999999, 1, true, false)); @@ -334,7 +327,7 @@ public class Cannon extends SiegeWeapon Slime playerMount = _location.getWorld().spawn(_location.clone(), Slime.class); UtilEnt.silence(playerMount, true); - UtilEnt.Vegetate(playerMount); + UtilEnt.vegetate(playerMount); playerMount.setSize(-1); playerMount.addPotionEffect(new PotionEffect(PotionEffectType.INVISIBILITY, 99999999, 1, true, false)); diff --git a/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/gameplay/safelog/npc/CombatLogNPC.java b/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/gameplay/safelog/npc/CombatLogNPC.java index 1d0dd2814..60eac7a0f 100644 --- a/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/gameplay/safelog/npc/CombatLogNPC.java +++ b/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/gameplay/safelog/npc/CombatLogNPC.java @@ -195,7 +195,7 @@ public class CombatLogNPC skel.setMetadata("CombatLogNPC", new FixedMetadataValue(ClansManager.getInstance().getPlugin(), player.getUniqueId().toString())); skel.teleport(spawnLoc); skel.setHealth(_spawnHealth); - UtilEnt.Vegetate(skel); + UtilEnt.vegetate(skel); UtilEnt.silence(skel, true); skel.getEquipment().setHelmet(player.getInventory().getHelmet()); diff --git a/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/tutorials/clans/objective/AttackEnemyObjective.java b/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/tutorials/clans/objective/AttackEnemyObjective.java index 2b6449d02..2bf5e0555 100644 --- a/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/tutorials/clans/objective/AttackEnemyObjective.java +++ b/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/tutorials/clans/objective/AttackEnemyObjective.java @@ -94,7 +94,7 @@ public class AttackEnemyObjective extends OrderedObjective shooter.setCustomName(name); shooter.setCustomNameVisible(true); - UtilEnt.Vegetate(shooter); + UtilEnt.vegetate(shooter); shooter.teleport(location); shooter.setHealth(shooter.getMaxHealth()); diff --git a/Plugins/Mineplex.Hub/src/mineplex/hub/modules/HalloweenSpookinessManager.java b/Plugins/Mineplex.Hub/src/mineplex/hub/modules/HalloweenSpookinessManager.java index 3f033bcd6..10e7b7068 100644 --- a/Plugins/Mineplex.Hub/src/mineplex/hub/modules/HalloweenSpookinessManager.java +++ b/Plugins/Mineplex.Hub/src/mineplex/hub/modules/HalloweenSpookinessManager.java @@ -113,7 +113,7 @@ public class HalloweenSpookinessManager extends MiniPlugin Skeleton skeleton = loc.getWorld().spawn(loc, Skeleton.class); UtilEnt.silence(skeleton, true); - UtilEnt.Vegetate(skeleton); + UtilEnt.vegetate(skeleton); UtilEnt.ghost(skeleton, true, false); skeleton.getEquipment().setItemInHand(ItemStackFactory.Instance.CreateStack(0)); diff --git a/Plugins/Mineplex.Hub/src/mineplex/hub/modules/SoccerManager.java b/Plugins/Mineplex.Hub/src/mineplex/hub/modules/SoccerManager.java index cdb17aa96..73ef20d70 100644 --- a/Plugins/Mineplex.Hub/src/mineplex/hub/modules/SoccerManager.java +++ b/Plugins/Mineplex.Hub/src/mineplex/hub/modules/SoccerManager.java @@ -159,7 +159,7 @@ public class SoccerManager extends MiniPlugin _ball = mid.getWorld().spawn(mid, Slime.class); _ball.setSize(2); - UtilEnt.Vegetate(_ball); + UtilEnt.vegetate(_ball); UtilEnt.ghost(_ball, true, false); _ballVel = new Vector(0,-0.1,0); diff --git a/Plugins/Mineplex.Hub/src/mineplex/hub/modules/mavericks/basketball/BasketballGame.java b/Plugins/Mineplex.Hub/src/mineplex/hub/modules/mavericks/basketball/BasketballGame.java index 0b5660ee7..122cd21be 100644 --- a/Plugins/Mineplex.Hub/src/mineplex/hub/modules/mavericks/basketball/BasketballGame.java +++ b/Plugins/Mineplex.Hub/src/mineplex/hub/modules/mavericks/basketball/BasketballGame.java @@ -97,7 +97,7 @@ public class BasketballGame implements Listener { _velocity = -7; Entity e = loc.getWorld().spawnEntity(loc, EntityType.SLIME); - UtilEnt.Vegetate(e, true); + UtilEnt.vegetate(e, true); UtilEnt.ghost(e, true, false); ((Slime)e).setSize(1); diff --git a/Plugins/Mineplex.Minecraft.Game.ClassCombat/src/mineplex/minecraft/game/classcombat/Skill/Assassin/Illusion.java b/Plugins/Mineplex.Minecraft.Game.ClassCombat/src/mineplex/minecraft/game/classcombat/Skill/Assassin/Illusion.java index 43b9624ec..8c6261db8 100644 --- a/Plugins/Mineplex.Minecraft.Game.ClassCombat/src/mineplex/minecraft/game/classcombat/Skill/Assassin/Illusion.java +++ b/Plugins/Mineplex.Minecraft.Game.ClassCombat/src/mineplex/minecraft/game/classcombat/Skill/Assassin/Illusion.java @@ -3,7 +3,6 @@ package mineplex.minecraft.game.classcombat.Skill.Assassin; import java.util.ArrayList; import java.util.HashMap; import java.util.HashSet; -import java.util.Set; import java.util.UUID; import org.bukkit.Material; @@ -17,7 +16,6 @@ import org.bukkit.event.EventPriority; import org.bukkit.event.block.Action; import org.bukkit.event.entity.EntityDeathEvent; import org.bukkit.inventory.ItemStack; -import org.bukkit.metadata.FixedMetadataValue; import mineplex.minecraft.game.classcombat.Class.IPvpClass.ClassType; import mineplex.core.updater.event.UpdateEvent; @@ -95,7 +93,7 @@ public class Illusion extends SkillActive Skeleton skel = player.getWorld().spawn(player.getLocation(), Skeleton.class); skel.teleport(player.getLocation()); - UtilEnt.Vegetate(skel); + UtilEnt.vegetate(skel); UtilEnt.silence(skel, true); skel.setMaxHealth(14); diff --git a/Plugins/Mineplex.Minecraft.Game.ClassCombat/src/mineplex/minecraft/game/classcombat/Skill/Ranger/RopedArrow.java b/Plugins/Mineplex.Minecraft.Game.ClassCombat/src/mineplex/minecraft/game/classcombat/Skill/Ranger/RopedArrow.java index 524aca959..8b6f4e2bc 100644 --- a/Plugins/Mineplex.Minecraft.Game.ClassCombat/src/mineplex/minecraft/game/classcombat/Skill/Ranger/RopedArrow.java +++ b/Plugins/Mineplex.Minecraft.Game.ClassCombat/src/mineplex/minecraft/game/classcombat/Skill/Ranger/RopedArrow.java @@ -91,7 +91,7 @@ public class RopedArrow extends SkillActive _arrows.add(event.getProjectile()); - UtilEnt.Leash(player, event.getProjectile(), false, false); + UtilEnt.leash(player, event.getProjectile(), false, false); } @EventHandler diff --git a/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/broodmother/SpiderCreature.java b/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/broodmother/SpiderCreature.java index a4b657260..c438f7351 100644 --- a/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/broodmother/SpiderCreature.java +++ b/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/broodmother/SpiderCreature.java @@ -5,7 +5,6 @@ import java.util.Collections; import java.util.Comparator; import java.util.HashMap; import java.util.Iterator; -import java.util.List; import java.util.Map.Entry; import org.bukkit.Bukkit; @@ -20,8 +19,6 @@ import org.bukkit.event.HandlerList; import org.bukkit.event.entity.EntityDamageEvent.DamageCause; import org.bukkit.util.Vector; -import com.google.common.collect.Lists; - import mineplex.core.common.util.UtilAlg; import mineplex.core.common.util.UtilBlock; import mineplex.core.common.util.UtilEnt; @@ -61,7 +58,7 @@ public class SpiderCreature extends EventCreature @Override protected void spawnCustom() { - UtilEnt.Vegetate(getEntity()); + UtilEnt.vegetate(getEntity()); } @Override diff --git a/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/broodmother/SpiderMinionCreature.java b/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/broodmother/SpiderMinionCreature.java index 15eb9a843..1fb301cd2 100644 --- a/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/broodmother/SpiderMinionCreature.java +++ b/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/broodmother/SpiderMinionCreature.java @@ -49,7 +49,7 @@ public class SpiderMinionCreature extends EventCreature @Override protected void spawnCustom() { - UtilEnt.Vegetate(getEntity(), true); + UtilEnt.vegetate(getEntity(), true); getEntity().setVelocity(new Vector(UtilMath.rr(0.5, true), 0.4, UtilMath.rr(0.4, true))); } diff --git a/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/ironwizard/GolemCreature.java b/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/ironwizard/GolemCreature.java index be4e87f8c..b2fefc3ba 100644 --- a/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/ironwizard/GolemCreature.java +++ b/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/ironwizard/GolemCreature.java @@ -40,7 +40,6 @@ import org.bukkit.entity.IronGolem; import org.bukkit.entity.Player; import org.bukkit.event.EventHandler; import org.bukkit.event.HandlerList; -import org.bukkit.event.entity.EntityDamageEvent.DamageCause; import org.bukkit.util.Vector; public class GolemCreature extends EventCreature @@ -124,7 +123,7 @@ public class GolemCreature extends EventCreature @Override protected void spawnCustom() { - UtilEnt.Vegetate(getEntity()); + UtilEnt.vegetate(getEntity()); // EntityInsentient creature = (EntityInsentient) ((CraftEntity) getEntity()).getHandle(); // creature.Vegetated = false; diff --git a/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/skeletonking/SkeletonCreature.java b/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/skeletonking/SkeletonCreature.java index 45cae347e..36e892a07 100644 --- a/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/skeletonking/SkeletonCreature.java +++ b/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/skeletonking/SkeletonCreature.java @@ -79,7 +79,7 @@ public class SkeletonCreature extends EventCreature @Override protected void spawnCustom() { - UtilEnt.Vegetate(getEntity()); + UtilEnt.vegetate(getEntity()); getEntity().setSkeletonType(SkeletonType.WITHER); getEntity().getEquipment().setItemInHand(new ItemStack(Material.RECORD_6)); //Meridian Scepter getEntity().getEquipment().setItemInHandDropChance(0.f); diff --git a/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/skeletonking/abilities/SkeletonArcherShield.java b/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/skeletonking/abilities/SkeletonArcherShield.java index c393c73e3..558cbcfb6 100644 --- a/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/skeletonking/abilities/SkeletonArcherShield.java +++ b/Plugins/Mineplex.Minecraft.Game.Core/src/mineplex/minecraft/game/core/boss/skeletonking/abilities/SkeletonArcherShield.java @@ -82,7 +82,7 @@ public class SkeletonArcherShield extends BossAbility protected void spawnCustom() { getEntity().addPotionEffect(new PotionEffect(PotionEffectType.INVISIBILITY, 10000, 0)); - UtilEnt.Vegetate(getEntity()); + UtilEnt.vegetate(getEntity()); UtilEnt.ghost(getEntity(), true, false); Vector dir = new Vector(UtilMath.rr(1, true), 0, UtilMath.rr(1, true)).normalize().multiply(_seperator); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/baconbrawl/kits/KitSheepPig.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/baconbrawl/kits/KitSheepPig.java index 725f5b910..2f9c89563 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/baconbrawl/kits/KitSheepPig.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/baconbrawl/kits/KitSheepPig.java @@ -73,7 +73,7 @@ public class KitSheepPig extends ProgressingKit sheep.setColor(DyeColor.PINK); } - UtilEnt.Vegetate(entity); + UtilEnt.vegetate(entity); SpawnCustom(entity); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/basketball/Basketball.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/basketball/Basketball.java index 4493f5f19..df5ecf96f 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/basketball/Basketball.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/basketball/Basketball.java @@ -137,7 +137,7 @@ public class Basketball extends TeamGame this.CreatureAllowOverride = true; _velocity = -7; Entity e = Manager.GetCreature().SpawnEntity(loc, EntityType.SLIME); - UtilEnt.Vegetate(e, true); + UtilEnt.vegetate(e, true); UtilEnt.ghost(e, true, false); ((Slime)e).setSize(1); this.CreatureAllowOverride = false; diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/IronWizardDisplay.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/IronWizardDisplay.java index 614728267..fb08f2abf 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/IronWizardDisplay.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/IronWizardDisplay.java @@ -8,8 +8,6 @@ import nautilus.game.arcade.game.games.bossbattles.BossBattles; import org.bukkit.Location; import org.bukkit.entity.EntityType; import org.bukkit.entity.IronGolem; -import org.bukkit.event.EventHandler; -import org.bukkit.event.player.PlayerInteractEntityEvent; public class IronWizardDisplay extends BossDisplay { @@ -27,7 +25,7 @@ public class IronWizardDisplay extends BossDisplay _golem = (IronGolem) getLocation().getWorld().spawnEntity(getLocation(), EntityType.IRON_GOLEM); _golem.teleport(getLocation()); - UtilEnt.Vegetate(_golem); + UtilEnt.vegetate(_golem); addEntity(_golem); } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/SlimeKingDisplay.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/SlimeKingDisplay.java index a2da07725..d5f46afc5 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/SlimeKingDisplay.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/SlimeKingDisplay.java @@ -7,10 +7,7 @@ import nautilus.game.arcade.game.games.bossbattles.BossBattles; import org.bukkit.Location; import org.bukkit.entity.EntityType; -import org.bukkit.entity.IronGolem; import org.bukkit.entity.Slime; -import org.bukkit.event.EventHandler; -import org.bukkit.event.player.PlayerInteractEntityEvent; public class SlimeKingDisplay extends BossDisplay { @@ -31,7 +28,7 @@ public class SlimeKingDisplay extends BossDisplay _slime.teleport(getLocation()); - UtilEnt.Vegetate(_slime); + UtilEnt.vegetate(_slime); addEntity(_slime); } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/SnakeDisplay.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/SnakeDisplay.java index 44a373b6f..e4ff3e152 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/SnakeDisplay.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/SnakeDisplay.java @@ -7,11 +7,7 @@ import nautilus.game.arcade.game.games.bossbattles.BossBattles; import org.bukkit.Location; import org.bukkit.entity.EntityType; -import org.bukkit.entity.IronGolem; import org.bukkit.entity.Sheep; -import org.bukkit.entity.Slime; -import org.bukkit.event.EventHandler; -import org.bukkit.event.player.PlayerInteractEntityEvent; public class SnakeDisplay extends BossDisplay { @@ -30,7 +26,7 @@ public class SnakeDisplay extends BossDisplay _sheep.teleport(getLocation()); - UtilEnt.Vegetate(_sheep); + UtilEnt.vegetate(_sheep); addEntity(_sheep); } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/SpiderDisplay.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/SpiderDisplay.java index 1afd06f6a..219083d9c 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/SpiderDisplay.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bossbattles/displays/SpiderDisplay.java @@ -29,7 +29,7 @@ public class SpiderDisplay extends BossDisplay Entity entity = getLocation().getWorld().spawnEntity(getLocation(), EntityType.SPIDER); - UtilEnt.Vegetate(entity); + UtilEnt.vegetate(entity); this.addEntity(entity); } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bouncyballs/Ball.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bouncyballs/Ball.java index c8ab8f459..d59015956 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bouncyballs/Ball.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/bouncyballs/Ball.java @@ -108,7 +108,7 @@ public class Ball _ball = _ballSpawn.getWorld().spawn(_ballSpawn, Slime.class); _ball.setSize(2); - UtilEnt.Vegetate(_ball); + UtilEnt.vegetate(_ball); UtilEnt.ghost(_ball, false, false); _host.CreatureAllowOverride = false; diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/build/BuildData.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/build/BuildData.java index fa4c8fe05..e3d2b9d40 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/build/BuildData.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/build/BuildData.java @@ -197,7 +197,7 @@ public class BuildData } Entities.add(entity); - UtilEnt.Vegetate(entity, true); + UtilEnt.vegetate(entity, true); UtilEnt.ghost(entity, true, false); return true; } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/Sleigh.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/Sleigh.java index 26ef62540..1e63440f4 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/Sleigh.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/Sleigh.java @@ -51,7 +51,7 @@ public class Sleigh Target = loc.clone(); CentralEntity = loc.getWorld().spawn(loc, Chicken.class); - UtilEnt.Vegetate(CentralEntity, true); + UtilEnt.vegetate(CentralEntity, true); UtilEnt.ghost(CentralEntity, true, false); Host.Manager.GetCondition().Factory().Invisible("Sleigh", (LivingEntity) CentralEntity, null, Double.MAX_VALUE, 3, false, false, true); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/SleighHorse.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/SleighHorse.java index 8bbe45336..cbd84ff1c 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/SleighHorse.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/SleighHorse.java @@ -187,7 +187,7 @@ public class SleighHorse horseId = UtilEnt.getNewEntityId(false); _previousDir = getAngles(_lastFacing.getYaw()); Ent = _lastFacing.getWorld().spawn(_lastFacing.subtract(0, 0.5, 0), Horse.class); - UtilEnt.Vegetate(Ent); + UtilEnt.vegetate(Ent); UtilEnt.ghost(Ent, true, false); Ent.setRemoveWhenFarAway(false); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/SleighPart.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/SleighPart.java index 877d36049..0181704a7 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/SleighPart.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/SleighPart.java @@ -36,7 +36,7 @@ public class SleighPart Ent.setAgeLock(true); Ent.setRemoveWhenFarAway(false); - UtilEnt.Vegetate(Ent, true); + UtilEnt.vegetate(Ent, true); UtilEnt.ghost(Ent, true, false); sleigh.Host.Manager.GetCondition().Factory().Invisible("Sleigh", Ent, null, Double.MAX_VALUE, 3, false, false, true); @@ -87,7 +87,7 @@ public class SleighPart return null; Skeleton skel = Ent.getWorld().spawn(Ent.getLocation().add(0, 1, 0), Skeleton.class); - UtilEnt.Vegetate(skel); + UtilEnt.vegetate(skel); UtilEnt.ghost(skel, true, false); ItemStack head = new ItemStack(Material.LEATHER_HELMET); @@ -169,7 +169,7 @@ public class SleighPart newTop.setAgeLock(true); newTop.setRemoveWhenFarAway(false); - UtilEnt.Vegetate(newTop, true); + UtilEnt.vegetate(newTop, true); UtilEnt.ghost(newTop, true, false); sleigh.Host.Manager.GetCondition().Factory().Invisible("Sleigh", newTop, null, Double.MAX_VALUE, 3, false, false, true); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/BossSnowmanPattern.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/BossSnowmanPattern.java index 0b0909fd9..b3a571140 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/BossSnowmanPattern.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/BossSnowmanPattern.java @@ -1,7 +1,6 @@ package nautilus.game.arcade.game.games.christmas.content; import java.util.ArrayList; -import java.util.HashMap; import java.util.Iterator; import mineplex.core.common.util.UtilAction; @@ -9,11 +8,10 @@ import mineplex.core.common.util.UtilEnt; import mineplex.core.common.util.UtilMath; import mineplex.core.common.util.UtilTime; import mineplex.core.recharge.Recharge; -import nautilus.game.arcade.game.games.christmas.Christmas; + import nautilus.game.arcade.game.games.christmas.parts.Part5; import net.minecraft.server.v1_8_R3.EntityCreature; -import org.bukkit.Effect; import org.bukkit.Location; import org.bukkit.craftbukkit.v1_8_R3.entity.CraftCreature; import org.bukkit.entity.Player; @@ -116,7 +114,7 @@ public class BossSnowmanPattern Location loc = _spawnA.get(i); Snowman ent = loc.getWorld().spawn(loc, Snowman.class); - UtilEnt.Vegetate(ent); + UtilEnt.vegetate(ent); UtilEnt.ghost(ent, true, false); _ents.add(new BossSnowman(ent, loc, _aDir)); } @@ -129,7 +127,7 @@ public class BossSnowmanPattern Location loc = _spawnB.get(i); Snowman ent = loc.getWorld().spawn(loc, Snowman.class); - UtilEnt.Vegetate(ent); + UtilEnt.vegetate(ent); UtilEnt.ghost(ent, true, false); _ents.add(new BossSnowman(ent, loc, _bDir)); } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/CaveGiant.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/CaveGiant.java index 65c5b40d1..98fd71794 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/CaveGiant.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/CaveGiant.java @@ -10,7 +10,6 @@ import nautilus.game.arcade.game.games.christmas.parts.Part4; import org.bukkit.Location; import org.bukkit.Sound; -import org.bukkit.entity.Entity; import org.bukkit.entity.Giant; import org.bukkit.entity.Player; import org.bukkit.event.entity.EntityDamageEvent.DamageCause; @@ -30,7 +29,7 @@ public class CaveGiant Host.Host.CreatureAllowOverride = true; _ent = loc.getWorld().spawn(loc, Giant.class); Host.Host.CreatureAllowOverride = false; - UtilEnt.Vegetate(_ent); + UtilEnt.vegetate(_ent); _ent.setMaxHealth(300); _ent.setHealth(300); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/PumpkinKing.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/PumpkinKing.java index 75aca805b..37404c6a5 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/PumpkinKing.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/PumpkinKing.java @@ -47,7 +47,7 @@ public class PumpkinKing Host.Host.CreatureAllowOverride = true; _ent = UtilVariant.spawnWitherSkeleton(loc); Host.Host.CreatureAllowOverride = false; - UtilEnt.Vegetate(_ent); + UtilEnt.vegetate(_ent); UtilEnt.ghost(_ent, true, false); _ent.getEquipment().setHelmet(new ItemStack(Material.PUMPKIN)); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanBoss.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanBoss.java index 82b334134..649c3cff4 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanBoss.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanBoss.java @@ -51,7 +51,7 @@ public class SnowmanBoss _heart = _spawn.getWorld().spawn(_spawn, IronGolem.class); _heart.setMaxHealth(1400); _heart.setHealth(1400); - UtilEnt.Vegetate(_heart); + UtilEnt.vegetate(_heart); Host.CreatureAllowOverride = false; diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanMaze.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanMaze.java index e65212177..3a6d3c6fd 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanMaze.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanMaze.java @@ -262,7 +262,7 @@ public class SnowmanMaze Snowman ent = loc.getWorld().spawn(loc, Snowman.class); Host.CreatureAllowOverride = false; - UtilEnt.Vegetate(ent); + UtilEnt.vegetate(ent); UtilEnt.ghost(ent, true, false); _ents.put(ent, new SnowmanWaypoint(ent.getLocation())); } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanMinion.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanMinion.java index 19bc79523..0bc2f4d6c 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanMinion.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanMinion.java @@ -20,7 +20,7 @@ public class SnowmanMinion public SnowmanMinion(Snowman ent) { Ent = ent; - UtilEnt.Vegetate(Ent); + UtilEnt.vegetate(Ent); Ent.setMaxHealth(100); Ent.setHealth(Ent.getMaxHealth()); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanWaveA.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanWaveA.java index db9a10f0d..71f5f0a68 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanWaveA.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanWaveA.java @@ -96,7 +96,7 @@ public class SnowmanWaveA Host.CreatureAllowOverride = true; Snowman ent = loc.getWorld().spawn(loc, Snowman.class); Host.CreatureAllowOverride = false; - UtilEnt.Vegetate(ent); + UtilEnt.vegetate(ent); UtilEnt.ghost(ent, true, false); _ents.add(ent); } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanWaveB.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanWaveB.java index 0e2568a54..9a73bdde7 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanWaveB.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/christmas/content/SnowmanWaveB.java @@ -6,7 +6,6 @@ import java.util.Iterator; import mineplex.core.common.util.UtilAction; import mineplex.core.common.util.UtilEnt; import mineplex.core.common.util.UtilMath; -import mineplex.core.common.util.UtilTime; import mineplex.core.recharge.Recharge; import nautilus.game.arcade.game.games.christmas.Christmas; import net.minecraft.server.v1_8_R3.EntityCreature; @@ -93,7 +92,7 @@ public class SnowmanWaveB Host.CreatureAllowOverride = true; Snowman ent = loc.getWorld().spawn(loc, Snowman.class); Host.CreatureAllowOverride = false; - UtilEnt.Vegetate(ent); + UtilEnt.vegetate(ent); UtilEnt.ghost(ent, true, false); _ents.add(ent); } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/dragonriders/DragonData.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/dragonriders/DragonData.java index 50df5fe35..0a6a50d84 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/dragonriders/DragonData.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/dragonriders/DragonData.java @@ -41,7 +41,7 @@ public class DragonData //Spawn Dragon manager.GetGame().CreatureAllowOverride = true; Dragon = rider.getWorld().spawn(rider.getLocation(), EnderDragon.class); - UtilEnt.Vegetate(Dragon); + UtilEnt.vegetate(Dragon); manager.GetGame().CreatureAllowOverride = false; rider.getWorld().playSound(rider.getLocation(), Sound.ENDERDRAGON_GROWL, 20f, 1f); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/dragons/Dragons.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/dragons/Dragons.java index 2ec7e7daa..734b84444 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/dragons/Dragons.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/dragons/Dragons.java @@ -155,7 +155,7 @@ public class Dragons extends SoloGame { CreatureAllowOverride = true; EnderDragon ent = GetSpectatorLocation().getWorld().spawn(_dragonSpawns.get(0), EnderDragon.class); - UtilEnt.Vegetate(ent); + UtilEnt.vegetate(ent); CreatureAllowOverride = false; ent.getWorld().playSound(ent.getLocation(), Sound.ENDERDRAGON_GROWL, 20f, 1f); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/dragons/DragonsTeams.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/dragons/DragonsTeams.java index b088fe019..4ad55f0ee 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/dragons/DragonsTeams.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/dragons/DragonsTeams.java @@ -156,7 +156,7 @@ public class DragonsTeams extends TeamGame { CreatureAllowOverride = true; EnderDragon ent = GetSpectatorLocation().getWorld().spawn(_dragonSpawns.get(0), EnderDragon.class); - UtilEnt.Vegetate(ent); + UtilEnt.vegetate(ent); CreatureAllowOverride = false; ent.getWorld().playSound(ent.getLocation(), Sound.ENDERDRAGON_GROWL, 20f, 1f); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/gladiators/Gladiators.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/gladiators/Gladiators.java index 59dd19d6c..d3e1bfc18 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/gladiators/Gladiators.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/gladiators/Gladiators.java @@ -172,7 +172,7 @@ public class Gladiators extends SoloGame DisguisePlayer player = new DisguisePlayer(zombie, (zombie.equals(zombie1) ? tiger : random)); Manager.GetDisguise().disguise(player); - UtilEnt.Vegetate(zombie); + UtilEnt.vegetate(zombie); zombie.getEquipment().setHelmet(ArenaType.ORANGE.getLoadout().getHelmet()); zombie.getEquipment().setChestplate(ArenaType.ORANGE.getLoadout().getChestplate()); zombie.getEquipment().setLeggings(ArenaType.ORANGE.getLoadout().getLeggings()); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/gravity/Gravity.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/gravity/Gravity.java index d7c3b2c49..643d644e9 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/gravity/Gravity.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/gravity/Gravity.java @@ -29,7 +29,6 @@ import org.bukkit.event.entity.EntityDamageEvent.DamageCause; import org.bukkit.event.entity.EntityShootBowEvent; import org.bukkit.event.player.PlayerDropItemEvent; import org.bukkit.event.player.PlayerInteractEvent; -import org.bukkit.event.player.PlayerJoinEvent; import org.bukkit.util.Vector; import mineplex.core.common.util.C; @@ -44,7 +43,6 @@ import mineplex.core.common.util.UtilPlayer; import mineplex.core.common.util.UtilServer; import mineplex.core.common.util.UtilTextMiddle; import mineplex.core.common.util.UtilTime; -import mineplex.core.common.util.UtilWorld; import mineplex.core.common.util.UtilParticle.ParticleType; import mineplex.core.common.util.UtilParticle.ViewDist; import mineplex.core.recharge.Recharge; @@ -333,12 +331,12 @@ public class Gravity extends SoloGame this.CreatureAllowOverride = false; slime.setSize(1); - UtilEnt.Vegetate(slime, true); + UtilEnt.vegetate(slime, true); UtilEnt.ghost(slime, true, false); GravityHook hook = new GravityHook(this, slime, 4, velocity); - UtilEnt.Leash(hook.Base, player, false, false); + UtilEnt.leash(hook.Base, player, false, false); _hooks.put(player, hook); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/gravity/GravityObject.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/gravity/GravityObject.java index 34c83e330..7b68f58d1 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/gravity/GravityObject.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/gravity/GravityObject.java @@ -9,7 +9,6 @@ import mineplex.core.common.util.UtilParticle.ViewDist; import mineplex.core.disguise.disguises.DisguiseBat; import nautilus.game.arcade.game.games.gravity.objects.*; -import org.bukkit.Effect; import org.bukkit.Sound; import org.bukkit.entity.Entity; import org.bukkit.entity.Player; @@ -58,7 +57,7 @@ public abstract class GravityObject Bat.setSitting(true); Host.Manager.GetDisguise().disguise(Bat); - UtilEnt.Vegetate(Base, true); + UtilEnt.vegetate(Base, true); //UtilEnt.ghost(Base, true, true); Host.Manager.GetCondition().Factory().Invisible(null, Base, null, 9999, 1, false, false, false); } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween/creatures/PumpkinKing.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween/creatures/PumpkinKing.java index cff83a8df..b2d3b7431 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween/creatures/PumpkinKing.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween/creatures/PumpkinKing.java @@ -27,7 +27,6 @@ import nautilus.game.arcade.game.games.halloween.Halloween; import nautilus.game.arcade.game.games.halloween.HalloweenAudio; import net.minecraft.server.v1_8_R3.EntityArrow; import net.minecraft.server.v1_8_R3.EntityCreature; -import net.minecraft.server.v1_8_R3.Navigation; import net.minecraft.server.v1_8_R3.NavigationAbstract; import org.bukkit.Effect; @@ -391,7 +390,7 @@ public class PumpkinKing extends CreatureBase _minions.add(skel); - UtilEnt.Vegetate(skel); + UtilEnt.vegetate(skel); } _minionSpawn = false; @@ -646,7 +645,7 @@ public class PumpkinKing extends CreatureBase Blaze ent = GetEntity().getWorld().spawn(GetEntity().getLocation().add(0, 6, 0), Blaze.class); ent.getEquipment().setHelmet(new ItemStack(Material.PUMPKIN)); _shields.add(ent); - UtilEnt.Vegetate(ent); + UtilEnt.vegetate(ent); //ent.setSize(1); Host.CreatureAllowOverride = false; diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/Halloween2016.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/Halloween2016.java index 2240ee244..12c810ee7 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/Halloween2016.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/Halloween2016.java @@ -245,7 +245,7 @@ public class Halloween2016 extends Halloween CreatureAllowOverride = true; ArmorStand bat = doorSchematicLocation.getWorld().spawn(doorSchematicLocation, ArmorStand.class); CreatureAllowOverride = false; - UtilEnt.Vegetate(bat, true); + UtilEnt.vegetate(bat, true); UtilEnt.setAI(bat, false); UtilEnt.setTickWhenFarAway(bat, true); bat.setRemoveWhenFarAway(false); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/creatures/MobGiant.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/creatures/MobGiant.java index 6f6a41af4..05e9dc7af 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/creatures/MobGiant.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/creatures/MobGiant.java @@ -57,7 +57,7 @@ public class MobGiant extends CryptBreaker ent.setHealth(ent.getMaxHealth()); UtilEnt.setBoundingBox(_pathDummy, 0, 0); - UtilEnt.Vegetate(_pathDummy, true); + UtilEnt.vegetate(_pathDummy, true); UtilEnt.setStepHeight(_pathDummy, 1); //Prevent other mobs from pushing the giant diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/creatures/MobPumpkinPrince.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/creatures/MobPumpkinPrince.java index a09970660..0675e2841 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/creatures/MobPumpkinPrince.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/creatures/MobPumpkinPrince.java @@ -110,7 +110,7 @@ public class MobPumpkinPrince extends CreatureBase implements Listener ((CraftZombie)_horse).getHandle().b(true); _horse.setPassenger(ent); - UtilEnt.Vegetate(_horse); + UtilEnt.vegetate(_horse); UtilServer.RegisterEvents(this); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/creatures/MobWitch.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/creatures/MobWitch.java index 3342f1f96..64f3ea607 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/creatures/MobWitch.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/creatures/MobWitch.java @@ -132,7 +132,7 @@ public class MobWitch extends CreatureBase for(int i = 0; i < BATS_BURST; i++) { Bat bat = GetEntity().getWorld().spawn(GetEntity().getEyeLocation(), Bat.class); - UtilEnt.Vegetate(bat); + UtilEnt.vegetate(bat); _bats.add(bat); addEntityPart(bat); } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/wave/WaveBoss.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/wave/WaveBoss.java index c390473bc..43315155c 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/wave/WaveBoss.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/halloween2016/wave/WaveBoss.java @@ -228,7 +228,7 @@ public class WaveBoss extends WaveBase implements Listener _pumpkinKing.setCustomName(C.cYellow + C.Bold + "Pumpking King"); _pumpkinKing.setCustomNameVisible(true); - UtilEnt.Vegetate(_pumpkinKing); + UtilEnt.vegetate(_pumpkinKing); _pumpkinKing.getWorld().strikeLightningEffect(_pumpkinKing.getLocation()); } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/minecraftleague/data/Spawner.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/minecraftleague/data/Spawner.java index f55764201..6c244fadb 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/minecraftleague/data/Spawner.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/minecraftleague/data/Spawner.java @@ -80,7 +80,7 @@ public class Spawner if (canSpawnMob(l)) { Entity e = Host.getArcadeManager().GetCreature().SpawnEntity(l, _toSpawn); - UtilEnt.Vegetate(e); + UtilEnt.vegetate(e); spawned = true; _lastSpawned = System.currentTimeMillis(); continue; diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/minecraftleague/variation/wither/data/PathfinderData.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/minecraftleague/variation/wither/data/PathfinderData.java index 97d6ec69a..377712a58 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/minecraftleague/variation/wither/data/PathfinderData.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/minecraftleague/variation/wither/data/PathfinderData.java @@ -24,7 +24,7 @@ public class PathfinderData { Wither = wither; UtilEnt.ghost(wither, true, false); - UtilEnt.Vegetate(wither, false); + UtilEnt.vegetate(wither, false); Location temp = wither.getLocation(); temp.setPitch(UtilAlg.GetPitch(UtilAlg.getTrajectory(wither.getLocation(), target))); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/minecraftleague/variation/wither/data/WitherMinionManager.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/minecraftleague/variation/wither/data/WitherMinionManager.java index acbdded52..396a991aa 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/minecraftleague/variation/wither/data/WitherMinionManager.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/minecraftleague/variation/wither/data/WitherMinionManager.java @@ -125,7 +125,7 @@ public class WitherMinionManager implements Listener Skeleton e = UtilVariant.spawnWitherSkeleton(chosen); _entity = (Skeleton)e; UtilEnt.ghost(e, true, false); - UtilEnt.Vegetate(e); + UtilEnt.vegetate(e); e.setCustomName(C.cRed + "Wither Skeleton"); ((Skeleton)e).setMaxHealth(/*100*/65); ((Skeleton)e).setHealth(/*100*/65); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/mineware/challenge/other/ZombieWrapper.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/mineware/challenge/other/ZombieWrapper.java index 5e7e30c7f..ab5053d71 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/mineware/challenge/other/ZombieWrapper.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/mineware/challenge/other/ZombieWrapper.java @@ -35,7 +35,7 @@ public class ZombieWrapper _wrapper = (Zombie) world.spawnEntity(center.clone().add(0.5, 1, 0.5), EntityType.ZOMBIE); - UtilEnt.Vegetate(_wrapper); + UtilEnt.vegetate(_wrapper); UtilEnt.ghost(_wrapper, true, false); _wrapper.setCustomName(C.cRedB + "Infected Zombie"); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/mineware/challenge/type/ChallengeRedLightGreenLight.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/mineware/challenge/type/ChallengeRedLightGreenLight.java index df3f3e458..8df1e66cd 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/mineware/challenge/type/ChallengeRedLightGreenLight.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/mineware/challenge/type/ChallengeRedLightGreenLight.java @@ -230,7 +230,7 @@ public class ChallengeRedLightGreenLight extends Challenge Location spawn = getCenter().add(VILLAGER_X, MAP_HEIGHT, 0); _villager = (Villager) getCenter().getWorld().spawnEntity(spawn, EntityType.VILLAGER); - UtilEnt.Vegetate(_villager); + UtilEnt.vegetate(_villager); UtilEnt.CreatureLook(_villager, Host.GetSpectatorLocation()); UtilEnt.ghost(_villager, true, false); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/mineware/challenge/type/ChallengeVolleyPig.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/mineware/challenge/type/ChallengeVolleyPig.java index 9c9f7c5d7..5b3e32ee5 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/mineware/challenge/type/ChallengeVolleyPig.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/mineware/challenge/type/ChallengeVolleyPig.java @@ -241,7 +241,7 @@ public class ChallengeVolleyPig extends TeamChallenge getCenter().add(PIG_CENTER_X, PIG_CENTER_Y, PIG_CENTER_Z).subtract(getArenaSize(), 0, 0), Pig.class); - UtilEnt.Vegetate(_pig); + UtilEnt.vegetate(_pig); Host.CreatureAllow = false; } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/monsterleague/Ball.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/monsterleague/Ball.java index 65af10219..49c6bee11 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/monsterleague/Ball.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/monsterleague/Ball.java @@ -1,7 +1,6 @@ package nautilus.game.arcade.game.games.monsterleague; import java.util.ArrayList; -import java.util.HashMap; import mineplex.core.common.util.UtilAction; import mineplex.core.common.util.UtilAlg; @@ -17,7 +16,6 @@ import mineplex.core.recharge.Recharge; import nautilus.game.arcade.game.GameTeam; import nautilus.game.arcade.game.games.monsterleague.kits.LeagueKit; -import org.bukkit.Bukkit; import org.bukkit.ChatColor; import org.bukkit.Color; import org.bukkit.EntityEffect; @@ -159,7 +157,7 @@ public class Ball _ball = _ballSpawn.getWorld().spawn(_ballSpawn, Slime.class); _ball.setSize(2); - UtilEnt.Vegetate(_ball); + UtilEnt.vegetate(_ball); UtilEnt.ghost(_ball, false, false); _host.CreatureAllowOverride = false; diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/monstermaze/Maze.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/monstermaze/Maze.java index 1eef92624..8c020184c 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/monstermaze/Maze.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/monstermaze/Maze.java @@ -530,7 +530,7 @@ public class Maze implements Listener _host.CreatureAllowOverride = false; - UtilEnt.Vegetate(ent, true); + UtilEnt.vegetate(ent, true); UtilEnt.ghost(ent, true, false); _ents.put(ent, new MazeMobWaypoint(ent.getLocation())); @@ -568,7 +568,7 @@ public class Maze implements Listener _host.CreatureAllowOverride = false; - UtilEnt.Vegetate(ent, true); + UtilEnt.vegetate(ent, true); UtilEnt.ghost(ent, true, false); _ents.put(ent, new MazeMobWaypoint(ent.getLocation())); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/paintball/PlayerCopyPaintball.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/paintball/PlayerCopyPaintball.java index a42d2592b..234e96287 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/paintball/PlayerCopyPaintball.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/paintball/PlayerCopyPaintball.java @@ -45,7 +45,7 @@ public class PlayerCopyPaintball UtilEnt.ghost(_ent, true, false); - UtilEnt.Vegetate(_ent); + UtilEnt.vegetate(_ent); _ent.setArms(true); _ent.setBasePlate(false); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/sheep/SheepData.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/sheep/SheepData.java index 05161e8d3..a109225e3 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/sheep/SheepData.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/sheep/SheepData.java @@ -57,7 +57,7 @@ public class SheepData StuckLocation = Sheep.getLocation(); StuckTime = System.currentTimeMillis(); - UtilEnt.Vegetate(Sheep); + UtilEnt.vegetate(Sheep); UtilEnt.ghost(Sheep, true, false); } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/chicken/PerkChickenRocket.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/chicken/PerkChickenRocket.java index 2c04bff35..a671bd243 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/chicken/PerkChickenRocket.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/chicken/PerkChickenRocket.java @@ -105,7 +105,7 @@ public class PerkChickenRocket extends SmashPerk ent.getLocation().setYaw(player.getLocation().getYaw()); ent.setBaby(); ent.setAgeLock(true); - UtilEnt.Vegetate(ent); + UtilEnt.vegetate(ent); Manager.GetGame().CreatureAllowOverride = false; _data.add(new ChickenMissileData(player, ent)); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/enderman/SmashEnderman.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/enderman/SmashEnderman.java index 254343602..ec4d33f6b 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/enderman/SmashEnderman.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/enderman/SmashEnderman.java @@ -54,7 +54,7 @@ public class SmashEnderman extends SmashUltimate Manager.GetGame().CreatureAllowOverride = true; EnderDragon dragon = player.getWorld().spawn(player.getLocation().add(0, 5, 0), EnderDragon.class); - UtilEnt.Vegetate(dragon); + UtilEnt.vegetate(dragon); Manager.GetGame().CreatureAllowOverride = false; dragon.setCustomName(C.cYellow + player.getName() + "'s Dragon"); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/pig/PerkPigBaconBomb.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/pig/PerkPigBaconBomb.java index 9e863f0a0..c14f70a82 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/pig/PerkPigBaconBomb.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/pig/PerkPigBaconBomb.java @@ -125,7 +125,7 @@ public class PerkPigBaconBomb extends SmashPerk Manager.GetGame().CreatureAllowOverride = false; pig.setBaby(); - UtilEnt.Vegetate(pig); + UtilEnt.vegetate(pig); UtilEnt.ghost(pig, true, false); UUID key = player.getUniqueId(); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/snowman/SmashSnowman.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/snowman/SmashSnowman.java index 83823308a..d63314583 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/snowman/SmashSnowman.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/snowman/SmashSnowman.java @@ -69,7 +69,7 @@ public class SmashSnowman extends SmashUltimate Snowman ent = player.getWorld().spawn(player.getEyeLocation(), Snowman.class); game.CreatureAllowOverride = false; - UtilEnt.Vegetate(ent); + UtilEnt.vegetate(ent); UtilEnt.ghost(ent, true, false); ent.setMaxHealth(TURRET_HEALTH); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/wolf/PerkWolf.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/wolf/PerkWolf.java index 74501dd68..4482fa932 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/wolf/PerkWolf.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/perks/wolf/PerkWolf.java @@ -113,7 +113,7 @@ public class PerkWolf extends SmashPerk wolf.setAngry(true); - UtilEnt.Vegetate(wolf); + UtilEnt.vegetate(wolf); wolf.setMaxHealth(WOLF_HEALTH); wolf.setHealth(wolf.getMaxHealth()); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/snake/Snake.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/snake/Snake.java index 0c4b96110..d09fc466a 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/snake/Snake.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/snake/Snake.java @@ -12,7 +12,6 @@ import org.bukkit.EntityEffect; import org.bukkit.Location; import org.bukkit.Material; import org.bukkit.Sound; -import org.bukkit.craftbukkit.v1_8_R3.entity.CraftCreature; import org.bukkit.entity.Creature; import org.bukkit.entity.Entity; import org.bukkit.entity.Player; @@ -23,13 +22,9 @@ import org.bukkit.event.HandlerList; import org.bukkit.event.entity.EntityCombustEvent; import org.bukkit.event.entity.EntityDamageEvent.DamageCause; import org.bukkit.event.entity.EntityTargetEvent; -import org.bukkit.event.player.PlayerEvent; import org.bukkit.event.player.PlayerInteractEvent; import org.bukkit.util.Vector; -import net.minecraft.server.v1_8_R3.EntityCreature; -import net.minecraft.server.v1_8_R3.Navigation; -import net.minecraft.server.v1_8_R3.PacketPlayInUseEntity; import mineplex.core.common.util.C; import mineplex.core.common.util.UtilAlg; import mineplex.core.common.util.UtilBlock; @@ -53,7 +48,6 @@ import nautilus.game.arcade.GameType; import nautilus.game.arcade.events.GamePrepareCountdownCommence; import nautilus.game.arcade.events.GameStateChangeEvent; import nautilus.game.arcade.game.SoloGame; -import nautilus.game.arcade.game.Game.GameState; import nautilus.game.arcade.game.games.snake.events.SlimeUpgradeEvent; import nautilus.game.arcade.game.games.snake.events.TailGrowEvent; import nautilus.game.arcade.game.games.snake.kits.KitInvulnerable; @@ -137,7 +131,7 @@ public class Snake extends SoloGame sheep.setColor(DyeColor.getByDyeData((byte) (i % 16))); sheep.setPassenger(player); - UtilEnt.Vegetate(sheep); + UtilEnt.vegetate(sheep); _tail.put(player, new ArrayList()); _tail.get(player).add(sheep); @@ -384,7 +378,7 @@ public class Snake extends SoloGame Slime pig = loc.getWorld().spawn(loc, Slime.class); this.CreatureAllowOverride = false; pig.setSize(2); - UtilEnt.Vegetate(pig); + UtilEnt.vegetate(pig); _food.add(pig); } @@ -454,7 +448,7 @@ public class Snake extends SoloGame //Sets yaw/pitch tail.teleport(loc); - UtilEnt.Vegetate(tail); + UtilEnt.vegetate(tail); UtilEnt.ghost(tail, true, false); _tail.get(player).add(tail); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/sneakyassassins/npc/NpcManager.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/sneakyassassins/npc/NpcManager.java index f491bfa88..7d711fdc7 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/sneakyassassins/npc/NpcManager.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/sneakyassassins/npc/NpcManager.java @@ -52,7 +52,7 @@ public class NpcManager implements Listener LivingEntity npc = (LivingEntity) spawn.getWorld().spawn(spawn, getDisguiseType().getEntityClass()); npc.setCanPickupItems(false); npc.setRemoveWhenFarAway(false); - UtilEnt.Vegetate(npc); + UtilEnt.vegetate(npc); getGame().CreatureAllowOverride = false; return npc; diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/sneakyassassins/powerups/PowerUpItem.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/sneakyassassins/powerups/PowerUpItem.java index 70cce7b1c..f640c0681 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/sneakyassassins/powerups/PowerUpItem.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/sneakyassassins/powerups/PowerUpItem.java @@ -9,11 +9,9 @@ import mineplex.core.updater.event.*; import org.bukkit.*; import org.bukkit.block.*; import org.bukkit.entity.*; -import org.bukkit.entity.Skeleton.SkeletonType; import org.bukkit.inventory.*; import org.bukkit.potion.PotionEffect; import org.bukkit.potion.PotionEffectType; -import org.bukkit.util.*; /** * Created by Tim on 8/5/2014. @@ -106,7 +104,7 @@ public class PowerUpItem _powerUpManager.getGame().CreatureAllowOverride = true; _npc = itemLocation.getWorld().spawn(itemLocation, Skeleton.class); _powerUpManager.getGame().CreatureAllowOverride = false; - UtilEnt.Vegetate(_npc); + UtilEnt.vegetate(_npc); UtilEnt.ghost(_npc, true, false); _npc.getEquipment().setChestplate(new ItemStack(Material.DIAMOND_CHESTPLATE)); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/speedbuilders/SpeedBuilders.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/speedbuilders/SpeedBuilders.java index c03f7f326..6cf791021 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/speedbuilders/SpeedBuilders.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/speedbuilders/SpeedBuilders.java @@ -340,7 +340,7 @@ public class SpeedBuilders extends SoloGame Entity entity = loc.getWorld().spawnEntity(loc, mobData.EntityType); - UtilEnt.Vegetate(entity, true); + UtilEnt.vegetate(entity, true); UtilEnt.ghost(entity, true, false); _middleMobs.add(entity); @@ -1609,7 +1609,7 @@ public class SpeedBuilders extends SoloGame Entity entity = block.getWorld().spawnEntity(block.getLocation().add(0.5, 0, 0.5), type); - UtilEnt.Vegetate(entity, true); + UtilEnt.vegetate(entity, true); UtilEnt.ghost(entity, true, false); CreatureAllowOverride = false; diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/speedbuilders/data/RecreationData.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/speedbuilders/data/RecreationData.java index 2bf2488c0..d832ccd21 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/speedbuilders/data/RecreationData.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/speedbuilders/data/RecreationData.java @@ -191,7 +191,7 @@ public class RecreationData Entity entity = loc.getWorld().spawnEntity(loc, mobData.EntityType); - UtilEnt.Vegetate(entity, true); + UtilEnt.vegetate(entity, true); UtilEnt.ghost(entity, true, false); Mobs.add(entity); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/typewars/Minion.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/typewars/Minion.java index 51df05364..88fa186fb 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/typewars/Minion.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/typewars/Minion.java @@ -314,7 +314,7 @@ public class Minion private void path() { - UtilEnt.Vegetate(_entity); + UtilEnt.vegetate(_entity); UtilEnt.silence(_entity, true); UtilEnt.ghost(_entity, true, false); } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/typewars/TypeWars.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/typewars/TypeWars.java index 723d2591e..47ad7eeea 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/typewars/TypeWars.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/typewars/TypeWars.java @@ -233,7 +233,7 @@ public class TypeWars extends TeamGame _giantLocs.put(giant, loc.clone()); this.CreatureAllowOverride = false; giant.setRemoveWhenFarAway(false); - UtilEnt.Vegetate(giant, true); + UtilEnt.vegetate(giant, true); UtilEnt.ghost(giant, true, false); ItemStack helmet = new ItemStack(Material.LEATHER_HELMET); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/valentines/Valentines.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/valentines/Valentines.java index 26b6728e2..aa06acba9 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/valentines/Valentines.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/valentines/Valentines.java @@ -18,7 +18,6 @@ import mineplex.core.common.util.UtilTextBottom; import mineplex.core.common.util.UtilTextMiddle; import mineplex.core.common.util.UtilTime; import mineplex.core.itemstack.ItemStackFactory; -import mineplex.core.noteblock.INoteVerifier; import mineplex.core.noteblock.NBSReader; import mineplex.core.noteblock.NotePlayer; import mineplex.core.noteblock.NoteSong; @@ -167,7 +166,7 @@ public class Valentines extends SoloGame _cow.setCustomName(C.cGreen + C.Bold + _cowName); _cow.setCustomNameVisible(true); - UtilEnt.Vegetate(_cow); + UtilEnt.vegetate(_cow); UtilEnt.ghost(_cow, true, false); CreatureAllowOverride = false; } @@ -410,7 +409,7 @@ public class Valentines extends SoloGame Pig pig = loc.getWorld().spawn(loc, Pig.class); _pigs.put(pig, pig.getLocation()); - UtilEnt.Vegetate(pig); + UtilEnt.vegetate(pig); //Give Item if (toSpawn > 1) diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/valentines/tutorial/TutorialValentines.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/valentines/tutorial/TutorialValentines.java index 386bc5fe1..6ec02a900 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/valentines/tutorial/TutorialValentines.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/valentines/tutorial/TutorialValentines.java @@ -20,7 +20,6 @@ import mineplex.core.common.util.UtilMath; import mineplex.core.common.util.UtilServer; import mineplex.core.common.util.UtilTextMiddle; import nautilus.game.arcade.ArcadeManager; -import nautilus.game.arcade.game.games.valentines.ValItem; import nautilus.game.arcade.game.games.valentines.Valentines; import nautilus.game.arcade.gametutorial.GameTutorial; import nautilus.game.arcade.gametutorial.TutorialPhase; @@ -110,7 +109,7 @@ public class TutorialValentines extends GameTutorial //Spawn Pig pig = _pigSpawn.getWorld().spawn(_pigSpawn, Pig.class); - UtilEnt.Vegetate(pig); + UtilEnt.vegetate(pig); //Item @@ -183,12 +182,12 @@ public class TutorialValentines extends GameTutorial _cowBoy = _pigSpawn.getWorld().spawn(Host.WorldData.GetDataLocs("BROWN").get(0), Cow.class); _cowBoy.setCustomName(C.cGreenB + "Calvin"); _cowBoy.setCustomNameVisible(true); - UtilEnt.Vegetate(_cowBoy); + UtilEnt.vegetate(_cowBoy); _cowGirl = _pigSpawn.getWorld().spawn(Host.WorldData.GetDataLocs("RED").get(0), MushroomCow.class); _cowGirl.setCustomName(C.cRedB + "Moolanie"); _cowGirl.setCustomNameVisible(true); - UtilEnt.Vegetate(_cowGirl); + UtilEnt.vegetate(_cowGirl); Host.CreatureAllowOverride = false; diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/wither/PlayerCopyWither.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/wither/PlayerCopyWither.java index d1348569e..41da8752e 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/wither/PlayerCopyWither.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/wither/PlayerCopyWither.java @@ -28,7 +28,7 @@ public class PlayerCopyWither UtilEnt.ghost(_ent, true, false); - UtilEnt.Vegetate(_ent); + UtilEnt.vegetate(_ent); //Armor _ent.getEquipment().setArmorContents(owner.getInventory().getArmorContents()); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/modules/combatlog/CombatLogNPC.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/modules/combatlog/CombatLogNPC.java index 57f844ef2..974de2053 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/modules/combatlog/CombatLogNPC.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/modules/combatlog/CombatLogNPC.java @@ -1,7 +1,6 @@ package nautilus.game.arcade.game.modules.combatlog; import net.minecraft.server.v1_8_R3.EntityCreeper; -import net.minecraft.server.v1_8_R3.EntitySkeleton; import mineplex.core.common.util.UtilEnt; import mineplex.core.common.util.UtilTime; @@ -15,14 +14,11 @@ import nautilus.game.arcade.ArcadeManager; import org.bukkit.Location; import org.bukkit.craftbukkit.v1_8_R3.CraftWorld; import org.bukkit.craftbukkit.v1_8_R3.entity.CraftPlayer; -import org.bukkit.entity.ArmorStand; -import org.bukkit.entity.Creeper; import org.bukkit.entity.Entity; import org.bukkit.entity.LivingEntity; import org.bukkit.entity.Player; import org.bukkit.event.entity.EntityDamageByEntityEvent; import org.bukkit.event.entity.EntityDamageEvent; -import org.bukkit.inventory.ItemStack; import org.bukkit.metadata.FixedMetadataValue; public class CombatLogNPC @@ -147,7 +143,7 @@ public class CombatLogNPC skel.setFallDistance(player.getFallDistance()); // fixme potion effects, mobs don't target, entity collision (setting to ghost disables arrows and fishing rods), logging while sleeping // best solution to spawn EntityPlayer? - UtilEnt.Vegetate(skel); + UtilEnt.vegetate(skel); UtilEnt.silence(skel, true); skel.getEquipment().setHelmet(player.getInventory().getHelmet()); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/kit/Kit.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/kit/Kit.java index 8f9f95b5a..bc6d41347 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/kit/Kit.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/kit/Kit.java @@ -166,7 +166,7 @@ public abstract class Kit implements Listener skel.setSkeletonType(SkeletonType.WITHER); } - UtilEnt.Vegetate(entity, true); + UtilEnt.vegetate(entity, true); UtilEnt.ghost(entity, true, false); UtilEnt.setFakeHead(entity, true); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/kit/perks/PerkHorsePet.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/kit/perks/PerkHorsePet.java index 051a3e8d1..9f762f2c7 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/kit/perks/PerkHorsePet.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/kit/perks/PerkHorsePet.java @@ -103,7 +103,7 @@ public class PerkHorsePet extends Perk horse.setMaxHealth(40); horse.setHealth(40); - UtilEnt.Vegetate(horse); + UtilEnt.vegetate(horse); _horseMap.put(player, horse); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/lobby/current/NewGameLobbyManager.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/lobby/current/NewGameLobbyManager.java index 432ec1298..a0a07de20 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/lobby/current/NewGameLobbyManager.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/lobby/current/NewGameLobbyManager.java @@ -398,7 +398,7 @@ public class NewGameLobbyManager extends LobbyManager ent.setColor(DyeColor.getByWoolData(team.GetColorData())); - UtilEnt.Vegetate(ent, true); + UtilEnt.vegetate(ent, true); UtilEnt.setFakeHead(ent, true); UtilEnt.ghost(ent, true, false); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/lobby/legacy/LegacyGameLobbyManager.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/lobby/legacy/LegacyGameLobbyManager.java index 3ecc7b3a1..2d988d0d5 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/lobby/legacy/LegacyGameLobbyManager.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/lobby/legacy/LegacyGameLobbyManager.java @@ -81,7 +81,7 @@ public class LegacyGameLobbyManager extends LobbyManager ent.setColor(DyeColor.getByWoolData(teams.get(i).GetColorData())); - UtilEnt.Vegetate(ent, true); + UtilEnt.vegetate(ent, true); UtilEnt.setFakeHead(ent, true); UtilEnt.ghost(ent, true, false); diff --git a/Plugins/mavericks-review-hub/src/mineplex/mavericks/review/MavericksReviewManager.java b/Plugins/mavericks-review-hub/src/mineplex/mavericks/review/MavericksReviewManager.java index 1b417821d..7dfe4810f 100644 --- a/Plugins/mavericks-review-hub/src/mineplex/mavericks/review/MavericksReviewManager.java +++ b/Plugins/mavericks-review-hub/src/mineplex/mavericks/review/MavericksReviewManager.java @@ -625,7 +625,7 @@ public class MavericksReviewManager extends MiniPlugin } else { - UtilEnt.Vegetate(e, true); + UtilEnt.vegetate(e, true); UtilEnt.ghost(e, true, false); } }