mirror of
https://github.com/EssentialsX/Essentials.git
synced 2025-02-27 01:32:11 +01:00
Give actually helpful error message for attempts to load on 1.7
This commit is contained in:
parent
5e605f992a
commit
480055b3d7
@ -136,6 +136,15 @@ public class Essentials extends JavaPlugin implements net.ess3.api.IEssentials {
|
|||||||
@Override
|
@Override
|
||||||
public void onEnable() {
|
public void onEnable() {
|
||||||
try {
|
try {
|
||||||
|
String serverString = Bukkit.getServer().getClass().getName();
|
||||||
|
for (int i = 1; i <= 7; i++) {
|
||||||
|
if (serverString.contains(".v1_" + i + "_R")) {
|
||||||
|
throw new Error("Outdated server. This version of Essentials will only work on Bukkit 1.8 or higher.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (serverString.contains(".v1_8_R1.")) {
|
||||||
|
getLogger().warning("Detected Bukkit 1.8.0. Spawners will not work properly until you upgrade to 1.8.3 or higher.");
|
||||||
|
}
|
||||||
LOGGER.setParent(this.getLogger());
|
LOGGER.setParent(this.getLogger());
|
||||||
execTimer = new ExecuteTimer();
|
execTimer = new ExecuteTimer();
|
||||||
execTimer.start();
|
execTimer.start();
|
||||||
|
Loading…
Reference in New Issue
Block a user