Skip to content

Commit

Permalink
ACCESS: MM - Fix a crash
Browse files Browse the repository at this point in the history
  • Loading branch information
Strangerke committed Feb 6, 2015
1 parent a05e862 commit ef9c9b7
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions engines/access/inventory.cpp
Expand Up @@ -73,19 +73,20 @@ InventoryManager::InventoryManager(AccessEngine *vm) : Manager(vm) {
names = Amazon::INVENTORY_NAMES;
combineP = &Amazon::COMBO_TABLE[0][0];
_inv.resize(85);
for (uint i = 0; i < _inv.size(); ++i, combineP += 4)
_inv[i].load(names[i], combineP);
break;
case GType_MartianMemorandum:
names = Martian::INVENTORY_NAMES;
combineP = nullptr;
_inv.resize(55);
for (uint i = 0; i < _inv.size(); ++i)
_inv[i].load(names[i], nullptr);
break;
default:
error("Unknown game");
}

for (uint i = 0; i < _inv.size(); ++i, combineP += 4)
_inv[i].load(names[i], combineP);

for (uint i = 0; i < 26; ++i) {
const int *r = INVCOORDS[i];
_invCoords.push_back(Common::Rect(r[0], r[2], r[1], r[3]));
Expand Down

0 comments on commit ef9c9b7

Please sign in to comment.