Reimplement spawn-if-no-home config option (#2757)

This reimplements the `spawn-if-no-home` config option from the original Essentials plugin. If set to true, running `/home` without having set a home will send the player to spawn (previous behaviour). If set to false, running `/home` will instead show an error message and not teleport the player anywhere.

Closes #1452.
This commit is contained in:
Glare 2019-10-20 03:12:53 -05:00 committed by md678685
parent f6a70a542e
commit 882699919e
4 changed files with 15 additions and 1 deletions

View file

@ -1624,4 +1624,9 @@ public class Settings implements net.ess3.api.ISettings {
public double getMaxProjectileSpeed() {
return maxProjectileSpeed;
}
@Override
public boolean isSpawnIfNoHome() {
return config.getBoolean("spawn-if-no-home", true);
}
}