Re: What do most people compile pac-man code with?



"D Widel" <dwidel@xxxxxxxxx> wrote in message
news:1182014668.175077.308120@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Yes, decompiling and recompliing exactly is not hard. I have a z80
dissasember that will produce compilable code w/o any problem. But as
soon as you try to change anything it will blow sky high. The big
problem is jump tables embedded in the code.
<<snip>>

I see what you are saying and I agree. I didn't really know that there was
much you could do about it except understand the whole disassembly enough to
work around issues such as that. I would think that if you could find the
jump table then you could do a global search and replace to make the
addresses labels, and after that you could modify to your heats content. But
that, as you know, is an oversimplification because it is detailed and
tedious work and finding everything is very difficult. I guess the only
advice I have to offer is to do things in very small incremets, test it, and
if it works, save the source in a dated file and repeat the process. I put
the date first in my archive files so that I can go back easily such as
"20070616 Gorf Source.asm". Good luck in your efforts. :-)

The compiler I use for z80 is AS80. Normally what I do is have a
program with an origin after the end of normal code. I start out with
a jump list. Then I mod the pacman binary to jump to my jump table at
the appropriate places. I have a bat file that does the compile and
merges the roms and runs the debugger automatically.

At this time, most of my effort is to document and understand the original
code but not modify it. I like to write my own little test programs and such
which run stand alone. One day, I may try modifying the original code, but
it will be a very long time before I try much in that direction. My goal
(for now) is to write a small stand alone game for the real hardware, even
if it is a simple one. I don't think it would be that hard, but I just
haven't been working on it at all lately.

I also set up batch files so that it will compile and place the object file
in the right area for MAME and run MAME in debug mode. I have other batch
files for other purposes such as resetting the MAME directory to the
original EPROM's. It sure makes things a lot easier!

-Commander Dave


.