How To

Map

1

Ryangamer 2024-05-02 02:08

I’m making a game and I’m trying to use the map to set a background but I can’t find out out how to set the map on screen.


was8bit 2024-05-02 03:56

So, you can go to Gfx Designer, click on the last tab at the bottom right, and there design (and save) a background layout...

Currently you haven't posted anything where you have saved a background layout in your designer...

Once you do, say create a background layout 20x16 in size, use

BG 1
BG COPY 0,0,20,16 TO 0,0

And presto, your background can be seen during gameplay... just be sure if you are adding text numbers or cells, put them on BG 0


was8bit 2024-05-02 04:03

Check this out as an example...


was8bit 2024-05-02 04:38

This one uses a wider BG layout so it can scroll...


was8bit 2024-05-02 04:42 (Edited)

The code i added isn't special, so no credit needed...

... edit graphics and layout to your tastes

Edit the 0.25 in the code below... carefully... to adjust the speed of the background... making it slower than the game adds depth

ADD XSCROLL,0.25
SCROLL 1,XSCROLL,0


was8bit 2024-05-02 14:29 (Edited)

Lowres NX stores graphics as single cells of 8x8 pixels... it stores 256 graphic cells numbered 0 to 255, and uses character designer to edit them.

BG 1 and BG 0 only store reference #'s to those graphic cells, they dont actually hold the graphics... when the game plays, it displays the graphics referenced by the #'s, which by default are all set to zero until you change those numbers... test this by editing character #0, and presto, both backgrounds will fill all #0's with the #0 character ;)


was8bit 2024-05-02 14:30 (Edited)

Both backgrounds are 32x32 (0 to 31) in size, however only 20x16 cells are seen on the screen


was8bit 2024-05-02 14:38 (Edited)

Color #0 is kinda like backlight behind all of your graphics, it is like a "special layer" but doesnt hold any graphics...

All numbers and text characters use a hidden set of fonts on page 4 of your graphics... if you want to make your own font set, go to page 4, and then while in character editor, hit FILE button, then FON (or font) button, then choose the font set you want... these are graphics, so use FILE SAVE to save your font set...

... now, you may use the font set as is, but you may also edit them as you wish :)


was8bit 2024-05-02 14:45 (Edited)

All of your graphics are stored as a data block below your code... you can actually copy/paste this block into a new program, and all your graphics are now available in your new program ;)

The graphic data block starts with...

#2:MAIN CHARACTERS


Ryangamer 2024-05-02 20:19

Thanks, I was really excited for these post so I can release my new game.


was8bit 2024-05-03 05:45

Cool :)


Log in to reply.