Option to load chunk before /f wild teleport.
This commit is contained in:
parent
861f88a916
commit
f8421c09cf
@ -423,6 +423,8 @@ public class Conf {
|
|||||||
public static HashMap<String, DefaultPermissions> defaultFactionPermissions = new HashMap<>();
|
public static HashMap<String, DefaultPermissions> defaultFactionPermissions = new HashMap<>();
|
||||||
public static HashSet<PermissableAction> lockedPermissions = new HashSet<>();
|
public static HashSet<PermissableAction> lockedPermissions = new HashSet<>();
|
||||||
|
|
||||||
|
public static boolean wildLoadChunkBeforeTeleport = true;
|
||||||
|
|
||||||
private static transient Conf i = new Conf();
|
private static transient Conf i = new Conf();
|
||||||
|
|
||||||
static {
|
static {
|
||||||
|
@ -1,10 +1,7 @@
|
|||||||
package com.massivecraft.factions.cmd.wild;
|
package com.massivecraft.factions.cmd.wild;
|
||||||
|
|
||||||
|
|
||||||
import com.massivecraft.factions.Board;
|
import com.massivecraft.factions.*;
|
||||||
import com.massivecraft.factions.FLocation;
|
|
||||||
import com.massivecraft.factions.FPlayers;
|
|
||||||
import com.massivecraft.factions.FactionsPlugin;
|
|
||||||
import com.massivecraft.factions.cmd.Aliases;
|
import com.massivecraft.factions.cmd.Aliases;
|
||||||
import com.massivecraft.factions.cmd.CommandContext;
|
import com.massivecraft.factions.cmd.CommandContext;
|
||||||
import com.massivecraft.factions.cmd.CommandRequirements;
|
import com.massivecraft.factions.cmd.CommandRequirements;
|
||||||
@ -65,6 +62,7 @@ public class CmdWild extends FCommand implements WaitedTask {
|
|||||||
p.sendMessage(TL.GENERIC_NOTENOUGHMONEY.toString());
|
p.sendMessage(TL.GENERIC_NOTENOUGHMONEY.toString());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (Conf.wildLoadChunkBeforeTeleport && !loc.getChunk().isLoaded()) loc.getChunk().load();
|
||||||
teleportPlayer(p, loc);
|
teleportPlayer(p, loc);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user