Win32 - Ramwatch - fix so 2 byte is little endian with 2 byte, hacky needs to be cleaned up
This commit is contained in:
parent
2b2b547617
commit
17e7c9f436
|
@ -59,6 +59,14 @@ bool ResetWatches();
|
||||||
|
|
||||||
unsigned int GetCurrentValue(AddressWatcher& watch)
|
unsigned int GetCurrentValue(AddressWatcher& watch)
|
||||||
{
|
{
|
||||||
|
unsigned int x = 0;
|
||||||
|
if (watch.Size == 2) //Do little endian
|
||||||
|
{
|
||||||
|
x = ReadValueAtHardwareAddress(watch.Address+1, 1) * 256;
|
||||||
|
x += ReadValueAtHardwareAddress(watch.Address, 1);
|
||||||
|
return x;
|
||||||
|
}
|
||||||
|
else
|
||||||
return ReadValueAtHardwareAddress(watch.Address, watch.Size == 'd' ? 4 : watch.Size == 'w' ? 2 : 1);
|
return ReadValueAtHardwareAddress(watch.Address, watch.Size == 'd' ? 4 : watch.Size == 'w' ? 2 : 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue