mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-12-23 01:37:37 +00:00
Change some platform related messages.
This commit is contained in:
parent
f068a7491f
commit
a954e87e8c
@ -19,9 +19,7 @@
|
|||||||
|
|
||||||
package com.sk89q.worldedit.bukkit.adapter;
|
package com.sk89q.worldedit.bukkit.adapter;
|
||||||
|
|
||||||
import com.sk89q.worldedit.WorldEdit;
|
|
||||||
import com.sk89q.worldedit.util.io.Closer;
|
import com.sk89q.worldedit.util.io.Closer;
|
||||||
import org.bukkit.Bukkit;
|
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
@ -49,24 +47,15 @@ public class BukkitImplLoader {
|
|||||||
private static final String CLASS_SUFFIX = ".class";
|
private static final String CLASS_SUFFIX = ".class";
|
||||||
|
|
||||||
private static final String LOAD_ERROR_MESSAGE =
|
private static final String LOAD_ERROR_MESSAGE =
|
||||||
"Failed to find an adapter for Bukkit!\n\n" +
|
"\n**********************************************\n" +
|
||||||
"This version of WorldEdit (%s) does not fully support your version of Bukkit (%s).\n\n" +
|
"** This WorldEdit version does not fully support your version of Bukkit.\n" +
|
||||||
"What this means:\n" +
|
"**\n" +
|
||||||
"1) Block operations will work, but chests will be empty, signs will be blank, and so on.\n" +
|
"** When working with blocks or undoing, chests will be empty, signs\n" +
|
||||||
"2) You won't be able to save and load chests, signs, etc. with .schematic files.\n" +
|
"** will be blank, and so on. There will be no support for entity\n" +
|
||||||
"3) You won't be able to work with entities properly.\n" +
|
"** and biome-related functions.\n" +
|
||||||
"4) Undo will will not be able to restore chests, signs, and etc.\n\n" +
|
"**\n" +
|
||||||
"Possible solutions:\n" +
|
"** Please see http://wiki.sk89q.com/wiki/WorldEdit/Bukkit_adapters\n" +
|
||||||
"1) If this is a new version of Minecraft, please wait for us to update. " +
|
"**********************************************\n";
|
||||||
"You can also put in a ticket at http://youtrack.sk89q.com (check for an existing ticket first).\n" +
|
|
||||||
"2) If you are using an older version of Minecraft, you may need to downgrade WorldEdit.\n" +
|
|
||||||
"3) If you are using an older version of WorldEdit, you may need to update your WorldEdit.\n" +
|
|
||||||
"4) If you are not using CraftBukkit, then report this issue to http://youtrack.sk89q.com " +
|
|
||||||
"(check for an existing ticket first).\n" +
|
|
||||||
"5) If you are developing WorldEdit, you can force an adapter with " +
|
|
||||||
"-Dworldedit.bukkit.adapter=the_class_name.\n\n" +
|
|
||||||
"Can I ignore this error? Yes! Just be aware of the undo issue.\n" +
|
|
||||||
"Am I using CraftBukkit? %s.\n";
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Create a new instance.
|
* Create a new instance.
|
||||||
@ -183,15 +172,7 @@ public class BukkitImplLoader {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
String weVersion = WorldEdit.getVersion();
|
throw new AdapterLoadException(LOAD_ERROR_MESSAGE);
|
||||||
String bukkitVersion = Bukkit.getBukkitVersion() + " implemented by " + Bukkit.getName() + " " + Bukkit.getVersion();
|
|
||||||
String usingCraftBukkit =
|
|
||||||
Bukkit.getName().equals("CraftBukkit")
|
|
||||||
? "Probably (if you got it from dl.bukkit.org, then yes)"
|
|
||||||
: "No! You are using " + Bukkit.getName();
|
|
||||||
|
|
||||||
throw new AdapterLoadException(
|
|
||||||
String.format(LOAD_ERROR_MESSAGE, weVersion, bukkitVersion, usingCraftBukkit));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -88,19 +88,9 @@ public class PlatformManager {
|
|||||||
// Make sure that versions are in sync
|
// Make sure that versions are in sync
|
||||||
if (firstSeenVersion != null) {
|
if (firstSeenVersion != null) {
|
||||||
if (!firstSeenVersion.equals(platform.getVersion())) {
|
if (!firstSeenVersion.equals(platform.getVersion())) {
|
||||||
logger.log(Level.WARNING,
|
logger.log(Level.WARNING, "Multiple ports of WorldEdit are installed but they report different versions ({0} and {1}). " +
|
||||||
"\n**********************************************\n" +
|
"If these two versions are truly different, then you may run into unexpected crashes and errors.",
|
||||||
"** You have WorldEdit installed for multiple platforms in the same \n" +
|
new Object[]{ firstSeenVersion, platform.getVersion() });
|
||||||
"** game/program. This is OK except that you have different WorldEdit versions\n" +
|
|
||||||
"** installed (i.e. {0} and {1}).\n" +
|
|
||||||
"**\n" +
|
|
||||||
"** WorldEdit has seen both versions {0} and {1}.\n" +
|
|
||||||
"**\n" +
|
|
||||||
"** Things may break! Please make sure that your WE versions are in sync.\n" +
|
|
||||||
"**********************************************\n",
|
|
||||||
new Object[]{
|
|
||||||
firstSeenVersion, platform.getVersion()
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
firstSeenVersion = platform.getVersion();
|
firstSeenVersion = platform.getVersion();
|
||||||
|
Loading…
Reference in New Issue
Block a user