Fixed rankUpdate changing existing higher ranked players.

Fixed join limits in arcade and hub.
This commit is contained in:
Jonathan Williams 2014-07-02 16:05:26 -07:00
parent 558f79fe34
commit f1393ffb33
4 changed files with 4 additions and 18 deletions

View File

@ -252,7 +252,7 @@ public class HubManager extends MiniClientPlugin<HubClient>
// Reserved Slot Check
if (Bukkit.getOnlinePlayers().length >= Bukkit.getServer().getMaxPlayers())
{
if (!client.GetRank().Has(Rank.ULTRA))
if (!client.GetRank().Has(Rank.HELPER))
{
Bukkit.getScheduler().scheduleSyncDelayedTask(GetPlugin(), new Runnable()
{

View File

@ -493,23 +493,6 @@ public class ArcadeManager extends MiniPlugin implements IRelation
new String[] {"", ChatColor.RESET + "Click while holding this", ChatColor.RESET + "to return to the Hub."}));
}
@EventHandler
public void Login(PlayerLoginEvent event)
{
// Reserved Slot Check
if (Bukkit.getOnlinePlayers().length >= Bukkit.getServer().getMaxPlayers())
{
if (_clientManager.Get(event.getPlayer().getName()).GetRank().Has(event.getPlayer(), Rank.ULTRA, false) || _donationManager.Get(event.getPlayer().getName()).OwnsUnknownPackage(_serverConfig.ServerType + " ULTRA"))
{
event.allow();
event.setResult(PlayerLoginEvent.Result.ALLOWED);
return;
}
event.disallow(PlayerLoginEvent.Result.KICK_OTHER, "Server Full > Purchase Ultra at www.mineplex.com/shop");
}
}
public boolean IsAlive(Player player)
{
if (_game == null)

View File

@ -506,6 +506,9 @@
if (account == null)
return "ALL";
if (account.Rank.Name == "ADMIN" || account.Rank.Name == "OWNER" || account.Rank.Name == "DEVELOPER" || account.Rank.Name == "YOUTUBE")
return token.Rank;
if (rank == null)
return account.Rank.ToString();

Binary file not shown.