mirror of
https://github.com/scummvm/scummvm.git
synced 2026-11-18 21:34:48 +00:00
DIRECTOR: LINGO: Do not crash during tests on 'set the stageColor'
This commit is contained in:
1 parent
4fc151caf1
commit
10c2055faf
1 file changed
+6
-2
@@ -631,8 +631,12 @@ void Lingo::setTheEntity(int entity, Datum &id, int field, Datum &d) {
|
||||
case kTheStageColor: {
|
||||
Score *score = _vm->getCurrentScore();
|
||||
score->_stageColor = d.asInt();
|
||||
score->_surface->clear(score->_stageColor);
|
||||
score->renderFrame(score->getCurrentFrame(), true);
|
||||
if (score->_surface) {
|
||||
score->_surface->clear(score->_stageColor);
|
||||
score->renderFrame(score->getCurrentFrame(), true);
|
||||
} else {
|
||||
warning("setStageColor: score has no surface, skipping");
|
||||
}
|
||||
}
|
||||
break;
|
||||
case kTheSprite:
|
||||
|
||||
Reference in new issue
Block a user