Jump to content



0

Starfield with positioning glitch


4 replies to this topic

#1 Richi_S OFFLINE  

Richi_S

    Star Raider

  • 50 posts
  • Location:Germany - Munich

Posted Thu Jun 18, 2009 3:52 PM

Well, here we go, my first Atari 2600 programm.

This programm draws a starfield of 30 stars (Balls) moving horizontally over the screen.
Various star colors and star speeds implemented.
Unfortunately there is a glitch, the stars are jumping foreward at X-position 75.
This must be some problem with the Tia ball movement.
The Star X-position registers show their designated behavior. I checked this with Stella.
Out of frustration I wrote the vertical positioning tables by my own (Rev. 2).
Then playing around with the positions (Rev. 3) not causing any improvement.
Can you give me assistance on that?.

Attached File  starfield.bin   4K   137 downloads
Attached File  starfield.txt   10.51K   112 downloads

#2 Omegamatrix OFFLINE  

Omegamatrix

    River Patroller

  • 4,795 posts
  • Location:Oh, Canada

Posted Thu Jun 18, 2009 9:58 PM

Hi Richi_S,


Nice demo. I think it's neat. :D The jump you are noticing is a timing error. The error occurs because your "Horizontal_move_fine_table" data table crosses over a page boundary. This is bad because it will sometimes add an extra cycle to your critically timed positioning routine. To fix this problem make sure that it all falls within a page. I put ORG $F100 before it, and then it worked fine.



Happy programming :)
Jeff

#3 Richi_S OFFLINE  

Richi_S

    Star Raider

  • 50 posts
  • Location:Germany - Munich

Posted Fri Jun 19, 2009 10:54 AM

Thank you Jeff!

Now it works fine!
Attached File  starfield.bin   4K   132 downloads
Attached File  starfield.txt   10.43K   108 downloads

#4 mos6507 OFFLINE  

mos6507

    River Patroller

  • 4,728 posts

Posted Fri Jun 19, 2009 1:55 PM

Nice demo. Any chance of using it in a game, like a horizontal shooter?

#5 grafixbmp OFFLINE  

grafixbmp

    Dragonstomper

  • 659 posts
  • Location:South Central US

Posted Sat Jun 20, 2009 12:02 AM

That might be great for a drop-in sequence for an R-Type game.




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users