diff options
Diffstat (limited to 'engines/fullpipe/fullpipe.cpp')
-rw-r--r-- | engines/fullpipe/fullpipe.cpp | 24 |
1 files changed, 21 insertions, 3 deletions
diff --git a/engines/fullpipe/fullpipe.cpp b/engines/fullpipe/fullpipe.cpp index ebaff32550..54a77938c9 100644 --- a/engines/fullpipe/fullpipe.cpp +++ b/engines/fullpipe/fullpipe.cpp @@ -24,6 +24,8 @@ #include "common/archive.h" #include "common/config-manager.h" +#include "common/debug-channels.h" +#include "audio/mixer.h" #include "engines/util.h" @@ -46,6 +48,16 @@ FullpipeEngine *g_fp = 0; Vars *g_vars = 0; FullpipeEngine::FullpipeEngine(OSystem *syst, const ADGameDescription *gameDesc) : Engine(syst), _gameDescription(gameDesc) { + DebugMan.addDebugChannel(kDebugPathfinding, "path", "Pathfinding"); + DebugMan.addDebugChannel(kDebugDrawing, "drawing", "Drawing"); + DebugMan.addDebugChannel(kDebugLoading, "loading", "Scene loading"); + DebugMan.addDebugChannel(kDebugAnimation, "animation", "Animation"); + DebugMan.addDebugChannel(kDebugBehavior, "behavior", "Behavior"); + DebugMan.addDebugChannel(kDebugMemory, "memory", "Memory management"); + DebugMan.addDebugChannel(kDebugEvents, "events", "Event handling"); + DebugMan.addDebugChannel(kDebugInventory, "inventory", "Inventory"); + DebugMan.addDebugChannel(kDebugSceneLogic, "scenelogic", "Scene Logic"); + // Setup mixer if (!_mixer->isReady()) { warning("Sound initialization failed."); @@ -112,6 +124,8 @@ FullpipeEngine::FullpipeEngine(OSystem *syst, const ADGameDescription *gameDesc) _musicLocal = 0; _trackStartDelay = 0; + _sceneTrackHandle = new Audio::SoundHandle(); + memset(_sceneTracks, 0, sizeof(_sceneTracks)); memset(_trackName, 0, sizeof(_trackName)); memset(_sceneTracksCurrentTrack, 0, sizeof(_sceneTracksCurrentTrack)); @@ -128,7 +142,7 @@ FullpipeEngine::FullpipeEngine(OSystem *syst, const ADGameDescription *gameDesc) _scene3 = 0; _movTable = 0; _floaters = 0; - _mgm = 0; + _aniHandler = 0; _globalMessageQueueList = 0; _messageHandlers = 0; @@ -192,6 +206,7 @@ FullpipeEngine::~FullpipeEngine() { delete _rnd; delete _console; delete _globalMessageQueueList; + delete _sceneTrackHandle; } void FullpipeEngine::initialize() { @@ -204,7 +219,7 @@ void FullpipeEngine::initialize() { _sceneRect.bottom = 599; _floaters = new Floaters; - _mgm = new MGM; + _aniHandler = new AniHandler; } void FullpipeEngine::restartGame() { @@ -391,6 +406,7 @@ void FullpipeEngine::updateEvents() { _lastInputTicks = _updateTicks; ex->handle(); } + _mouseScreenPos = event.mouse; break; case Common::EVENT_LBUTTONDOWN: if (!_inputArFlag && (_updateTicks - _lastInputTicks) >= 2) { @@ -403,6 +419,7 @@ void FullpipeEngine::updateEvents() { _lastInputTicks = _updateTicks; ex->handle(); } + _mouseScreenPos = event.mouse; break; case Common::EVENT_LBUTTONUP: if (!_inputArFlag && (_updateTicks - _lastButtonUpTicks) >= 2) { @@ -411,6 +428,7 @@ void FullpipeEngine::updateEvents() { _lastButtonUpTicks = _updateTicks; ex->handle(); } + _mouseScreenPos = event.mouse; break; default: break; @@ -448,7 +466,7 @@ void FullpipeEngine::cleanup() { } void FullpipeEngine::updateScreen() { - debug(4, "FullpipeEngine::updateScreen()"); + debugC(4, kDebugDrawing, "FullpipeEngine::updateScreen()"); _mouseVirtX = _mouseScreenPos.x + _sceneRect.left; _mouseVirtY = _mouseScreenPos.y + _sceneRect.top; |