diff options
author | Paul Gilbert | 2014-04-10 22:34:26 -0400 |
---|---|---|
committer | Paul Gilbert | 2014-04-10 22:34:26 -0400 |
commit | a30e78137e326c49d7de09f4fb2293bedfdd4a30 (patch) | |
tree | 239825e25efb88cfe976fe3449895535956b87fe /engines | |
parent | 39c66afe6698faaa5ccac78e6cbb85b11c1118b3 (diff) | |
download | scummvm-rg350-a30e78137e326c49d7de09f4fb2293bedfdd4a30.tar.gz scummvm-rg350-a30e78137e326c49d7de09f4fb2293bedfdd4a30.tar.bz2 scummvm-rg350-a30e78137e326c49d7de09f4fb2293bedfdd4a30.zip |
MADS: Added method stub for unhandled action method
Diffstat (limited to 'engines')
-rw-r--r-- | engines/mads/game.h | 5 | ||||
-rw-r--r-- | engines/mads/nebular/game_nebular.cpp | 6 | ||||
-rw-r--r-- | engines/mads/nebular/game_nebular.h | 2 |
3 files changed, 12 insertions, 1 deletions
diff --git a/engines/mads/game.h b/engines/mads/game.h index 56593660b5..c7cb66081d 100644 --- a/engines/mads/game.h +++ b/engines/mads/game.h @@ -156,6 +156,11 @@ public: virtual void doObjectAction() = 0; /** + * Fallback handler for any action that isn't explicitly handled + */ + virtual void unhandledAction() = 0; + + /** * Global game step */ virtual void step() = 0; diff --git a/engines/mads/nebular/game_nebular.cpp b/engines/mads/nebular/game_nebular.cpp index 467f3c3c6b..ed7d976635 100644 --- a/engines/mads/nebular/game_nebular.cpp +++ b/engines/mads/nebular/game_nebular.cpp @@ -376,7 +376,7 @@ void GameNebular::doObjectAction() { _objects.addToInventory(OBJ_COMBINATION); dialogs.showPicture(OBJ_COMBINATION, 851); } else if ((action.isAction(VERB_LOOK) || action.isAction(NOUN_READ)) && - ((id = _objects.getIdFromDesc(action._activeAction._objectNameId)) != 0 || + ((id = _objects.getIdFromDesc(action._activeAction._objectNameId)) > 0 || (action._activeAction._indirectObjectId > 0 && (id = _objects.getIdFromDesc(action._activeAction._indirectObjectId))))) { if (id == OBJ_REPAIR_LIST) { @@ -565,6 +565,10 @@ void GameNebular::doObjectAction() { action._inProgress = false; } +void GameNebular::unhandledAction() { + warning("TODO: unhandledAction"); +} + void GameNebular::step() { if (_player._visible && _player._stepEnabled && !_player._moving && (_player._facing == _player._turnToFacing)) { diff --git a/engines/mads/nebular/game_nebular.h b/engines/mads/nebular/game_nebular.h index e4f4efcd8a..4d011c2f4a 100644 --- a/engines/mads/nebular/game_nebular.h +++ b/engines/mads/nebular/game_nebular.h @@ -67,6 +67,8 @@ public: virtual void doObjectAction(); + virtual void unhandledAction(); + virtual void step(); }; |