BLADERUNNER: Refactor to use Engine debugger

This commit is contained in:
Paul Gilbert 2020-02-08 20:50:36 -08:00 committed by Filippos Karapetis
parent 43f49b7307
commit e708906916
2 changed files with 2 additions and 12 deletions

View File

@ -502,6 +502,7 @@ bool BladeRunnerEngine::startup(bool hasSavegames) {
_sceneScript = new SceneScript(this);
_debugger = new Debugger(this);
setDebugger(_debugger);
// This is the original startup in the game
@ -933,7 +934,7 @@ void BladeRunnerEngine::shutdown() {
// These are static objects in original game
delete _debugger;
//delete _debugger; Debugger deletion is handled by Engine
_debugger = nullptr;
delete _sceneScript;
@ -1269,12 +1270,6 @@ void BladeRunnerEngine::handleKeyUp(Common::Event &event) {
}
void BladeRunnerEngine::handleKeyDown(Common::Event &event) {
if ((event.kbd.keycode == Common::KEYCODE_d) && (event.kbd.flags & Common::KBD_CTRL)) {
getDebugger()->attach();
getDebugger()->onFrame();
return;
}
if (_vqaIsPlaying && (event.kbd.keycode == Common::KEYCODE_ESCAPE || event.kbd.keycode == Common::KEYCODE_RETURN)) {
_vqaStopIsRequested = true;
_vqaIsPlaying = false;
@ -2319,10 +2314,6 @@ Graphics::Surface BladeRunnerEngine::generateThumbnail() const {
return thumbnail;
}
GUI::Debugger *BladeRunnerEngine::getDebugger() {
return _debugger;
}
Common::String BladeRunnerEngine::getTargetName() const {
return _targetName;
}

View File

@ -322,7 +322,6 @@ public:
void blitToScreen(const Graphics::Surface &src) const;
Graphics::Surface generateThumbnail() const;
GUI::Debugger *getDebugger() override;
Common::String getTargetName() const;
};