Jump to content

Yet Another... Sudoku Game


fisofo
 Share

Recommended Posts

Update Feb 8th, Version 1.0.1!

Well, I have not had the time I wanted to work on this, but I wanted to post progress that has been made thus far. jpm provided massive improvements to the GUI, so props to him, and this version is basically what he has added thus far.

I still plan to work on this project, but the _SplitMon is a bit higher priority for me right now, so please be patient :whistle: I have some ideas for solving algorithms and I'd like to clean up some of the code, but it's going to be a bit before I can really focus on this one.

Current Features/Details

  • Load/Save Functionality now exists!
  • Easy, Medium, Hard, and Insane puzzle levels to choose from
  • Very Nice GUI that jpm created from my measly one
  • Solves most puzzles given to it, new algorithms are in the works for Hard and Insane ones
  • A "Helper" will enumerate possibilities for you
  • Generates new puzzles by connecting to websudoku.com
  • Use Right/Left clicks on game board to do stuff
  • Check the INI file for a few more settings, including the Ratio = changes size of the board!
What's Next
  • A Timer / Overrall time spent on a puzzle/time loaded
  • Hinter - lists a cell where a solution is possible/solves a single cell rather than all
  • Ability to solve Hard and Insane puzzles (in progress, algorithms are in pseudo-code)
  • print the sudoku
Thanks for everyone's interest in this, It's going to be fun to develop it further!

EDIT: I have found some excellent open source sudoku solving algorithms (at http://www.sudoku.com) that I'd like to implement into AutoIt. They are written in Java and are complex, so if anyone would like to help out, I could really use someone that knows the java-speak and that can translate it into pseudo code. From there I should be able to handle it. Or if you want to translate it to au3, that's even better ;) Post here/PM me if interested.

UPDATE 4/27/07: This project is on hold until I hear of more interest or if I get more interested.

Pic Links are found here:

http://www.autoitscript.com/fileman/users/fisofo/GameGuess.JPG

http://www.autoitscript.com/fileman/users/fisofo/GameSelect.JPG

http://www.autoitscript.com/fileman/users/fisofo/GameSettings.JPG

http://www.autoitscript.com/fileman/users/fisofo/GameSolving.JPG

http://www.autoitscript.com/fileman/users/fisofo/Menu.JPG

(over 300 downloads previously)

Sudoko_It_v1.0.1.zip

Edited by fisofo
Link to comment
Share on other sites

Just glancing at the first picture you left, I noticed one mistake. I don't know how to fix it in the code, but here it is. In the very top and very bottom rows, 7 of the numbers are already complete. So in the top row, it must be a one and a nine in those two boxes of the middle section. This means that a one and a nine can't go in the second and third row of the middle section. This is the same problem with the bottom row. Since those numbers are still there I would assume that you didn't put that knowledge into the solve part. But I know what happens when people assume...

Link to comment
Share on other sites

Just glancing at the first picture you left, I noticed one mistake. I don't know how to fix it in the code, but here it is. In the very top and very bottom rows, 7 of the numbers are already complete. So in the top row, it must be a one and a nine in those two boxes of the middle section. This means that a one and a nine can't go in the second and third row of the middle section. This is the same problem with the bottom row. Since those numbers are still there I would assume that you didn't put that knowledge into the solve part. But I know what happens when people assume...

Hmmm... i'm not sure I quite follow you... I don't see how those would conflict??? Perhaps a bit later i'll load it up again and put that one in as a custom puzzle and take a look. But I've been looking at it too long this weekend :whistle:

Edit: keep in mind the puzzle posted is in the "insane" category, so they can be pretty complex, and my solver only fills in what it can for them at this level. Despite that, I've run a good 30 puzzles all the way through and it has not yet made a mistake, so it's probably fine. Give it a try and see what you think, i'd like to hear about actual use of the script!

Edited by fisofo
Link to comment
Share on other sites

  • 1 month later...

Hi fisofo !

( sorry all...my English very bad )

Your Sudoku-game very good ! But i want download to play offline.

But your game use cell-numbers of view.sudoku.com

Because,

When i download your game to play offline , game not run. ( except level Custom ).

Can you re-code this game,it can home-made cell-number or we provide to it a database cell-number ?

Can you help me ?

Thank you !

Link to comment
Share on other sites

  • 2 weeks later...

I saw some of the other Sudoku's posted, and although good, I thought I might take a stab at making my own. I did this primarily to learn more about Auto-It (GUI's specifically) and improve my coding. Please make recommendations! I'm constantly looking for ways to improve my code... and i'm betting this is still a bit messy :P

I borrowed the Main Game GUI from nfwu and updated it a bit, and I also grabbed the sweet progress bar that PsaltyDS made. Thanks guys!

Couple things about Sudoku-It:

-it doesn't generate it's own sudoku's (yet). Right now it connects to websudoku.com and loads a puzzle in depending on the selected difficulty. With that said, you can make your own Sudoku by clicking the "custom" button.

-Solving will work for easy's and medium's, and some of the hard. Insane is not yet solvable with the button :D If a puzzle is unsolvable, it will check it a few times and then exit the solving routine... just be patient.

-The "Check It" button just checks to see if all the squares are filled in, i'm hoping to make it a full checker once the solver is fully working.

-I'd love suggestions (preferably specific) on improvements to the code. Some of it is pretty messy still. Also ideas for the solver would be great as well. I actually have not inspected how the other Sudoku's went about this, I just started from scratch, so I may look into that.

Thoughts for Improvements, things I may add:

- Load/Save functionality

- A Timer.

- Hinter - lists a cell where a solution is possible/solves a single cell rather than all?

- Ability to solve Hard and Insane puzzles (in progress)

- improved GUI (I'm thinking of incorporating gafrosts colored buttons, perhaps make it easier for the disabled buttons to be seen)

- Still trying to figure this one out: disable the entire GUI window while it's solving to prevent issues with buttons being clicked?

- your ideas???

Thanks for taking a look!

fisofo .....

You have superb script ... but dont solve hard puzzles . Do you have uppdated version of your script ?

Link to comment
Share on other sites

fisofo .....

You have superb script ... but dont solve hard puzzles . Do you have uppdated version of your script ?

Wow... thanks for all the responses guys! I thought this one had bit the dust a while back :D As of right now, I don't have very much updated for this one, but I'm still hoping to add some of the functions I mentioned, particularly the save/load functions. As for solving harder puzzles... that's possible too, but kinda *ahem* hard :P

Thanks for the input though, I may just get motivated to continue this project!

Link to comment
Share on other sites

  • 2 weeks later...

Did you get it? :)

I've actually just started this project back up! Now that I've gotten my splitview project to a more completed state, I should be able to get this game further.

Thanks for the interest, I'll hopefully have an update by this weekend with some new stuff.

Link to comment
Share on other sites

  • 4 weeks later...

Hi my name is Carlos Martinez. New to Autoit, suduko and using this email screen. Hope this comment gets to fisofo

I got hooked in Dec 07 when my wife got me a suduko book. I then saw your Suduko-It program in Autoit. I have modified your program to suit my needs. Changed the 1st screen by adding change resolution 1024 or 800 buttons. Added a Load, save and update routing to the suduko screen. I now realize I should have asked you before I did the changes if it was alright. Would like to send you the updated sudkoit for you to check out and see if it would be OK to post it in this forum. I have given credit in the script to those whose routines I used. Carlos

Link to comment
Share on other sites

Hi my name is Carlos Martinez. New to Autoit, suduko and using this email screen. Hope this comment gets to fisofo

I got hooked in Dec 07 when my wife got me a suduko book. I then saw your Suduko-It program in Autoit. I have modified your program to suit my needs. Changed the 1st screen by adding change resolution 1024 or 800 buttons. Added a Load, save and update routing to the suduko screen. I now realize I should have asked you before I did the changes if it was alright. Would like to send you the updated sudkoit for you to check out and see if it would be OK to post it in this forum. I have given credit in the script to those whose routines I used. Carlos

No problem, I've actually received a hugely modified script from jpm as well that I was hoping to post soon that has a lot of GUI improvements. It's a pity I didn't know you were working on it, now it will take a lot more work to put the two together.

Did you want to post the script in this topic for further improvement, or start a new topic? I'd prefer it if you posted it here and then we can work on integrating a couple of the versions that are out there... would that be ok?

Let me know, you can also PM me if you want to discuss privately.

Link to comment
Share on other sites

Sorry to all who have been waiting for an update to this script... between being newly married, getting super busy at work and releasing some other projects I've been working on, this one got lost in the shuffle for a bit :whistle:

I hope to continue to develop this, but the three conditions I listed above have not changed, so please be patient with me.

Anyway, a new version has finally been posted, go check it out and enjoy!

Link to comment
Share on other sites

No problem, I've actually received a hugely modified script from jpm as well that I was hoping to post soon that has a lot of GUI improvements. It's a pity I didn't know you were working on it, now it will take a lot more work to put the two together.

Did you want to post the script in this topic for further improvement, or start a new topic? I'd prefer it if you posted it here and then we can work on integrating a couple of the versions that are out there... would that be ok?

Let me know, you can also PM me if you want to discuss privately.

I have not figured out how to attah a file. I used the help button but could not find any reference to attachment. I am used to Outlook and this system is entriely different. I would like to send you my updated file and you can chose to use or not. My email address is carlosmartinez1 at satx dot rr dot com. Thanks!

Carlos

Edited by JdeB
Link to comment
Share on other sites

fisofo

Hi, great script, i have tried to do something like this, but while trying i am almost has lost consciousness :whistle:

One remark:

-The size of gui is too big even for my 17 inch monitor :"> - Probably better to match the gui by macros @DesktopHeight and @DesktopWidth?

Anyway, big thanx for the script, now i have chance to learn how to do this, and now i am 100% sure that is really possible :) .

Edited by MsCreatoR

 

Spoiler

Using OS: Win 7 Professional, Using AutoIt Ver(s): 3.3.6.1 / 3.3.8.1

AutoIt_Rus_Community.png AutoIt Russian Community

My Work...

Spoiler

AutoIt_Icon_small.pngProjects: ATT - Application Translate Tool {new}| BlockIt - Block files & folders {new}| SIP - Selected Image Preview {new}| SISCABMAN - SciTE Abbreviations Manager {new}| AutoIt Path Switcher | AutoIt Menu for Opera! | YouTube Download Center! | Desktop Icons Restorator | Math Tasks | KeyBoard & Mouse Cleaner | CaptureIt - Capture Images Utility | CheckFileSize Program

AutoIt_Icon_small.pngUDFs: OnAutoItErrorRegister - Handle AutoIt critical errors {new}| AutoIt Syntax Highlight {new}| Opera Library! | Winamp Library | GetFolderToMenu | Custom_InputBox()! | _FileRun UDF | _CheckInput() UDF | _GUIInputSetOnlyNumbers() UDF | _FileGetValidName() UDF | _GUICtrlCreateRadioCBox UDF | _GuiCreateGrid() | _PathSplitByRegExp() | _GUICtrlListView_MoveItems - UDF | GUICtrlSetOnHover_UDF! | _ControlTab UDF! | _MouseSetOnEvent() UDF! | _ProcessListEx - UDF | GUICtrl_SetResizing - UDF! | Mod. for _IniString UDFs | _StringStripChars UDF | _ColorIsDarkShade UDF | _ColorConvertValue UDF | _GUICtrlTab_CoverBackground | CUI_App_UDF | _IncludeScripts UDF | _AutoIt3ExecuteCode | _DragList UDF | Mod. for _ListView_Progress | _ListView_SysLink | _GenerateRandomNumbers | _BlockInputEx | _IsPressedEx | OnAutoItExit Handler | _GUICtrlCreateTFLabel UDF | WinControlSetEvent UDF | Mod. for _DirGetSizeEx UDF
 
AutoIt_Icon_small.pngExamples: 
ScreenSaver Demo - Matrix included | Gui Drag Without pause the script | _WinAttach()! | Turn Off/On Monitor | ComboBox Handler Example | Mod. for "Thinking Box" | Cool "About" Box | TasksBar Imitation Demo

Like the Projects/UDFs/Examples? Please rate the topic (up-right corner of the post header: Rating AutoIt_Rating.gif)

* === My topics === *

==================================================
My_Userbar.gif
==================================================

 

 

 

AutoIt is simple, subtle, elegant. © AutoIt Team

Link to comment
Share on other sites

fisofo

Hi, great script, i have tried to do something like this, but while trying i am almost has lost consciousness :whistle:

One remark:

-The size of gui is too big even for my 17 inch monitor : - Probably better to match the gui by macros @DesktopHeight and @DesktopWidth?

Anyway, big thanx for the script, now i have chance to learn how to do this, and now i am 100% sure that is really possible :) .

@CarlosMartinez: I sent you an email, you may want to edit your post and remove your address now so that it does not get abused.

@MsCreatoR: It is indeed a bit of a beast to write :lol:

In regards to GUI size, go into the .ini file and make the "ratio" key smaller... this will in turn make the Sudoku board smaller.

I believe typical size range is 2 to 5.

Link to comment
Share on other sites

Thanks guys! When I first released this, I don't think it got much response, but I guess 300 downloads ain't bad :whistle:

But credit should be given where it's due, jpm did a fantastic job with the GUI, the only thing left from my version is the overall button layout and calculation... he basically doubled the code length too! :)

It'll be fun to start developing this again.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...