| |
Credits :
Download :
Look for downloads on external sites:
Pokefinder.org
User Comment Submitted by Skate on 5 December 2012
congratulations! these are one of the most trickiest 12 bytes. :) | User Comment Submitted by Wisdom on 5 December 2012
Frantic, right, but then, you don't have to use X for indexing, and you can use Y instead (which has $01 as default value on startup, but I didn't check where it's coming from, it worked on all emus I have).
007C JSR $FFD2
007F SRE ($83),Y
0081 TXA
0082 SBC #$91
0084 BNE $007C
That makes it 12 bytes, as Skate suggested. Also that makes it very cooperatively written code, cheers guys.
| User Comment Submitted by Frantic on 5 December 2012
@Wisdom: There is no ROR (z,x) but there is SRE (z,x) which does A <- (M >> 1) \-/ A. If the value of A is thrown away anyway, with that TXA that Skate suggested, then the extra EOR stuff on the A register performed by SRE doesn't matter. The problem would rather be that you would have to do SBC #$91 instead of $92, due to different value in the A register than in your version, and then your trick of accessing $d012 through its mirror on $d092 wouldn't work any more... :) | User Comment Submitted by Wisdom on 5 December 2012
Also very nice trick, Skate. I don't think it is possible to merge two methods, due to unavailability of an (ZP,X) addressing mode for ROR. But something else can be thought, of course. Thank you for your contribution. | User Comment Submitted by Skate on 5 December 2012
13 bytes version has a very nice trick. but if we're going to assume x register to be $ff at the start up, there is an alternative method which i've used for random +-1 value switching before.
ror $d012
txa
adc #$6e
jsr $ffd2
bvc -
if we merge both methods (didn't try it myself), 12 bytes might be possible. just my 2 cents. | User Comment Submitted by Wisdom on 4 December 2012
Uploaded a screenshot from 11 byte (memmaze) version. If you wait around 45 seconds (until the program reaches $A000), this is what you see. Previously, I was lazy to upload a new screenshot, and just used the one from Thread Down. :-)
$FFD2 preserves input register values on exit, when output device is the screen. | User Comment Submitted by enthusi on 4 December 2012
The 11 byte version looks nothing like the screenshot though of course, depending on if you run it after powercycle :).
Isnt ffd2 even kinda setting X?
Anyway, nice one :) | User Comment Submitted by Wisdom on 4 December 2012
11 and 13 bytes versions of the original effect. Both versions have their own drawbacks; 13 bytes version expects X register to be $FF at startup (nevertheless, it worked on all emus I have tried), and 11 bytes version uses the data in memory for its output, instead of having a "random" input. |
|
|
|
| Search CSDb |
| Navigate | |
|
| Detailed Info | |
|
| Fun Stuff | |
· Goofs · Hidden Parts · Trivia
|
|
| Forum | |
|
| Info on other sites | |
|
| Support CSDb | |
|
| |
|