ogarcia / opensudoku

Open Source Sudoku game for Android.
GNU General Public License v3.0
328 stars 144 forks source link

Provide documentation on how to create new puzzles #3

Closed reibuehl closed 7 years ago

reibuehl commented 7 years ago

The readme says that new puzzles can be generated using gnome-sudoku, but there seems to be no documentation on how to do this - neither here nor in gnome-sudoku. As gnome-sudoku does not provide any obvious export functionality, can you please provide a short description on how to create new puzzles in the right format?

ogarcia commented 7 years ago

Hi @reibuehl

Te files are generated by old versions of Gnome Sudoku.

But the format is very easy to undestand. Simply is the numbers of sudoku board in one line, the zero is no number.

For example in first game data line of easy file you can see:

<game data="379000014060010070080009005435007000090040020000800436900700080040080050850000249" />

That is this board:

379 000 014
060 010 070
080 009 005

435 007 000
090 040 020
000 800 436

900 700 080
040 080 050
850 000 249

You can use any sudoku generator to make new boards and create new files.

reibuehl commented 7 years ago

I still think this should be clearer documented or an alternative should be provided to get more puzzles. I created a Perl script which uses www.websudoku.com to fetch a selectable number of puzzles and converts them into a XML usable for import. The logic is fairly simple and maybe could be integrated in the app? You can find the script here: https://github.com/reibuehl/SudokuFetch Feel free to integrate it if you see use.

ogarcia commented 7 years ago

Hi @reibuehl

I do small modification into Open Sudoku webpage and add a sudoku generator. The js generators are not the fastest ones, but it works.

Greetings.

bebehei commented 6 years ago

@ogarcia Is there a possibility to generate new "Very Hard" sudokus on the website? There's only the single pregenerated one, and I finished all those :sob:

ogarcia commented 6 years ago

@bebehei Done