Fixed vqa crashes
This commit is contained in:
@@ -90,10 +90,17 @@ namespace OpenRA.FileFormats
|
|||||||
frameData = new uint[frameSize, frameSize];
|
frameData = new uint[frameSize, frameSize];
|
||||||
|
|
||||||
var type = stream.ReadASCII(4);
|
var type = stream.ReadASCII(4);
|
||||||
if (type != "FINF")
|
while (type != "FINF")
|
||||||
{
|
{
|
||||||
stream.Seek(27, SeekOrigin.Current);
|
// Sub type is a file tag
|
||||||
type = stream.ReadASCII(4);
|
if (type[3] == 'F')
|
||||||
|
{
|
||||||
|
var jmp = int2.Swap(stream.ReadUInt32());
|
||||||
|
stream.Seek(jmp, SeekOrigin.Current);
|
||||||
|
type = stream.ReadASCII(4);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
throw new NotSupportedException("Vqa uses unknown Subtype : {0}".F(type));
|
||||||
}
|
}
|
||||||
|
|
||||||
/*var length = */stream.ReadUInt16();
|
/*var length = */stream.ReadUInt16();
|
||||||
|
|||||||
@@ -135,9 +135,9 @@ end
|
|||||||
|
|
||||||
MissionAccomplished = function()
|
MissionAccomplished = function()
|
||||||
Media.PlaySpeechNotification(player, "Win")
|
Media.PlaySpeechNotification(player, "Win")
|
||||||
--Trigger.AfterDelay(DateTime.Seconds(1), function()
|
Trigger.AfterDelay(DateTime.Seconds(1), function()
|
||||||
--Media.PlayMovieFullscreen("snowbomb.vqa") -- https://github.com/OpenRA/OpenRA/issues/4224
|
Media.PlayMovieFullscreen("snowbomb.vqa")
|
||||||
--end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
MissionFailed = function()
|
MissionFailed = function()
|
||||||
|
|||||||
Reference in New Issue
Block a user