From afc117474281fd2f5ce5a90fd82329a57a79d803 Mon Sep 17 00:00:00 2001 From: Freddy Cansick Date: Fri, 18 Feb 2022 12:53:28 +0000 Subject: [PATCH] Added exit message --- core/src/com/tsp/Main.java | 3 ++- desktop/src/com/tsp/desktop/DesktopLauncher.java | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/core/src/com/tsp/Main.java b/core/src/com/tsp/Main.java index 4d55200..8fbad19 100644 --- a/core/src/com/tsp/Main.java +++ b/core/src/com/tsp/Main.java @@ -98,7 +98,8 @@ public void render () { // turn on anti aliasing if (edges[0] == -1) { // if a full rotation was made without any swaps occurring System.out.println("-------------------------------------------" + "\nLOCAL MINIMUM FOUND." + - "\n-------------------------------------------"); + "\n-------------------------------------------" + + "\nCTRL+C to exit."); running = false; return; } diff --git a/desktop/src/com/tsp/desktop/DesktopLauncher.java b/desktop/src/com/tsp/desktop/DesktopLauncher.java index 15ab946..f834808 100644 --- a/desktop/src/com/tsp/desktop/DesktopLauncher.java +++ b/desktop/src/com/tsp/desktop/DesktopLauncher.java @@ -14,7 +14,7 @@ public static void main (String[] arg) { config.title = "Travelling Salesman"; config.initialBackgroundColor = Color.WHITE; config.samples = 3; // anti aliasing - config.forceExit = true; + config.forceExit = false; config.resizable = false; config.addIcon("icon_128.png", FileType.Internal); config.addIcon("icon_32.png", FileType.Internal);