diff options
author | Max Horn | 2005-11-19 23:53:02 +0000 |
---|---|---|
committer | Max Horn | 2005-11-19 23:53:02 +0000 |
commit | c712f0c44bcf6299fc2efb49e7b8062749467daa (patch) | |
tree | 235900b2e3b51dff59f299e8b9aa4fe6aa053f71 /scumm | |
parent | 8262b6dc2ac542b84d8ef2304df0f549039f411c (diff) | |
download | scummvm-rg350-c712f0c44bcf6299fc2efb49e7b8062749467daa.tar.gz scummvm-rg350-c712f0c44bcf6299fc2efb49e7b8062749467daa.tar.bz2 scummvm-rg350-c712f0c44bcf6299fc2efb49e7b8062749467daa.zip |
Fix for crash caused by very rapid camera movement in V7/V8 games
svn-id: r19671
Diffstat (limited to 'scumm')
-rw-r--r-- | scumm/gfx.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/scumm/gfx.cpp b/scumm/gfx.cpp index 21f5855b36..57d2748ec3 100644 --- a/scumm/gfx.cpp +++ b/scumm/gfx.cpp @@ -802,11 +802,10 @@ void ScummEngine::redrawBGAreas() { if (_features & GF_NEW_CAMERA) { diff = camera._cur.x / 8 - camera._last.x / 8; - if (_fullRedraw) { + if (_fullRedraw || ABS(diff) >= gdi._numStrips) { _bgNeedsRedraw = false; redrawBGStrip(0, gdi._numStrips); } else if (diff > 0) { - assert(gdi._numStrips > diff); val = -diff; redrawBGStrip(gdi._numStrips - diff, diff); } else if (diff < 0) { |