This commit is contained in:
Anuken
2021-07-15 11:25:35 -04:00
parent ae15d838f0
commit caf9ea38df
3 changed files with 8 additions and 9 deletions

View File

@@ -30,9 +30,8 @@ public class CrashSender{
} }
return report return report
+ "Version: " + Version.combined() + (Vars.headless ? " (Server)" : "") + "\n" + "Version: " + Version.combined() + (Vars.headless ? " (Server)" : "") + "\n"
+ "OS: " + System.getProperty("os.name") + " x" + (OS.is64Bit ? "64" : "32") + "\n" + "OS: " + OS.osName + " x" + (OS.osArchBits) + " (" + OS.osArch + ")\n"
+ "Java Version: " + System.getProperty("java.version") + "\n" + "Java Version: " + OS.javaVersion + "\n"
+ "Java Architecture: " + System.getProperty("sun.arch.data.model") + "\n"
+ (mods == null ? "<no mod init>" : mods.list().size + " Mods" + (mods.list().isEmpty() ? "" : ": " + mods.list().toString(", ", mod -> mod.name + ":" + mod.meta.version))) + (mods == null ? "<no mod init>" : mods.list().size + " Mods" + (mods.list().isEmpty() ? "" : ": " + mods.list().toString(", ", mod -> mod.name + ":" + mod.meta.version)))
+ "\n\n" + error; + "\n\n" + error;
} }
@@ -60,7 +59,7 @@ public class CrashSender{
}catch(Throwable ignored){} }catch(Throwable ignored){}
//don't create crash logs for custom builds, as it's expected //don't create crash logs for custom builds, as it's expected
if(Version.build == -1 || (System.getProperty("user.name").equals("anuke") && !"steam".equals(Version.modifier))){ if(Version.build == -1 || (OS.username.equals("anuke") && !"steam".equals(Version.modifier))){
ret(); ret();
} }
@@ -141,10 +140,10 @@ public class CrashSender{
ex(() -> value.addChild("server", new JsonValue(fs))); ex(() -> value.addChild("server", new JsonValue(fs)));
ex(() -> value.addChild("players", new JsonValue(Groups.player.size()))); ex(() -> value.addChild("players", new JsonValue(Groups.player.size())));
ex(() -> value.addChild("state", new JsonValue(Vars.state.getState().name()))); ex(() -> value.addChild("state", new JsonValue(Vars.state.getState().name())));
ex(() -> value.addChild("os", new JsonValue(System.getProperty("os.name") + "x" + (OS.is64Bit ? "64" : "32")))); ex(() -> value.addChild("os", new JsonValue(OS.osName + " x" + OS.osArchBits + " " + OS.osVersion)));
ex(() -> value.addChild("trace", new JsonValue(parseException(exception)))); ex(() -> value.addChild("trace", new JsonValue(parseException(exception))));
ex(() -> value.addChild("javaVersion", new JsonValue(System.getProperty("java.version")))); ex(() -> value.addChild("javaVersion", new JsonValue(OS.javaVersion)));
ex(() -> value.addChild("javaArch", new JsonValue(System.getProperty("sun.arch.data.model")))); ex(() -> value.addChild("javaArch", new JsonValue(OS.osArchBits)));
Log.info("Sending crash report."); Log.info("Sending crash report.");

View File

@@ -77,7 +77,7 @@ public class Links{
- [ ] **I have updated to the latest release (https://github.com/Anuken/Mindustry/releases) to make sure my issue has not been fixed.** - [ ] **I have updated to the latest release (https://github.com/Anuken/Mindustry/releases) to make sure my issue has not been fixed.**
- [ ] **I have searched the closed and open issues to make sure that this problem has not already been reported.** - [ ] **I have searched the closed and open issues to make sure that this problem has not already been reported.**
""", """,
OS.isAndroid ? "Android " + Core.app.getVersion() : (System.getProperty("os.name") + (OS.is64Bit ? " x64" : " x32")), OS.isAndroid ? "Android " + Core.app.getVersion() : (OS.osName + " x" + OS.osArchBits),
Version.combined(), Version.combined(),
Vars.mods.list().any() ? Vars.mods.list().select(LoadedMod::enabled).map(l -> l.meta.author + "/" + l.name + ":" + l.meta.version) : "none")); Vars.mods.list().any() ? Vars.mods.list().select(LoadedMod::enabled).map(l -> l.meta.author + "/" + l.name + ":" + l.meta.version) : "none"));
} }

View File

@@ -10,4 +10,4 @@ kapt.include.compile.classpath=false
kotlin.stdlib.default.dependency=false kotlin.stdlib.default.dependency=false
#needed for android compilation #needed for android compilation
android.useAndroidX=true android.useAndroidX=true
archash=fbdfa0307101b881e208f53666c1f4b7ebf0fe90 archash=f223b2a9d421d751209efedc615352257fb3773b