FORUMS

How to Lock and Protect Your Apps – XDA Xposed Tuesday

The smartphone revolution has passed. Everybody has mobile apps. Some of … more

Which OEM Would You Like to Help?

Most manufacturers have moments of greatness and moments of decadence, and in the past few years … more

Root T-Mobile S6/Edge on 5.1.1 Without Tripping Knox

If you purchase phones from a carrier, you may be no stranger to the difficulties … more

IonVR Coming Soon, HTC M9 Dev Edition Gets Android 5.1 – XDA TV

The HTC M9 Developer Edition has received Android 5.1. That and … more

[Game] Cribbage

1,020 posts
Thanks Meter: 88
 
By Mach2003, Senior Member on 9th July 2010, 07:56 AM
Post Reply Subscribe to Thread Email Thread
Major update posted today:

All paint routines re-done, nice felt graphic background (stolen from win7)
Help re-done, includes Menu, Help, Context to give help based on game play
Added Win7 card backs and faces, removed a couple of old winmo card backs
Using Win7 and Xp's card faces, instead of pegcards
Card size and text size better fits screen space (drag to size on PC).

Versions for WM2003, WM5, and WM6.5.3 included.
PC Versions for Win32 and Win64 included (msi in zip file)

New Cards SDK (soon to be) added to post number 6, includes new functions (see cards.h)


/*************/

A very long time ago I wrote a One person Crib game for Windows PC. I never really released it into the wild, but did pass it on to many people I knew (attached here as a zipped CribSetup.MSI file).

I decided to convert that code over to Windows mobile.

The first stumbling block was that windows mobile is missing the famous "cards(32).dll" file that I depended on to display the cards on the PC version. However the standard shell comes with a resource dll "pegcards.dll" that contains the card images, and may contain a higher resolution one as well (pegcards.192.dll, for example). So all I needed to do was emulate the cards.dll functions and use the pegcards images to get it to fly.

The attached WMCrib.exe (zipped) is the beta build of that game.
The attached CAB is an installer, that includes shortcuts and help file/link.
Post number 6, has the Cards32.dll for developers

- The PC version uses a right click to do many things, Tap the stock pile on the Mobile version to do the same functions ("Go", "Done"...).

- The existing application searches for pegcards.196.dll, Pegcards.128.dll, pegcards.96.dll and then pegcards.dll in that order, so chooses the highest resolution images available. I noticed that there are different card backs in each set I have here.

This is a beta build, I have tested it on my phone (and run it on my PC for many years), but you may have issues with your device, use at your own risk

Have Fun!
Attached Files
File Type: cab CribGame2003.CAB - [Click for QR Code] (1.03 MB, 69 views)
File Type: cab CribGame653.CAB - [Click for QR Code] (1.02 MB, 72 views)
File Type: cab CribGame5.CAB - [Click for QR Code] (1.03 MB, 50 views)
File Type: zip CribSetup32.zip - [Click for QR Code] (2.10 MB, 36 views)
File Type: zip CribSetup64.zip - [Click for QR Code] (2.10 MB, 25 views)
Last edited by Mach2003; 9th February 2012 at 01:06 AM. Reason: New!!!!!!
 
 
9th July 2010, 08:00 AM |#2  
Zepiii's Avatar
Retired Forum Moderator
Flag www.generation-mobiles.net
Thanks Meter: 14
 
Donate to Me
More
Maybe some screenshots ?
9th July 2010, 08:26 AM |#3  
Mach2003's Avatar
OP Senior Member
Flag Kelowna
Thanks Meter: 88
 
Donate to Me
More
A picture is worth a thousand words
Screens (wvga: OmniaII)
Attached Thumbnails
Click image for larger version

Name:	Crib1.JPG
Views:	732
Size:	24.7 KB
ID:	357202   Click image for larger version

Name:	Crib2.JPG
Views:	412
Size:	24.6 KB
ID:	357203   Click image for larger version

Name:	Crib3.JPG
Views:	295
Size:	23.0 KB
ID:	357204   Click image for larger version

Name:	Crib4.JPG
Views:	221
Size:	26.9 KB
ID:	357205   Click image for larger version

Name:	Crib5.JPG
Views:	202
Size:	19.8 KB
ID:	357206   Click image for larger version

Name:	CribSolitare.JPG
Views:	149
Size:	21.1 KB
ID:	357207   Click image for larger version

Name:	CribStats.JPG
Views:	149
Size:	27.8 KB
ID:	357208  
10th July 2010, 10:15 AM |#4  
Mach2003's Avatar
OP Senior Member
Flag Kelowna
Thanks Meter: 88
 
Donate to Me
More
Edited the first post, added a cab file with installer, links, and help files.
10th July 2010, 02:24 PM |#5  
the0ne's Avatar
Senior Member
Flag Melbourne
Thanks Meter: 52
 
More
looks nice
10th July 2010, 07:28 PM |#6  
Mach2003's Avatar
OP Senior Member
Flag Kelowna
Thanks Meter: 88
 
Donate to Me
More
Cards32.dll for developers
If you wish to include the standard cards32 functions plus a new extra functions, in your program, include cards.h in your project, and link with the correct cardsxx.lib.
On WinMo move the dll into the devices windows folder.
On PC, save the dll into the application's folder, or to the windows folder.

WATCH OUT that on XP or older there is an existing "Cards32.dll" in the windows folder. Mine should be fine to replace it, but I have not tested this on XP with original card based applications (Hearts, Solitare...). It should allow the "new" cards to be used on thse older XP card games (even when used on non-XP machines). You could even copy cards32.dll into the windows folder on 64 bit machines so that the XP card games will play on Win7 (or Vista)

The header file is well documented.

Cards32.dll for 32 bit desktop use
Cards64.dll for 64 bit desktop use
CardsWinMo2003 for older ARM machines, any ARM code machine will be fine.
CardsWinMo5, and Cards WinMo653 (should be identical , for any ARM THUMB machine
Attached Files
File Type: zip CardsSDK.zip - [Click for QR Code] (4.84 MB, 9 views)
Last edited by Mach2003; 9th February 2012 at 01:21 AM. Reason: New SDK
11th July 2010, 03:58 AM |#7  
thex's Avatar
Senior Member
Thanks Meter: 7
 
More
Can you add an option for us to add our own scores with a penalty of overcounting or under counting to go to the opponent?
11th July 2010, 04:09 AM |#8  
ai6908's Avatar
Senior Member
Flag Land of Lincoln
Thanks Meter: 268
 
Donate to Me
More
Excellent game...thanks...
11th July 2010, 05:51 AM |#9  
Mach2003's Avatar
OP Senior Member
Flag Kelowna
Thanks Meter: 88
 
Donate to Me
More
Quote:
Originally Posted by thex

Can you add an option for us to add our own scores with a penalty of overcounting or under counting to go to the opponent?

It could be done, and it would add another level of difficulty to the game. I'll look into it.
11th July 2010, 11:16 PM |#10  
Mach2003's Avatar
OP Senior Member
Flag Kelowna
Thanks Meter: 88
 
Donate to Me
More
Quote:
Originally Posted by thex

Can you add an option for us to add our own scores with a penalty of overcounting or under counting to go to the opponent?

A question to the order of adding the penalty points. If you enter a tally too small (or large), do you score your tally (or the correct tally), and THEN the computer gets your error points? Could affect the winner near the end of the game. Is this order dependant on who is counting first?
Post Reply Subscribe to Thread

Tags
cards.dll, crib, cribbage, wm game
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes