diff options
Diffstat (limited to 'engines/avalanche/graphics.h')
-rw-r--r-- | engines/avalanche/graphics.h | 24 |
1 files changed, 11 insertions, 13 deletions
diff --git a/engines/avalanche/graphics.h b/engines/avalanche/graphics.h index b3710742ca..8a9d26cb99 100644 --- a/engines/avalanche/graphics.h +++ b/engines/avalanche/graphics.h @@ -39,11 +39,7 @@ class AvalancheEngine; struct SpriteType; typedef byte FontType[256][16]; - typedef byte ManiType[2049]; -// manitype = array[5..2053] of byte; -// Be aware!!! - typedef byte SilType[51][11]; // 35, 4 class SpriteInfo { @@ -55,21 +51,19 @@ public: uint16 _size; // The size of one picture. }; -struct MouseHotspotType { // mouse-void +struct MouseHotspotType { int16 _horizontal, _vertical; }; class GraphicManager { public: static const MouseHotspotType kMouseHotSpots[9]; - - Graphics::Surface _surface; Color _talkBackgroundColor, _talkFontColor; GraphicManager(AvalancheEngine *vm); ~GraphicManager(); void init(); - void loadDigits(Common::File &file); // Load the scoring digits & rwlites + void loadDigits(Common::File &file); void loadMouse(byte which); void fleshColors(); @@ -104,7 +98,7 @@ public: Graphics::Surface loadPictureRow(Common::File &file, uint16 width, uint16 height); // Reads Row-planar EGA data. void drawSprite(const SpriteInfo &sprite, byte picnum, int16 x, int16 y); - void drawPicture(Graphics::Surface &target, const Graphics::Surface &picture, uint16 destX, uint16 destY); // Can't call .free() here. See showScore() for example. + void drawPicture(Graphics::Surface &target, const Graphics::Surface picture, uint16 destX, uint16 destY); // Can't call .free() here. See showScore() for example. void drawThinkPic(Common::String filename, int id); void drawToolbar(); @@ -112,6 +106,7 @@ public: void drawReadyLight(Color color); void drawSign(Common::String name, int16 xl, int16 yl, int16 y); // This is for drawing a big "about" or "gameover" picture loaded from a file into an empty scroll. void drawIcon(int16 x, int16 y, byte which); // Draws an icon to the current scroll. + void drawScreenLine(int16 x, int16 y, int16 x2, int16 y2, Color color); void prepareBubble(int xc, int xw, int my, Common::Point points[3]); @@ -122,25 +117,28 @@ public: void setDialogColor(Color bg, Color text); void zoomOut(int16 x, int16 y); // Only used when entering the map. - void showScroll(); + void getNaturalPicture(SpriteType &sprite); + void saveScreen(); void removeBackup(); void restoreScreen(); + private: static const uint16 kBackgroundWidth = kScreenWidth; + static const byte kEgaPaletteIndex[16]; static const byte kBackgroundHeight = 8 * 12080 / kScreenWidth; // With 640 width it's 151. // The 8 = number of bits in a byte, and 12080 comes from Lucerna::load(). - static const byte kEgaPaletteIndex[16]; Graphics::Surface _background; - Graphics::Surface _magics; // Lucerna::draw_also_lines() draws the "magical" lines here. Further information: https://github.com/urukgit/avalot/wiki/Also + Graphics::Surface _backup; Graphics::Surface _digits[10]; // digitsize and rwlitesize are defined in loadDigits() !!! Graphics::Surface _directions[9]; // Maybe it will be needed to move them to the class itself instead. + Graphics::Surface _magics; // Lucerna::draw_also_lines() draws the "magical" lines here. Further information: https://github.com/urukgit/avalot/wiki/Also Graphics::Surface _screen; // Only used in refreshScreen() to make it more optimized. (No recreation of it at every call of the function.) Graphics::Surface _scrolls; - Graphics::Surface _backup; + Graphics::Surface _surface; byte _egaPalette[64][3]; AvalancheEngine *_vm; |