mirror of
https://github.com/Brettflan/WorldBorder.git
synced 2025-01-23 16:01:23 +01:00
Fix for Fill command potentially running on wrong world if specified by player with "fill confirm" command not specifying world
This commit is contained in:
parent
b074a34ee3
commit
0eec9a007a
@ -613,7 +613,7 @@ public class WBCommand implements CommandExecutor
|
||||
pad = split[2];
|
||||
|
||||
String world = "";
|
||||
if (player != null)
|
||||
if (player != null && !cancel && !confirm && !pause)
|
||||
world = player.getWorld().getName();
|
||||
|
||||
if (!cancel && !confirm && !pause && world.isEmpty())
|
||||
@ -949,7 +949,7 @@ public class WBCommand implements CommandExecutor
|
||||
{
|
||||
int task = plugin.getServer().getScheduler().scheduleSyncRepeatingTask(plugin, Config.fillTask, ticks, ticks);
|
||||
Config.fillTask.setTaskID(task);
|
||||
sender.sendMessage("WorldBorder map generation task started.");
|
||||
sender.sendMessage("WorldBorder map generation for world \"" + fillWorld + "\" task started.");
|
||||
}
|
||||
else
|
||||
sender.sendMessage(clrErr + "The world map generation task failed to start.");
|
||||
@ -1053,7 +1053,7 @@ public class WBCommand implements CommandExecutor
|
||||
{
|
||||
int task = plugin.getServer().getScheduler().scheduleSyncRepeatingTask(plugin, Config.trimTask, ticks, ticks);
|
||||
Config.trimTask.setTaskID(task);
|
||||
sender.sendMessage("WorldBorder map trimming task started.");
|
||||
sender.sendMessage("WorldBorder map trimming task for world \"" + trimWorld + "\" started.");
|
||||
}
|
||||
else
|
||||
sender.sendMessage(clrErr + "The world map trimming task failed to start.");
|
||||
|
@ -328,7 +328,6 @@ public class WorldFillTask implements Runnable
|
||||
if (!originalChunks.contains(coord))
|
||||
world.unloadChunkRequest(coord.x, coord.z);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// is this task still valid/workable?
|
||||
|
Loading…
Reference in New Issue
Block a user