24 #ifndef SWORD2_MOUSE_H 25 #define SWORD2_MOUSE_H 27 #include "common/rect.h" 29 #define MENU_MASTER_OBJECT 44 31 #define MAX_SUBJECT_LIST 30 // is that enough? 33 #define TOTAL_subjects (375 - 256 + 1) // the speech subject bar 34 #define TOTAL_engine_pockets (15 + 10) // +10 for overflow 35 #define TOTAL_mouse_list 50 45 #define RDMENU_BOTTOM 1 51 MOUSE_system_menu = 3,
68 #define RDMENU_ICONWIDE 35 69 #define RDMENU_PSXICONWIDE 36 70 #define RDMENU_ICONDEEP 30 71 #define RDMENU_ICONSTART 24 72 #define RDMENU_ICONSPACING 5 73 #define RDMENU_MAXPOCKETS 15 75 #define MOUSE_ANIM_HEADER_SIZE 6 132 int32 luggage_resource;
146 MenuObject _masterMenuList[TOTAL_engine_pockets];
147 uint32 _totalMasters;
155 uint32 _defaultResponseId;
160 uint8 _menuStatus[2];
161 byte *_icons[2][RDMENU_MAXPOCKETS];
162 uint8 _pocketStatus[2][RDMENU_MAXPOCKETS];
169 uint32 _mousePointerRes;
179 bool _mouseModeLocked;
182 uint32 _realLuggageItem;
183 uint32 _currentLuggageResource;
187 uint32 _pointerTextBlocNo;
188 uint32 _playerActivityDelay;
190 bool _examiningMenuIcon;
193 uint32 _mouseTouching;
194 uint32 _oldMouseTouching;
198 uint32 _menuSelectedPos;
200 void decompressMouse(byte *decomp, byte *comp, uint8 frame,
int width,
int height,
int pitch,
int xOff = 0,
int yOff = 0);
202 int32 setMouseAnim(byte *ma, int32 size, int32 mouseFlash);
203 int32 setLuggageAnim(byte *la, int32 size);
205 void clearIconArea(
int menu,
int pocket,
Common::Rect *r);
211 void getPos(
int &x,
int &y);
215 bool getObjectLabels() {
return _objectLabels; }
216 void setObjectLabels(
bool b) { _objectLabels = b; }
218 bool getMouseStatus() {
return _mouseStatus; }
219 uint32 getMouseTouching() {
return _mouseTouching; }
220 void setMouseTouching(uint32 touching) { _mouseTouching = touching; }
222 void pauseEngine(
bool pause);
224 void setMouse(uint32 res);
225 void setLuggage(uint32 res);
227 void setObjectHeld(uint32 res);
229 void resetMouseList();
231 void registerMouse(byte *ob_mouse,
BuildUnit *build_unit);
232 void registerPointerText(int32 text_id);
234 void createPointerText(uint32 text_id, uint32 pointer_res);
235 void clearPointerText();
238 int32 animateMouse();
242 void addMenuObject(byte *ptr);
243 void addSubject(int32
id, int32 ref);
246 void buildSystemMenu();
248 int32 showMenu(uint8 menu);
249 int32 hideMenu(uint8 menu);
250 int32 setMenuIcon(uint8 menu, uint8 pocket, byte *icon);
252 void closeMenuImmediately();
254 void refreshInventory();
256 void startConversation();
257 void endConversation();
263 void resetPlayerActivityDelay() { _playerActivityDelay = 0; }
264 void monitorPlayerActivity();
265 void checkPlayerActivity(uint32 seconds);
268 uint32 checkMouseList();
274 void systemMenuMouse();
276 bool isChoosing() {
return _choosing; }
277 uint32 chooseMouse();
279 int menuClick(
int menu_items);
283 void setMouseMode(
int mouseMode);
Definition: animation.h:37
int16 right
Definition: rect.h:146
int16 left
Definition: rect.h:145