Videopac / Odyssey2 forum

Programming the Videopac / Odyssey2 => Unreleased HomeBrew and test code => Topic started by: Gorf on January 26, 2009, 08:02:07 PM



Title: Grid Map copy code demo.
Post by: Gorf on January 26, 2009, 08:02:07 PM
Moved from 'Let's get this started!'

Allow me to be the first to contribute! :D

Until a standard of upload is decided,
I'll zip it up with this first one.

The 'Gridmap' demo. This is a small piece of code
that cycles through 8 grids like the WOW demo
except much smaller and hopefully easier to
understand.

This will unzip to a folder named 'Gridmap'
It will have three files with in:

'zmap.bat'     ---the bat file to compile the code using TASM.
'Gridmap.a48' ---the source code.
'Gridmap.bin'  ---the O2 or O2EM executable.

Before you do anything you need to go and download TASM.
You must add to the 'Gridmap' folder, 'TASM.EXE' and also the
'TASM48.TAB' or the bat file will not work. I did not add these
as I am not sure if you can distribute TASM in part.)

For others with other OS's you are on your own...sorry.

There are instructions in comments in the source file telling you
how to stop the grid cycling and leave any one of the stationary
maps up permenently and just once at the initialize stage outside
the loop.

I'll try to do more of these simple and hopefully useful samples in
the future. Use it however...I only ask you give me a shout in your
app if you do use it outside of educational purposes! :)

Gorf.




Title: Re: Grid Map copy code demo.
Post by: Ozyr on January 28, 2009, 01:06:27 AM
Thanks for being the first to post some code here!  ;D

As for a format here, I would think that could be left up to the person posting. Personally, I like how you're doing it right now. Works for me Thanks!


Title: Re: Grid Map copy code demo.
Post by: Gorf on January 28, 2009, 03:58:14 AM
Thanks for being the first to post some code here!  ;D

As for a format here, I would think that could be left up to the person posting. Personally, I like how you're doing it right now. Works for me Thanks!

Hey not a problem. I get a rise out of seeing beginners wanting to
learning to code. I try to do what I can to help. :D

I figured zip files would keep it simple, small and easier to deal with.

All my sample code will follow similar format in the zips.

a ) the *.bin file
b ) the source file
c ) and any other support files such as includes or read me files.

All will require 'TASM.EXE' and 'TASM48.TAB' in the same folder.
Ofcourse anyone wanting and willing to convert these over to
another OS such as MAC OS or Linux, you have my blessing. :)

Also feel free to rearange the bat file for allowing only one TASM
in one folder instead of everyfolder. I did this just to keep it as
simple and understandable as possible to even the very novice
of coders.

This project did not really require a 'read me' since it is pretty
straight foward. I'll try to keep things as clutter free as possible.

Next I'll show how to use characters in a simple a way as possible.
Sprites I'll do after as they are rather simple to deal with for the
most part. Characters are a bit more difficult to deal with so, I'll
try to get these out of the way first.

I'd appreciate anyone who has dl'ed this to report to me any
problems you are dealing with.

The best way to continue to see more of these lessons is to
show me you appreciate them. What I mean by appreciation
is simply give me feed back and let me know they are useful
or you are learning. Please make use of them. The idea is to
evenetually see more games released for the O2.

Your interest will always be my interest so if you keep me
interested I will reciprocate. :)