Jump to content
IGNORED

Confusion over sprite graphics


xucaen

Recommended Posts

I am trying to figure out how to enter sprite graphics for the 7800 and I am confused about the examples I am seeing.

 

For example, an Atari 2600 sprite looks like this:

Sprite0 .byte #%11000011
    .byte #%10000001
    .byte #%10011001
    .byte #%01011010
    .byte #%00111100
    .byte #%00011000
    .byte #%00011000

but that same exact sprite for some reason has to look like this?

;Sprite0
org $a000
.byte #%00000000
org $a100
.byte #%00000000
org $a200
.byte #%00000000
org $a300
.byte #%00000000
org $a400
.byte #%00000000
org $a500
.byte #%00000000
org $a600
.byte #%00000000
org $a700
.byte #%00000000
org $a800
.byte #%00000000
org $a900
.byte #%11000011
org $aA00
.byte #%10000001
org $aB00
.byte #%10011001
org $aC00
.byte #%01011010
org $aD00
.byte #%00111100
org $aE00
.byte #%00011000
org $aF00
.byte #%00011000

I was wondering why do I need the ORG statements and why do I have to have 16 bytes? It seems to be much easier and more straight forward to make sprites for the 2600 than it is for the 7800. Is there a better/simpler way to do it for the 7800?

Link to comment
Share on other sites

The reason for that is that MARIA decreases the high byte for every line of the sprite as it processes a zone. As a result each line of the sprite is separated by $100 as you see in the sprite. There's no easy away around it as that's how MARIA expects the data to be organized.

  • Like 3
Link to comment
Share on other sites

There is an old program HERE that I used for my wip game. Maybe it can export in a format you can use? I had to manually enter my graphic information into a binary and include it into the assembly due to using a different assembler...

Link to comment
Share on other sites

7800 sprites may be more than a single byte wide (and can have some interesting bit to pixel mappings). Therefore putting each row on a separate page means MARIA doesn't have to perform any multiplication to get the data for the next row.

 

7800 sprites are also "upside down" - i.e. the lowest memory address contains the bottom row of the sprite.

Edited by EricBall
  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...