diff options
author | Colin Snover | 2017-12-01 11:41:49 -0600 |
---|---|---|
committer | Colin Snover | 2017-12-01 19:43:12 -0600 |
commit | 5c855a0a5a71ca17dae6015ea0676fc2e2c4f249 (patch) | |
tree | ba9b8c9b53eaed0271b08dc758a8948311b476c4 /backends/graphics/opengl | |
parent | 4d3f05ae7928ba625f29749b73b754314bdbe728 (diff) | |
download | scummvm-rg350-5c855a0a5a71ca17dae6015ea0676fc2e2c4f249.tar.gz scummvm-rg350-5c855a0a5a71ca17dae6015ea0676fc2e2c4f249.tar.bz2 scummvm-rg350-5c855a0a5a71ca17dae6015ea0676fc2e2c4f249.zip |
BACKENDS: Fix shake position getting stuck
If a game is doing a screen shake (for example, DOTT when the
stereo is on), and the user does an RTL, the screen shake offset
may get stuck if the engine does not reset it on shutdown. To
avoid this in all cases, just always reset the screen shake
whenever the graphics manager is told to switch to a new graphics
mode.
Diffstat (limited to 'backends/graphics/opengl')
-rw-r--r-- | backends/graphics/opengl/opengl-graphics.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/backends/graphics/opengl/opengl-graphics.cpp b/backends/graphics/opengl/opengl-graphics.cpp index 7bac4c85cb..7d29a81f12 100644 --- a/backends/graphics/opengl/opengl-graphics.cpp +++ b/backends/graphics/opengl/opengl-graphics.cpp @@ -342,6 +342,7 @@ void OpenGLGraphicsManager::initSize(uint width, uint height, const Graphics::Pi _currentState.gameWidth = width; _currentState.gameHeight = height; + _gameScreenShakeOffset = 0; } int16 OpenGLGraphicsManager::getWidth() const { |