Re: [stella] Poker Solitaire/Squares build 025

Subject: Re: [stella] Poker Solitaire/Squares build 025
From: Erik Mooney <erik@xxxxxxxxxx>
Date: Sun, 16 Dec 2001 12:55:01 -0500
On Sun, 16 Dec 2001 11:41:04 -0500 (EST), you wrote:

>I'm doing tons of this already. The current hand of cards though, is
>25 bytes that can't be shared... and the remaining cards in the deck can't
>really be shared either (25 more bytes). Then there's 25 pointers into the
>card sprite data, which are generated every frame from the 25-byte hand.
>These can be overwritten during the overscan (which the scoring routine does),
>but they get regenerated every frame, so I can't store anything in there
>for long.

Hang about.  Who said you needed to store the remaining cards in the deck?
When you generate a card, simply generate it randomly from all 52
possibilities, then cycle through the current hand of cards and see if
it's already there; if so, generate another.  That'd also give you 100%
randomized card flow, instead of your not-always-random shuffling.  If it
takes too long to get a new card, you can always just white-out the screen
for a frame or two.

----------------------------------------------------------------------------------------------
Archives (includes files) at http://www.biglist.com/lists/stella/archives/
Unsub & more at http://www.biglist.com/lists/stella/


Current Thread