+/*if (GPU_RUNNING)
+{
+ if (gpu_pc == 0xF035D8)
+ {
+// GPUDumpDisassembly();
+// log_done();
+// exit(1);
+ gpu_control &= 0xFFFFFFFE; // Don't run it and let's see what happens!
+//Hmm. Seems to lock up when going into the demo...
+//Try to disable the collision altogether!
+ }
+}//*/
+extern int effect_start5;
+static bool finished = false;
+//if (GPU_RUNNING && effect_start5 && !finished)
+if (GPU_RUNNING && effect_start5 && gpu_pc == 0xF035D8)
+{
+ // Let's do a dump of $6528!
+/* uint32 numItems = JaguarReadWord(0x6BD6);
+ WriteLog("\nDump of $6528: %u items.\n\n", numItems);
+ for(int i=0; i<numItems*3*4; i+=3*4)
+ {
+ WriteLog("\t%04X: %08X %08X %08X -> ", 0x6528+i, JaguarReadLong(0x6528+i),
+ JaguarReadLong(0x6528+i+4), JaguarReadLong(0x6528+i+8));
+ uint16 link = JaguarReadWord(0x6528+i+8+2);
+ for(int j=0; j<40; j+=4)
+ WriteLog("%08X ", JaguarReadLong(link + j));
+ WriteLog("\n");
+ }
+ WriteLog("\n");//*/
+ // Let's try a manual blit here...
+//This isn't working the way it should! !!! FIX !!!
+//Err, actually, it is.
+// NOW, it works right! Problem solved!!! It's a blitter bug!
+/* uint32 src = 0x4D54, dst = 0xF03000, width = 10 * 4;
+ for(int y=0; y<127; y++)
+ {
+ for(int x=0; x<2; x++)
+ {
+ JaguarWriteLong(dst, JaguarReadLong(src));
+
+ src += 4;
+ dst += 4;
+ }
+ src += width - (2 * 4);
+ }//*/
+/* finished = true;
+ doGPUDis = true;
+ WriteLog("\nGPU: About to execute collision detection code.\n\n");//*/
+
+/* WriteLog("\nGPU: About to execute collision detection code. Data @ 4D54:\n\n");
+ int count = 0;
+ for(int i=0x004D54; i<0x004D54+2048; i++)
+ {
+ WriteLog("%02X ", JaguarReadByte(i));
+ count++;
+ if (count == 32)
+ {
+ count = 0;
+ WriteLog("\n");
+ }
+ }
+ WriteLog("\n\nData @ F03000:\n\n");
+ count = 0;
+ for(int i=0xF03000; i<0xF03200; i++)
+ {
+ WriteLog("%02X ", JaguarReadByte(i));
+ count++;
+ if (count == 32)
+ {
+ count = 0;
+ WriteLog("\n");
+ }
+ }
+ WriteLog("\n\n");
+ log_done();
+ exit(0);//*/
+}
+//if (!GPU_RUNNING)
+// doGPUDis = false;
+/*if (!GPU_RUNNING && finished)
+{
+ WriteLog("\nGPU: Finished collision detection code. Exiting!\n\n");
+ GPUDumpRegisters();
+ log_done();
+ exit(0);
+}//*/