Skip to content

Commit e2b6e0f

Browse files
authored
Lots of changes (#14)
* fix string table not updating correctly * cleanup sawyer stream stuff * small optimisations * some stream optimisations, file cleanup * fix string table ui and parsing * add viewing of other data files, and playing of music tracks * improve music loading * add scuffed audio rendering * figured out the /2 is the bytes per sample * clean up riff code * add loading of misc tracks and sound effects file (css1) * add exporting music (buggy with sound effects though) * add sound ids to ui
1 parent e877b5f commit e2b6e0f

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+1281
-683
lines changed

OpenLocoTool/DatFileParsing/ObjectAnnotator.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ public static IList<Annotation> Annotate(byte[] bytelist, out byte[] fullData)
3434
fullData =
3535
[
3636
.. bytelist[..runningCount],
37-
.. SawyerStreamReader.Decode(objectHeader.Encoding, bytelist.AsSpan()[runningCount..(int)(runningCount + objectHeader.DataLength)]),
37+
.. SawyerStreamReader.Decode(objectHeader.Encoding, bytelist[runningCount..(int)(runningCount + objectHeader.DataLength)]),
3838
];
3939

4040
var locoStruct = SawyerStreamReader.GetLocoStruct(s5Header.ObjectType, fullData.AsSpan()[runningCount..]);
@@ -137,7 +137,7 @@ public static IList<Annotation> AnnotateG1Data(byte[] fullData, int runningCount
137137
return annotations;
138138
}
139139

140-
public static int AnnotateStringTable(byte[] fullData, int runningCount, ILocoStruct locoStruct, IList<Annotation> annotations)
140+
static int AnnotateStringTable(byte[] fullData, int runningCount, ILocoStruct locoStruct, IList<Annotation> annotations)
141141
{
142142
var root = new Annotation("String Table", runningCount, 1);
143143
annotations.Add(root);

0 commit comments

Comments
 (0)