From 0bcf9c30de1b0dbe672d8264224e2478422432d8 Mon Sep 17 00:00:00 2001 From: Thomas Harte Date: Sun, 12 Mar 2017 21:14:12 -0400 Subject: [PATCH] Added an attempt, at least, at spotting the Activision titles. Which reduces back to only the one breakage, but this is getting a bit too much like spotting the hard-coded bytes. --- StaticAnalyser/Atari/StaticAnalyser.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/StaticAnalyser/Atari/StaticAnalyser.cpp b/StaticAnalyser/Atari/StaticAnalyser.cpp index 9e3e33aad..f6c837ee5 100644 --- a/StaticAnalyser/Atari/StaticAnalyser.cpp +++ b/StaticAnalyser/Atari/StaticAnalyser.cpp @@ -90,6 +90,17 @@ static void DeterminePagingFor2kCartridge(StaticAnalyser::Target &target, const static void DeterminePagingFor8kCartridge(StaticAnalyser::Target &target, const Storage::Cartridge::Cartridge::Segment &segment, const StaticAnalyser::MOS6502::Disassembly &disassembly) { + // Activision stack titles have their vectors at the top of the low 4k, not the top, and + // always list 0xf000 as both vectors; they do not repeat them + if( + segment.data[4095] == 0xf0 && segment.data[4093] == 0xf0 && segment.data[4094] == 0x00 && segment.data[4092] == 0x00 && + (segment.data[8191] != 0xf0 || segment.data[8189] != 0xf0 || segment.data[8190] != 0x00 || segment.data[8188] != 0x00) + ) + { + target.atari.paging_model = StaticAnalyser::Atari2600PagingModel::ActivisionStack; + return; + } + // make an assumption that this is the Atari paging model target.atari.paging_model = StaticAnalyser::Atari2600PagingModel::Atari8k;