Alright, so I’m finally getting around to making a little more progress on my sudoku game. so I figured I would post a few screenshots and show my progress and discuss what’s left on my todo list. First of all, here is what I started out with:
This is an image of the program nsudoku which I shamelessly open-sourced from the AUR. I figured nsudoku would be perfect for this exercise in learning ncurses because it already is a perfectly functional sudoku puzzle creator, meaning I don’t have to reinvent the wheel too much. After playing around with nsudoku for a little while, it wasn’t long before I found a laundry list of things I thought needed tweaked and improved on it and I decided to get to hacking. First of all, I can’t stand the color, or that the user is locked into only one color scheme. one of my goals is to implement a feature (whether it be via command line arguments or a menu) that allows the user to specify a variety of color schemes to make things a little easier on the eyes. Another goal that I have in mind is to implement a game clock/best time feature. Basically I want a small clock displayed during the puzzle that keeps track of the amount of time the user spends on the puzzle, and then records this value and the difficulty level to a “best times” file which is displayed at the end of each game. Those are the two major additions I’ve been considering and haven’t quite had the time for yet. Of the progress I’ve made, however, I’ve managed to create a much better looking grid around the puzzle and I’ve also added ‘vim style’ key bindings for cursor movement:
I’ve also created a much more elegant solution to the difficulty selection. In the original nsudoku, the program had to be started with an integer argument between 1 and 80 equal to the number of cells the user wanted to have given initially. I didn’t really like this and decided instead to have a “choose difficulty” menu open at the start of the program, allowing the user to choose from 5 difficulty levels, each level randomly choosing an integer initial value within a small range just to add a little suprise.
here’s what I have so far for the difficulty selection menu:
So far it’s pretty basic, and I still need to implement colors, but for now I think this will work quite nicely.
I think that’s about it for my progress update on Doku, It’s going to be slow going over the next couple of weeks, I’ve got a new addition to the family who is taking up quite a bit of my free time lately, however, I should still be able to find some time to get through this project by the end of summer.