- Lava parkour fire ticks are no more

- Lava gem rewards on npcs reflect actual value (1000 and 4000)
- Can't carry people into parkour areas now

Removed unused code with Portal
Added portal functionality for server quick join
Disabled SG text
Updated quick game menu text.
This commit is contained in:
Jonathan Williams 2013-09-27 12:40:09 -07:00
parent 894a121a2e
commit b6d33010ca
14 changed files with 266 additions and 524 deletions

View File

@ -1,43 +1,17 @@
package mineplex.core.portal; package mineplex.core.portal;
import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.ByteArrayOutputStream; import java.io.ByteArrayOutputStream;
import java.io.DataOutputStream; import java.io.DataOutputStream;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileWriter;
import java.io.IOException; import java.io.IOException;
import java.io.InputStreamReader;
import java.util.AbstractMap;
import java.util.HashSet; import java.util.HashSet;
import java.util.Map.Entry;
import org.bukkit.Bukkit; import org.bukkit.Bukkit;
import org.bukkit.ChatColor;
import org.bukkit.Location;
import org.bukkit.Material;
import org.bukkit.entity.Player; import org.bukkit.entity.Player;
import org.bukkit.event.EventHandler;
import org.bukkit.event.block.Action;
import org.bukkit.event.player.PlayerInteractEvent;
import org.bukkit.event.player.PlayerMoveEvent;
import org.bukkit.plugin.java.JavaPlugin; import org.bukkit.plugin.java.JavaPlugin;
import org.bukkit.util.Vector;
import mineplex.core.MiniPlugin; import mineplex.core.MiniPlugin;
import mineplex.core.arena.Region;
import mineplex.core.common.Rank;
import mineplex.core.common.util.F;
import mineplex.core.common.util.NautHashMap;
import mineplex.core.common.util.UtilPlayer;
import mineplex.core.portal.commands.PortalCommand;
public class Portal extends MiniPlugin public class Portal extends MiniPlugin
{ {
private NautHashMap<Region, String> _portalServerMap = new NautHashMap<Region, String>();
private NautHashMap<String, Entry<Location, Location>> _portalSetupMap = new NautHashMap<String, Entry<Location, Location>>();
private HashSet<String> _connectingPlayers = new HashSet<String>(); private HashSet<String> _connectingPlayers = new HashSet<String>();
public Portal(JavaPlugin plugin) public Portal(JavaPlugin plugin)
@ -45,51 +19,6 @@ public class Portal extends MiniPlugin
super("Portal", plugin); super("Portal", plugin);
Bukkit.getMessenger().registerOutgoingPluginChannel(GetPlugin(), "BungeeCord"); Bukkit.getMessenger().registerOutgoingPluginChannel(GetPlugin(), "BungeeCord");
LoadPortals();
}
public void AddCommands()
{
AddCommand(new PortalCommand(this));
}
@EventHandler
public void OnPlayerMove(PlayerMoveEvent event)
{
for (Region region : _portalServerMap.keySet())
{
if (region.Contains(event.getTo().toVector()))
{
SendPlayerToServer(event.getPlayer(), _portalServerMap.get(region));
break;
}
}
}
@EventHandler
public void OnPlayerInteract(PlayerInteractEvent event)
{
Player player = event.getPlayer();
if (player.isOp() && _portalSetupMap.containsKey(player.getName()))
{
if (player.getItemInHand() != null && player.getItemInHand().getType() == Material.BLAZE_ROD)
{
if (event.getAction() == Action.LEFT_CLICK_BLOCK)
{
_portalSetupMap.put(player.getName(), new AbstractMap.SimpleEntry<Location, Location>(event.getClickedBlock().getLocation(), null));
player.sendMessage(F.main(GetName(), "Set first point."));
}
else if (event.getAction() == Action.RIGHT_CLICK_BLOCK)
{
_portalSetupMap.get(player.getName()).setValue(event.getClickedBlock().getLocation());
player.sendMessage(F.main(GetName(), "Set second point."));
}
event.setCancelled(true);
}
}
} }
public void SendAllPlayers(String serverName) public void SendAllPlayers(String serverName)
@ -140,179 +69,4 @@ public class Portal extends MiniPlugin
} }
}, 20L); }, 20L);
} }
public void Help(Player caller, String message)
{
UtilPlayer.message(caller, F.main(_moduleName, "Commands List:"));
UtilPlayer.message(caller, F.help("/portal toggle", "Turn off and on Portal mode.", Rank.ADMIN));
UtilPlayer.message(caller, F.help("/portal create <name>", "Creates portal to name server.", Rank.OWNER));
if (message != null)
UtilPlayer.message(caller, F.main(_moduleName, ChatColor.RED + message));
}
public void Help(Player caller)
{
Help(caller, null);
}
public void LoadPortals()
{
FileInputStream fstream = null;
BufferedReader br = null;
try
{
File portalsFile = new File("portals.dat");
if (portalsFile.exists())
{
fstream = new FileInputStream(portalsFile);
br = new BufferedReader(new InputStreamReader(fstream));
String line = br.readLine();
while (line != null)
{
Region region = ParseRegion(line);
_portalServerMap.put(region, region.GetName());
line = br.readLine();
}
}
}
catch (Exception e)
{
System.out.println(F.main(GetName(), "Error parsing portals file."));
}
finally
{
if (br != null)
{
try
{
br.close();
}
catch (IOException e)
{
e.printStackTrace();
}
}
if (fstream != null)
{
try
{
fstream.close();
}
catch (IOException e)
{
e.printStackTrace();
}
}
}
}
public void SavePortals()
{
FileWriter fstream = null;
BufferedWriter out = null;
try
{
fstream = new FileWriter("portals.dat");
out = new BufferedWriter(fstream);
for (Region region : _portalServerMap.keySet())
{
out.write(region.GetMinimumPoint().getBlockX() + " " + region.GetMinimumPoint().getBlockY() + " " + region.GetMinimumPoint().getBlockZ() + ", " + region.GetMaximumPoint().getBlockX() + " " + region.GetMaximumPoint().getBlockY() + " " + region.GetMaximumPoint().getBlockZ() + ", " + region.GetName());
out.newLine();
}
out.close();
}
catch (Exception e)
{
System.err.println("Portals Save Error: " + e.getMessage());
}
finally
{
if (out != null)
{
try
{
out.close();
}
catch (IOException e)
{
e.printStackTrace();
}
}
if (fstream != null)
{
try
{
fstream.close();
}
catch (IOException e)
{
e.printStackTrace();
}
}
}
}
private Region ParseRegion(String value)
{
String [] parts = value.split(",");
Vector pointOne = ParseVector(parts[0].trim());
Vector pointTwo = ParseVector(parts[1].trim());
return new Region(parts.length == 3 ? parts[2].trim() : "Null", pointOne, pointTwo);
}
private Vector ParseVector(String vectorString)
{
Vector vector = new Vector();
String [] parts = vectorString.split(" ");
vector.setX(Double.parseDouble(parts[0]));
vector.setY(Double.parseDouble(parts[1]));
vector.setZ(Double.parseDouble(parts[2]));
return vector;
}
public void ToggleSetupAdmin(Player caller)
{
if (_portalSetupMap.containsKey(caller.getName()))
{
_portalSetupMap.remove(caller.getName());
caller.sendMessage(F.main(GetName(), "Disabled Portal Setup."));
}
else
{
_portalSetupMap.put(caller.getName(), new AbstractMap.SimpleEntry<Location, Location>(null, null));
caller.sendMessage(F.main(GetName(), "Enabled Portal Setup."));
}
}
public boolean IsAdminPortalValid(Player caller)
{
return _portalSetupMap.containsKey(caller.getName()) && _portalSetupMap.get(caller.getName()).getKey() != null && _portalSetupMap.get(caller.getName()).getValue() != null;
}
public void CreatePortal(Player caller, String name)
{
Vector first = _portalSetupMap.get(caller.getName()).getKey().toVector();
Vector second = _portalSetupMap.get(caller.getName()).getValue().toVector();
_portalServerMap.put(new Region(name, first, second), name);
caller.sendMessage(F.main(GetName(), "Created '" + name + "' portal at (" + first.toString() + ") and (" + second.toString() + "."));
SavePortals();
}
} }

View File

@ -1,37 +0,0 @@
package mineplex.core.portal.commands;
import org.bukkit.entity.Player;
import mineplex.core.command.CommandBase;
import mineplex.core.common.Rank;
import mineplex.core.portal.Portal;
public class CreateCommand extends CommandBase<Portal>
{
public CreateCommand(Portal plugin)
{
super(plugin, Rank.ADMIN, "create");
}
@Override
public void Execute(final Player caller, String[] args)
{
if (args == null)
{
Plugin.Help(caller);
}
else
{
if (!Plugin.IsAdminPortalValid(caller))
{
Plugin.Help(caller, "You don't have two points set. Use Blaze rod to set them.");
}
else
{
String serverName = args[0];
Plugin.CreatePortal(caller, serverName);
}
}
}
}

View File

@ -1,24 +0,0 @@
package mineplex.core.portal.commands;
import org.bukkit.entity.Player;
import mineplex.core.command.MultiCommandBase;
import mineplex.core.common.Rank;
import mineplex.core.portal.Portal;
public class PortalCommand extends MultiCommandBase<Portal>
{
public PortalCommand(Portal plugin)
{
super(plugin, Rank.ADMIN, "portal");
AddCommand(new CreateCommand(plugin));
AddCommand(new ToggleCommand(plugin));
}
@Override
protected void Help(Player caller, String[] args)
{
Plugin.Help(caller);
}
}

View File

@ -1,21 +0,0 @@
package mineplex.core.portal.commands;
import org.bukkit.entity.Player;
import mineplex.core.command.CommandBase;
import mineplex.core.common.Rank;
import mineplex.core.portal.Portal;
public class ToggleCommand extends CommandBase<Portal>
{
public ToggleCommand(Portal plugin)
{
super(plugin, Rank.ADMIN, "toggle");
}
@Override
public void Execute(final Player caller, String[] args)
{
Plugin.ToggleSetupAdmin(caller);
}
}

View File

@ -9,8 +9,6 @@ import java.util.Enumeration;
import java.util.List; import java.util.List;
import org.bukkit.Bukkit; import org.bukkit.Bukkit;
import org.bukkit.configuration.file.FileConfiguration;
import org.bukkit.configuration.file.YamlConfiguration;
import org.bukkit.event.EventHandler; import org.bukkit.event.EventHandler;
import org.bukkit.event.server.ServerListPingEvent; import org.bukkit.event.server.ServerListPingEvent;
import org.bukkit.plugin.java.JavaPlugin; import org.bukkit.plugin.java.JavaPlugin;
@ -27,6 +25,7 @@ public class ServerStatusManager extends MiniPlugin
private LagMeter _lagMeter; private LagMeter _lagMeter;
private boolean _alternateSeconds; private boolean _alternateSeconds;
private boolean _enabled = true;
public ServerStatusManager(JavaPlugin plugin, LagMeter lagMeter) public ServerStatusManager(JavaPlugin plugin, LagMeter lagMeter)
{ {
@ -34,6 +33,9 @@ public class ServerStatusManager extends MiniPlugin
_lagMeter = lagMeter; _lagMeter = lagMeter;
if (new File("IgnoreUpdates.dat").exists())
_enabled = false;
ServerListPingEvent event = new ServerListPingEvent(null, plugin.getServer().getMotd(), plugin.getServer().getOnlinePlayers().length, plugin.getServer().getMaxPlayers()); ServerListPingEvent event = new ServerListPingEvent(null, plugin.getServer().getMotd(), plugin.getServer().getOnlinePlayers().length, plugin.getServer().getMaxPlayers());
GetPluginManager().callEvent(event); GetPluginManager().callEvent(event);
@ -88,6 +90,8 @@ public class ServerStatusManager extends MiniPlugin
plugin.getConfig().getString("serverstatus.group"), plugin.getConfig().getString("serverstatus.group"),
address + ":" + _plugin.getServer().getPort(), event.getMaxPlayers() address + ":" + _plugin.getServer().getPort(), event.getMaxPlayers()
); );
if (_enabled)
_repository.initialize(); _repository.initialize();
} }
catch (Exception ex) catch (Exception ex)
@ -143,6 +147,9 @@ public class ServerStatusManager extends MiniPlugin
if (event.getType() != UpdateType.SEC) if (event.getType() != UpdateType.SEC)
return; return;
if (!_enabled)
return;
_alternateSeconds = !_alternateSeconds; _alternateSeconds = !_alternateSeconds;
if (!_alternateSeconds) if (!_alternateSeconds)

View File

@ -26,6 +26,7 @@ import mineplex.core.task.TaskManager;
import mineplex.core.teleport.Teleport; import mineplex.core.teleport.Teleport;
import mineplex.core.updater.FileUpdater; import mineplex.core.updater.FileUpdater;
import mineplex.core.updater.Updater; import mineplex.core.updater.Updater;
import mineplex.hub.modules.StackerManager;
import mineplex.hub.party.PartyManager; import mineplex.hub.party.PartyManager;
import mineplex.hub.server.ServerManager; import mineplex.hub.server.ServerManager;
import mineplex.minecraft.game.classcombat.Class.ClassManager; import mineplex.minecraft.game.classcombat.Class.ClassManager;
@ -79,8 +80,8 @@ public class Hub extends JavaPlugin implements INautilusPlugin, IRelation
PacketHandler packetHandler = new PacketHandler(this); PacketHandler packetHandler = new PacketHandler(this);
Portal portal = new Portal(this); Portal portal = new Portal(this);
PartyManager partyManager = new PartyManager(this, clientManager); PartyManager partyManager = new PartyManager(this, clientManager);
new HubManager(this, clientManager, donationManager, new DisguiseManager(this, packetHandler), new TaskManager(this, GetWebServerAddress()), portal, partyManager); HubManager hubManager = new HubManager(this, clientManager, donationManager, new DisguiseManager(this, packetHandler), new TaskManager(this, GetWebServerAddress()), portal, partyManager);
new ServerManager(this, clientManager, donationManager, portal, partyManager, new ServerStatusManager(this, new LagMeter(this, clientManager))); new ServerManager(this, clientManager, donationManager, portal, partyManager, new ServerStatusManager(this, new LagMeter(this, clientManager)), hubManager, new StackerManager(hubManager));
new Chat(this, clientManager); new Chat(this, clientManager);
new MemoryFix(this); new MemoryFix(this);
new FileUpdater(this, portal); new FileUpdater(this, portal);

View File

@ -66,7 +66,6 @@ public class HubManager extends MiniClientPlugin<HubClient>
private PartyManager _partyManager; private PartyManager _partyManager;
private Portal _portal; private Portal _portal;
private TutorialManager _tutorialManager; private TutorialManager _tutorialManager;
private TextManager _textCreator; private TextManager _textCreator;
private ParkourManager _parkour; private ParkourManager _parkour;
@ -102,7 +101,6 @@ public class HubManager extends MiniClientPlugin<HubClient>
new MapManager(this); new MapManager(this);
new WorldManager(this); new WorldManager(this);
new JumpManager(this); new JumpManager(this);
new StackerManager(this);
_partyManager = partyManager; _partyManager = partyManager;
_tutorialManager = new TutorialManager(this, donationManager, taskManager, _textCreator); _tutorialManager = new TutorialManager(this, donationManager, taskManager, _textCreator);
@ -212,18 +210,10 @@ public class HubManager extends MiniClientPlugin<HubClient>
{ {
if (((LivingEntity)entity).isCustomNameVisible() && ((LivingEntity)entity).getCustomName() != null) if (((LivingEntity)entity).isCustomNameVisible() && ((LivingEntity)entity).getCustomName() != null)
{ {
if (((LivingEntity)entity).getCustomName().equalsIgnoreCase("play minekart plz")) if (ChatColor.stripColor(((LivingEntity)entity).getCustomName()).equalsIgnoreCase("Minekart"))
{ {
_disguiseManager.disguise(new DisguisePlayer(entity, ChatColor.YELLOW + "MineKart")); _disguiseManager.disguise(new DisguisePlayer(entity, ChatColor.YELLOW + "MineKart"));
} }
else if (((LivingEntity)entity).getCustomName().equalsIgnoreCase("defek7"))
_disguiseManager.disguise(new DisguisePlayer(entity, "defek7"));
else if (((LivingEntity)entity).getCustomName().equalsIgnoreCase("chiss"))
_disguiseManager.disguise(new DisguisePlayer(entity, "Chiss"));
else if (((LivingEntity)entity).getCustomName().equalsIgnoreCase("Sterling_"))
_disguiseManager.disguise(new DisguisePlayer(entity, "sterling_"));
else if (((LivingEntity)entity).getCustomName().equalsIgnoreCase("Spu_"))
_disguiseManager.disguise(new DisguisePlayer(entity, "Spu_"));
} }
} }
} }

View File

@ -12,6 +12,7 @@ import org.bukkit.entity.LivingEntity;
import org.bukkit.entity.Player; import org.bukkit.entity.Player;
import org.bukkit.event.EventHandler; import org.bukkit.event.EventHandler;
import org.bukkit.event.block.BlockBreakEvent; import org.bukkit.event.block.BlockBreakEvent;
import org.bukkit.event.entity.EntityCombustEvent;
import org.bukkit.event.entity.EntityDamageEvent; import org.bukkit.event.entity.EntityDamageEvent;
import org.bukkit.event.entity.EntityDamageEvent.DamageCause; import org.bukkit.event.entity.EntityDamageEvent.DamageCause;
import org.bukkit.event.player.PlayerInteractEntityEvent; import org.bukkit.event.player.PlayerInteractEntityEvent;
@ -99,6 +100,15 @@ public class ParkourManager extends MiniPlugin
} }
} }
@EventHandler
public void combustPrevent(EntityCombustEvent event)
{
if (event.getEntity() instanceof Player)
{
event.setCancelled(true);
}
}
@EventHandler @EventHandler
public void LavaReturn(EntityDamageEvent event) public void LavaReturn(EntityDamageEvent event)
{ {
@ -108,7 +118,6 @@ public class ParkourManager extends MiniPlugin
event.getEntity().eject(); event.getEntity().eject();
event.getEntity().leaveVehicle(); event.getEntity().leaveVehicle();
event.getEntity().teleport(_lavaParkourReturn); event.getEntity().teleport(_lavaParkourReturn);
event.getEntity().setFireTicks(0);
} }
else else
@ -117,6 +126,27 @@ public class ParkourManager extends MiniPlugin
event.setCancelled(true); event.setCancelled(true);
} }
@EventHandler
public void preventCarriers(UpdateEvent event)
{
if (event.getType() != UpdateType.SEC)
return;
for (Player player : UtilServer.getPlayers())
{
if (InParkour(player))
{
if (player.getVehicle() != null || player.getPassenger() != null)
{
player.eject();
player.leaveVehicle();
UtilPlayer.message(player, F.main("Parkour", "You can't run parkours while stacked!"));
}
}
}
}
@EventHandler @EventHandler
public void LavaBlockReturn(UpdateEvent event) public void LavaBlockReturn(UpdateEvent event)
{ {

View File

@ -246,6 +246,9 @@ public class StackerManager extends MiniPlugin implements IThrown
if (target == null) if (target == null)
return; return;
if (target.getCustomName() != null || (target.getPassenger() != null && target.getPassenger() instanceof LivingEntity && ((LivingEntity)target.getPassenger()).getCustomName() != null))
return;
//Velocity //Velocity
UtilAction.velocity(target, UtilAlg.getTrajectory2d(data.GetThrown(), target), 1, true, 0.8, 0, 10, true); UtilAction.velocity(target, UtilAlg.getTrajectory2d(data.GetThrown(), target), 1, true, 0.8, 0, 10, true);

View File

@ -51,7 +51,9 @@ public class TextManager extends MiniPlugin
"DEATH TAG", "DEATH TAG",
"TURF WARS", "TURF WARS",
"DRAGONS", "DRAGONS",
"RUNNER" "RUNNER",
"BACON BRAWL",
"SQUID SAUCE"
}; };
CreateText(); CreateText();
@ -82,10 +84,10 @@ public class TextManager extends MiniPlugin
UtilText.MakeText("THE BRIDGES", locSurvival.clone().add(-15, 14, 0), faceSurvival, 159, (byte)4, TextAlign.CENTER); UtilText.MakeText("THE BRIDGES", locSurvival.clone().add(-15, 14, 0), faceSurvival, 159, (byte)4, TextAlign.CENTER);
UtilText.MakeText("THE BRIDGES", locSurvival.clone().add(-16, 14, 0), faceSurvival, 159, (byte)15, TextAlign.CENTER); UtilText.MakeText("THE BRIDGES", locSurvival.clone().add(-16, 14, 0), faceSurvival, 159, (byte)15, TextAlign.CENTER);
/*
UtilText.MakeText("SURVIVAL GAMES", locSurvival.clone().add(-15, 21, 0), faceSurvival, 159, (byte)1, TextAlign.CENTER); UtilText.MakeText("SURVIVAL GAMES", locSurvival.clone().add(-15, 21, 0), faceSurvival, 159, (byte)1, TextAlign.CENTER);
UtilText.MakeText("SURVIVAL GAMES", locSurvival.clone().add(-16, 21, 0), faceSurvival, 159, (byte)15, TextAlign.CENTER); UtilText.MakeText("SURVIVAL GAMES", locSurvival.clone().add(-16, 21, 0), faceSurvival, 159, (byte)15, TextAlign.CENTER);
*/
//Other //Other
UtilText.MakeText("CLASSICS", locClassics, faceOther, 159, (byte)5, TextAlign.CENTER); UtilText.MakeText("CLASSICS", locClassics, faceOther, 159, (byte)5, TextAlign.CENTER);

View File

@ -1,13 +1,13 @@
package mineplex.hub.server; package mineplex.hub.server;
import java.io.BufferedReader; import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.File; import java.io.File;
import java.io.FileInputStream; import java.io.FileInputStream;
import java.io.FileWriter;
import java.io.IOException; import java.io.IOException;
import java.io.InputStreamReader; import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.Collection; import java.util.Collection;
import java.util.Collections;
import java.util.HashSet; import java.util.HashSet;
import java.util.List; import java.util.List;
import java.util.Set; import java.util.Set;
@ -17,9 +17,14 @@ import org.bukkit.Material;
import org.bukkit.entity.Player; import org.bukkit.entity.Player;
import org.bukkit.event.EventHandler; import org.bukkit.event.EventHandler;
import org.bukkit.event.EventPriority; import org.bukkit.event.EventPriority;
import org.bukkit.event.entity.EntityPortalEnterEvent;
import org.bukkit.event.entity.EntityPortalEvent;
import org.bukkit.event.player.PlayerInteractEvent; import org.bukkit.event.player.PlayerInteractEvent;
import org.bukkit.event.player.PlayerJoinEvent; import org.bukkit.event.player.PlayerJoinEvent;
import org.bukkit.event.player.PlayerMoveEvent;
import org.bukkit.event.player.PlayerPortalEvent;
import org.bukkit.plugin.java.JavaPlugin; import org.bukkit.plugin.java.JavaPlugin;
import org.bukkit.util.Vector;
import mineplex.core.MiniPlugin; import mineplex.core.MiniPlugin;
import mineplex.core.account.CoreClientManager; import mineplex.core.account.CoreClientManager;
@ -28,16 +33,21 @@ import mineplex.core.common.util.C;
import mineplex.core.common.util.Callback; import mineplex.core.common.util.Callback;
import mineplex.core.common.util.F; import mineplex.core.common.util.F;
import mineplex.core.common.util.NautHashMap; import mineplex.core.common.util.NautHashMap;
import mineplex.core.common.util.UtilAction;
import mineplex.core.common.util.UtilAlg;
import mineplex.core.common.util.UtilPlayer; import mineplex.core.common.util.UtilPlayer;
import mineplex.core.common.util.UtilTime; import mineplex.core.common.util.UtilTime;
import mineplex.core.common.util.UtilTime.TimeUnit; import mineplex.core.common.util.UtilTime.TimeUnit;
import mineplex.core.donation.DonationManager; import mineplex.core.donation.DonationManager;
import mineplex.core.itemstack.ItemStackFactory; import mineplex.core.itemstack.ItemStackFactory;
import mineplex.core.portal.Portal; import mineplex.core.portal.Portal;
import mineplex.core.recharge.Recharge;
import mineplex.core.status.ServerStatusData; import mineplex.core.status.ServerStatusData;
import mineplex.core.status.ServerStatusManager; import mineplex.core.status.ServerStatusManager;
import mineplex.core.updater.UpdateType; import mineplex.core.updater.UpdateType;
import mineplex.core.updater.event.UpdateEvent; import mineplex.core.updater.event.UpdateEvent;
import mineplex.hub.HubManager;
import mineplex.hub.modules.StackerManager;
import mineplex.hub.party.Party; import mineplex.hub.party.Party;
import mineplex.hub.party.PartyManager; import mineplex.hub.party.PartyManager;
import mineplex.hub.server.command.ServerNpcCommand; import mineplex.hub.server.command.ServerNpcCommand;
@ -51,19 +61,22 @@ public class ServerManager extends MiniPlugin
private Portal _portal; private Portal _portal;
private PartyManager _partyManager; private PartyManager _partyManager;
private ServerStatusManager _statusManager; private ServerStatusManager _statusManager;
private HubManager _hubManager;
private StackerManager _stackerManager;
private NautHashMap<String, HashSet<ServerInfo>> _serverNpcMap = new NautHashMap<String, HashSet<ServerInfo>>(); private NautHashMap<String, HashSet<ServerInfo>> _serverNpcMap = new NautHashMap<String, HashSet<ServerInfo>>();
private NautHashMap<String, String> _serverNpcTag = new NautHashMap<String, String>();
private NautHashMap<String, ServerNpcShop> _serverNpcShopMap = new NautHashMap<String, ServerNpcShop>(); private NautHashMap<String, ServerNpcShop> _serverNpcShopMap = new NautHashMap<String, ServerNpcShop>();
private NautHashMap<String, ServerInfo> _serverInfoMap = new NautHashMap<String, ServerInfo>(); private NautHashMap<String, ServerInfo> _serverInfoMap = new NautHashMap<String, ServerInfo>();
private NautHashMap<String, Long> _serverUpdate = new NautHashMap<String, Long>(); private NautHashMap<String, Long> _serverUpdate = new NautHashMap<String, Long>();
private NautHashMap<Vector, String> _serverPortalLocations = new NautHashMap<Vector, String>();
private ServerNpcShop _quickShop; private ServerNpcShop _quickShop;
private boolean _loading = false;
private boolean _alternateUpdateFire = false; private boolean _alternateUpdateFire = false;
private boolean _retrieving = false; private boolean _retrieving = false;
public ServerManager(JavaPlugin plugin, CoreClientManager clientManager, DonationManager donationManager, Portal portal, PartyManager partyManager, ServerStatusManager statusManager) public ServerManager(JavaPlugin plugin, CoreClientManager clientManager, DonationManager donationManager, Portal portal, PartyManager partyManager, ServerStatusManager statusManager, HubManager hubManager, StackerManager stackerManager)
{ {
super("Server Manager", plugin); super("Server Manager", plugin);
@ -72,6 +85,8 @@ public class ServerManager extends MiniPlugin
_portal = portal; _portal = portal;
_partyManager = partyManager; _partyManager = partyManager;
_statusManager = statusManager; _statusManager = statusManager;
_hubManager = hubManager;
_stackerManager = stackerManager;
plugin.getServer().getMessenger().registerOutgoingPluginChannel(plugin, "BungeeCord"); plugin.getServer().getMessenger().registerOutgoingPluginChannel(plugin, "BungeeCord");
@ -86,6 +101,78 @@ public class ServerManager extends MiniPlugin
AddCommand(new ServerNpcCommand(this)); AddCommand(new ServerNpcCommand(this));
} }
@EventHandler(priority = EventPriority.LOW)
public void playerPortalEvent(PlayerPortalEvent event)
{
event.setCancelled(true);
}
@EventHandler(priority = EventPriority.LOW)
public void entityPortalEvent(EntityPortalEvent event)
{
event.setCancelled(true);
}
@EventHandler(priority = EventPriority.LOW)
public void playerCheckPortalEvent(EntityPortalEnterEvent event)
{
if (!(event.getEntity() instanceof Player))
{
UtilAction.velocity(event.getEntity(), UtilAlg.getTrajectory(event.getEntity().getLocation(), _hubManager.GetSpawn()), 1, true, 0.8, 0, 1, true);
return;
}
Player player = (Player)event.getEntity();
if (!_stackerManager.CanPortal(player))
{
UtilAction.velocity(player, UtilAlg.getTrajectory(player.getLocation(), _hubManager.GetSpawn()), 1, true, 0.8, 0, 1, true);
return;
}
if (!Recharge.Instance.use(player, "Portal Server", 1000, false))
return;
String serverName = _serverPortalLocations.get(player.getLocation().getBlock().getLocation().toVector());
if (serverName != null)
{
List<ServerInfo> serverList = new ArrayList<ServerInfo>(GetServerList(serverName));
int slots = 1;
if (serverList.size() > 0)
{
slots = GetRequiredSlots(player, serverList.get(0).ServerType);
}
try
{
Collections.sort(serverList, new ServerSorter(slots));
for (ServerInfo serverInfo : serverList)
{
if ((serverInfo.MOTD.contains("Starting") || serverInfo.MOTD.contains("Recruiting") || serverInfo.MOTD.contains("Waiting") || serverInfo.MOTD.contains("Cup")) && (serverInfo.MaxPlayers - serverInfo.CurrentPlayers) >= slots)
{
SelectServer(player, serverInfo);
return;
}
}
}
catch (Exception exception)
{
exception.printStackTrace();
for (ServerInfo serverInfo : serverList)
{
System.out.println(F.main("ServerManager", ChatColor.YELLOW + serverInfo.Name + ": " + serverInfo.MOTD + " " + serverInfo.CurrentPlayers + "/" + serverInfo.MaxPlayers));
}
}
player.sendMessage(F.main("Server Portal", "There are currently no joinable servers!"));
}
}
@EventHandler(priority = EventPriority.LOW) @EventHandler(priority = EventPriority.LOW)
public void playerJoin(PlayerJoinEvent event) public void playerJoin(PlayerJoinEvent event)
{ {
@ -101,24 +188,6 @@ public class ServerManager extends MiniPlugin
} }
} }
public void AddServer(String serverNpcName, String serverName)
{
ServerInfo serverInfo = new ServerInfo();
serverInfo.Name = serverName;
if (_serverInfoMap.containsKey(serverName))
{
_serverInfoMap.remove(serverName);
_serverUpdate.remove(serverName);
}
_serverNpcMap.get(serverNpcName).add(serverInfo);
_serverInfoMap.put(serverName, serverInfo);
_serverUpdate.put(serverName, System.currentTimeMillis());
SaveServers();
}
public void RemoveServer(String serverName) public void RemoveServer(String serverName)
{ {
for (String key : _serverNpcMap.keySet()) for (String key : _serverNpcMap.keySet())
@ -220,9 +289,15 @@ public class ServerManager extends MiniPlugin
{ {
for (ServerStatusData serverStatus : serverStatusList) for (ServerStatusData serverStatus : serverStatusList)
{ {
if (_serverInfoMap.containsKey(serverStatus.Name)) if (!_serverInfoMap.containsKey(serverStatus.Name))
{ {
ServerInfo newServerInfo = new ServerInfo();
newServerInfo.Name = serverStatus.Name;
_serverInfoMap.put(serverStatus.Name, newServerInfo);
}
String[] args = serverStatus.Motd.split("\\|"); String[] args = serverStatus.Motd.split("\\|");
String tag = (serverStatus.Name != null && serverStatus.Name.contains("-")) ? serverStatus.Name.split("-")[0] : "N/A";
ServerInfo serverInfo = _serverInfoMap.get(serverStatus.Name); ServerInfo serverInfo = _serverInfoMap.get(serverStatus.Name);
serverInfo.MOTD = args.length > 0 ? args[0] : serverStatus.Motd; serverInfo.MOTD = args.length > 0 ? args[0] : serverStatus.Motd;
@ -239,6 +314,11 @@ public class ServerManager extends MiniPlugin
serverInfo.Map = args[3]; serverInfo.Map = args[3];
_serverUpdate.put(serverStatus.Name, System.currentTimeMillis()); _serverUpdate.put(serverStatus.Name, System.currentTimeMillis());
if (_serverNpcTag.containsKey(tag))
{
_serverNpcMap.get(_serverNpcTag.get(tag)).add(serverInfo);
}
} }
for (String name : _serverUpdate.keySet()) for (String name : _serverUpdate.keySet())
@ -253,7 +333,6 @@ public class ServerManager extends MiniPlugin
_serverUpdate.put(name, -1L); _serverUpdate.put(name, -1L);
} }
} }
}
// Reset // Reset
_retrieving = false; _retrieving = false;
@ -369,63 +448,6 @@ public class ServerManager extends MiniPlugin
} }
} }
public void SaveServers()
{
if (_loading)
return;
FileWriter fstream = null;
BufferedWriter out = null;
try
{
fstream = new FileWriter("ServerManager.dat");
out = new BufferedWriter(fstream);
for (String key : _serverNpcMap.keySet())
{
System.out.println("Saving serverinfos for " + key);
for (ServerInfo serverInfo : _serverNpcMap.get(key))
{
out.write(key + " | " + serverInfo.Name);
out.newLine();
}
}
out.close();
}
catch (Exception e)
{
System.err.println("ServerManager Save Error: " + e.getMessage());
}
finally
{
if (out != null)
{
try
{
out.close();
}
catch (IOException e)
{
e.printStackTrace();
}
}
if (fstream != null)
{
try
{
fstream.close();
}
catch (IOException e)
{
e.printStackTrace();
}
}
}
}
public void LoadServers() public void LoadServers()
{ {
_serverInfoMap.clear(); _serverInfoMap.clear();
@ -436,7 +458,7 @@ public class ServerManager extends MiniPlugin
_serverNpcMap.get(npcName).clear(); _serverNpcMap.get(npcName).clear();
} }
_loading = true; _serverNpcTag.clear();
FileInputStream fstream = null; FileInputStream fstream = null;
BufferedReader br = null; BufferedReader br = null;
@ -457,14 +479,20 @@ public class ServerManager extends MiniPlugin
while (line != null) while (line != null)
{ {
String serverNpcName = line.substring(0, line.indexOf('|')).trim(); String serverNpcName = line.substring(0, line.indexOf('|')).trim();
String server = line.substring(line.indexOf('|') + 1).trim(); String serverTag = line.substring(line.indexOf('|') + 1, line.indexOf('|', line.indexOf('|') + 1)).trim();
String[] locations = line.substring(line.indexOf('|', line.indexOf('|') + 1) + 1).trim().split(",");
for (String location : locations)
{
_serverPortalLocations.put(ParseVector(location), serverNpcName);
}
if (!HasServerNpc(serverNpcName)) if (!HasServerNpc(serverNpcName))
{ {
AddServerNpc(serverNpcName); AddServerNpc(serverNpcName);
} }
AddServer(serverNpcName, server); _serverNpcTag.put(serverTag, serverNpcName);
npcNames.add(serverNpcName); npcNames.add(serverNpcName);
line = br.readLine(); line = br.readLine();
@ -500,8 +528,6 @@ public class ServerManager extends MiniPlugin
e.printStackTrace(); e.printStackTrace();
} }
} }
_loading = false;
} }
for (String npcName : npcNames) for (String npcName : npcNames)
@ -549,7 +575,7 @@ public class ServerManager extends MiniPlugin
public ServerNpcShop getMixedArcadeShop() public ServerNpcShop getMixedArcadeShop()
{ {
return _serverNpcShopMap.get("Mixed Arcade Games"); return _serverNpcShopMap.get("Mixed Arcade");
} }
public ServerNpcShop getSuperSmashMobsShop() public ServerNpcShop getSuperSmashMobsShop()
@ -559,7 +585,7 @@ public class ServerManager extends MiniPlugin
public ServerNpcShop getDominateShop() public ServerNpcShop getDominateShop()
{ {
return _serverNpcShopMap.get("Dominate Beta"); return _serverNpcShopMap.get("Dominate");
} }
public ServerNpcShop getBridgesShop() public ServerNpcShop getBridgesShop()
@ -569,6 +595,19 @@ public class ServerManager extends MiniPlugin
public ServerNpcShop getMinekartShop() public ServerNpcShop getMinekartShop()
{ {
return _serverNpcShopMap.get("play minekart plz"); return _serverNpcShopMap.get("Minekart");
}
private Vector ParseVector(String vectorString)
{
Vector vector = new Vector();
String [] parts = vectorString.trim().split(" ");
vector.setX(Double.parseDouble(parts[0]));
vector.setY(Double.parseDouble(parts[1]));
vector.setZ(Double.parseDouble(parts[2]));
return vector;
} }
} }

View File

@ -1,55 +0,0 @@
package mineplex.hub.server.command;
import org.bukkit.ChatColor;
import org.bukkit.entity.Player;
import mineplex.core.command.CommandBase;
import mineplex.core.common.Rank;
import mineplex.core.common.util.F;
import mineplex.core.common.util.UtilPlayer;
import mineplex.hub.server.ServerManager;
public class AddServerCommand extends CommandBase<ServerManager>
{
public AddServerCommand(ServerManager plugin)
{
super(plugin, Rank.OWNER, "addserver");
}
@Override
public void Execute(Player caller, String[] args)
{
if (args.length < 2)
{
Plugin.Help(caller, "Invalid arguments");
return;
}
String argsCombined = args[0];
String serverNpcName = "";
String serverName = "";
for (int i = 1; i < args.length; i++)
{
argsCombined += " " + args[i];
}
if (!argsCombined.contains("|"))
{
Plugin.Help(caller, "Invalid arguments");
}
serverNpcName = argsCombined.substring(0, argsCombined.indexOf("|")).trim();
serverName = argsCombined.substring(argsCombined.indexOf("|") + 1).trim();
if (!Plugin.HasServerNpc(serverNpcName))
{
UtilPlayer.message(caller, F.main(Plugin.GetName(), ChatColor.RED + "That ServerNpc doesn't exist."));
}
else
{
Plugin.AddServer(serverNpcName, serverName);
UtilPlayer.message(caller, F.main(Plugin.GetName(), "Added '" + serverName + "' to '" + serverNpcName + "' server list."));
}
}
}

View File

@ -14,7 +14,6 @@ public class ServerNpcCommand extends MultiCommandBase<ServerManager>
AddCommand(new CreateCommand(plugin)); AddCommand(new CreateCommand(plugin));
AddCommand(new DeleteCommand(plugin)); AddCommand(new DeleteCommand(plugin));
AddCommand(new AddServerCommand(plugin));
AddCommand(new RemoveServerCommand(plugin)); AddCommand(new RemoveServerCommand(plugin));
AddCommand(new ListNpcsCommand(plugin)); AddCommand(new ListNpcsCommand(plugin));
AddCommand(new ListServersCommand(plugin)); AddCommand(new ListServersCommand(plugin));

View File

@ -105,6 +105,8 @@ public class ServerGameMenu extends ShopPageBase<ServerManager, ServerNpcShop>
ChatColor.RESET + "A Barbarian's Life", ChatColor.RESET + "A Barbarian's Life",
ChatColor.RESET + "Turf Forts", ChatColor.RESET + "Turf Forts",
ChatColor.RESET + "Death Tag", ChatColor.RESET + "Death Tag",
ChatColor.RESET + "Bacon Brawl",
ChatColor.RESET + "Squid Sauce"
})); }));
_minigameCycle.add(ItemStackFactory.Instance.CreateStack(Material.GOLD_BOOTS.getId(), (byte)0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String [] _minigameCycle.add(ItemStackFactory.Instance.CreateStack(Material.GOLD_BOOTS.getId(), (byte)0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String []
@ -121,6 +123,8 @@ public class ServerGameMenu extends ShopPageBase<ServerManager, ServerNpcShop>
ChatColor.RESET + "A Barbarian's Life", ChatColor.RESET + "A Barbarian's Life",
ChatColor.RESET + "Turf Forts", ChatColor.RESET + "Turf Forts",
ChatColor.RESET + "Death Tag", ChatColor.RESET + "Death Tag",
ChatColor.RESET + "Bacon Brawl",
ChatColor.RESET + "Squid Sauce"
})); }));
_minigameCycle.add(ItemStackFactory.Instance.CreateStack(122, (byte)0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String [] _minigameCycle.add(ItemStackFactory.Instance.CreateStack(122, (byte)0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String []
@ -137,6 +141,8 @@ public class ServerGameMenu extends ShopPageBase<ServerManager, ServerNpcShop>
ChatColor.RESET + "A Barbarian's Life", ChatColor.RESET + "A Barbarian's Life",
ChatColor.RESET + "Turf Forts", ChatColor.RESET + "Turf Forts",
ChatColor.RESET + "Death Tag", ChatColor.RESET + "Death Tag",
ChatColor.RESET + "Bacon Brawl",
ChatColor.RESET + "Squid Sauce"
})); }));
_minigameCycle.add(ItemStackFactory.Instance.CreateStack(Material.BOW, (byte)0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String [] _minigameCycle.add(ItemStackFactory.Instance.CreateStack(Material.BOW, (byte)0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String []
@ -153,6 +159,8 @@ public class ServerGameMenu extends ShopPageBase<ServerManager, ServerNpcShop>
ChatColor.RESET + "A Barbarian's Life", ChatColor.RESET + "A Barbarian's Life",
ChatColor.RESET + "Turf Forts", ChatColor.RESET + "Turf Forts",
ChatColor.RESET + "Death Tag", ChatColor.RESET + "Death Tag",
ChatColor.RESET + "Bacon Brawl",
ChatColor.RESET + "Squid Sauce"
})); }));
_minigameCycle.add(ItemStackFactory.Instance.CreateStack(Material.LEATHER_BOOTS.getId(), (byte)0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String [] _minigameCycle.add(ItemStackFactory.Instance.CreateStack(Material.LEATHER_BOOTS.getId(), (byte)0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String []
@ -169,6 +177,8 @@ public class ServerGameMenu extends ShopPageBase<ServerManager, ServerNpcShop>
ChatColor.RESET + "A Barbarian's Life", ChatColor.RESET + "A Barbarian's Life",
ChatColor.RESET + "Turf Forts", ChatColor.RESET + "Turf Forts",
ChatColor.RESET + "Death Tag", ChatColor.RESET + "Death Tag",
ChatColor.RESET + "Bacon Brawl",
ChatColor.RESET + "Squid Sauce"
})); }));
_minigameCycle.add(ItemStackFactory.Instance.CreateStack(Material.MILK_BUCKET.getId(), (byte)0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String [] _minigameCycle.add(ItemStackFactory.Instance.CreateStack(Material.MILK_BUCKET.getId(), (byte)0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String []
@ -185,6 +195,8 @@ public class ServerGameMenu extends ShopPageBase<ServerManager, ServerNpcShop>
ChatColor.RESET + "A Barbarian's Life", ChatColor.RESET + "A Barbarian's Life",
ChatColor.RESET + "Turf Forts", ChatColor.RESET + "Turf Forts",
ChatColor.RESET + "Death Tag", ChatColor.RESET + "Death Tag",
ChatColor.RESET + "Bacon Brawl",
ChatColor.RESET + "Squid Sauce"
})); }));
_minigameCycle.add(ItemStackFactory.Instance.CreateStack(Material.IRON_AXE.getId(), (byte)0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String [] _minigameCycle.add(ItemStackFactory.Instance.CreateStack(Material.IRON_AXE.getId(), (byte)0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String []
@ -201,6 +213,8 @@ public class ServerGameMenu extends ShopPageBase<ServerManager, ServerNpcShop>
ChatColor.RESET + C.Bold + ChatColor.GREEN + "A Barbarian's Life", ChatColor.RESET + C.Bold + ChatColor.GREEN + "A Barbarian's Life",
ChatColor.RESET + "Turf Forts", ChatColor.RESET + "Turf Forts",
ChatColor.RESET + "Death Tag", ChatColor.RESET + "Death Tag",
ChatColor.RESET + "Bacon Brawl",
ChatColor.RESET + "Squid Sauce"
})); }));
_minigameCycle.add(ItemStackFactory.Instance.CreateStack(159, (byte)14, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String [] _minigameCycle.add(ItemStackFactory.Instance.CreateStack(159, (byte)14, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String []
@ -217,6 +231,8 @@ public class ServerGameMenu extends ShopPageBase<ServerManager, ServerNpcShop>
ChatColor.RESET + "A Barbarian's Life", ChatColor.RESET + "A Barbarian's Life",
ChatColor.RESET + C.Bold + ChatColor.GREEN + "Turf Forts", ChatColor.RESET + C.Bold + ChatColor.GREEN + "Turf Forts",
ChatColor.RESET + "Death Tag", ChatColor.RESET + "Death Tag",
ChatColor.RESET + "Bacon Brawl",
ChatColor.RESET + "Squid Sauce"
})); }));
_minigameCycle.add(ItemStackFactory.Instance.CreateStack(144, (byte)1, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String [] _minigameCycle.add(ItemStackFactory.Instance.CreateStack(144, (byte)1, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String []
@ -233,6 +249,44 @@ public class ServerGameMenu extends ShopPageBase<ServerManager, ServerNpcShop>
ChatColor.RESET + "A Barbarian's Life", ChatColor.RESET + "A Barbarian's Life",
ChatColor.RESET + "Turf Forts", ChatColor.RESET + "Turf Forts",
ChatColor.RESET + C.Bold + ChatColor.GREEN + "Death Tag", ChatColor.RESET + C.Bold + ChatColor.GREEN + "Death Tag",
ChatColor.RESET + "Bacon Brawl",
ChatColor.RESET + "Squid Sauce"
}));
_minigameCycle.add(ItemStackFactory.Instance.CreateStack(144, (byte)1, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String []
{
ChatColor.RESET + "",
ChatColor.RESET + "Play all of these fun minigames:",
ChatColor.RESET + "",
ChatColor.RESET + "Super Spleef",
ChatColor.RESET + "Runner",
ChatColor.RESET + "Dragons",
ChatColor.RESET + "One in the Quiver",
ChatColor.RESET + "Dragon Escape",
ChatColor.RESET + "Milk the Cow",
ChatColor.RESET + "A Barbarian's Life",
ChatColor.RESET + "Turf Forts",
ChatColor.RESET + "Death Tag",
ChatColor.RESET + C.Bold + ChatColor.GREEN + "Bacon Brawl",
ChatColor.RESET + "Squid Sauce"
}));
_minigameCycle.add(ItemStackFactory.Instance.CreateStack(144, (byte)1, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Arcade " + C.cGray + "Mixed Games", new String []
{
ChatColor.RESET + "",
ChatColor.RESET + "Play all of these fun minigames:",
ChatColor.RESET + "",
ChatColor.RESET + "Super Spleef",
ChatColor.RESET + "Runner",
ChatColor.RESET + "Dragons",
ChatColor.RESET + "One in the Quiver",
ChatColor.RESET + "Dragon Escape",
ChatColor.RESET + "Milk the Cow",
ChatColor.RESET + "A Barbarian's Life",
ChatColor.RESET + "Turf Forts",
ChatColor.RESET + "Death Tag",
ChatColor.RESET + "Bacon Brawl",
ChatColor.RESET + C.Bold + ChatColor.GREEN + "Squid Sauce"
})); }));
} }