GameRes refactoring.

(FormatCatalog.CreateEntry): method renamed to 'Create' and made generic
towards Entry type.
This commit is contained in:
morkt
2015-08-30 22:34:06 +04:00
parent 4bfdc502e4
commit 46dbf2b142
53 changed files with 75 additions and 99 deletions

View File

@@ -71,7 +71,7 @@ namespace GameRes.Formats.BlackCyc
return null;
string name = gtb.View.ReadString (name_offset, (uint)(gtb.MaxOffset-name_offset));
name += ".dwq";
var entry = FormatCatalog.Instance.CreateEntry (name);
var entry = FormatCatalog.Instance.Create<Entry> (name);
entry.Offset = next_offset;
if (i + 1 == count)
next_offset = (uint)file.MaxOffset;

View File

@@ -61,7 +61,7 @@ namespace GameRes.Formats.BlackCyc
for (int i = 0; i < count; ++i)
{
string name = vtb.View.ReadString (index_offset, 8) + ".vaw";
var entry = FormatCatalog.Instance.CreateEntry (name);
var entry = FormatCatalog.Instance.Create<Entry> (name);
entry.Offset = next_offset;
index_offset += 0xC;
next_offset = vtb.View.ReadUInt32 (index_offset+8);