Skip to content

Commit

Permalink
comment/syntax tweak
Browse files Browse the repository at this point in the history
  • Loading branch information
LogicAndTrick committed Nov 27, 2023
1 parent 4bcca43 commit dd7e486
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions Sledge.Formats.Model/Goldsource/MdlFile.cs
Original file line number Diff line number Diff line change
Expand Up @@ -280,17 +280,16 @@ private void Read(BinaryReader br, Dictionary<string, BinaryReader> sequenceGrou

var seqGroup = SequenceGroups[sequence.SequenceGroup];

// Only load seqence group 0 for now (others are in other files)
// Load sequence group 0 from the main file, the other sequence groups are in sub files
if (sequence.SequenceGroup == 0)
{
var pos = br.BaseStream.Position;
sequence.Blends = LoadAnimationBlends(br, sequence, numBones);
br.BaseStream.Position = pos;
}
else if (sequenceGroups.ContainsKey(seqGroup.Name))
else if (sequenceGroups.TryGetValue(seqGroup.Name, out var group))
{
var reader = sequenceGroups[seqGroup.Name];
sequence.Blends = LoadAnimationBlends(reader, sequence, numBones);
sequence.Blends = LoadAnimationBlends(group, sequence, numBones);
}

Sequences.Add(sequence);
Expand Down

0 comments on commit dd7e486

Please sign in to comment.