Re: [stella] Climber5 source and binary

Subject: Re: [stella] Climber5 source and binary
From: "Andrew Davie" <atari2600@xxxxxxxxxxxxx>
Date: Fri, 18 Apr 2003 00:05:14 +1000
> And a potentional bug:
>    eor #$FE      ; make the number negative
> 
> This does only work for odd numbers!
>    1 eor $FE = $FF = -1
>    2 eor $FE = $FC = -4
>    3 eor $FE = $FD = -3

Two ways to make a number negative are...

    lda number
    eor #$FF
    clc
    adc #1

or

    sec
    lda #0
    sbc number

Cheers
A


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


Current Thread