From 102cf0254aac784ff0941f4f3f99951705ec6fa0 Mon Sep 17 00:00:00 2001 From: David Eriksson Date: Sat, 10 Jan 2004 15:52:00 +0000 Subject: [PATCH] - Honor speech and subtitle toggles - Make text stay on screen longer svn-id: r12297 --- queen/cutaway.cpp | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/queen/cutaway.cpp b/queen/cutaway.cpp index 2d8fc97b054..6ed11af40a3 100644 --- a/queen/cutaway.cpp +++ b/queen/cutaway.cpp @@ -1352,16 +1352,21 @@ void Cutaway::handleText( flags = 1; } - BobSlot *bob = - _vm->graphics()->bob( _vm->logic()->findBob(ABS(object.objectNumber)) ); + if (OBJECT_TYPE_TEXT_SPEAK != type && !_vm->subtitles()) + { + BobSlot *bob = + _vm->graphics()->bob( _vm->logic()->findBob(ABS(object.objectNumber)) ); - _vm->graphics()->setBobText(bob, sentence, x, object.bobStartY, object.specialMove, flags); + _vm->graphics()->setBobText(bob, sentence, x, object.bobStartY, object.specialMove, flags); + } if (OBJECT_TYPE_TEXT_SPEAK == type || OBJECT_TYPE_TEXT_DISPLAY_AND_SPEAK == type) { char voiceFileName[MAX_STRING_SIZE]; findCdCut(_basename, index, voiceFileName); strcat(voiceFileName, "1"); - _vm->sound()->playSfx(voiceFileName); + + if (_vm->sound()->speechOn()) + _vm->sound()->playSfx(voiceFileName); } int i; @@ -1391,8 +1396,8 @@ int Cutaway::countSpaces(ObjectType type, const char *segment) { while (*segment++) tmp++; - if (tmp < 10) - tmp = 10; + if (tmp < 50) + tmp = 50; if (OBJECT_TYPE_TEXT_DISPLAY == type) tmp *= 3;