mirror of
https://github.com/BlueMap-Minecraft/BlueMap.git
synced 2024-11-25 12:05:13 +01:00
Small debug dump improvements
This commit is contained in:
parent
f66695acf6
commit
59bd00734c
@ -33,6 +33,7 @@
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
@DebugDump
|
||||
public class MinecraftVersion implements Comparable<MinecraftVersion> {
|
||||
|
||||
private static final Pattern VERSION_REGEX = Pattern.compile("(?:(?<major>\\d+)\\.(?<minor>\\d+))(?:\\.(?<patch>\\d+))?(?:\\-(?:pre|rc)\\d+)?");
|
||||
@ -41,10 +42,8 @@ public class MinecraftVersion implements Comparable<MinecraftVersion> {
|
||||
public static final MinecraftVersion EARLIEST_SUPPORTED = new MinecraftVersion(1, 12, 2);
|
||||
public static final MinecraftVersion THE_FLATTENING = new MinecraftVersion(1, 13);
|
||||
|
||||
@DebugDump
|
||||
private final int major, minor, patch;
|
||||
|
||||
@DebugDump
|
||||
private final Lazy<MinecraftResource> resource;
|
||||
|
||||
public MinecraftVersion(int major, int minor) {
|
||||
@ -142,6 +141,7 @@ public static MinecraftVersion of(String versionString) {
|
||||
return new MinecraftVersion(major, minor, patch);
|
||||
}
|
||||
|
||||
@DebugDump
|
||||
public enum MinecraftResource {
|
||||
|
||||
MC_1_12 (new MinecraftVersion(1, 12), "mc1_12", "https://launcher.mojang.com/v1/objects/0f275bc1547d01fa5f56ba34bdc87d981ee12daf/client.jar"),
|
||||
@ -152,9 +152,9 @@ public enum MinecraftResource {
|
||||
MC_1_16_2 (new MinecraftVersion(1, 16, 2), "mc1_16", "https://launcher.mojang.com/v1/objects/653e97a2d1d76f87653f02242d243cdee48a5144/client.jar"),
|
||||
MC_1_17 (new MinecraftVersion(1, 17), "mc1_16", "https://launcher.mojang.com/v1/objects/1cf89c77ed5e72401b869f66410934804f3d6f52/client.jar");
|
||||
|
||||
@DebugDump private final MinecraftVersion version;
|
||||
@DebugDump private final String resourcePrefix;
|
||||
@DebugDump private final String clientUrl;
|
||||
private final MinecraftVersion version;
|
||||
private final String resourcePrefix;
|
||||
private final String clientUrl;
|
||||
|
||||
MinecraftResource(MinecraftVersion version, String resourcePrefix, String clientUrl) {
|
||||
this.version = version;
|
||||
|
@ -30,14 +30,14 @@
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
|
||||
@DebugDump
|
||||
public class CoreConfig {
|
||||
|
||||
@DebugDump private boolean downloadAccepted = false;
|
||||
@DebugDump private int renderThreadCount = 0;
|
||||
@DebugDump private boolean metricsEnabled = false;
|
||||
@DebugDump private File dataFolder = new File("data");
|
||||
|
||||
|
||||
private boolean downloadAccepted = false;
|
||||
private int renderThreadCount = 0;
|
||||
private boolean metricsEnabled = false;
|
||||
private File dataFolder = new File("data");
|
||||
|
||||
public CoreConfig(ConfigurationNode node) throws IOException {
|
||||
|
||||
//accept-download
|
||||
|
@ -182,5 +182,15 @@ public boolean equals(Object obj) {
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "BmMap{" +
|
||||
"id='" + id + '\'' +
|
||||
", name='" + name + '\'' +
|
||||
", world=" + world +
|
||||
", fileRoot=" + fileRoot +
|
||||
'}';
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -422,5 +422,14 @@ public static Vector2i blockToChunk(Vector3i pos) {
|
||||
pos.getZ() >> 4
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "MCAWorld{" +
|
||||
"uuid=" + uuid +
|
||||
", worldFolder=" + worldFolder +
|
||||
", name='" + name + '\'' +
|
||||
'}';
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user