Don't allow jailing in unloaded worlds and don't allow joining while

jailed in unloaded worlds.
This commit is contained in:
graywolf336
2014-07-14 22:53:48 -05:00
parent 5c4122ee92
commit a5bf89b07e
8 changed files with 64 additions and 1 deletions

View File

@ -174,6 +174,11 @@ public class JailCommand implements Command {
//Get the jail instance from the name of jail in the params.
Jail j = jm.getJail(jailName);
if(!j.isEnabled()) {
sender.sendMessage(jm.getPlugin().getJailIO().getLanguageString(LangString.WORLDUNLOADED, j.getName()));
return true;
}
Cell c = j.getCell(params.getCell());
Prisoner pris = new Prisoner(uuid, params.getPlayer(), muted, time, sender.getName(), reason);