-/* common code for Memory.c and cd/Memory.c */
+// common code for Memory.c and cd/Memory.c
+// (c) Copyright 2006-2007, Grazvydas "notaz" Ignotas
+
+#ifndef UTYPES_DEFINED
+typedef unsigned char u8;
+typedef unsigned short u16;
+typedef unsigned int u32;
+#define UTYPES_DEFINED
+#endif
+
+#ifdef _ASM_MEMORY_C
+u32 OtherRead16End(u32 a, int realsize);
+#endif
+#ifdef _ASM_CD_MEMORY_C
+static void OtherWrite8End(u32 a,u32 d,int realsize);
+#endif
static int PadRead(int i)
{
// |=0x80 for Shadow of the Beast & Super Offroad; rotate fakes next fetched instruction for Time Killers
if (a==0xa11100) { // z80 busreq
d=Pico.m.z80Run&1;
+#if 1
if (!d) {
// needed by buggy Terminator (Sega CD)
- extern int z80stopCycle;
int stop_before = SekCyclesDone() - z80stopCycle;
dprintf("stop before: %i", stop_before);
if (stop_before > 0 && stop_before <= 32) // Gens uses 16 here
d = 1; // bus not yet available
}
+#endif
d=(d<<8)|0x8000|Pico.m.rotate++;
dprintf("get_zrun: %04x [%i|%i] @%06x", d, Pico.m.scanline, SekCyclesDone(), SekPc);
goto end;