![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
Assumptions and SetupI am assuming you have already downloaded and installed the RGBDS assembler. If you haven't, quickly go to the tools section to find the home page and download and install it. I am also assuming that you have set up a path to the RGBDS executables so that you can compile your code from anywhere on the hard drive. I have provided a little DOS batch file which you can run to compile your code with little fuss. The file is called asm.bat. To download the file using a PC, right-click the link and select the option "Save Target As" then save the file as you would any other file from windows. To use asm.bat, copy it to your working directory (where your source code is located) and, whilst in that directory, type: asm sourcenameWhere sourcename is the name of your source file, without the .asm extension (the batch file adds that on automatically). The batch file will compile your code, run RGBFIX to correct the ROM and create your final project.gb file. StartupTo start off with, we need to make a directory for the project. Throughout the project, we will be using a directory called exped. It doesn't matter where the directory is on your hard drive, so long as you have the directory. Next, we need the skeletal source file. This can be found in the source code section of the web site, or you can click on this link to view or download it. To download the file using a PC, right-click the link and select the option "Save Target As" then save the file as you would any other file from windows. Now we have the file, make a copy of it, and call the copy exped.asm This will be our working file. It is always worth keeping an untouched copy of skeletal.asm to use in other projects or start this one again if things go all wrong. It is also worth making regular copies of your working file. An easy way to do this is to create a sub-directory within your project directory (exped) called backup, and regularly copy the exped.asm file into there, but give the file a name that is the date that you copy it. For example, a file copied across on the 23rd of June 1999 would be saved as 23061999.asm. After a while you can start deleting the older files, but it does mean that you have a series of back-ups to restore from quickly and easily. TestingIt's worthwhile quickly testing that you have your development area set up properly, so go to your exped directory, and compile exped.asm (using asm.bat if you have it). Make sure the resulting exped.gb file runs on an emulator, and then move on to the next section. The bare exped.asm file won't do anything exciting on the gameboy, but it will run without errors if compiled properly. All it does is wake the gameboy up and then sit with a white screen until you exit the emulator.
|