aboutsummaryrefslogtreecommitdiff
path: root/engines/saga
diff options
context:
space:
mode:
authorFilippos Karapetis2007-11-08 23:35:46 +0000
committerFilippos Karapetis2007-11-08 23:35:46 +0000
commit422e88aa20089bcf675335d4e012f8c848c80ac4 (patch)
tree6e195439d8664bf3a912cc3083fb930966d3b04b /engines/saga
parent783a0bf67d7319f291202a739bfaf82b77295448 (diff)
downloadscummvm-rg350-422e88aa20089bcf675335d4e012f8c848c80ac4.tar.gz
scummvm-rg350-422e88aa20089bcf675335d4e012f8c848c80ac4.tar.bz2
scummvm-rg350-422e88aa20089bcf675335d4e012f8c848c80ac4.zip
Slight fix for off screen path calculation
svn-id: r29454
Diffstat (limited to 'engines/saga')
-rw-r--r--engines/saga/scene.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/engines/saga/scene.cpp b/engines/saga/scene.cpp
index dbcca5021c..336399eefa 100644
--- a/engines/saga/scene.cpp
+++ b/engines/saga/scene.cpp
@@ -553,8 +553,8 @@ bool Scene::offscreenPath(Point &testPoint) {
return false;
}
- point.x = clamp( 0, testPoint.x, _bgMask.w - 1 );
- point.y = clamp( 0, testPoint.y, _bgMask.h - 1 );
+ point.x = clamp(0, testPoint.x, _vm->getDisplayWidth() - 1);
+ point.y = clamp(0, testPoint.y, _bgMask.h - 1);
if (point == testPoint) {
return false;
}