diff --git a/src/CPU.java b/src/CPU.java index c652017..adb55bb 100644 --- a/src/CPU.java +++ b/src/CPU.java @@ -539,7 +539,7 @@ public void IZY() { //INSTRUCTIONS public void ADC() { fetch(); - short temp = (short)((short)a + (short)fetched + (short)(getFlag('C') ? 1 : 0)); + short temp = (short)((short)Byte.toUnsignedInt(a) + (short)Byte.toUnsignedInt(fetched) + (short)(getFlag('C') ? 1 : 0)); setFlag('C', temp > 255); setFlag('Z', (temp & 0x00FF) == 0); setFlag('N', (temp & 0x80) == 0x80); diff --git a/src/EaterEmulator.java b/src/EaterEmulator.java index 7d60494..5f7319a 100644 --- a/src/EaterEmulator.java +++ b/src/EaterEmulator.java @@ -9,7 +9,7 @@ public class EaterEmulator extends JFrame implements ActionListener { public static EaterEmulator emu; - public static String versionString = "1.3"; + public static String versionString = "1.4"; //Swing Things JPanel p = new JPanel();