Fix typechart offset find

Closes #74
offset is before 0x500000
This commit is contained in:
Kurt
2016-12-25 23:25:04 -08:00
parent ce8cecde87
commit 0120df2dd8

View File

@@ -23,7 +23,7 @@ public TypeChart7()
if (!File.Exists(files[0]) || !Path.GetFileNameWithoutExtension(files[0]).Contains("code")) { Util.Alert("No .code.bin detected."); Close(); }
exefs = File.ReadAllBytes(files[0]);
if (exefs.Length % 0x200 != 0) { Util.Alert(".code.bin not decompressed. Aborting."); Close(); }
offset = Util.IndexOfBytes(exefs, Signature, 0x500000, 0) + Signature.Length;
offset = Util.IndexOfBytes(exefs, Signature, 0x400000, 0) + Signature.Length;
Array.Copy(exefs, offset, chart, 0, chart.Length);
populateChart();