From 046ae48ac5022a7202e29ae28e67282afa758bc3 Mon Sep 17 00:00:00 2001 From: masterofpuppets152001 Date: Tue, 23 Apr 2013 22:45:20 +0000 Subject: [PATCH] Fixed crash on addcode --- BizHawk.MultiClient/SNESTools/SNESGameGenie.cs | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/BizHawk.MultiClient/SNESTools/SNESGameGenie.cs b/BizHawk.MultiClient/SNESTools/SNESGameGenie.cs index e65613f805..ab31736e79 100644 --- a/BizHawk.MultiClient/SNESTools/SNESGameGenie.cs +++ b/BizHawk.MultiClient/SNESTools/SNESGameGenie.cs @@ -308,11 +308,15 @@ namespace BizHawk.MultiClient { return; } - c.address = int.Parse(AddressBox.Text, NumberStyles.HexNumber); - c.value = byte.Parse(ValueBox.Text, NumberStyles.HexNumber); + c.address = Address; + c.value = (byte)Value; + //c. + //c.address = int.Parse(AddressBox.Text, NumberStyles.HexNumber); + //c.value = byte.Parse(ValueBox.Text, NumberStyles.HexNumber); c.compare = null; - c.domain = Global.Emulator.MemoryDomains[7]; //Bus + c.domain = Global.Emulator.MemoryDomains[6]; //Bus c.Enable(); + Global.MainForm.Cheats1.AddCheat(c); }