(ANI): change name assignment to include containing file name.

This commit is contained in:
morkt 2020-03-30 17:34:00 +04:00
parent e78e80ca26
commit 56b3e862c2

View File

@ -56,6 +56,7 @@ namespace GameRes.Formats.Musica
return null; return null;
using (var input = file.CreateStream()) using (var input = file.CreateStream())
{ {
var base_name = Path.GetFileNameWithoutExtension (file.Name);
input.Position = 8; input.Position = 8;
var dir = new List<Entry> (count); var dir = new List<Entry> (count);
for (int i = 0; i < count; ++i) for (int i = 0; i < count; ++i)
@ -64,7 +65,7 @@ namespace GameRes.Formats.Musica
if (string.IsNullOrWhiteSpace (name)) if (string.IsNullOrWhiteSpace (name))
return null; return null;
var entry = new Entry { var entry = new Entry {
Name = name, Name = string.Format ("{0}#{1}", base_name, name),
Type = "image", Type = "image",
Offset = input.Position, Offset = input.Position,
}; };