For /wb fill and /wb trim, "stop" can now be used interchangeably with existing "cancel" directive.

Removed plugin "loading" and "shutting down" log messages at startup and shutdown since Bukkit now handles such messages itself.
Updated CoordXZ to have slightly more unique hashCode values for fewer hashCode intersections.
This commit is contained in:
Brettflan 2012-02-10 20:09:27 -06:00
parent a4f7cd6487
commit 9ee2d3aa50
4 changed files with 7 additions and 12 deletions

View File

@ -54,6 +54,6 @@ public class CoordXZ
@Override
public int hashCode()
{
return (this.x << 6) + this.z;
return (this.x << 9) + this.z;
}
}

View File

@ -457,7 +457,7 @@ public class WBCommand implements CommandExecutor
String pad = "", frequency = "";
if (split.length >= 3)
{
cancel = split[2].equalsIgnoreCase("cancel");
cancel = split[2].equalsIgnoreCase("cancel") || split[2].equalsIgnoreCase("stop");
confirm = split[2].equalsIgnoreCase("confirm");
pause = split[2].equalsIgnoreCase("pause");
if (!cancel && !confirm && !pause)
@ -480,7 +480,7 @@ public class WBCommand implements CommandExecutor
String pad = "", frequency = "";
if (split.length >= 2)
{
cancel = split[1].equalsIgnoreCase("cancel");
cancel = split[1].equalsIgnoreCase("cancel") || split[1].equalsIgnoreCase("stop");
confirm = split[1].equalsIgnoreCase("confirm");
pause = split[1].equalsIgnoreCase("pause");
if (!cancel && !confirm && !pause)
@ -511,7 +511,7 @@ public class WBCommand implements CommandExecutor
String pad = "", frequency = "";
if (split.length >= 3)
{
cancel = split[2].equalsIgnoreCase("cancel");
cancel = split[2].equalsIgnoreCase("cancel") || split[2].equalsIgnoreCase("stop");
confirm = split[2].equalsIgnoreCase("confirm");
pause = split[2].equalsIgnoreCase("pause");
if (!cancel && !confirm && !pause)
@ -534,7 +534,7 @@ public class WBCommand implements CommandExecutor
String pad = "", frequency = "";
if (split.length >= 2)
{
cancel = split[1].equalsIgnoreCase("cancel");
cancel = split[1].equalsIgnoreCase("cancel") || split[1].equalsIgnoreCase("stop");
confirm = split[1].equalsIgnoreCase("confirm");
pause = split[1].equalsIgnoreCase("pause");
if (!cancel && !confirm && !pause)
@ -731,7 +731,7 @@ public class WBCommand implements CommandExecutor
}
String cmd = clrCmd + ((player == null) ? "wb" : "/wb");
sender.sendMessage(clrHead + "World generation task is ready for world \"" + fillWorld + "\", padding the map out to " + fillPadding + " blocks beyond the border (default " + CoordXZ.chunkToBlock(13) + "), and the task will try to process up to " + fillFrequency + " chunks per second (default 20).");
sender.sendMessage(clrHead + "World generation task is ready for world \"" + fillWorld + "\", padding the map out to " + fillPadding + " blocks beyond the border (default " + CoordXZ.chunkToBlock(13) + "), and the task will try to generate up to " + fillFrequency + " chunks per second (default 20).");
sender.sendMessage(clrHead + "This process can take a very long time depending on the world's border size. Also, depending on the chunk processing rate, players will likely experience severe lag for the duration.");
sender.sendMessage(clrDesc + "You should now use " + cmd + " fill confirm" + clrDesc + " to start the process.");
sender.sendMessage(clrDesc + "You can cancel at any time with " + cmd + " fill cancel" + clrDesc + ", or pause/unpause with " + cmd + " fill pause" + clrDesc + ".");

View File

@ -10,9 +10,6 @@ public class WorldBorder extends JavaPlugin
@Override
public void onEnable()
{
PluginDescriptionFile desc = this.getDescription();
System.out.println( desc.getName() + " version " + desc.getVersion() + " loading" );
// Load (or create new) config file
Config.load(this, false);
@ -30,8 +27,6 @@ public class WorldBorder extends JavaPlugin
@Override
public void onDisable()
{
PluginDescriptionFile desc = this.getDescription();
System.out.println( desc.getName() + " version " + desc.getVersion() + " shutting down" );
Config.StopBorderTimer();
Config.StoreFillTask();
Config.StopFillTask();

View File

@ -1,7 +1,7 @@
name: WorldBorder
author: Brettflan
description: Efficient, feature-rich plugin for limiting the size of your worlds.
version: 1.5.0
version: 1.5.1_dev
main: com.wimbli.WorldBorder.WorldBorder
softdepend:
- Essentials