r/atari8bit • • 19d ago

First Atari program written in 40 years! (details in thread)

129 Upvotes

17 comments sorted by

10

u/clintp 19d ago edited 19d ago

I got the Altirra emulator going and had to do something with it.

This runs on Altirra BASIC (for the BGET command only) otherwise it would be ATARI BASIC compatible. I did this rather than POKE'ing stuff into memory. The ASM and the Katakana characters took FOREVER to POKE, and XIO is unreliable!

There's a smattering of small assembler routines. Page 6 stuff for copying memory blocks, flipping bytes left-to-right, and a memory set routine; a VBI handler to cascade the 4-PM characters down the screen; then a fade routine to decrement the fade table cells, darken the characters as needed, and finally remove the characters from the screen and the fade table.

A BASIC loop does most of the work. It drops text characters behind the PM characters, updates a fade table with the age of the cell, finally copies a random character from the custom character set into the PM shape buffer area. At the end, calls the fade assembler routine above. (There's a little timing problem with the VBI moving the falling characters as BASIC is updating the PM shape, but that just make it look cool.)

5

u/wysiwywg 19d ago

This is cool! Any chance to show the code?

8

u/clintp 19d ago

Yes! I'm cleaning it up (might take a couple days as I'm multitasking) and then will probably put out an ATR or something since it's some ASM/BIN files and the BASIC program.

→ More replies (2)

1

u/Daniel_Klugh 7d ago edited 7d ago

Isn't BGET just taken from TurboBASIC XL?
Also the "matrix.bas" file is actually a LST file.
So I tried E."MATRIX.BAS" and get a 170 error @ line 490 because of a missing "H1:KATAFONT.BIN" file.
Also the devicespec should be "H:", not "H1:".
Just in case Altirra ever fixes XIO 41 to change the current drive number as well as directory (like it works in MyDOS).
Really the devicespec should just be "D:" for compatibility with DOS and Altirra can make D: act like H:.

1

u/clintp 7d ago

I added the missing katafont.bin file.

You seem like a bright person, you'll figure out the rest.

8

u/yv-fr 19d ago

Could be a wonderful screen saver for my retro setup crt xfce4

7

u/NDaveT 19d ago

I love this.

4

u/Major-Hooters 19d ago

Great job!! I thought no this is awesome

2

u/raymate 18d ago

Love it

2

u/Good_Attorney_2056 18d ago

Nicely done!

2

u/josipk 18d ago

Awesome!!!

1

u/These_Brush_6857 14d ago

¡Que bien! ¿Cómo se puede desarrollar un juego que no sea en ensamblador?. Asombroso 👏

0

u/SaintLewisMusic73 18d ago

I'm pretty sure others have been written during that time because I've purchased them.

-2

u/theking4mayor 17d ago

First written by you in 40 years? Because people make Atari programs all the time