ScummVM API documentation
panel_art.h
1/* ScummVM - Graphic Adventure Engine
2 *
3 * ScummVM is the legal property of its developers, whose names
4 * are too numerous to list here. Please refer to the COPYRIGHT
5 * file distributed with this source distribution.
6 *
7 * This program is free software: you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation, either version 3 of the License, or
10 * (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program. If not, see <http://www.gnu.org/licenses/>.
19 *
20 */
21
22#ifndef HOLLYWOOD_MONSTERS_GAMEPLAY_PANEL_ART_H
23#define HOLLYWOOD_MONSTERS_GAMEPLAY_PANEL_ART_H
24
25#include "common/array.h"
26#include "common/str.h"
27#include "common/types.h"
28
29namespace Graphics {
30struct Surface;
31}
32
33namespace Hollywood {
34
35class HollywoodFont;
36struct HollywoodGameStrings;
37struct DialogueMenuState;
38struct GameplayPanelState;
39struct GameplayState;
40
42public:
44
45 bool load();
46 bool isLoaded() const { return _loaded; }
47
48 // The current actor resource owns colors 0xd0-0xff.
49 bool applyInteractiveObjectPalette(Common::Array<byte> &palette) const;
50 void drawVerbPanel(Graphics::Surface &surface, const Graphics::Surface &sceneComposite,
51 uint16 viewportXOffset, uint16 viewportYOffset, const GameplayPanelState &panelState,
52 HollywoodFont *font) const;
53 void drawDialogueInventoryPanel(Graphics::Surface &surface, const Graphics::Surface &sceneComposite,
54 uint16 viewportXOffset, uint16 viewportYOffset, const GameplayPanelState &panelState,
55 const GameplayState &gameState, HollywoodFont *font) const;
56 void drawDialogueMenuPanel(Graphics::Surface &surface, const DialogueMenuState &menuState,
57 HollywoodFont *font) const;
58
59private:
60 bool loadBottomPanelBuffer();
61 bool loadDialogueMenuPanelBuffer();
62 bool loadDialogueMenuPanelBufferFromResource000();
63 bool loadObjectPalette();
64 bool loadObjectPaletteFromResource000();
65 bool loadInventoryItemTilePage(byte pageIndex, Common::Array<byte> &page) const;
66 void copySceneCaptionBand(Graphics::Surface &surface, const Graphics::Surface &sceneComposite,
67 uint16 viewportXOffset, uint16 viewportYOffset, uint16 screenY) const;
68 void copyBottomPanelRows(Graphics::Surface &surface, uint16 sourceRow, uint16 screenY,
69 uint16 rowCount) const;
70 void applyInventoryArrowState(Graphics::Surface &surface, const GameplayState &gameState) const;
71 void drawInventoryItems(Graphics::Surface &surface, const GameplayState &gameState) const;
72 void drawDialogueMenuRows(Graphics::Surface &surface, const DialogueMenuState &menuState,
73 uint16 screenY, HollywoodFont *font) const;
74 void drawCaptionText(Graphics::Surface &surface, const Common::String &text, int y,
75 HollywoodFont *font) const;
76 void drawVerbStripLabels(Graphics::Surface &surface, int screenY, HollywoodFont *font) const;
77 void applySelectedVerbStrip(Graphics::Surface &surface, int screenY, byte stripIndex) const;
78 byte sueInventoryItemPage(byte itemId) const;
79
80 Common::Array<byte> _bottomPanelBuffer;
81 Common::Array<byte> _dialogueMenuPanelBuffer;
82 Common::Array<byte> _objectPaletteTriples;
83 mutable Common::Array<Common::Array<byte> > _inventoryItemTilePages;
84 uint32 _inventoryItemPageBaseOffset;
85 const HollywoodGameStrings &_strings;
86 bool _loaded;
87};
88
89} // End of namespace Hollywood
90
91#endif // HOLLYWOOD_MONSTERS_GAMEPLAY_PANEL_ART_H
Definition: str.h:59
Definition: panel_art.h:41
Definition: font.h:32
Definition: formatinfo.h:28
Definition: surface.h:67
Definition: dialogue_menu.h:50
Definition: game_loop.h:60
Definition: game_state.h:37
Definition: game_strings.h:40