mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-23 13:46:46 +01:00
Adding a permission for the /mcmmo command.
This commit is contained in:
parent
2888fdff9e
commit
939586ce1a
@ -11,10 +11,15 @@ import com.gmail.nossr50.mcMMO;
|
|||||||
import com.gmail.nossr50.config.Config;
|
import com.gmail.nossr50.config.Config;
|
||||||
import com.gmail.nossr50.locale.LocaleLoader;
|
import com.gmail.nossr50.locale.LocaleLoader;
|
||||||
import com.gmail.nossr50.util.Anniversary;
|
import com.gmail.nossr50.util.Anniversary;
|
||||||
|
import com.gmail.nossr50.util.Permissions;
|
||||||
|
|
||||||
public class McmmoCommand implements CommandExecutor {
|
public class McmmoCommand implements CommandExecutor {
|
||||||
@Override
|
@Override
|
||||||
public boolean onCommand(CommandSender sender, Command command, String label, String[] args) {
|
public boolean onCommand(CommandSender sender, Command command, String label, String[] args) {
|
||||||
|
if (!Permissions.hasPermission(sender, "mcmmo.commands.mcmmo")) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
String description = LocaleLoader.getString("mcMMO.Description");
|
String description = LocaleLoader.getString("mcMMO.Description");
|
||||||
String[] mcSplit = description.split(",");
|
String[] mcSplit = description.split(",");
|
||||||
sender.sendMessage(mcSplit);
|
sender.sendMessage(mcSplit);
|
||||||
|
@ -723,6 +723,7 @@ permissions:
|
|||||||
children:
|
children:
|
||||||
mcmmo.commands.inspect: true
|
mcmmo.commands.inspect: true
|
||||||
mcmmo.commands.mcability: true
|
mcmmo.commands.mcability: true
|
||||||
|
mcmmo.commands.mcmmo: true
|
||||||
mcmmo.commands.mcrank: true
|
mcmmo.commands.mcrank: true
|
||||||
mcmmo.commands.mcstats: true
|
mcmmo.commands.mcstats: true
|
||||||
mcmmo.commands.mctop: true
|
mcmmo.commands.mctop: true
|
||||||
@ -764,6 +765,8 @@ permissions:
|
|||||||
description: Allows access to the mcgod command
|
description: Allows access to the mcgod command
|
||||||
mcmmo.commands.mcgod.others:
|
mcmmo.commands.mcgod.others:
|
||||||
description: Allows access to the mcgod command for other players
|
description: Allows access to the mcgod command for other players
|
||||||
|
mcmmo.commands.mcmmo:
|
||||||
|
description: Allows access to the mcmmo command
|
||||||
mcmmo.commands.mcrank:
|
mcmmo.commands.mcrank:
|
||||||
description: Allows access to the mcrank command
|
description: Allows access to the mcrank command
|
||||||
mcmmo.commands.mcstats:
|
mcmmo.commands.mcstats:
|
||||||
|
Loading…
Reference in New Issue
Block a user