diff options
author | Joost Peters | 2004-01-11 01:36:00 +0000 |
---|---|---|
committer | Joost Peters | 2004-01-11 01:36:00 +0000 |
commit | 9cd7d7959638336b4424ccb50231dd466199ba61 (patch) | |
tree | c9e0451d523a1694233fb426b625e743348ba3c4 /queen/logic.cpp | |
parent | f00ec302b8a6737324b3699bff53f3565f97e75b (diff) | |
download | scummvm-rg350-9cd7d7959638336b4424ccb50231dd466199ba61.tar.gz scummvm-rg350-9cd7d7959638336b4424ccb50231dd466199ba61.tar.bz2 scummvm-rg350-9cd7d7959638336b4424ccb50231dd466199ba61.zip |
- stop voice when skipping dialogue
- scroll 4 inventory items when right-clicking
svn-id: r12314
Diffstat (limited to 'queen/logic.cpp')
-rw-r--r-- | queen/logic.cpp | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/queen/logic.cpp b/queen/logic.cpp index 2f0803ced8..84fb807bea 100644 --- a/queen/logic.cpp +++ b/queen/logic.cpp @@ -1026,17 +1026,18 @@ void Logic::inventoryDeleteItem(uint16 itemNum, bool refresh) { void Logic::inventoryScroll(uint16 count, bool up) { if (!(numItemsInventory() > 4)) return; - - if (up) { - for (int i = 3; i > 0; i--) - _inventoryItem[i] = _inventoryItem[i - 1]; - _inventoryItem[0] = previousInventoryItem(_inventoryItem[0]); - } else { - for (int i = 0; i < 3; i++) - _inventoryItem[i] = _inventoryItem[i + 1]; - _inventoryItem[3] = nextInventoryItem(_inventoryItem[3]); + while (count--) { + if (up) { + for (int i = 3; i > 0; i--) + _inventoryItem[i] = _inventoryItem[i - 1]; + _inventoryItem[0] = previousInventoryItem(_inventoryItem[0]); + } else { + for (int i = 0; i < 3; i++) + _inventoryItem[i] = _inventoryItem[i + 1]; + _inventoryItem[3] = nextInventoryItem(_inventoryItem[3]); + } } - + inventoryRefresh(); } |