Re: [stella] behold, i am become shiva, destroyer of kernals!

Subject: Re: [stella] behold, i am become shiva, destroyer of kernals!
From: KirkIsrael@xxxxxxxxxxxxx
Date: 12 Mar 2004 04:12:58 -0000
> What does this code do (specifically all the LSR's):

It provides a countdown timer....3,2,1
varTimeBeforeBallMoves starts at (3 * 32)...
5 lsr's divide by 32, rounding down, which means
the accumulator is set to 2 then 1 then 0.
3 asls then multiply by eight, and each frame of 
the score is 8 rows, so I use it as an offset.
(and you can't just divide by 4, then you get 
a speedometer scrolly effect)

(When it's 0, it's a one time event to choose 
a "random" ball trajectory and reset Pterry to 
its Pterry and not countdown position. From then
on it's minus, or 255, and we go straight to the 
usual Pterry flapping around code.)

The code you suggested just freezes on 1.
You were right about the gratuitous tay though,
musta been an artifact of when I was figuring out 
how to do stuff (I do some moderately clever 
manipulations with X register, grabbing the divided 
value at one (experimentally determined) point, 
AND mask it so it's just the...luminance? I guess,
then ORing it into the "orangey" color range so it matches 
the color range pterry and the ball end up at,
and also or'ing the right most bit so it's never
quite black.  I think the end result is pretty nice,
and the 3 2 1 countdown adds to the perceived quality
of the game.)

Thanks for looking at this.
I feel like I'm debugging in a minefield. Though I don't know
if a physical cart will act more like Z26 or more like a 
supercharger...but Something Is Still Wrong, and I'd be 
best friend in the whole world of anyone who can explain 
how I was munging the kernal so badly, with your analysis 
making it look like a bajillion CMPs were just giving 
errnoneous results.

"Power corrupts.  Absolute power is kind of neat."
        --John Lehman, secretary of the navy 1981-1987

Archives (includes files) at
Unsub & more at

Current Thread