Fixed NPE in GameHostManager

Fixed CD for creating server.
This commit is contained in:
Jonathan Williams 2014-12-23 06:46:05 -05:00
parent 4bfd34034b
commit 07cca7a1d4
3 changed files with 3 additions and 3 deletions

View File

@ -16,7 +16,7 @@ public class HostServerCommand extends CommandBase<PersonalServerManager>
@Override
public void Execute(Player caller, String[] args)
{
if (!Recharge.Instance.use(caller, "Host Server", 30000, true, true))
if (!Recharge.Instance.use(caller, "Host Server", 30000, false, false))
return;
Plugin.hostServer(caller, caller.getName());

View File

@ -67,7 +67,7 @@ public class PersonalServerManager extends MiniPlugin
{
if (_interfaceItem.equals(event.getPlayer().getItemInHand()))
{
if (!Recharge.Instance.use(event.getPlayer(), "Host Server", 30000, true, true))
if (!Recharge.Instance.use(event.getPlayer(), "Host Server Melon", 30000, false, false))
return;
if (_clientManager.Get(event.getPlayer()).GetRank().Has(Rank.LEGEND))

View File

@ -253,7 +253,7 @@ public class GameHostManager implements Listener
public boolean isPrivateServer()
{
return Manager.GetHost() != null || Manager.GetHost().length() > 0;
return Manager.GetHost() != null && Manager.GetHost().length() > 0;
}
@EventHandler