public MDStringHeap(BinaryReader reader, long offs, long size, string name)
: base()
{
reader.BaseStream.Position = offs;
Start = offs;
Length = size;
_name = name;
string s = "";
int reloffs = (int)(reader.BaseStream.Position - offs);
for(long i=offs; i < offs + size; ++i)
{
//BinaryReader is utf8 by default and that's what we want.
char c = reader.ReadChar();
if (c == '\0')
{
_data.Add(reloffs, s);
s = "";
reloffs = (int)(reader.BaseStream.Position - offs);
}
else
{
s += c;
}
}
}