diff options
author | Paul Gilbert | 2014-04-08 23:37:16 -0400 |
---|---|---|
committer | Paul Gilbert | 2014-04-08 23:37:16 -0400 |
commit | 6c2c752d055a448dff4cc42e3504be8550f4e72f (patch) | |
tree | 7743fb84f57ebfa5da35c7cd2fe3698ba2f1c100 /engines/mads | |
parent | e144e9810f7aad29575b98faad9fcc64a82d785d (diff) | |
download | scummvm-rg350-6c2c752d055a448dff4cc42e3504be8550f4e72f.tar.gz scummvm-rg350-6c2c752d055a448dff4cc42e3504be8550f4e72f.tar.bz2 scummvm-rg350-6c2c752d055a448dff4cc42e3504be8550f4e72f.zip |
MADS: Fix selecting inventory vocab actions in the user interface
Diffstat (limited to 'engines/mads')
-rw-r--r-- | engines/mads/action.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/engines/mads/action.cpp b/engines/mads/action.cpp index b646ca5f2b..f3e1d2db1e 100644 --- a/engines/mads/action.cpp +++ b/engines/mads/action.cpp @@ -426,11 +426,9 @@ void MADSAction::checkActionAtMousePos() { _hotspotId = -1; _mainObjectSource = CAT_NONE; } else { - int objectId = _vm->_game->_objects._inventoryList[_selectedRow]; - InventoryObject &invObject = _vm->_game->_objects[objectId]; - - _verbType = invObject._vocabList[_selectedRow - 2]._verbType; - _prepType = invObject._vocabList[_selectedRow - 2]._prepType; + InventoryObject &invObject = _vm->_game->_objects.getItem(userInterface._selectedInvIndex); + _verbType = invObject._vocabList[_selectedRow + 1]._verbType; + _prepType = invObject._vocabList[_selectedRow + 1]._prepType; _hotspotId = userInterface._selectedInvIndex; _mainObjectSource = CAT_INV_LIST; |