How To

How do I make a scrolling BG that comes from the bottom?

1

DJMoffinz 2019-12-06 04:24

I saw the “Flat Eric” project and wanted to make something like it, minus the doggo, music, etc. But I can’t figure out the code, can anyone help me out?


was8bit 2019-12-06 05:42

NOT that easy....

Backgrounds are 32x32 (0-31) in both directions, and viewscreen is only 20x16 ...

I will work out something for you look at... i will post it soon...


DJMoffinz 2019-12-06 05:46

Thanks for seeing/replying to this so quick!


was8bit 2019-12-06 06:44

:)

... check this out :)

https://lowresnx.inutilis.com/topic.php?id=835


was8bit 2019-12-06 09:39

BTW, in Flat Eric, they are simply using the SCROLL command and adding random vertical lines...


DJMoffinz 2019-12-07 05:58

Yes thats what I meant, is there a way to do that? (But from the bottom)


was8bit 2019-12-07 09:23

?? Are you asking how to use SCROLL.... or how my example works??


DJMoffinz 2019-12-12 09:17

How do I use scroll?!


was8bit 2019-12-12 11:51

SCROLL changes what you SEE at pixel amounts, it only changes what you SEE, not what is in memory...

if all you want is visual effects, not to worry... if you want to be able to READ what you see, its a whole different level of difficulty...

Attached is an example that ONLY moves Y in one direction, by 8 pixels at a time to keep it less confusing...

The variable C always reads cell position (0,0) which initially is see. at the top left corner of your screen...

As you use SCROLL, you will realize that C remains unchanged even though what you SEE is changing, the actual memory values dont change, so the cell value if memory position (0,0) is the same, all that was changed is the screens VIEW, not its memory

Variable CC adjusts for the changing view, so what you SEE in the upper left corner of your visual screen is read

Play around with this and hopefully it helps a little... i know it can be abit confusing and thats why great care should be used and lots of testing done like ive shown here so you can verify it is doing what you think is should be doing...

Hope this helps :)

Scroll Example.nx | Open in app
2019-12-12 11:51

DJMoffinz 2020-04-08 10:10 (Edited)

Thanks! That’s a big help.


was8bit 2020-04-08 10:12

Always glad to help :)


Log in to reply.