summaryrefslogtreecommitdiff
path: root/src/cpu/6502.c
diff options
context:
space:
mode:
authoralekseiplusplus <alekseijeaves@protonmail.com>2023-12-07 02:19:48 +1100
committeralekseiplusplus <alekseijeaves@protonmail.com>2023-12-07 02:19:48 +1100
commit98dd41e2ce7dedb81ab91342eed29da017006ea4 (patch)
treede5efd1f899815dcad218accda405873687cbaf1 /src/cpu/6502.c
parent5bb10fc4121a8c8434dcd367f2e611599a11e12e (diff)
about to rip apart my code, so saving progress
Diffstat (limited to 'src/cpu/6502.c')
-rw-r--r--src/cpu/6502.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cpu/6502.c b/src/cpu/6502.c
index e7c1669..595cd4e 100644
--- a/src/cpu/6502.c
+++ b/src/cpu/6502.c
@@ -36,7 +36,7 @@ void SetFlagN(byte x){
//Perform prior to any changes TODO: FIX THIS! WTF WERE YOU THINKING?
void SetFlagV(byte x, byte y){
address z = (address)x + (address)y;
- if (z > 0xFF)
+ if ((x & 0x80) != (y & 0x80))
SetFlag(flag_V, 1);
else
SetFlag(flag_V, 0);