Phytolizer / picross

My first game project! Based on the Japanese puzzle by the same name.
MIT License
4 stars 2 forks source link

Client will crash if prefs.txt does not exist #10

Closed WestonReed closed 7 years ago

WestonReed commented 7 years ago

If prefs.txt does not exit, the client will crash, but will create the file, so re-launching it will work.

prefs.txt does not exist! Creating... null Exception in thread "main" java.lang.NumberFormatException: For input string: "null" at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65) at java.lang.Integer.parseInt(Integer.java:580) at java.lang.Integer.parseInt(Integer.java:615) at picross.GameWindow.initControls(GameWindow.java:1510) at picross.GameWindow.<init>(GameWindow.java:158) at picross.Main.main(Main.java:54)

Phytolizer commented 7 years ago

Fixed as of f6de5021ce3a835fbd32c5a6b88b6bc53b8e0478. I had an unnecessary conditional in the controls restoring button.