2011-06-27 17:09:55 +00:00
|
|
|
/* ScummVM - Graphic Adventure Engine
|
|
|
|
*
|
|
|
|
* ScummVM is the legal property of its developers, whose names
|
|
|
|
* are too numerous to list here. Please refer to the COPYRIGHT
|
|
|
|
* file distributed with this source distribution.
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU General Public License
|
|
|
|
* as published by the Free Software Foundation; either version 2
|
|
|
|
* of the License, or (at your option) any later version.
|
|
|
|
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef NEVERHOOD_GAMEMODULE_H
|
|
|
|
#define NEVERHOOD_GAMEMODULE_H
|
|
|
|
|
|
|
|
#include "neverhood/neverhood.h"
|
|
|
|
#include "neverhood/module.h"
|
|
|
|
|
|
|
|
namespace Neverhood {
|
|
|
|
|
|
|
|
class GameModule : public Module {
|
|
|
|
public:
|
|
|
|
GameModule(NeverhoodEngine *vm);
|
|
|
|
virtual ~GameModule();
|
2011-07-27 18:02:30 +00:00
|
|
|
void startup();
|
2012-10-19 13:55:37 +00:00
|
|
|
void checkMainMenu();
|
2011-07-11 12:21:56 +00:00
|
|
|
void handleMouseMove(int16 x, int16 y);
|
2011-07-07 20:26:12 +00:00
|
|
|
void handleMouseDown(int16 x, int16 y);
|
2012-10-12 19:19:24 +00:00
|
|
|
void handleMouseUp(int16 x, int16 y);
|
2012-10-19 13:55:37 +00:00
|
|
|
void handleEscapeKey();
|
2012-10-11 21:23:55 +00:00
|
|
|
void handleSpaceKey();
|
2012-10-18 17:15:20 +00:00
|
|
|
void initKeySlotsPuzzle();
|
|
|
|
void initMemoryPuzzle();
|
|
|
|
void initWaterPipesPuzzle();
|
|
|
|
void initRadioPuzzle();
|
|
|
|
void initTestTubes1Puzzle();
|
|
|
|
void initTestTubes2Puzzle();
|
|
|
|
void initCannonSymbolsPuzzle();
|
|
|
|
uint32 getCurrRadioMusicFileHash();
|
2011-06-27 17:09:55 +00:00
|
|
|
protected:
|
|
|
|
Entity *_prevChildObject;
|
2012-10-19 13:55:37 +00:00
|
|
|
int _prevModuleNum;
|
|
|
|
bool _gameWasLoaded;
|
|
|
|
bool _mainMenuRequested;
|
2011-06-27 17:09:55 +00:00
|
|
|
bool _someFlag1;
|
|
|
|
bool _field2C;
|
|
|
|
uint32 _counter;
|
2011-09-19 13:16:41 +00:00
|
|
|
int _moduleNum;
|
2011-06-27 17:09:55 +00:00
|
|
|
uint32 handleMessage(int messageNum, const MessageParam ¶m, Entity *sender);
|
2011-09-19 13:16:41 +00:00
|
|
|
void createModule(int moduleNum, int which);
|
2012-10-15 15:50:43 +00:00
|
|
|
void createModuleByHash(uint32 nameHash);
|
2011-09-19 13:16:41 +00:00
|
|
|
void updateModule();
|
2012-10-19 13:55:37 +00:00
|
|
|
void openMainMenu();
|
|
|
|
void createMenuModule();
|
|
|
|
void updateMenuModule();
|
2011-06-27 17:09:55 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
} // End of namespace Neverhood
|
|
|
|
|
|
|
|
#endif /* NEVERHOOD_MODULE_H */
|