From 041af01f7d2053cad29f022865325602cb44d39b Mon Sep 17 00:00:00 2001 From: Torbjörn Andersson Date: Sat, 7 Mar 2009 17:27:18 +0000 Subject: Don't show a warning dialog for missing cutscenes in the demo. As noted in bug #2669360, the demo tries to play cutscenes which really aren't there. svn-id: r39194 --- engines/sword2/animation.cpp | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'engines/sword2') diff --git a/engines/sword2/animation.cpp b/engines/sword2/animation.cpp index c35be49865..ab5a6e67a0 100644 --- a/engines/sword2/animation.cpp +++ b/engines/sword2/animation.cpp @@ -31,6 +31,7 @@ #include "sword2/sword2.h" #include "sword2/defs.h" #include "sword2/header.h" +#include "sword2/logic.h" #include "sword2/maketext.h" #include "sword2/resman.h" #include "sword2/sound.h" @@ -348,9 +349,14 @@ MoviePlayer *makeMoviePlayer(const char *name, Sword2Engine *vm, Audio::Mixer *s return NULL; } - sprintf(buf, "Cutscene '%s' not found", name); - GUI::MessageDialog dialog(buf, "OK"); - dialog.runModal(); + // The demo tries to play some cutscenes that aren't there, so make + // those warnings more discreet. + if (!vm->_logic->readVar(DEMO)) { + sprintf(buf, "Cutscene '%s' not found", name); + GUI::MessageDialog dialog(buf, "OK"); + dialog.runModal(); + } else + warning("Cutscene '%s' not found", name); return NULL; } -- cgit v1.2.3