diff options
-rw-r--r-- | engines/cge2/bitmap.cpp | 5 | ||||
-rw-r--r-- | engines/cge2/bitmap.h | 3 |
2 files changed, 7 insertions, 1 deletions
diff --git a/engines/cge2/bitmap.cpp b/engines/cge2/bitmap.cpp index 6237feaa5d..39483b067d 100644 --- a/engines/cge2/bitmap.cpp +++ b/engines/cge2/bitmap.cpp @@ -368,4 +368,9 @@ bool Bitmap::loadVBM(EncryptedStream *f) { return (!f->err()); } +void Bitmap::xLatPos(V2D& p) { + p.x -= (_w >> 1); + p.y = kWorldHeight - p.y - _h; +} + } // End of namespace CGE2 diff --git a/engines/cge2/bitmap.h b/engines/cge2/bitmap.h index 3d3c27f97e..ea7146f0d7 100644 --- a/engines/cge2/bitmap.h +++ b/engines/cge2/bitmap.h @@ -28,7 +28,7 @@ #ifndef CGE2_BITMAP_H #define CGE2_BITMAP_H -#include "cge/general.h" +#include "cge2/general.h" #include "common/file.h" namespace CGE2 { @@ -77,6 +77,7 @@ public: void show(int16 x, int16 y); void xShow(int16 x, int16 y); bool solidAt(int16 x, int16 y); + void xLatPos(V2D& p); }; |