Add Lucky Bridges, CookieFight and OP MB
This commit is contained in:
parent
dc57f7b4e6
commit
b34d652617
@ -10,6 +10,7 @@ import nautilus.game.arcade.game.games.barbarians.Barbarians;
|
|||||||
import nautilus.game.arcade.game.games.bossbattles.BossBattles;
|
import nautilus.game.arcade.game.games.bossbattles.BossBattles;
|
||||||
import nautilus.game.arcade.game.games.bouncyballs.BouncyBalls;
|
import nautilus.game.arcade.game.games.bouncyballs.BouncyBalls;
|
||||||
import nautilus.game.arcade.game.games.bridge.Bridge;
|
import nautilus.game.arcade.game.games.bridge.Bridge;
|
||||||
|
import nautilus.game.arcade.game.games.bridge.modes.LuckyBridges;
|
||||||
import nautilus.game.arcade.game.games.bridge.modes.OverpoweredBridge;
|
import nautilus.game.arcade.game.games.bridge.modes.OverpoweredBridge;
|
||||||
import nautilus.game.arcade.game.games.bridge.modes.SpeedBridges ;
|
import nautilus.game.arcade.game.games.bridge.modes.SpeedBridges ;
|
||||||
import nautilus.game.arcade.game.games.build.Build;
|
import nautilus.game.arcade.game.games.build.Build;
|
||||||
@ -41,6 +42,8 @@ import nautilus.game.arcade.game.games.holeinwall.HoleInTheWall;
|
|||||||
import nautilus.game.arcade.game.games.horsecharge.Horse;
|
import nautilus.game.arcade.game.games.horsecharge.Horse;
|
||||||
import nautilus.game.arcade.game.games.lobbers.BombLobbers;
|
import nautilus.game.arcade.game.games.lobbers.BombLobbers;
|
||||||
import nautilus.game.arcade.game.games.micro.Micro;
|
import nautilus.game.arcade.game.games.micro.Micro;
|
||||||
|
import nautilus.game.arcade.game.games.micro.modes.CookieFight;
|
||||||
|
import nautilus.game.arcade.game.games.micro.modes.OverpoweredMicroBattles;
|
||||||
import nautilus.game.arcade.game.games.micro.modes.TinyWinners;
|
import nautilus.game.arcade.game.games.micro.modes.TinyWinners;
|
||||||
import nautilus.game.arcade.game.games.milkcow.MilkCow;
|
import nautilus.game.arcade.game.games.milkcow.MilkCow;
|
||||||
import nautilus.game.arcade.game.games.minecraftleague.MinecraftLeague;
|
import nautilus.game.arcade.game.games.minecraftleague.MinecraftLeague;
|
||||||
@ -195,19 +198,19 @@ public enum GameType
|
|||||||
GameType.WitherAssault, GameType.Wizards, GameType.ZombieSurvival}, true),
|
GameType.WitherAssault, GameType.Wizards, GameType.ZombieSurvival}, true),
|
||||||
|
|
||||||
Brawl(null, new GameMode[]{
|
Brawl(null, new GameMode[]{
|
||||||
new GameMode(OverpoweredBridge.class, GameType.Bridge, "OP Bridges"), new GameMode(SpeedBridges.class, GameType.Bridge, "Speed Bridges"),
|
new GameMode(OverpoweredBridge.class, GameType.Bridge, "OP Bridges"), new GameMode(SpeedBridges.class, GameType.Bridge, "Speed Bridges"), new GameMode(LuckyBridges.class, GameType.Bridge, "Lucky Bridges"),
|
||||||
new GameMode(OverpoweredGladiators.class, GameType.Gladiators, "OP Gladiators"), new GameMode(ChampionsGladiators.class, GameType.Gladiators, "Champions Gladiators"),
|
new GameMode(OverpoweredGladiators.class, GameType.Gladiators, "OP Gladiators"), new GameMode(ChampionsGladiators.class, GameType.Gladiators, "Champions Gladiators"),
|
||||||
new GameMode(OverpoweredSkywars.class, GameType.Skywars, "OP Skywars"), new GameMode(UHCSkywars.class, GameType.Skywars, "UHC Skywars"),
|
new GameMode(OverpoweredSkywars.class, GameType.Skywars, "OP Skywars"), new GameMode(UHCSkywars.class, GameType.Skywars, "UHC Skywars"),
|
||||||
new GameMode(TeamBuild.class, GameType.Build, "Team Master Builders"), new GameMode(DukesOfDecoration.class, GameType.Build, "Dukes Of Decoration"),
|
new GameMode(TeamBuild.class, GameType.Build, "Team Master Builders"), new GameMode(DukesOfDecoration.class, GameType.Build, "Dukes Of Decoration"),
|
||||||
new GameMode(CutClean.class, GameType.UHC, "Cut Clean"), new GameMode(GodBattles.class, GameType.UHC, "God Battles"),
|
new GameMode(CutClean.class, GameType.UHC, "Cut Clean"), new GameMode(GodBattles.class, GameType.UHC, "God Battles"),
|
||||||
new GameMode(BloodDiamonds.class, GameType.UHC, "Blood Diamonds"), new GameMode(Assassins.class, GameType.UHC, "Assassins"),
|
new GameMode(BloodDiamonds.class, GameType.UHC, "Blood Diamonds"), new GameMode(Assassins.class, GameType.UHC, "Assassins"),
|
||||||
new GameMode(OverpoweredSurvival.class, GameType.SurvivalGames, "OP Survival Games"), new GameMode(UHCSurvivalgames.class, GameType.SurvivalGames, "UHC Survivalgames"),
|
new GameMode(OverpoweredSurvival.class, GameType.SurvivalGames, "OP Survival Games"), new GameMode(UHCSurvivalgames.class, GameType.SurvivalGames, "UHC Survivalgames"),
|
||||||
|
new GameMode(TinyWinners.class, GameType.Micro, "Tiny Winners"), new GameMode(OverpoweredMicroBattles.class, GameType.Micro, "OP Micro Battles"), new GameMode(CookieFight.class, GameType.Micro, "Cookie Fight"),
|
||||||
new GameMode(UltraSpleef.class, GameType.Spleef, "Ultra Spleef"),
|
new GameMode(UltraSpleef.class, GameType.Spleef, "Ultra Spleef"),
|
||||||
new GameMode(RandomKitSSM.class, GameType.Smash, "Random Kit SSM"),
|
new GameMode(RandomKitSSM.class, GameType.Smash, "Random Kit SSM"),
|
||||||
new GameMode(EweHeroes.class, GameType.Sheep, "Heroes Of The Ewe"),
|
new GameMode(EweHeroes.class, GameType.Sheep, "Heroes Of The Ewe"),
|
||||||
new GameMode(FasterThanLight.class, GameType.Runner, "Faster Than Light"),
|
new GameMode(FasterThanLight.class, GameType.Runner, "Faster Than Light"),
|
||||||
new GameMode(BunnyHop.class, GameType.Quiver, "Bunny Hop"),
|
new GameMode(BunnyHop.class, GameType.Quiver, "Bunny Hop"),
|
||||||
new GameMode(TinyWinners.class, GameType.Micro, "Tiny Winners"),
|
|
||||||
new GameMode(Countdown.class, GameType.HideSeek, "Countdown"),
|
new GameMode(Countdown.class, GameType.HideSeek, "Countdown"),
|
||||||
}, GameDisplay.Brawl, null, false, null, false, true);
|
}, GameDisplay.Brawl, null, false, null, false, true);
|
||||||
|
|
||||||
|
@ -0,0 +1,82 @@
|
|||||||
|
package nautilus.game.arcade.game.games.bridge.modes;
|
||||||
|
|
||||||
|
import java.util.Arrays;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.bukkit.Bukkit;
|
||||||
|
import org.bukkit.Material;
|
||||||
|
import org.bukkit.event.EventHandler;
|
||||||
|
import org.bukkit.event.block.BlockBreakEvent;
|
||||||
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
|
import mineplex.core.common.util.UtilMath;
|
||||||
|
import nautilus.game.arcade.ArcadeManager;
|
||||||
|
import nautilus.game.arcade.GameType;
|
||||||
|
import nautilus.game.arcade.game.games.AbsorptionFix;
|
||||||
|
import nautilus.game.arcade.game.games.bridge.Bridge;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* LuckyBridges gamemode for Bridges
|
||||||
|
*
|
||||||
|
* @author xXVevzZXx
|
||||||
|
*/
|
||||||
|
public class LuckyBridges extends Bridge
|
||||||
|
{
|
||||||
|
|
||||||
|
private HashMap<Material, List<Material>> _drops;
|
||||||
|
|
||||||
|
public LuckyBridges(ArcadeManager manager)
|
||||||
|
{
|
||||||
|
super(manager, GameType.Brawl);
|
||||||
|
|
||||||
|
_drops = new HashMap<>();
|
||||||
|
|
||||||
|
_drops.put(Material.DIAMOND_ORE, Arrays.asList(
|
||||||
|
Material.DIAMOND_HELMET, Material.DIAMOND_CHESTPLATE, Material.DIAMOND_LEGGINGS, Material.DIAMOND_BOOTS,
|
||||||
|
Material.DIAMOND_PICKAXE, Material.DIAMOND_AXE, Material.DIAMOND_SWORD));
|
||||||
|
|
||||||
|
|
||||||
|
_drops.put(Material.IRON_ORE, Arrays.asList(
|
||||||
|
Material.IRON_HELMET, Material.IRON_CHESTPLATE, Material.IRON_LEGGINGS, Material.IRON_BOOTS,
|
||||||
|
Material.IRON_PICKAXE, Material.IRON_AXE, Material.IRON_SWORD));
|
||||||
|
|
||||||
|
|
||||||
|
_drops.put(Material.GOLD_ORE, Arrays.asList(
|
||||||
|
Material.GOLD_HELMET, Material.GOLD_CHESTPLATE, Material.GOLD_LEGGINGS, Material.GOLD_BOOTS,
|
||||||
|
Material.GOLD_PICKAXE, Material.GOLD_AXE, Material.GOLD_SWORD, Material.GOLDEN_APPLE));
|
||||||
|
|
||||||
|
new AbsorptionFix(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
@EventHandler
|
||||||
|
public void mine(BlockBreakEvent event)
|
||||||
|
{
|
||||||
|
for (Material mat : _drops.keySet())
|
||||||
|
{
|
||||||
|
if (event.getBlock().getType() == mat)
|
||||||
|
{
|
||||||
|
event.setCancelled(true);
|
||||||
|
event.getBlock().setType(Material.AIR);
|
||||||
|
|
||||||
|
Bukkit.getScheduler().runTaskLater(Manager.getPlugin(), new Runnable()
|
||||||
|
{
|
||||||
|
@Override
|
||||||
|
public void run()
|
||||||
|
{
|
||||||
|
event.getBlock().getWorld().dropItem(
|
||||||
|
event.getBlock().getLocation().add(0.5, 0.2, 0.5),
|
||||||
|
new ItemStack(_drops.get(mat).get(UtilMath.r(_drops.get(mat).size()))));
|
||||||
|
}
|
||||||
|
}, 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String GetMode()
|
||||||
|
{
|
||||||
|
return "Lucky Bridges";
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -50,12 +50,6 @@ public class OverpoweredBridge extends Bridge
|
|||||||
WorldBoundaryKill = true;
|
WorldBoundaryKill = true;
|
||||||
|
|
||||||
new AbsorptionFix(this);
|
new AbsorptionFix(this);
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void ParseData()
|
|
||||||
{
|
|
||||||
_starterChests = new HashMap<>();
|
|
||||||
_starterItems = new HashMap<>();
|
_starterItems = new HashMap<>();
|
||||||
|
|
||||||
_starterItems.put(Material.WOOD, 64);
|
_starterItems.put(Material.WOOD, 64);
|
||||||
@ -68,6 +62,12 @@ public class OverpoweredBridge extends Bridge
|
|||||||
_starterItems.put(Material.EXP_BOTTLE, 64);
|
_starterItems.put(Material.EXP_BOTTLE, 64);
|
||||||
_starterItems.put(Material.COOKED_BEEF, 64);
|
_starterItems.put(Material.COOKED_BEEF, 64);
|
||||||
_starterItems.put(Material.DIAMOND, 300);
|
_starterItems.put(Material.DIAMOND, 300);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void ParseData()
|
||||||
|
{
|
||||||
|
_starterChests = new HashMap<>();
|
||||||
|
|
||||||
ParseLavaBridge();
|
ParseLavaBridge();
|
||||||
ParseWoodBridge();
|
ParseWoodBridge();
|
||||||
|
@ -30,6 +30,19 @@ public class Micro extends TeamGame
|
|||||||
private ArrayList<Block> _blocks = new ArrayList<Block>();
|
private ArrayList<Block> _blocks = new ArrayList<Block>();
|
||||||
private ArrayList<Block> _glass = new ArrayList<Block>();
|
private ArrayList<Block> _glass = new ArrayList<Block>();
|
||||||
|
|
||||||
|
public Micro(ArcadeManager manager, GameType type)
|
||||||
|
{
|
||||||
|
this(manager,
|
||||||
|
|
||||||
|
new Kit[]
|
||||||
|
{
|
||||||
|
new KitArcher(manager),
|
||||||
|
new KitWorker(manager),
|
||||||
|
new KitFighter(manager)
|
||||||
|
},
|
||||||
|
GameType.Micro);
|
||||||
|
}
|
||||||
|
|
||||||
public Micro(ArcadeManager manager, Kit[] kits, GameType type)
|
public Micro(ArcadeManager manager, Kit[] kits, GameType type)
|
||||||
{
|
{
|
||||||
super(manager, type, kits,
|
super(manager, type, kits,
|
||||||
@ -54,15 +67,7 @@ public class Micro extends TeamGame
|
|||||||
|
|
||||||
public Micro(ArcadeManager manager)
|
public Micro(ArcadeManager manager)
|
||||||
{
|
{
|
||||||
this(manager,
|
this(manager, GameType.Micro);
|
||||||
|
|
||||||
new Kit[]
|
|
||||||
{
|
|
||||||
new KitArcher(manager),
|
|
||||||
new KitWorker(manager),
|
|
||||||
new KitFighter(manager)
|
|
||||||
},
|
|
||||||
GameType.Micro);
|
|
||||||
|
|
||||||
registerStatTrackers(
|
registerStatTrackers(
|
||||||
new KillsWithinGameStatTracker(this, 8, "Annihilation")
|
new KillsWithinGameStatTracker(this, 8, "Annihilation")
|
||||||
|
@ -0,0 +1,55 @@
|
|||||||
|
package nautilus.game.arcade.game.games.micro.modes;
|
||||||
|
|
||||||
|
import org.bukkit.Material;
|
||||||
|
import org.bukkit.enchantments.Enchantment;
|
||||||
|
import org.bukkit.entity.Player;
|
||||||
|
import org.bukkit.event.EventHandler;
|
||||||
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
|
import mineplex.core.common.util.F;
|
||||||
|
import mineplex.core.common.util.UtilPlayer;
|
||||||
|
import nautilus.game.arcade.ArcadeManager;
|
||||||
|
import nautilus.game.arcade.GameType;
|
||||||
|
import nautilus.game.arcade.events.GameStateChangeEvent;
|
||||||
|
import nautilus.game.arcade.game.games.micro.Micro;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* CookieFight
|
||||||
|
*
|
||||||
|
* @author xXVevzZXx
|
||||||
|
*/
|
||||||
|
public class CookieFight extends Micro
|
||||||
|
{
|
||||||
|
|
||||||
|
private int _enchantmentLevel;
|
||||||
|
|
||||||
|
public CookieFight(ArcadeManager manager)
|
||||||
|
{
|
||||||
|
super(manager, GameType.Brawl);
|
||||||
|
|
||||||
|
_enchantmentLevel = 250;
|
||||||
|
}
|
||||||
|
|
||||||
|
@EventHandler
|
||||||
|
public void cookie(GameStateChangeEvent event)
|
||||||
|
{
|
||||||
|
if (event.GetState() != GameState.Live)
|
||||||
|
return;
|
||||||
|
|
||||||
|
for (Player player : GetPlayers(true))
|
||||||
|
{
|
||||||
|
ItemStack item = new ItemStack(Material.COOKIE);
|
||||||
|
item.addUnsafeEnchantment(Enchantment.KNOCKBACK, _enchantmentLevel);
|
||||||
|
player.getInventory().addItem(item);
|
||||||
|
|
||||||
|
UtilPlayer.message(player, F.main("Game", "Oh look, you got a Cookie!"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String GetMode()
|
||||||
|
{
|
||||||
|
return "Cookie Fight";
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,35 @@
|
|||||||
|
package nautilus.game.arcade.game.games.micro.modes;
|
||||||
|
|
||||||
|
import nautilus.game.arcade.ArcadeManager;
|
||||||
|
import nautilus.game.arcade.GameType;
|
||||||
|
import nautilus.game.arcade.game.games.micro.Micro;
|
||||||
|
import nautilus.game.arcade.game.games.micro.modes.kits.KitOverlord;
|
||||||
|
import nautilus.game.arcade.kit.Kit;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* OPMicroBattles
|
||||||
|
*
|
||||||
|
* @author xXVevzZXx
|
||||||
|
*/
|
||||||
|
public class OverpoweredMicroBattles extends Micro
|
||||||
|
{
|
||||||
|
|
||||||
|
public OverpoweredMicroBattles(ArcadeManager manager)
|
||||||
|
{
|
||||||
|
super(manager,
|
||||||
|
new Kit[]
|
||||||
|
{
|
||||||
|
new KitOverlord(manager)
|
||||||
|
},
|
||||||
|
GameType.Brawl);
|
||||||
|
|
||||||
|
TeamArmor = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String GetMode()
|
||||||
|
{
|
||||||
|
return "OP Micro Battles";
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,49 @@
|
|||||||
|
package nautilus.game.arcade.game.games.micro.modes.kits;
|
||||||
|
|
||||||
|
import org.bukkit.Material;
|
||||||
|
import org.bukkit.entity.EntityType;
|
||||||
|
import org.bukkit.entity.Player;
|
||||||
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
|
import mineplex.core.itemstack.ItemStackFactory;
|
||||||
|
import nautilus.game.arcade.ArcadeManager;
|
||||||
|
import nautilus.game.arcade.kit.KitAvailability;
|
||||||
|
import nautilus.game.arcade.kit.Perk;
|
||||||
|
import nautilus.game.arcade.kit.ProgressingKit;
|
||||||
|
import nautilus.game.arcade.kit.perks.PerkFletcher;
|
||||||
|
|
||||||
|
public class KitOverlord extends ProgressingKit
|
||||||
|
{
|
||||||
|
private static final String[] DESCRIPTION = {
|
||||||
|
"You tell me I'am OP?!",
|
||||||
|
};
|
||||||
|
|
||||||
|
private static final Perk[] PERKS = {
|
||||||
|
new PerkFletcher(20, 3, true)
|
||||||
|
};
|
||||||
|
|
||||||
|
private static final ItemStack IN_HAND = new ItemStack(Material.GOLDEN_APPLE);
|
||||||
|
|
||||||
|
private static final ItemStack[] PLAYER_ITEMS = {
|
||||||
|
ItemStackFactory.Instance.CreateStack(Material.DIAMOND_SWORD),
|
||||||
|
ItemStackFactory.Instance.CreateStack(Material.DIAMOND_PICKAXE),
|
||||||
|
ItemStackFactory.Instance.CreateStack(Material.BOW),
|
||||||
|
ItemStackFactory.Instance.CreateStack(Material.GOLDEN_APPLE, 5)
|
||||||
|
};
|
||||||
|
|
||||||
|
public KitOverlord(ArcadeManager manager)
|
||||||
|
{
|
||||||
|
super(manager, "Overlord", "microoverlord", KitAvailability.Free, DESCRIPTION, PERKS, EntityType.ZOMBIE, IN_HAND);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void GiveItems(Player player)
|
||||||
|
{
|
||||||
|
player.getInventory().addItem(PLAYER_ITEMS);
|
||||||
|
|
||||||
|
player.getInventory().setHelmet(new ItemStack(Material.DIAMOND_HELMET));
|
||||||
|
player.getInventory().setChestplate(new ItemStack(Material.DIAMOND_CHESTPLATE));
|
||||||
|
player.getInventory().setLeggings(new ItemStack(Material.DIAMOND_LEGGINGS));
|
||||||
|
player.getInventory().setBoots(new ItemStack(Material.DIAMOND_BOOTS));
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user