News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu

Catching when a color is changed in the debugger

Started by l12n, 13:57, 05 June 24

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

l12n

I'm trying to learn how are CPC games implementing their animation and drawing in the WinApe debugger.

However, for Head over Heels, it sets all the colors to black between screens. Where can I find where that code is? I tried searching for the address which changes the ink color but couldn't find it in the code

Jean-Marie

First you need to understand how the Gate Array is programmed to select the colors :
 Gate Array - CPCWiki
Sometimes a program might use the Firmware rather than programming the Gate Array directly (call &BC32), but that's quite uncommon.
A quick search using WinApe with the term ld bc,#7F00 returns the code setting the colors, at offset 053Ah. The value in HL register is the address of the 4 colors of the room to be drawn.
 

l12n


Powered by SMFPacks Menu Editor Mod