This commit is contained in:
Telesphoreo
2018-07-24 19:44:00 -07:00
committed by Seth
parent 0d503a6c06
commit 7278176143
24 changed files with 184 additions and 53 deletions

View File

@ -85,6 +85,7 @@ public class Command_cage extends FreedomCommand
}
}
}
Location location = player.getLocation().clone().add(0.0, 1.0, 0.0);
if (skullName != null)
{
@ -95,7 +96,7 @@ public class Command_cage extends FreedomCommand
fPlayer.getCageData().cage(location, outerMaterial, innerMaterial);
}
player.setGameMode(GameMode.SURVIVAL);
if (outerMaterial == Material.PLAYER_HEAD)
{
FUtil.adminAction(sender.getName(), "Caging " + player.getName() + " in " + skullName, true);
}

View File

@ -71,7 +71,7 @@ public class Command_premium extends FreedomCommand
catch (Exception ex)
{
FLog.severe(ex);
msg("There was an error querying the mojang server.", ChatColor.RED);
msg("There was an error querying the Mojang server.", ChatColor.RED);
}
}
}.runTaskAsynchronously(plugin);

View File

@ -15,7 +15,7 @@ public class Command_restart extends FreedomCommand
@Override
public boolean run(CommandSender sender, Player playerSender, Command cmd, String commandLabel, String[] args, boolean senderIsConsole)
{
if(!plugin.amp.enabled)
if (!plugin.amp.enabled)
{
msg(ChatColor.RED + "AMP integration is not enabled. Please use /stop instead.");
return true;

View File

@ -15,6 +15,12 @@ public class Command_wipecoreprotectdata extends FreedomCommand
@Override
public boolean run(final CommandSender sender, Player playerSender, Command cmd, String commandLabel, String[] args, boolean senderIsConsole)
{
if (!plugin.cpb.isEnabled())
{
msg("CoreProtect is not enabled on this server");
return true;
}
FUtil.adminAction(sender.getName(), "Wiping CoreProtect data for the flatlands", true);
new BukkitRunnable()

View File

@ -6,7 +6,6 @@ import org.bukkit.ChatColor;
import org.bukkit.command.Command;
import org.bukkit.command.CommandSender;
import org.bukkit.entity.Player;
import org.bukkit.scheduler.BukkitRunnable;
@CommandPermissions(level = Rank.SENIOR_ADMIN, source = SourceType.ONLY_CONSOLE, blockHostConsole = true)
@CommandParameters(description = "Wipe the flatlands map. Requires manual restart after command is used.", usage = "/<command>")
@ -20,7 +19,10 @@ public class Command_wipeflatlands extends FreedomCommand
FUtil.bcastMsg("Server is going offline for flatlands wipe.", ChatColor.GRAY);
plugin.wgb.wipeRegions(plugin.wm.flatlands.getWorld());
if (plugin.wgb.isPluginEnabled())
{
plugin.wgb.wipeRegions(plugin.wm.flatlands.getWorld());
}
for (Player player : server.getOnlinePlayers())
{

View File

@ -38,7 +38,6 @@ public class Command_wipeuserdata extends FreedomCommand
FUtil.deleteFolder(new File(Bukkit.getServer().getWorld(plugin.wm.flatlands.getName()).getWorldFolder().getName() + "stats"));
FUtil.deleteFolder(new File(Bukkit.getServer().getWorld(w.getName()).getWorldFolder().getName() + "stats"));
FUtil.deleteFolder(new File(Bukkit.getServer().getWorld(w.getName()).getWorldFolder().getName() + "playerdata"));
msg("All playerdata deleted.");
return true;
}