diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/castlesiege/kits/KitHumanBrawler.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/castlesiege/kits/KitHumanBrawler.java index b39f56de8..2ebc6c976 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/castlesiege/kits/KitHumanBrawler.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/castlesiege/kits/KitHumanBrawler.java @@ -32,7 +32,7 @@ public class KitHumanBrawler extends KitHuman new Perk[] { new PerkSeismicSlamCS(), - new PerkCleave(0.75), + new PerkCleave(0.75, true), }, EntityType.ZOMBIE, new ItemStack(Material.IRON_AXE)); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/kits/KitGolem.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/kits/KitGolem.java index b125bf374..cbab11fa3 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/kits/KitGolem.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/smash/kits/KitGolem.java @@ -112,7 +112,7 @@ public class KitGolem extends SmashKit else disguise.setName(player.getName()); - //disguise.setCustomNameVisible(true); + disguise.setCustomNameVisible(true); Manager.GetDisguise().disguise(disguise); } } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/survivalgames/SurvivalGames.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/survivalgames/SurvivalGames.java index 8ef383f36..760dd343e 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/survivalgames/SurvivalGames.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/survivalgames/SurvivalGames.java @@ -182,7 +182,9 @@ public class SurvivalGames extends SoloGame new KitNecromancer(manager), - new KitHorseman(manager) + new KitSlasher(manager), + + new KitHorseman(manager), }, new String[] diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/survivalgames/kit/KitSlasher.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/survivalgames/kit/KitSlasher.java new file mode 100644 index 000000000..b2bfe056c --- /dev/null +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/survivalgames/kit/KitSlasher.java @@ -0,0 +1,41 @@ +package nautilus.game.arcade.game.games.survivalgames.kit; + +import org.bukkit.Material; +import org.bukkit.entity.EntityType; +import org.bukkit.entity.Player; +import org.bukkit.inventory.ItemStack; + +import nautilus.game.arcade.ArcadeManager; +import nautilus.game.arcade.kit.Kit; +import nautilus.game.arcade.kit.KitAvailability; +import nautilus.game.arcade.kit.Perk; +import nautilus.game.arcade.kit.perks.*; + +public class KitSlasher extends Kit +{ + public KitSlasher(ArcadeManager manager) + { + super(manager, "Slasher", KitAvailability.Gem, 10000, + + new String[] + { + "Skilled at taking out teams!" + }, + + new Perk[] + { + + new PerkCleave(0.75, false), + new PerkBladeVortex() + }, + EntityType.ZOMBIE, + new ItemStack(Material.DIAMOND_SWORD)); + + } + + @Override + public void GiveItems(Player player) + { + + } +} diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/kit/perks/PerkBladeVortex.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/kit/perks/PerkBladeVortex.java new file mode 100644 index 000000000..999abb4ad --- /dev/null +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/kit/perks/PerkBladeVortex.java @@ -0,0 +1,120 @@ +package nautilus.game.arcade.kit.perks; + +import java.util.HashMap; + +import org.bukkit.Bukkit; +import org.bukkit.Location; +import org.bukkit.Sound; +import org.bukkit.entity.LivingEntity; +import org.bukkit.entity.Player; +import org.bukkit.event.EventHandler; +import org.bukkit.event.block.Action; +import org.bukkit.event.entity.EntityDamageEvent.DamageCause; +import org.bukkit.event.player.PlayerInteractEvent; + +import mineplex.core.common.util.C; +import mineplex.core.common.util.F; +import mineplex.core.common.util.UtilAction; +import mineplex.core.common.util.UtilAlg; +import mineplex.core.common.util.UtilBlock; +import mineplex.core.common.util.UtilEnt; +import mineplex.core.common.util.UtilGear; +import mineplex.core.common.util.UtilParticle; +import mineplex.core.common.util.UtilPlayer; +import mineplex.core.common.util.UtilParticle.ParticleType; +import mineplex.core.recharge.Recharge; +import nautilus.game.arcade.kit.Perk; + +public class PerkBladeVortex extends Perk +{ + public PerkBladeVortex() + { + super("Blade Vortex", new String[] + { + C.cYellow + "Right-Click" + C.cGray + " with Sword/Axe to use " + C.cGreen + "Blade Vortex" + }); + } + + + @EventHandler + public void Shoot(PlayerInteractEvent event) + { + if (event.isCancelled()) + return; + + if (event.getAction() != Action.RIGHT_CLICK_AIR && event.getAction() != Action.RIGHT_CLICK_BLOCK) + return; + + if (UtilBlock.usable(event.getClickedBlock())) + return; + + if (!UtilGear.isWeapon(event.getPlayer().getItemInHand())) + return; + + final Player player = event.getPlayer(); + + if (!Kit.HasKit(player)) + return; + + if (!Recharge.Instance.use(player, GetName(), 30000, true, true)) + return; + + Recharge.Instance.setDisplayForce(player, GetName(), true); + + event.setCancelled(true); + + //Pull + Damage + HashMap targets = UtilEnt.getInRadius(player.getLocation(), 7); + for (LivingEntity cur : targets.keySet()) + { + if (cur.equals(player)) + continue; + + //Damage Event + Manager.GetDamage().NewDamageEvent(cur, player, null, + DamageCause.CUSTOM, 2 * targets.get(cur), false, true, false, + player.getName(), GetName()); + + //Velocity + UtilAction.velocity(cur, + UtilAlg.getTrajectory2d(cur.getLocation().toVector(), player.getLocation().toVector()), + 1.6 - 0.6*targets.get(cur), true, 0, 0.2, 1, true); + + //Inform + if (cur instanceof Player) + UtilPlayer.message((Player)cur, F.main("Game", F.name(player.getName()) +" hit you with " + F.skill(GetName()) + ".")); + } + + //Animation + for (double i=0 ; i