Minor versioning changes

This commit is contained in:
Kenzie Togami
2019-05-05 01:37:11 -07:00
committed by NotMyFault
parent 55b02e1b1f
commit 8d68da09a3
3 changed files with 19 additions and 34 deletions

View File

@ -30,9 +30,12 @@ public class FaweVersion {
}
}
@Override
public String toString() {
return "FastAsyncWorldEdit-" + year + "." + month + "." + day + "-" + Integer.toHexString(hash) + "-" + build;
@Override public String toString() {
if (hash == 0 && build == 0) {
return "FastAsyncWorldEdit-1.13-NoVer-SNAPSHOT";
} else {
return "FastAsyncWorldEdit-1.13" + build;
}
}
public boolean isNewer(FaweVersion other) {

View File

@ -63,8 +63,8 @@ public class WorldEditCommands {
)
public void version(Actor actor) throws WorldEditException {
FaweVersion fVer = Fawe.get().getVersion();
String fVerStr = fVer == null ? "unknown" : fVer.year + "." + fVer.month + "." + fVer.day + "-" + Integer.toHexString(fVer.hash) + "-" + fVer.build;
actor.print(BBC.getPrefix() + "FastAsyncWorldEdit 1.13-" + fVerStr + " by Empire92");
String fVerStr = fVer == null ? "unknown" : "-" + fVer.build;
actor.print(BBC.getPrefix() + "FastAsyncWorldEdit-1.13" + fVerStr + " by Empire92");
if (fVer != null) {
actor.printDebug("------------------------------------");
FaweVersion version = Fawe.get().getVersion();
@ -78,7 +78,7 @@ public class WorldEditCommands {
PlatformManager pm = we.getPlatformManager();
actor.printDebug("Platforms:");
for (Platform platform : pm.getPlatforms()) {
actor.printDebug(String.format(" - %s (%s)", platform.getPlatformName(), platform.getVersion()));
actor.printDebug(String.format(" - %s", platform.getPlatformName()));
}
actor.printDebug("Capabilities:");
for (Capability capability : Capability.values()) {
@ -92,7 +92,7 @@ public class WorldEditCommands {
@Command(
aliases = {"reload"},
usage = "",
desc = "Reload configuration",
desc = "Reload configuration and translations",
min = 0,
max = 0
)
@ -102,7 +102,7 @@ public class WorldEditCommands {
we.getEventBus().post(new ConfigurationLoadEvent(we.getPlatformManager().queryCapability(Capability.CONFIGURATION).getConfiguration()));
Fawe.get().setupConfigs();
CommandManager.getInstance().register(we.getPlatformManager().queryCapability(Capability.USER_COMMANDS));
actor.print(BBC.getPrefix() + "Reloaded WorldEdit " + we.getVersion() + " and " + Fawe.get().getVersion() + "");
actor.print(BBC.getPrefix() + "Reloaded FastAsyncWorldEdit configuration and translation files");
}
@Command(