diff options
author | Filippos Karapetis | 2018-08-25 12:04:26 +0300 |
---|---|---|
committer | Filippos Karapetis | 2018-08-25 12:39:12 +0300 |
commit | 66cbaeefe20967348bb5306272f937dba0281021 (patch) | |
tree | d7edaa68dbd2159273726dbf774dfa018d7ca884 /engines/sci/graphics | |
parent | 82e8bc43e60ce5908097d62be1b2fbb59c4679e8 (diff) | |
download | scummvm-rg350-66cbaeefe20967348bb5306272f937dba0281021.tar.gz scummvm-rg350-66cbaeefe20967348bb5306272f937dba0281021.tar.bz2 scummvm-rg350-66cbaeefe20967348bb5306272f937dba0281021.zip |
SCI32: Adapt the pathfinding debug code to work woth SCI32 games
Diffstat (limited to 'engines/sci/graphics')
-rw-r--r-- | engines/sci/graphics/frameout.cpp | 10 | ||||
-rw-r--r-- | engines/sci/graphics/frameout.h | 2 |
2 files changed, 12 insertions, 0 deletions
diff --git a/engines/sci/graphics/frameout.cpp b/engines/sci/graphics/frameout.cpp index 434c5a0fec..505e2063f3 100644 --- a/engines/sci/graphics/frameout.cpp +++ b/engines/sci/graphics/frameout.cpp @@ -1354,6 +1354,16 @@ void GfxFrameout::remapMarkRedraw() { #pragma mark - #pragma mark Debugging +Plane *GfxFrameout::getTopVisiblePlane() { + for (PlaneList::const_iterator it = _visiblePlanes.begin(); it != _visiblePlanes.end(); ++it) { + Plane *p = *it; + if (p->_type == kPlaneTypePicture) + return p; + } + + return nullptr; +} + void GfxFrameout::printPlaneListInternal(Console *con, const PlaneList &planeList) const { for (PlaneList::const_iterator it = planeList.begin(); it != planeList.end(); ++it) { Plane *p = *it; diff --git a/engines/sci/graphics/frameout.h b/engines/sci/graphics/frameout.h index eddf88f523..f67d53164b 100644 --- a/engines/sci/graphics/frameout.h +++ b/engines/sci/graphics/frameout.h @@ -288,6 +288,8 @@ public: */ void shakeScreen(const int16 numShakes, const ShakeDirection direction); + Plane *getTopVisiblePlane(); + private: /** * The last time the hardware screen was updated. |