Skip to content

Commit

Permalink
Merge
Browse files Browse the repository at this point in the history
  • Loading branch information
DSUK committed May 16, 2015
2 parents 483a779 + a251cfa commit 2ee6950
Show file tree
Hide file tree
Showing 42 changed files with 387 additions and 16,146 deletions.
1 change: 1 addition & 0 deletions AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ Also thanks to:
* Fahrradkette
* Frank Razenberg (zzattack)
* Gareth Needham (Ripley`)
* Glen Anderson (GlenAnderson)
* Glenn Martin Jensen (Baxxster)
* Gordon Martin (Happy0)
* Guido Lipke (LipkeGu)
Expand Down
1 change: 0 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@
CSC = dmcs
CSFLAGS = -nologo -warn:4 -debug:full -optimize- -codepage:utf8 -unsafe -warnaserror
DEFINE = DEBUG;TRACE

COMMON_LIBS = System.dll System.Core.dll System.Data.dll System.Data.DataSetExtensions.dll System.Drawing.dll System.Xml.dll thirdparty/download/ICSharpCode.SharpZipLib.dll thirdparty/download/FuzzyLogicLibrary.dll thirdparty/download/Mono.Nat.dll thirdparty/download/MaxMind.Db.dll thirdparty/download/MaxMind.GeoIP2.dll thirdparty/download/Eluant.dll thirdparty/download/Ionic.Zip.dll


Expand Down
8 changes: 7 additions & 1 deletion OpenRA.Game/FileFormats/VqaReader.cs
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,9 @@ void CollectAudioData()
{
case "SND0":
case "SND2":
if (audioChannels == 1)
if (audioChannels == 0)
throw new NotSupportedException();
else if (audioChannels == 1)
{
var rawAudio = stream.ReadBytes((int)length);
audio1.Write(rawAudio);
Expand All @@ -198,11 +200,15 @@ void CollectAudioData()
audio1.Write(rawAudio);
rawAudio = stream.ReadBytes((int)length / 2);
audio2.Write(rawAudio);
if (length % 2 != 0)
stream.ReadBytes(2);
}

compressed = type == "SND2";
break;
default:
if (length + stream.Position > stream.Length)
throw new NotSupportedException("Vqa uses unknown Subtype: {0}".F(type));
stream.ReadBytes((int)length);
break;
}
Expand Down

0 comments on commit 2ee6950

Please sign in to comment.