> > Here is one interesting way to do a static recompiler: > > http://www.gtoal.com/sbt/ > > > That's perfect, thank you. > > > 1.) dynamic code (self-modifying programs) > > I would be surprised if any game boards use anything like this, except maybe for > protection. Can you please be more specific?
Old games do it more than you might think for all sorts of weird reasons.
> > > 2.) programs that copy or load code into RAM > > You mean if the code is compressed or otherwise not part of the code segment but > "hidden" somewhere in the data segment and indistinguishable from the rest of the > data, or what R. Belmont calls - problem of "accidentally" compiling data, or is > there more and something else?
There is no "code segment". You can think of ROMs as being system-level code (like an OS or BIOS). Often times, they copy portions of the game program around to different parts of RAM, and it's not necessarily because the code is compressed. ROM is slower than RAM.
Even if you could identify code in ROM (RB touched upon the syncing problem for processors with variable-length instructions), you don't actually know where it's going to be executed from, so you can't translate it. And we haven't even touched upon code stored on hard drives or optical discs, which also has to be loaded into RAM.
> All in all, MAME seem to be the worst place to start, I should probably find the > simplest Z80 emulator for something like ZX Spectrum or Amstrad CPC, and that would > also already have almost compatible assembler with x86 in case that turns out to be > important or helpful. But again, my expertise has little to do with emulators, so I > would like a little bit more information or point to some better place where to > start, then I could do the rest myself, I think. >
I think it would be harder for these old systems, except for very simple programs.
> "fan-made remake". The point I am trying to make is that these 'remakes' are actually > legal unless being sold, since they do not violate game license or ROMs copyright, > but rather the trademark associated with the use of characters, names and logos, or > so it would seem. What do you think?
It would not be legal. Not only is it a derived work, being a simple transformation of the original code, it would also contain copyrighted data.
Bart
|