Fixed bug where trying to use /mctop or /xplock with the Smelting child

skill caused NPEs.

Fixes #748
This commit is contained in:
GJ
2013-03-01 10:38:14 -05:00
parent 7814fa8d46
commit a87336b7ee
3 changed files with 22 additions and 2 deletions

View File

@@ -39,6 +39,11 @@ public class XplockCommand extends SpoutCommand {
SkillType skill = SkillType.getSkill(args[0]);
if (skill.isChildSkill()) {
sender.sendMessage("Child skills are not yet supported by this command."); // TODO: Localize this
return true;
}
if (!Permissions.xplock(sender, skill)) {
sender.sendMessage(command.getPermissionMessage());
return true;