From 78825223415b0e9b9c48698b5c17b1eda81f4c96 Mon Sep 17 00:00:00 2001 From: GabrielXia Date: Thu, 2 Feb 2017 11:28:11 +0100 Subject: [PATCH 1/8] Rename CR button and put it under dev menu --- .../nui/layers/ingame/DevToolsMenuScreen.java | 3 +++ .../rendering/nui/layers/ingame/PauseMenu.java | 1 - .../src/main/resources/assets/i18n/menu_en.lang | 2 +- .../resources/assets/ui/ingame/pauseMenu.ui | 17 ----------------- .../assets/ui/menu/devToolsMenuScreen.ui | 5 +++++ 5 files changed, 9 insertions(+), 19 deletions(-) diff --git a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java index 529c8bc9a1e..b38eb738a90 100644 --- a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java +++ b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java @@ -16,6 +16,8 @@ package org.terasology.rendering.nui.layers.ingame; import org.terasology.assets.ResourceUrn; +import org.terasology.crashreporter.CrashReporter; +import org.terasology.engine.LoggingContext; import org.terasology.registry.In; import org.terasology.rendering.nui.CoreScreenLayer; import org.terasology.rendering.nui.WidgetUtil; @@ -36,6 +38,7 @@ public class DevToolsMenuScreen extends CoreScreenLayer { @Override public void initialise() { + WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("Report an error."), LoggingContext.getLoggingPath())); WidgetUtil.trySubscribe(this, "nuiEditor", button -> nuiEditorSystem.toggleEditor()); WidgetUtil.trySubscribe(this, "nuiSkinEditor", button -> nuiSkinEditorSystem.toggleEditor()); WidgetUtil.trySubscribe(this, "btEditor", button -> getManager().toggleScreen("engine:behaviorEditorScreen")); diff --git a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java index beca216aa6b..02492aeba39 100644 --- a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java +++ b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java @@ -33,7 +33,6 @@ public void initialise() { WidgetUtil.trySubscribe(this, "settings", widget -> getManager().pushScreen("settingsMenuScreen")); WidgetUtil.trySubscribe(this, "mainMenu", widget -> CoreRegistry.get(GameEngine.class).changeState(new StateMainMenu())); WidgetUtil.trySubscribe(this, "exit", widget -> CoreRegistry.get(GameEngine.class).shutdown()); - WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("Report an error."), LoggingContext.getLoggingPath())); WidgetUtil.trySubscribe(this, "devTools", widget -> getManager().pushScreen("devToolsMenuScreen")); } } diff --git a/engine/src/main/resources/assets/i18n/menu_en.lang b/engine/src/main/resources/assets/i18n/menu_en.lang index a901a147295..3a71a1f61e6 100644 --- a/engine/src/main/resources/assets/i18n/menu_en.lang +++ b/engine/src/main/resources/assets/i18n/menu_en.lang @@ -64,7 +64,7 @@ "connecting-to": "Connecting to", "connection-failed": "Connection Failed!", "could-not-connect-to-server": "Could not connect to server", - "crash-reporter": "Crash Reporter", + "crash-reporter": "Issue Reporter", "credits": "Credits", "create-game": "Create", "create-game-title": "Create Game", diff --git a/engine/src/main/resources/assets/ui/ingame/pauseMenu.ui b/engine/src/main/resources/assets/ui/ingame/pauseMenu.ui index 87064a85da1..27d0eac9897 100644 --- a/engine/src/main/resources/assets/ui/ingame/pauseMenu.ui +++ b/engine/src/main/resources/assets/ui/ingame/pauseMenu.ui @@ -68,23 +68,6 @@ "offset": 8 } } - }, - { - "type": "UIButton", - "id": "crashReporter", - "text": "${engine:menu#crash-reporter}", - "layoutInfo": { - "use-content-width": true, - "use-content-height": true, - "position-bottom": { - "offset": 8 - }, - "position-right": { - "offset": 8, - "target": "LEFT", - "widget": "devTools" - } - } } ] } diff --git a/engine/src/main/resources/assets/ui/menu/devToolsMenuScreen.ui b/engine/src/main/resources/assets/ui/menu/devToolsMenuScreen.ui index 37d2e6bfcd3..f54b811d4df 100644 --- a/engine/src/main/resources/assets/ui/menu/devToolsMenuScreen.ui +++ b/engine/src/main/resources/assets/ui/menu/devToolsMenuScreen.ui @@ -50,6 +50,11 @@ } }, "contents": [ + { + "type": "UIButton", + "id": "crashReporter", + "text": "${engine:menu#crash-reporter}" + }, { "type": "UIButton", "id": "nuiEditor", From 3fe7b959048bf0cc7b72f5712c116bc278849809 Mon Sep 17 00:00:00 2001 From: GabrielXia Date: Tue, 7 Feb 2017 21:35:06 +0100 Subject: [PATCH 2/8] Delete two import --- .../org/terasology/rendering/nui/layers/ingame/PauseMenu.java | 2 -- 1 file changed, 2 deletions(-) diff --git a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java index 02492aeba39..972cd1253df 100644 --- a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java +++ b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java @@ -15,9 +15,7 @@ */ package org.terasology.rendering.nui.layers.ingame; -import org.terasology.crashreporter.CrashReporter; import org.terasology.engine.GameEngine; -import org.terasology.engine.LoggingContext; import org.terasology.engine.modes.StateMainMenu; import org.terasology.registry.CoreRegistry; import org.terasology.rendering.nui.CoreScreenLayer; From 47571f90161386294a33e4e2c33b5f5a3990c12c Mon Sep 17 00:00:00 2001 From: GabrielXia Date: Thu, 9 Feb 2017 18:23:42 +0100 Subject: [PATCH 3/8] Add "boolean ifCritical" to CrashReporter in order that it can distinguish the real fatal crash or not --- .../rendering/nui/layers/ingame/DevToolsMenuScreen.java | 2 +- .../rendering/nui/layers/mainMenu/MainMenuScreen.java | 2 +- facades/PC/src/main/java/org/terasology/engine/Terasology.java | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java index b38eb738a90..f8546eaaef8 100644 --- a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java +++ b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java @@ -38,7 +38,7 @@ public class DevToolsMenuScreen extends CoreScreenLayer { @Override public void initialise() { - WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("Report an error."), LoggingContext.getLoggingPath())); + WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("Report an error."), LoggingContext.getLoggingPath(), false)); WidgetUtil.trySubscribe(this, "nuiEditor", button -> nuiEditorSystem.toggleEditor()); WidgetUtil.trySubscribe(this, "nuiSkinEditor", button -> nuiSkinEditorSystem.toggleEditor()); WidgetUtil.trySubscribe(this, "btEditor", button -> getManager().toggleScreen("engine:behaviorEditorScreen")); diff --git a/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java b/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java index 055eaa5fb47..81c434aae79 100644 --- a/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java +++ b/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java @@ -56,7 +56,7 @@ public void initialise() { WidgetUtil.trySubscribe(this, "settings", button -> triggerForwardAnimation(SettingsMenuScreen.ASSET_URI)); WidgetUtil.trySubscribe(this, "credits", button -> triggerForwardAnimation(CreditsScreen.ASSET_URI)); WidgetUtil.trySubscribe(this, "exit", button -> engine.shutdown()); - WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("Report an error."), LoggingContext.getLoggingPath())); + WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("Report a error."), LoggingContext.getLoggingPath(), false)); } @Override diff --git a/facades/PC/src/main/java/org/terasology/engine/Terasology.java b/facades/PC/src/main/java/org/terasology/engine/Terasology.java index f937bc7d105..a8ebff4cea4 100644 --- a/facades/PC/src/main/java/org/terasology/engine/Terasology.java +++ b/facades/PC/src/main/java/org/terasology/engine/Terasology.java @@ -380,7 +380,7 @@ private static void reportException(Throwable throwable) { Path logPath = LoggingContext.getLoggingPath(); if (!GraphicsEnvironment.isHeadless() && crashReportEnabled) { - CrashReporter.report(throwable, logPath); + CrashReporter.report(throwable, logPath, true); } else { throwable.printStackTrace(); System.err.println("For more details, see the log files in " + logPath.toAbsolutePath().normalize()); From 27949a61d698f7640d3efa09ba9072097378e792 Mon Sep 17 00:00:00 2001 From: GabrielXia Date: Fri, 10 Feb 2017 20:02:28 +0100 Subject: [PATCH 4/8] Change text and clarify "noCrashReport" --- .../rendering/nui/layers/ingame/DevToolsMenuScreen.java | 2 +- .../rendering/nui/layers/mainMenu/MainMenuScreen.java | 2 +- facades/PC/src/main/java/org/terasology/engine/Terasology.java | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java index f8546eaaef8..ae13fd55505 100644 --- a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java +++ b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java @@ -38,7 +38,7 @@ public class DevToolsMenuScreen extends CoreScreenLayer { @Override public void initialise() { - WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("Report an error."), LoggingContext.getLoggingPath(), false)); + WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("There is no error."), LoggingContext.getLoggingPath(), false)); WidgetUtil.trySubscribe(this, "nuiEditor", button -> nuiEditorSystem.toggleEditor()); WidgetUtil.trySubscribe(this, "nuiSkinEditor", button -> nuiSkinEditorSystem.toggleEditor()); WidgetUtil.trySubscribe(this, "btEditor", button -> getManager().toggleScreen("engine:behaviorEditorScreen")); diff --git a/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java b/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java index 81c434aae79..9e9f6f00b9a 100644 --- a/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java +++ b/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java @@ -56,7 +56,7 @@ public void initialise() { WidgetUtil.trySubscribe(this, "settings", button -> triggerForwardAnimation(SettingsMenuScreen.ASSET_URI)); WidgetUtil.trySubscribe(this, "credits", button -> triggerForwardAnimation(CreditsScreen.ASSET_URI)); WidgetUtil.trySubscribe(this, "exit", button -> engine.shutdown()); - WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("Report a error."), LoggingContext.getLoggingPath(), false)); + WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("There is no error."), LoggingContext.getLoggingPath(), false)); } @Override diff --git a/facades/PC/src/main/java/org/terasology/engine/Terasology.java b/facades/PC/src/main/java/org/terasology/engine/Terasology.java index a8ebff4cea4..27005978cc1 100644 --- a/facades/PC/src/main/java/org/terasology/engine/Terasology.java +++ b/facades/PC/src/main/java/org/terasology/engine/Terasology.java @@ -77,7 +77,7 @@ * -headlessStart headless. * -loadlastgameLoad the latest game on startup. * -noSaveGamesDisable writing of save games. - * -noCrashReportDisable crash reporting. + * -noCrashReportDisable crash reporting when having a crash. * -noSoundDisable sound. * -noSplashDisable splash screen. * -serverPort=xxxxxChange the server port. From 54ab3ffda5cada49057ae2b09b3a97e17475c267 Mon Sep 17 00:00:00 2001 From: GabrielXia Date: Sun, 12 Feb 2017 22:12:36 +0100 Subject: [PATCH 5/8] Change boolean to Severity --- .../rendering/nui/layers/ingame/DevToolsMenuScreen.java | 4 +++- .../rendering/nui/layers/mainMenu/MainMenuScreen.java | 4 +++- .../PC/src/main/java/org/terasology/engine/Terasology.java | 2 +- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java index ae13fd55505..eaaa7e600d1 100644 --- a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java +++ b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java @@ -24,6 +24,8 @@ import org.terasology.rendering.nui.editor.systems.NUIEditorSystem; import org.terasology.rendering.nui.editor.systems.NUISkinEditorSystem; +import javax.print.attribute.standard.Severity; + /** * */ @@ -38,7 +40,7 @@ public class DevToolsMenuScreen extends CoreScreenLayer { @Override public void initialise() { - WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("There is no error."), LoggingContext.getLoggingPath(), false)); + WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("There is no error."), LoggingContext.getLoggingPath(), Severity.REPORT)); WidgetUtil.trySubscribe(this, "nuiEditor", button -> nuiEditorSystem.toggleEditor()); WidgetUtil.trySubscribe(this, "nuiSkinEditor", button -> nuiSkinEditorSystem.toggleEditor()); WidgetUtil.trySubscribe(this, "btEditor", button -> getManager().toggleScreen("engine:behaviorEditorScreen")); diff --git a/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java b/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java index 9e9f6f00b9a..8b6788a1848 100644 --- a/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java +++ b/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java @@ -27,6 +27,8 @@ import org.terasology.rendering.nui.widgets.UILabel; import org.terasology.version.TerasologyVersion; +import javax.print.attribute.standard.Severity; + /** */ public class MainMenuScreen extends CoreScreenLayer { @@ -56,7 +58,7 @@ public void initialise() { WidgetUtil.trySubscribe(this, "settings", button -> triggerForwardAnimation(SettingsMenuScreen.ASSET_URI)); WidgetUtil.trySubscribe(this, "credits", button -> triggerForwardAnimation(CreditsScreen.ASSET_URI)); WidgetUtil.trySubscribe(this, "exit", button -> engine.shutdown()); - WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("There is no error."), LoggingContext.getLoggingPath(), false)); + WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("There is no error."), LoggingContext.getLoggingPath(), Severity.REPORT)); } @Override diff --git a/facades/PC/src/main/java/org/terasology/engine/Terasology.java b/facades/PC/src/main/java/org/terasology/engine/Terasology.java index 27005978cc1..dbe50fd0010 100644 --- a/facades/PC/src/main/java/org/terasology/engine/Terasology.java +++ b/facades/PC/src/main/java/org/terasology/engine/Terasology.java @@ -380,7 +380,7 @@ private static void reportException(Throwable throwable) { Path logPath = LoggingContext.getLoggingPath(); if (!GraphicsEnvironment.isHeadless() && crashReportEnabled) { - CrashReporter.report(throwable, logPath, true); + CrashReporter.report(throwable, logPath); } else { throwable.printStackTrace(); System.err.println("For more details, see the log files in " + logPath.toAbsolutePath().normalize()); From 147962063a8a802c2b92c7f1492c30dbbf57c469 Mon Sep 17 00:00:00 2001 From: GabrielXia Date: Mon, 13 Feb 2017 18:17:14 +0100 Subject: [PATCH 6/8] Move issue button to In game menu --- .../nui/layers/ingame/DevToolsMenuScreen.java | 5 ----- .../rendering/nui/layers/ingame/PauseMenu.java | 3 +++ .../nui/layers/mainMenu/MainMenuScreen.java | 4 +--- .../resources/assets/ui/ingame/pauseMenu.ui | 17 +++++++++++++++++ .../assets/ui/menu/devToolsMenuScreen.ui | 5 ----- .../java/org/terasology/engine/Terasology.java | 2 +- 6 files changed, 22 insertions(+), 14 deletions(-) diff --git a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java index eaaa7e600d1..529c8bc9a1e 100644 --- a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java +++ b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/DevToolsMenuScreen.java @@ -16,16 +16,12 @@ package org.terasology.rendering.nui.layers.ingame; import org.terasology.assets.ResourceUrn; -import org.terasology.crashreporter.CrashReporter; -import org.terasology.engine.LoggingContext; import org.terasology.registry.In; import org.terasology.rendering.nui.CoreScreenLayer; import org.terasology.rendering.nui.WidgetUtil; import org.terasology.rendering.nui.editor.systems.NUIEditorSystem; import org.terasology.rendering.nui.editor.systems.NUISkinEditorSystem; -import javax.print.attribute.standard.Severity; - /** * */ @@ -40,7 +36,6 @@ public class DevToolsMenuScreen extends CoreScreenLayer { @Override public void initialise() { - WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("There is no error."), LoggingContext.getLoggingPath(), Severity.REPORT)); WidgetUtil.trySubscribe(this, "nuiEditor", button -> nuiEditorSystem.toggleEditor()); WidgetUtil.trySubscribe(this, "nuiSkinEditor", button -> nuiSkinEditorSystem.toggleEditor()); WidgetUtil.trySubscribe(this, "btEditor", button -> getManager().toggleScreen("engine:behaviorEditorScreen")); diff --git a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java index 972cd1253df..a866497ea67 100644 --- a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java +++ b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java @@ -15,7 +15,9 @@ */ package org.terasology.rendering.nui.layers.ingame; +import org.terasology.crashreporter.CrashReporter; import org.terasology.engine.GameEngine; +import org.terasology.engine.LoggingContext; import org.terasology.engine.modes.StateMainMenu; import org.terasology.registry.CoreRegistry; import org.terasology.rendering.nui.CoreScreenLayer; @@ -32,5 +34,6 @@ public void initialise() { WidgetUtil.trySubscribe(this, "mainMenu", widget -> CoreRegistry.get(GameEngine.class).changeState(new StateMainMenu())); WidgetUtil.trySubscribe(this, "exit", widget -> CoreRegistry.get(GameEngine.class).shutdown()); WidgetUtil.trySubscribe(this, "devTools", widget -> getManager().pushScreen("devToolsMenuScreen")); + WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("There is no error."), LoggingContext.getLoggingPath(), CrashReporter.MODE.ISSUE_REPORTER)); } } diff --git a/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java b/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java index 8b6788a1848..55d0520ff6d 100644 --- a/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java +++ b/engine/src/main/java/org/terasology/rendering/nui/layers/mainMenu/MainMenuScreen.java @@ -27,8 +27,6 @@ import org.terasology.rendering.nui.widgets.UILabel; import org.terasology.version.TerasologyVersion; -import javax.print.attribute.standard.Severity; - /** */ public class MainMenuScreen extends CoreScreenLayer { @@ -58,7 +56,7 @@ public void initialise() { WidgetUtil.trySubscribe(this, "settings", button -> triggerForwardAnimation(SettingsMenuScreen.ASSET_URI)); WidgetUtil.trySubscribe(this, "credits", button -> triggerForwardAnimation(CreditsScreen.ASSET_URI)); WidgetUtil.trySubscribe(this, "exit", button -> engine.shutdown()); - WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("There is no error."), LoggingContext.getLoggingPath(), Severity.REPORT)); + WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("There is no error."), LoggingContext.getLoggingPath(), CrashReporter.MODE.ISSUE_REPORTER)); } @Override diff --git a/engine/src/main/resources/assets/ui/ingame/pauseMenu.ui b/engine/src/main/resources/assets/ui/ingame/pauseMenu.ui index 27d0eac9897..164086bdcd1 100644 --- a/engine/src/main/resources/assets/ui/ingame/pauseMenu.ui +++ b/engine/src/main/resources/assets/ui/ingame/pauseMenu.ui @@ -68,6 +68,23 @@ "offset": 8 } } + }, + { + "type": "UIButton", + "id": "crashReporter", + "text": "${engine:menu#crash-reporter}", + "layoutInfo": { + "use-content-width": true, + "use-content-height": true, + "position-bottom": { + "offset": 8 + }, + "position-right": { + "offset": 8, + "target": "LEFT", + "widget": "devTools" + } + } } ] } diff --git a/engine/src/main/resources/assets/ui/menu/devToolsMenuScreen.ui b/engine/src/main/resources/assets/ui/menu/devToolsMenuScreen.ui index f54b811d4df..37d2e6bfcd3 100644 --- a/engine/src/main/resources/assets/ui/menu/devToolsMenuScreen.ui +++ b/engine/src/main/resources/assets/ui/menu/devToolsMenuScreen.ui @@ -50,11 +50,6 @@ } }, "contents": [ - { - "type": "UIButton", - "id": "crashReporter", - "text": "${engine:menu#crash-reporter}" - }, { "type": "UIButton", "id": "nuiEditor", diff --git a/facades/PC/src/main/java/org/terasology/engine/Terasology.java b/facades/PC/src/main/java/org/terasology/engine/Terasology.java index dbe50fd0010..f937bc7d105 100644 --- a/facades/PC/src/main/java/org/terasology/engine/Terasology.java +++ b/facades/PC/src/main/java/org/terasology/engine/Terasology.java @@ -77,7 +77,7 @@ * -headlessStart headless. * -loadlastgameLoad the latest game on startup. * -noSaveGamesDisable writing of save games. - * -noCrashReportDisable crash reporting when having a crash. + * -noCrashReportDisable crash reporting. * -noSoundDisable sound. * -noSplashDisable splash screen. * -serverPort=xxxxxChange the server port. From 1f97db40651b8ec0e72ed1b94da12103525b094d Mon Sep 17 00:00:00 2001 From: GabrielXia Date: Mon, 13 Feb 2017 18:19:54 +0100 Subject: [PATCH 7/8] delete space --- engine/src/main/resources/assets/ui/ingame/pauseMenu.ui | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/engine/src/main/resources/assets/ui/ingame/pauseMenu.ui b/engine/src/main/resources/assets/ui/ingame/pauseMenu.ui index 164086bdcd1..87064a85da1 100644 --- a/engine/src/main/resources/assets/ui/ingame/pauseMenu.ui +++ b/engine/src/main/resources/assets/ui/ingame/pauseMenu.ui @@ -79,7 +79,7 @@ "position-bottom": { "offset": 8 }, - "position-right": { + "position-right": { "offset": 8, "target": "LEFT", "widget": "devTools" From 385544e5a304ce4573c68a3db57e879d2d0ab566 Mon Sep 17 00:00:00 2001 From: GabrielXia Date: Tue, 14 Mar 2017 00:35:23 +0100 Subject: [PATCH 8/8] Change a little order of the code --- .../org/terasology/rendering/nui/layers/ingame/PauseMenu.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java index a866497ea67..534761ce0ad 100644 --- a/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java +++ b/engine/src/main/java/org/terasology/rendering/nui/layers/ingame/PauseMenu.java @@ -33,7 +33,7 @@ public void initialise() { WidgetUtil.trySubscribe(this, "settings", widget -> getManager().pushScreen("settingsMenuScreen")); WidgetUtil.trySubscribe(this, "mainMenu", widget -> CoreRegistry.get(GameEngine.class).changeState(new StateMainMenu())); WidgetUtil.trySubscribe(this, "exit", widget -> CoreRegistry.get(GameEngine.class).shutdown()); - WidgetUtil.trySubscribe(this, "devTools", widget -> getManager().pushScreen("devToolsMenuScreen")); WidgetUtil.trySubscribe(this, "crashReporter", widget -> CrashReporter.report(new Throwable("There is no error."), LoggingContext.getLoggingPath(), CrashReporter.MODE.ISSUE_REPORTER)); + WidgetUtil.trySubscribe(this, "devTools", widget -> getManager().pushScreen("devToolsMenuScreen")); } }