I feel this should be easier to understand, but something is confusing me. The command in question:
00:589A 82 7B OR.W $0A(PC,D2),D1
So it is defiantly oring the value, so or 07 with 05 for example:
07 = 0111
05 = 0101
OR = 0111
So in this code, it OR 0A (1010), but I'm not sure what the brackets are doing? I think it is taking the Program Counter, and moving the result to D2, then moving the OR result to D1.
The results in the trace are as followed:
D2 = 00000016 > D2 00000016
D1 = 8000832C > D1 8000C32C
It's basically setting the palette from 0 (832C) to 2 (C32C).
I want to set it to use palette 1 (A32C), which I would need to change the OR value 0A. It's just knowing what value to set.