aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorEugene Sandulenko2013-08-19 09:24:36 +0300
committerEugene Sandulenko2013-09-06 14:51:16 +0300
commit5e21cefa72c25fa8695b3be323367411e1e7bd28 (patch)
tree2d5540f5668fa3ab1fb6720f6c933307546c4704 /engines
parentf9cefd02dfa3a8dd665e23d002aea870a3269e03 (diff)
downloadscummvm-rg350-5e21cefa72c25fa8695b3be323367411e1e7bd28.tar.gz
scummvm-rg350-5e21cefa72c25fa8695b3be323367411e1e7bd28.tar.bz2
scummvm-rg350-5e21cefa72c25fa8695b3be323367411e1e7bd28.zip
FULLPIPE: Implement PictureObject::isPointInside()
Diffstat (limited to 'engines')
-rw-r--r--engines/fullpipe/gfx.cpp16
-rw-r--r--engines/fullpipe/gfx.h1
2 files changed, 17 insertions, 0 deletions
diff --git a/engines/fullpipe/gfx.cpp b/engines/fullpipe/gfx.cpp
index de2b81d76c..63245a19e0 100644
--- a/engines/fullpipe/gfx.cpp
+++ b/engines/fullpipe/gfx.cpp
@@ -213,6 +213,22 @@ bool PictureObject::setPicAniInfo(PicAniInfo *picAniInfo) {
return false;
}
+bool PictureObject::isPointInside(int x, int y) {
+ bool res;
+ int oldx = _picture->_x;
+ int oldy = _picture->_y;
+
+ _picture->_x = _ox;
+ _picture->_y = _oy;
+
+ res = _picture->isPointInside(x, y);
+
+ _picture->_x = oldx;
+ _picture->_y = oldy;
+
+ return res;
+}
+
GameObject::GameObject() {
_okeyCode = 0;
_flags = 0;
diff --git a/engines/fullpipe/gfx.h b/engines/fullpipe/gfx.h
index 4c4ed3034d..45414eb331 100644
--- a/engines/fullpipe/gfx.h
+++ b/engines/fullpipe/gfx.h
@@ -159,6 +159,7 @@ class PictureObject : public GameObject {
void draw();
bool setPicAniInfo(PicAniInfo *picAniInfo);
+ bool isPointInside(int x, int y);
};
class Background : public CObject {