Best method for tiles into VRAM (snes)

Discussion in 'Nintendo Game Development' started by gompertz, Dec 14, 2010.

  1. gompertz

    gompertz Newly Registered

    Joined:
    Dec 11, 2010
    Messages:
    2
    Likes Received:
    0
    Hi All, first post on the forum.... nice site you all have!

    I've been more-or-less fiddling with ASM on the SNES to satisfy some cravings of understanding the system more; nothing too serious, just to gain some ASM knowledge, but have hit bit of a conceptual roadblock.

    Say I wanted a single screen with platforms I can jump on (no side-scrolling). Is it more advantageous (or even possible?) to have the entire "stage" pre-designed as one big "tile" and DMA it into VRAM, or to manually create the stage using small 8x8 tiles with a hoard of writes to register $2118?

    With the pre-designed big tile approach, I understand a tile can't be bigger than 16x16 because of the whole 2 bytes storage per address in VRAM, but I assume there is some kind of trickery that people can do to make a single-screen level quicker with far less code. =\

    Not sure if this post makes much sense, but guess I'll find out :)
     
  2. MottZilla

    MottZilla Champion of the Forum

    Joined:
    Feb 1, 2006
    Messages:
    5,066
    Likes Received:
    102
    For a homebrew game I'd say just DMA the nametable into place. No reason to manually write to the register. And tiles can be either 8x8 or 16x16. You choose.
     
  3. marshallh

    marshallh N64 Coder

    Joined:
    Mar 16, 2006
    Messages:
    661
    Likes Received:
    26
  4. gompertz

    gompertz Newly Registered

    Joined:
    Dec 11, 2010
    Messages:
    2
    Likes Received:
    0
    Thanks for the replies MottZilla and marshallh. I ended up writing a small C program that just generates all the assembly code for me (based on a text-file input that details where tiles should be placed), that I can then copy/paste into my ASM. Rudimentary but seems to work!

    Finally just started to really understand how the tile-data works in conjuction with looking up colors in the pallete table in CGRAM... that was a painful reading and experimentation experience!
     
sonicdude10
Draft saved Draft deleted
Insert every image as a...
  1.  0%

Share This Page