Comment out some temporarily short-circuited code to remove some warnings
This commit is contained in:
parent
b16a9b12ff
commit
a86ad73ade
|
@ -394,7 +394,7 @@ namespace BizHawk.Client.EmuHawk
|
|||
//blnActionReplayMax means "This is an Action Replay MAX code."
|
||||
Boolean blnActionReplayMax = false;
|
||||
//blnCodeBreaker means "This is a CodeBreaker code."
|
||||
Boolean blnCodeBreaker = false;
|
||||
//Boolean blnCodeBreaker = false;
|
||||
//blnUnhandled means "BizHawk can't do this one or the tool can't."
|
||||
Boolean blnUnhandled = false;
|
||||
//blnUnneeded means "You don't need this code."
|
||||
|
@ -402,14 +402,14 @@ namespace BizHawk.Client.EmuHawk
|
|||
private void GBA()
|
||||
{
|
||||
blnEncrypted = false;
|
||||
bool blnNoCode = false;
|
||||
//bool blnNoCode = false;
|
||||
//Super Ultra Mega HD BizHawk GameShark/Action Replay/Code Breaker Final Hyper Edition Arcade Remix EX + α GBA Code detection method.
|
||||
//Seriously, it's that complex.
|
||||
|
||||
//Check Game Shark/Action Replay (Not Max) Codes
|
||||
if (SingleCheat.Length == 17 && SingleCheat.IndexOf(" ") == 8)
|
||||
{
|
||||
blnNoCode = true;
|
||||
//blnNoCode = true;
|
||||
//Super Ultra Mega HD BizHawk GameShark/Action Replay/Code Breaker Final Hyper Edition Arcade Remix EX + α GBA Code detection method.
|
||||
//Seriously, it's that complex.
|
||||
|
||||
|
@ -531,57 +531,56 @@ namespace BizHawk.Client.EmuHawk
|
|||
//Sample Code
|
||||
//Encyped: 6C2A1F51C2C0
|
||||
//Decrypted: 82028048 FFFFFFFF
|
||||
GBACodeBreaker();
|
||||
//GBACodeBreaker();
|
||||
|
||||
if (blnCodeBreaker == false)
|
||||
{
|
||||
parseString = SingleCheat;
|
||||
UInt32 op1 = 0;
|
||||
UInt32 op2 = 0;
|
||||
UInt32 sum = 0xC6EF3720;
|
||||
string test1;
|
||||
string test2;
|
||||
test1 = parseString.Remove(5, 6);
|
||||
test2 = parseString.Remove(0, 6);
|
||||
MessageBox.Show(test1.ToString());
|
||||
MessageBox.Show(test2.ToString());
|
||||
op1 = UInt32.Parse(parseString.Remove(5, 6), NumberStyles.HexNumber);
|
||||
op2 = UInt32.Parse(parseString.Remove(0, 6), NumberStyles.HexNumber);
|
||||
//if (blnCodeBreaker == false)
|
||||
//{
|
||||
// parseString = SingleCheat;
|
||||
// UInt32 op1 = 0;
|
||||
// UInt32 op2 = 0;
|
||||
// UInt32 sum = 0xC6EF3720;
|
||||
// string test1;
|
||||
// string test2;
|
||||
// test1 = parseString.Remove(5, 6);
|
||||
// test2 = parseString.Remove(0, 6);
|
||||
// MessageBox.Show(test1.ToString());
|
||||
// MessageBox.Show(test2.ToString());
|
||||
// op1 = UInt32.Parse(parseString.Remove(5, 6), NumberStyles.HexNumber);
|
||||
// op2 = UInt32.Parse(parseString.Remove(0, 6), NumberStyles.HexNumber);
|
||||
|
||||
//Tiny Encryption Algorithm
|
||||
int i;
|
||||
for (i = 0; i < 32; ++i)
|
||||
{
|
||||
op2 -= ((op1 << 4) + GBAGameSharkSeeds[2]) ^ (op1 + sum) ^ ((op1 >> 5) + GBAGameSharkSeeds[3]);
|
||||
op1 -= ((op2 << 4) + GBAGameSharkSeeds[0]) ^ (op2 + sum) ^ ((op2 >> 5) + GBAGameSharkSeeds[1]);
|
||||
sum -= 0x9E3779B9;
|
||||
}
|
||||
//op1 has the Address
|
||||
//op2 has the Value
|
||||
//Sum, is pointless?
|
||||
RAMAddress = string.Format("{0:X8}", op1);
|
||||
//RAMAddress = RAMAddress.Remove(0, 1);
|
||||
RAMValue = string.Format("{0:X8}", op2);
|
||||
// && RAMAddress[6] == '0'
|
||||
}
|
||||
// //Tiny Encryption Algorithm
|
||||
// int i;
|
||||
// for (i = 0; i < 32; ++i)
|
||||
// {
|
||||
// op2 -= ((op1 << 4) + GBAGameSharkSeeds[2]) ^ (op1 + sum) ^ ((op1 >> 5) + GBAGameSharkSeeds[3]);
|
||||
// op1 -= ((op2 << 4) + GBAGameSharkSeeds[0]) ^ (op2 + sum) ^ ((op2 >> 5) + GBAGameSharkSeeds[1]);
|
||||
// sum -= 0x9E3779B9;
|
||||
// }
|
||||
// //op1 has the Address
|
||||
// //op2 has the Value
|
||||
// //Sum, is pointless?
|
||||
// RAMAddress = string.Format("{0:X8}", op1);
|
||||
// //RAMAddress = RAMAddress.Remove(0, 1);
|
||||
// RAMValue = string.Format("{0:X8}", op2);
|
||||
// // && RAMAddress[6] == '0'
|
||||
//}
|
||||
|
||||
if (blnCodeBreaker == true)
|
||||
{
|
||||
//We got a Valid Code Breaker Code. Hopefully.
|
||||
AddGBA();
|
||||
return;
|
||||
}
|
||||
|
||||
if (SingleCheat.IndexOf(" ") != 8 && SingleCheat.Length != 12)
|
||||
{
|
||||
MessageBox.Show("ALL Codes for Action Replay, Action Replay MAX, Codebreaker, GameShark Advance, GameShark SP, Xploder have a Space after the 8th character.", "Input Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
return;
|
||||
}
|
||||
//We have a code
|
||||
if (blnNoCode == false)
|
||||
{
|
||||
}
|
||||
//if (blnCodeBreaker == true)
|
||||
//{
|
||||
// //We got a Valid Code Breaker Code. Hopefully.
|
||||
// AddGBA();
|
||||
// return;
|
||||
//}
|
||||
|
||||
//if (SingleCheat.IndexOf(" ") != 8 && SingleCheat.Length != 12)
|
||||
//{
|
||||
// MessageBox.Show("ALL Codes for Action Replay, Action Replay MAX, Codebreaker, GameShark Advance, GameShark SP, Xploder have a Space after the 8th character.", "Input Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
// return;
|
||||
//}
|
||||
////We have a code
|
||||
//if (blnNoCode == false)
|
||||
//{
|
||||
//}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue