diff options
author | Colin Snover | 2016-09-30 19:59:05 -0500 |
---|---|---|
committer | Colin Snover | 2016-09-30 20:08:09 -0500 |
commit | 67acdb628bf371f04b7387c61dc0f669360abe40 (patch) | |
tree | bf349f9e1965cbd2c42c4ebbe17ee82a6d5c13ba /engines/sci/engine | |
parent | d1d44eba6f075fc271b0944e69070db1d2200829 (diff) | |
download | scummvm-rg350-67acdb628bf371f04b7387c61dc0f669360abe40.tar.gz scummvm-rg350-67acdb628bf371f04b7387c61dc0f669360abe40.tar.bz2 scummvm-rg350-67acdb628bf371f04b7387c61dc0f669360abe40.zip |
SCI32: Sync subtitle text speed with ScummVM GUI
Diffstat (limited to 'engines/sci/engine')
-rw-r--r-- | engines/sci/engine/vm.cpp | 7 | ||||
-rw-r--r-- | engines/sci/engine/vm.h | 1 |
2 files changed, 8 insertions, 0 deletions
diff --git a/engines/sci/engine/vm.cpp b/engines/sci/engine/vm.cpp index 9d8c5f7fc6..82de957387 100644 --- a/engines/sci/engine/vm.cpp +++ b/engines/sci/engine/vm.cpp @@ -20,6 +20,7 @@ * */ +#include "common/config-manager.h" #include "common/debug.h" #include "common/debug-channels.h" @@ -209,6 +210,12 @@ static void write_var(EngineState *s, int type, int index, reg_t value) { g_sci->updateScummVMAudioOptions(); } } + +#ifdef ENABLE_SCI32 + if (type == VAR_GLOBAL && index == kGlobalVarTextSpeed && getSciVersion() >= SCI_VERSION_2) { + ConfMan.setInt("talkspeed", (8 - value.toSint16()) * 255 / 8); + } +#endif } } diff --git a/engines/sci/engine/vm.h b/engines/sci/engine/vm.h index a4ac16ea32..dd66d9d52c 100644 --- a/engines/sci/engine/vm.h +++ b/engines/sci/engine/vm.h @@ -148,6 +148,7 @@ enum GlobalVar { kGlobalVarScore = 15, kGlobalVarFastCast = 84, // SCI16 kGlobalVarMessageType = 90, + kGlobalVarTextSpeed = 94, // SCI32; 0 is fastest, 8 is slowest kGlobalVarShivers1Score = 349 }; |