Mercurial > mm7
diff mm7_4.cpp @ 232:c879446b4a22
inventory indexing fixed
author | zipi |
---|---|
date | Sun, 17 Feb 2013 15:04:56 +0100 |
parents | 46ae2602aceb |
children | 37dcbe8f3cca |
line wrap: on
line diff
--- a/mm7_4.cpp Sun Feb 17 14:47:34 2013 +0100 +++ b/mm7_4.cpp Sun Feb 17 15:04:56 2013 +0100 @@ -9104,7 +9104,7 @@ || pMouse->GetCursorPos((POINT *)&v12)->x >= 462 || (v9 = v0->GetItemIDAtInventoryIndex(&v18)) == 0 ) return; - v7 = (ItemGen *)&v0->spellbook.pDarkSpellbook.bIsSpellAvailable[36 * v9 + 5]; + v7 = (ItemGen *)&v0->pInventoryItems[v9-1]; LABEL_15: GameUI_DrawItemInfo(v7); return; @@ -12266,7 +12266,7 @@ { v96 = 0; v94 = 4; - v4 = &_this->spellbook.pDarkSpellbook.bIsSpellAvailable[36 * result + 5]; + v4 = (char *)&_this->pInventoryItems[result-1]; if ( v4[20] & 1 ) { v5 = sub_495461("%24", uActiveCharacter - 1, (ItemGen *)v4, (char *)ptr_507BC0->ptr_1C, 4, 0); @@ -12306,7 +12306,7 @@ v96 = 0; v94 = 3; v93 = ptr_507BC0->ptr_1C; - v90 = (ItemGen *)&_this->spellbook.pDarkSpellbook.bIsSpellAvailable[36 * result + 5]; + v90 = (ItemGen *)&_this->pInventoryItems[result-1]; v12 = (int)ptr_507BC0->ptr_1C; uPlayerID = uActiveCharacter - 1; v13 = _this->_490EEE(v90, 3, v12, 3);