From ebb5f068fd2d5dcfc177186c7fe649da5cad0f72 Mon Sep 17 00:00:00 2001 From: Peter Evans Date: Fri, 13 Apr 2018 16:17:13 -0500 Subject: [PATCH] Always set the UNUSED and BREAK flags after execution. This change simply replicates the behavior demonstrated in AppleWin. --- src/mos6502/mos6502.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/mos6502/mos6502.c b/src/mos6502/mos6502.c index d80aca1..637d891 100644 --- a/src/mos6502/mos6502.c +++ b/src/mos6502/mos6502.c @@ -367,6 +367,8 @@ mos6502_execute(mos6502 *cpu) cpu->last_addr = cpu->eff_addr; cpu->last_operand = operand; + cpu->P |= MOS_UNUSED | MOS_BREAK; + // Ok -- we're done! This wasn't so hard, was it? return; }