mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-24 14:16:45 +01:00
Disabled worlds
This commit is contained in:
parent
43e3dd7977
commit
6e8ad54dc6
@ -23,7 +23,7 @@ public class AddxpCommand 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 (!mcPermissions.permissionsEnabled) {
|
if (!mcPermissions.isEnabled()) {
|
||||||
sender.sendMessage("This command requires permissions.");
|
sender.sendMessage("This command requires permissions.");
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -24,7 +24,7 @@ public class MmoeditCommand 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 (!mcPermissions.permissionsEnabled) {
|
if (!mcPermissions.isEnabled()) {
|
||||||
sender.sendMessage("This command requires permissions.");
|
sender.sendMessage("This command requires permissions.");
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -33,7 +33,7 @@ public class StatsCommand implements CommandExecutor {
|
|||||||
|
|
||||||
player.sendMessage(mcLocale.getString("mcPlayerListener.YourStats"));
|
player.sendMessage(mcLocale.getString("mcPlayerListener.YourStats"));
|
||||||
|
|
||||||
if (mcPermissions.getEnabled())
|
if (mcPermissions.isEnabled())
|
||||||
player.sendMessage(mcLocale.getString("mcPlayerListener.NoSkillNote"));
|
player.sendMessage(mcLocale.getString("mcPlayerListener.NoSkillNote"));
|
||||||
|
|
||||||
ChatColor header = ChatColor.GOLD;
|
ChatColor header = ChatColor.GOLD;
|
||||||
|
@ -14,7 +14,7 @@ import com.gmail.nossr50.locale.mcLocale;
|
|||||||
public class McabilityCommand implements CommandExecutor {
|
public class McabilityCommand 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 (!mcPermissions.permissionsEnabled) {
|
if (!mcPermissions.isEnabled()) {
|
||||||
sender.sendMessage("This command requires permissions.");
|
sender.sendMessage("This command requires permissions.");
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -28,7 +28,7 @@ public class McgodCommand implements CommandExecutor {
|
|||||||
Player player = (Player) sender;
|
Player player = (Player) sender;
|
||||||
PlayerProfile PP = Users.getProfile(player);
|
PlayerProfile PP = Users.getProfile(player);
|
||||||
|
|
||||||
if (mcPermissions.permissionsEnabled) {
|
if (mcPermissions.isEnabled()) {
|
||||||
if (!mcPermissions.getInstance().mcgod(player)) {
|
if (!mcPermissions.getInstance().mcgod(player)) {
|
||||||
player.sendMessage(ChatColor.YELLOW + "[mcMMO] " + ChatColor.DARK_RED + mcLocale.getString("mcPlayerListener.NoPermission"));
|
player.sendMessage(ChatColor.YELLOW + "[mcMMO] " + ChatColor.DARK_RED + mcLocale.getString("mcPlayerListener.NoPermission"));
|
||||||
return true;
|
return true;
|
||||||
|
@ -17,8 +17,10 @@
|
|||||||
package com.gmail.nossr50.config;
|
package com.gmail.nossr50.config;
|
||||||
|
|
||||||
import com.gmail.nossr50.mcMMO;
|
import com.gmail.nossr50.mcMMO;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
|
||||||
import org.bukkit.configuration.file.FileConfiguration;
|
import org.bukkit.configuration.file.FileConfiguration;
|
||||||
|
|
||||||
@ -86,6 +88,8 @@ public class LoadProperties {
|
|||||||
excavationxpmodifier, archeryxpmodifier, swordsxpmodifier,
|
excavationxpmodifier, archeryxpmodifier, swordsxpmodifier,
|
||||||
axesxpmodifier, acrobaticsxpmodifier;
|
axesxpmodifier, acrobaticsxpmodifier;
|
||||||
|
|
||||||
|
public static ArrayList<String> disabledWorlds;
|
||||||
|
|
||||||
public static HUDType defaulthud;
|
public static HUDType defaulthud;
|
||||||
protected static File configFile;
|
protected static File configFile;
|
||||||
protected static File dataFolder;
|
protected static File dataFolder;
|
||||||
@ -129,6 +133,12 @@ public class LoadProperties {
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static ArrayList<String> readList(String root, ArrayList<String> def) {
|
||||||
|
@SuppressWarnings({ "unchecked", "rawtypes" })
|
||||||
|
ArrayList<String> result = (ArrayList) config.getList(root, def);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
private static void saveConfig() {
|
private static void saveConfig() {
|
||||||
try {
|
try {
|
||||||
config.save(configFile);
|
config.save(configFile);
|
||||||
@ -297,6 +307,8 @@ public class LoadProperties {
|
|||||||
enableMySpawn = readBoolean("General.MySpawn.Enabled", true);
|
enableMySpawn = readBoolean("General.MySpawn.Enabled", true);
|
||||||
enableRegen = readBoolean("General.HP_Regeneration.Enabled", true);
|
enableRegen = readBoolean("General.HP_Regeneration.Enabled", true);
|
||||||
|
|
||||||
|
disabledWorlds = readList("General.Disabled_Worlds", new ArrayList<String>());
|
||||||
|
|
||||||
enableCobbleToMossy = readBoolean("Skills.Herbalism.Green_Thumb.Cobble_To_Mossy", true);
|
enableCobbleToMossy = readBoolean("Skills.Herbalism.Green_Thumb.Cobble_To_Mossy", true);
|
||||||
|
|
||||||
xpGainMultiplier = readInteger("Experience.Gains.Multiplier.Global", 1);
|
xpGainMultiplier = readInteger("Experience.Gains.Multiplier.Global", 1);
|
||||||
@ -431,5 +443,7 @@ public class LoadProperties {
|
|||||||
|
|
||||||
aDisplayNames = readBoolean("Commands.a.Display_Names", true);
|
aDisplayNames = readBoolean("Commands.a.Display_Names", true);
|
||||||
pDisplayNames = readBoolean("Commands.p.Display_Names", true);
|
pDisplayNames = readBoolean("Commands.p.Display_Names", true);
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -25,11 +25,11 @@ import org.bukkit.plugin.Plugin;
|
|||||||
import ru.tehkode.permissions.PermissionManager;
|
import ru.tehkode.permissions.PermissionManager;
|
||||||
import ru.tehkode.permissions.bukkit.PermissionsEx;
|
import ru.tehkode.permissions.bukkit.PermissionsEx;
|
||||||
|
|
||||||
|
import com.gmail.nossr50.config.LoadProperties;
|
||||||
import com.nijiko.permissions.PermissionHandler;
|
import com.nijiko.permissions.PermissionHandler;
|
||||||
import com.nijikokun.bukkit.Permissions.Permissions;
|
import com.nijikokun.bukkit.Permissions.Permissions;
|
||||||
|
|
||||||
public class mcPermissions
|
public class mcPermissions {
|
||||||
{
|
|
||||||
private static volatile mcPermissions instance;
|
private static volatile mcPermissions instance;
|
||||||
|
|
||||||
private enum PermissionType {
|
private enum PermissionType {
|
||||||
@ -38,41 +38,31 @@ public class mcPermissions
|
|||||||
|
|
||||||
private static PermissionType permissionType;
|
private static PermissionType permissionType;
|
||||||
private static Object PHandle;
|
private static Object PHandle;
|
||||||
public static boolean permissionsEnabled = false;
|
|
||||||
|
|
||||||
public static void initialize(Server server)
|
public static void initialize(Server server) {
|
||||||
{
|
|
||||||
Logger log = Logger.getLogger("Minecraft");
|
Logger log = Logger.getLogger("Minecraft");
|
||||||
|
|
||||||
if(permissionsEnabled && permissionType != PermissionType.PERMISSIONS) return;
|
if (permissionType != null && permissionType != PermissionType.PERMISSIONS)
|
||||||
|
return;
|
||||||
|
|
||||||
Plugin PEXtest = server.getPluginManager().getPlugin("PermissionsEx");
|
Plugin PEXtest = server.getPluginManager().getPlugin("PermissionsEx");
|
||||||
Plugin test = server.getPluginManager().getPlugin("Permissions");
|
Plugin test = server.getPluginManager().getPlugin("Permissions");
|
||||||
if (PEXtest != null) {
|
if (PEXtest != null) {
|
||||||
PHandle = (PermissionManager) PermissionsEx.getPermissionManager();
|
PHandle = (PermissionManager) PermissionsEx.getPermissionManager();
|
||||||
permissionType = PermissionType.PEX;
|
permissionType = PermissionType.PEX;
|
||||||
permissionsEnabled = true;
|
|
||||||
log.info("[mcMMO] PermissionsEx found, using PermissionsEx.");
|
log.info("[mcMMO] PermissionsEx found, using PermissionsEx.");
|
||||||
} else if (test != null) {
|
} else if (test != null) {
|
||||||
PHandle = (PermissionHandler) ((Permissions) test).getHandler();
|
PHandle = (PermissionHandler) ((Permissions) test).getHandler();
|
||||||
permissionType = PermissionType.PERMISSIONS;
|
permissionType = PermissionType.PERMISSIONS;
|
||||||
permissionsEnabled = true;
|
|
||||||
log.info("[mcMMO] Permissions version " + test.getDescription().getVersion() + " found, using Permissions.");
|
log.info("[mcMMO] Permissions version " + test.getDescription().getVersion() + " found, using Permissions.");
|
||||||
} else {
|
} else {
|
||||||
permissionType = PermissionType.BUKKIT;
|
permissionType = PermissionType.BUKKIT;
|
||||||
permissionsEnabled = true;
|
|
||||||
log.info("[mcMMO] Using Bukkit Permissions.");
|
log.info("[mcMMO] Using Bukkit Permissions.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean getEnabled()
|
public static boolean permission(Player player, String permission) {
|
||||||
{
|
if(LoadProperties.disabledWorlds.contains(player.getWorld().getName())) return false;
|
||||||
return permissionsEnabled;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static boolean permission(Player player, String permission)
|
|
||||||
{
|
|
||||||
if(!permissionsEnabled) return player.isOp();
|
|
||||||
switch (permissionType) {
|
switch (permissionType) {
|
||||||
case PEX:
|
case PEX:
|
||||||
return ((PermissionManager) PHandle).has(player, permission);
|
return ((PermissionManager) PHandle).has(player, permission);
|
||||||
@ -84,269 +74,163 @@ public class mcPermissions
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
public boolean admin(Player player){
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.admin");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean mcrefresh(Player player) {
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.tools.mcrefresh");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean mmoedit(Player player) {
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.tools.mmoedit");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean herbalismAbility(Player player){
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.ability.herbalism");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean excavationAbility(Player player){
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.ability.excavation");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean unarmedAbility(Player player){
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.ability.unarmed");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean chimaeraWing(Player player){
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.item.chimaerawing");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean miningAbility(Player player){
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.ability.mining");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean axesAbility(Player player){
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.ability.axes");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean swordsAbility(Player player){
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.ability.swords");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean woodCuttingAbility(Player player) {
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.ability.woodcutting");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean mcgod(Player player) {
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.tools.mcgod");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean regeneration(Player player){
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.regeneration");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean motd(Player player) {
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.motd");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean mcAbility(Player player) {
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.commands.ability");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean mySpawn(Player player) {
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.commands.myspawn");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean setMySpawn(Player player) {
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.commands.setmyspawn");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean partyChat(Player player) {
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.chat.partychat");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean partyLock(Player player) {
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.chat.partylock");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean partyTeleport(Player player) {
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.commands.ptp");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean whois(Player player) {
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.commands.whois");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean party(Player player) {
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.commands.party");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public boolean adminChat(Player player) {
|
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.chat.adminchat");
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static mcPermissions getInstance() {
|
public static mcPermissions getInstance() {
|
||||||
if (instance == null) {
|
if (instance == null) {
|
||||||
instance = new mcPermissions();
|
instance = new mcPermissions();
|
||||||
}
|
}
|
||||||
return instance;
|
return instance;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static boolean isEnabled() {
|
||||||
|
return permissionType != null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean admin(Player player) {
|
||||||
|
return permission(player, "mcmmo.admin");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean mcrefresh(Player player) {
|
||||||
|
return permission(player, "mcmmo.tools.mcrefresh");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean mmoedit(Player player) {
|
||||||
|
return permission(player, "mcmmo.tools.mmoedit");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean herbalismAbility(Player player) {
|
||||||
|
return permission(player, "mcmmo.ability.herbalism");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean excavationAbility(Player player) {
|
||||||
|
return permission(player, "mcmmo.ability.excavation");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean unarmedAbility(Player player) {
|
||||||
|
return permission(player, "mcmmo.ability.unarmed");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean chimaeraWing(Player player) {
|
||||||
|
return permission(player, "mcmmo.item.chimaerawing");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean miningAbility(Player player) {
|
||||||
|
return permission(player, "mcmmo.ability.mining");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean axesAbility(Player player) {
|
||||||
|
return permission(player, "mcmmo.ability.axes");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean swordsAbility(Player player) {
|
||||||
|
return permission(player, "mcmmo.ability.swords");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean woodCuttingAbility(Player player) {
|
||||||
|
return permission(player, "mcmmo.ability.woodcutting");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean mcgod(Player player) {
|
||||||
|
return permission(player, "mcmmo.tools.mcgod");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean regeneration(Player player) {
|
||||||
|
return permission(player, "mcmmo.regeneration");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean motd(Player player) {
|
||||||
|
return permission(player, "mcmmo.motd");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean mcAbility(Player player) {
|
||||||
|
return permission(player, "mcmmo.commands.ability");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean mySpawn(Player player) {
|
||||||
|
return permission(player, "mcmmo.commands.myspawn");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean setMySpawn(Player player) {
|
||||||
|
return permission(player, "mcmmo.commands.setmyspawn");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean partyChat(Player player) {
|
||||||
|
return permission(player, "mcmmo.chat.partychat");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean partyLock(Player player) {
|
||||||
|
return permission(player, "mcmmo.chat.partylock");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean partyTeleport(Player player) {
|
||||||
|
return permission(player, "mcmmo.commands.ptp");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean whois(Player player) {
|
||||||
|
return permission(player, "mcmmo.commands.whois");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean party(Player player) {
|
||||||
|
return permission(player, "mcmmo.commands.party");
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean adminChat(Player player) {
|
||||||
|
return permission(player, "mcmmo.chat.adminchat");
|
||||||
|
}
|
||||||
|
|
||||||
public boolean taming(Player player) {
|
public boolean taming(Player player) {
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.skills.taming");
|
return permission(player, "mcmmo.skills.taming");
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean mining(Player player) {
|
public boolean mining(Player player) {
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.skills.mining");
|
return permission(player, "mcmmo.skills.mining");
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean fishing(Player player) {
|
public boolean fishing(Player player) {
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.skills.fishing");
|
return permission(player, "mcmmo.skills.fishing");
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean alchemy(Player player) {
|
public boolean alchemy(Player player) {
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.skills.alchemy");
|
return permission(player, "mcmmo.skills.alchemy");
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean enchanting(Player player) {
|
public boolean enchanting(Player player) {
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.skills.enchanting");
|
return permission(player, "mcmmo.skills.enchanting");
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean woodcutting(Player player) {
|
public boolean woodcutting(Player player) {
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.skills.woodcutting");
|
return permission(player, "mcmmo.skills.woodcutting");
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean repair(Player player) {
|
public boolean repair(Player player) {
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.skills.repair");
|
return permission(player, "mcmmo.skills.repair");
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean unarmed(Player player) {
|
public boolean unarmed(Player player) {
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.skills.unarmed");
|
return permission(player, "mcmmo.skills.unarmed");
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean archery(Player player) {
|
public boolean archery(Player player) {
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.skills.archery");
|
return permission(player, "mcmmo.skills.archery");
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean herbalism(Player player) {
|
public boolean herbalism(Player player) {
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.skills.herbalism");
|
return permission(player, "mcmmo.skills.herbalism");
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean excavation(Player player) {
|
public boolean excavation(Player player) {
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.skills.excavation");
|
return permission(player, "mcmmo.skills.excavation");
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean swords(Player player) {
|
public boolean swords(Player player) {
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.skills.swords");
|
return permission(player, "mcmmo.skills.swords");
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean axes(Player player) {
|
public boolean axes(Player player) {
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.skills.axes");
|
return permission(player, "mcmmo.skills.axes");
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean acrobatics(Player player) {
|
public boolean acrobatics(Player player) {
|
||||||
if (permissionsEnabled) {
|
|
||||||
return permission(player, "mcmmo.skills.acrobatics");
|
return permission(player, "mcmmo.skills.acrobatics");
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -256,6 +256,8 @@ General:
|
|||||||
Enabled: true
|
Enabled: true
|
||||||
MOTD:
|
MOTD:
|
||||||
Enabled: true
|
Enabled: true
|
||||||
|
Disabled_Worlds:
|
||||||
|
- this_world_has_no_mcmmo
|
||||||
Excavation:
|
Excavation:
|
||||||
Drops:
|
Drops:
|
||||||
Cake: true
|
Cake: true
|
||||||
|
Loading…
Reference in New Issue
Block a user