OpenDUNE/OpenDUNE — pull request #194 by wangds (2013-03-06 10:42:18+00:00)
Title: -Fix (#117): correct formula for direction of incoming enemy warning

I am unable to reproduce the claim that the original game gives incorrect directions for the warnings about an incoming enemy in the early levels. Instead, it seems it was caused by two translation errors in OpenDUNE:

In commit b603fd4b,

emu_Sprites_B4CD_17DC (now "Orientation_Orientation256ToOrientation8") was replaced by
Sprites_B4CD_17F7 ("Orientation_Orientation256ToOrientation16").

And in commit c3e1aa8b,

emu_Sprites_B4CD_17DC();
...
emu_shrw(&emu_ax, 0x1);
emu_si = emu_ax;
emu_ax = emu_si;
emu_addw(&emu_ax, 0x2);

the "+ 2" here refers to the "enemy approaching from the north" feedback ID, and was replaced by "+ 1" (plain "enemy approaching").

I have restored the original code, and removed it from the list of enhancements.