Fixes to GT data decrypter

This commit is contained in:
Greg Edwards 2014-05-16 16:55:33 -04:00
parent a529ee09f7
commit 095ee08c00
5 changed files with 4 additions and 3 deletions

Binary file not shown.

View File

@ -140,4 +140,4 @@ namespace PkmnFoundations.GTS
return (prev * 0x45 + 0x1111) & 0x7fffffff;
}
}
}
}

View File

@ -6,7 +6,7 @@
<asp:Content ID="Content2" ContentPlaceHolderID="cpMain" runat="server">
<form id="theForm" runat="server">
<div>
<p>Uplaod your Generation IV box upload, battle video, and dressup capture:</p>
<p>Uplaod your Generation IV box upload, battle video, or dressup capture:</p>
<asp:FileUpload ID="fuBox" runat="server" />
&nbsp;Pad offset:
<asp:TextBox ID="txtOffset" runat="server" />

View File

@ -31,7 +31,7 @@ namespace PkmnFoundations.GTS.debug
s.Close();
int padOffset = Convert.ToInt32(txtOffset.Text);
for (int x = 4; x < data.Length; x++)
for (int x = 6; x < data.Length; x++)
{
data[x] ^= pad[(x + padOffset) % 256];
}

View File

@ -69,6 +69,7 @@ namespace PkmnFoundations.Structures
/// 16 bytes
/// </summary>
public byte[] TrainerName; // todo: decode/encode to unicode and provide a String wrapper.
// https://github.com/veekun/pokedex/blob/master/pokedex/struct/_pokemon_struct.py
public ushort TrainerOT;