[stella] Question about Circus Atari and BCD addition
Dennis Debro
dennis at debrofamily.com
Wed Jun 20 08:42:10 CDT 2007
Hi Andrew,
> http://forum.6502.org/viewtopic.php?start=15&t=778
> Sounds like a bug to me.
It does to me too but when I run it through the debugger in Stella the
addition comes out correct. Also running the game on a real console the
score display never shows this bug.
If you look at $f1a4 $B1 (what I'm calling totalBalloonPoints) is moved to
the accumulator and then it does a jsr to the IncrementScore routine.
IncrementScore
sed
clc
adc currentPlayerScore+1
sta currentPlayerScore+1
lda currentPlayerScore
adc #0
sta currentPlayerScore
cld
rts
When the addition is done, even if the accumulator holds #$0A, the value
is increased by $10 BCD. If I hack the game to make the point value $10
instead of $0A and run this same routine, again the score is incremented
by $10 BCD. Am I missing something?
Take care,
Dennis
More information about the Stella
mailing list