Post Reply 
Solitaire - Baker's Game
02-05-2014, 09:02 PM
Post: #7
RE: Solitaire - Baker's Game
Thank you everyone for your comments.

Hi Tugdual, I apologies for the somewhat brief help text but Jeff O. has done a great job to explaining the rules in more detail. Having played a similar version of the game on another platform I was too familiar with the game to explain it well on the first attempt. I'll try and expand the help to make it easier to understand.

Regarding the editor I used: the whole program was entered directly on the HP Prime itself. The arrow is the STO symbol (press the blue Shift key then the EEX key). I don't own a PC and had to borrow one to upload it to the net! I have managed to get a Raspberry Pi to run libhpcalcs since so I do now have a way of getting code off the Prime albeit in a somewhat convoluted way. Roll on Mac connectivity that's what I say.

Hi Jeff O., pause and resume sounds a great idea. When I get some time I'll add that for you. It should be pretty easy.

I also thought about adding a sample game that can be easily played to get the hang of it. Until I get around to that my recommendation is to use the Menu key and Deal again until you have some Aces near the bottom of the main deck and few of the low numbers near the top.

If you like playing in the code, make a copy of the program then

1) go into the SOL_BG function and comment out the line Shuffle()->deck;
2) un-comment the line REVERSE(NewDeck())->deck;
3) Start the game and press the A (for Auto) key.
4) Sit back and watch the game play itself.

I wrote this as an education for me, to show what the calculator can do and for other people to look at the code. Unfortunately typing the code direct into the calculator is quite tedious so I ended up barely commenting the code. I do have quite a few paper notes that I may turn into comments in the code to explain the outline, but it will end up making the code pretty big. I should also get rid of all the magic numbers lying about the code now I see from other people's code that constants can be put in without filling up the variable menu. It's currently not a great example of self-documenting code.

If Tim can suggest why the calculator sometimes turns off when the game ends, that would be great ;-)
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
Solitaire - Baker's Game - Mark Power - 01-09-2014, 08:58 PM
RE: Solitaire - Baker's Game - Tugdual - 02-03-2014, 09:41 PM
RE: Solitaire - Baker's Game - Jeff O. - 02-04-2014, 02:17 PM
RE: Solitaire - Baker's Game - Tim Wessman - 02-04-2014, 09:39 PM
RE: Solitaire - Baker's Game - Tugdual - 02-04-2014, 09:55 PM
RE: Solitaire - Baker's Game - Tim Wessman - 02-04-2014, 10:14 PM
RE: Solitaire - Baker's Game - Mark Power - 02-05-2014 09:02 PM
RE: Solitaire - Baker's Game - eried - 02-06-2014, 06:38 AM
RE: Solitaire - Baker's Game - debrouxl - 02-07-2014, 07:37 AM
RE: Solitaire - Baker's Game - Mark Power - 03-11-2014, 09:58 PM
RE: Solitaire - Baker's Game - Jeff O. - 03-12-2014, 01:40 PM
RE: Solitaire - Baker's Game - Mark Power - 06-10-2014, 07:35 PM
RE: Solitaire - Baker's Game - Mark Power - 03-15-2015, 07:22 PM
RE: Solitaire - Baker's Game - Mark Power - 02-12-2018, 10:24 PM



User(s) browsing this thread: 1 Guest(s)