Well I am trying to load allies from the Guilds.dat file.
They are defined as
Code:
public Dictionary<uint, string> Allies = new Dictionary<uint, string>();
Code:
Allies.Add(GuildID, GuildName);
Code:
BW.Write((int)Allies.Count);
foreach (KeyValuePair<uint, string> kvp in Allies)
{
BW.Write(kvp.Key);
BW.Write(kvp.Value);
}
Code:
int a = BR.ReadInt32();
{
for (int i = 0; i < a; i++)
Allies.Add(BR.ReadUInt32(), BR.ReadString());
}
Unable to read beyond the end of the stream.
is the error I get.
Any help?






