commit this and see who complains? :D
git-svn-id: https://svn.code.sf.net/p/vbam/code/trunk@1167 a31d4220-a93d-0410-bf67-fe4944624d44
This commit is contained in:
parent
4c03f2e836
commit
2818c8b1cb
|
@ -1651,7 +1651,7 @@ u8 gbReadOpcode(register u16 address)
|
||||||
return register_SCX;
|
return register_SCX;
|
||||||
case 0x44:
|
case 0x44:
|
||||||
if (((gbHardware & 7) && ((gbLcdMode == 1) && (gbLcdTicks == 0x71))) ||
|
if (((gbHardware & 7) && ((gbLcdMode == 1) && (gbLcdTicks == 0x71))) ||
|
||||||
(!(register_LCDC && 0x80)))
|
(!(register_LCDC & 0x80)))
|
||||||
return 0;
|
return 0;
|
||||||
else
|
else
|
||||||
return register_LY;
|
return register_LY;
|
||||||
|
@ -1931,7 +1931,7 @@ u8 gbReadMemory(register u16 address)
|
||||||
return register_SCX;
|
return register_SCX;
|
||||||
case 0x44:
|
case 0x44:
|
||||||
if (((gbHardware & 7) && ((gbLcdMode == 1) && (gbLcdTicks == 0x71))) ||
|
if (((gbHardware & 7) && ((gbLcdMode == 1) && (gbLcdTicks == 0x71))) ||
|
||||||
(!(register_LCDC && 0x80)))
|
(!(register_LCDC & 0x80)))
|
||||||
return (0);
|
return (0);
|
||||||
else
|
else
|
||||||
return register_LY;
|
return register_LY;
|
||||||
|
@ -2208,11 +2208,6 @@ void gbReset()
|
||||||
gbDmaTicks = 0;
|
gbDmaTicks = 0;
|
||||||
clockTicks = 0;
|
clockTicks = 0;
|
||||||
|
|
||||||
if(gbSpeed) {
|
|
||||||
gbSpeedSwitch();
|
|
||||||
gbMemory[0xff4d] = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
// clean Wram
|
// clean Wram
|
||||||
// This kinda emulates the startup state of Wram on GB/C (not very accurate,
|
// This kinda emulates the startup state of Wram on GB/C (not very accurate,
|
||||||
// but way closer to the reality than filling it with 00es or FFes).
|
// but way closer to the reality than filling it with 00es or FFes).
|
||||||
|
@ -2236,6 +2231,11 @@ void gbReset()
|
||||||
gbMemory[temp] = 0xff;
|
gbMemory[temp] = 0xff;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(gbSpeed) {
|
||||||
|
gbSpeedSwitch();
|
||||||
|
gbMemory[0xff4d] = 0;
|
||||||
|
}
|
||||||
|
|
||||||
// GB bios set this memory area to 0
|
// GB bios set this memory area to 0
|
||||||
// Fixes Pitman (J) title screen
|
// Fixes Pitman (J) title screen
|
||||||
if (gbHardware & 0x1) {
|
if (gbHardware & 0x1) {
|
||||||
|
@ -2244,10 +2244,10 @@ void gbReset()
|
||||||
|
|
||||||
// clean LineBuffer
|
// clean LineBuffer
|
||||||
if (gbLineBuffer != NULL)
|
if (gbLineBuffer != NULL)
|
||||||
memset(gbLineBuffer, 0, sizeof(gbLineBuffer));
|
memset(gbLineBuffer, 0, sizeof(*gbLineBuffer));
|
||||||
// clean Pix
|
// clean Pix
|
||||||
if (pix != NULL)
|
if (pix != NULL)
|
||||||
memset(pix, 0, sizeof(pix));
|
memset(pix, 0, sizeof(*pix));
|
||||||
// clean Vram
|
// clean Vram
|
||||||
if (gbVram != NULL)
|
if (gbVram != NULL)
|
||||||
memset(gbVram, 0, 0x4000);
|
memset(gbVram, 0, 0x4000);
|
||||||
|
|
Loading…
Reference in New Issue