Skip to content
Snippets Groups Projects
Commit 7a34dbbd authored by Aapeli Syrén's avatar Aapeli Syrén
Browse files

pieni lisäys

parent 2406936f
No related branches found
No related tags found
No related merge requests found
Pipeline #57495 passed
...@@ -9,8 +9,8 @@ import java.util.TimerTask; ...@@ -9,8 +9,8 @@ import java.util.TimerTask;
public class Main { public class Main {
public static void main(String[] args) { public static void main(String[] args) {
//Board board = new Board(40,20); //Board board = new Board(40,20);
int width = 6; int width = 100;
int height = 6; int height = 20;
final Board board = new Board(width,height); final Board board = new Board(width,height);
/** /**
* tämä on se muuttuja, joka sisältää tallennetut pelit paikallisesti * tämä on se muuttuja, joka sisältää tallennetut pelit paikallisesti
...@@ -45,7 +45,6 @@ public class Main { ...@@ -45,7 +45,6 @@ public class Main {
String input = scanner.nextLine(); String input = scanner.nextLine();
if (input.equals("lopeta")) { if (input.equals("lopeta")) {
timer.cancel();
break; break;
} }
else if (input.equals("uudestaan")) { else if (input.equals("uudestaan")) {
...@@ -114,6 +113,7 @@ public class Main { ...@@ -114,6 +113,7 @@ public class Main {
break; break;
} }
} }
timer.cancel();
scanner.close(); scanner.close();
} }
} }
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment