Mercurial > might-and-magic-trilogy
diff mm7_1.cpp @ 23:509744251c8e
Player-related members
author | Nomad |
---|---|
date | Sun, 14 Oct 2012 00:27:38 +0200 |
parents | 540178ef9b18 |
children | 93bf1d5f6a6d |
line wrap: on
line diff
--- a/mm7_1.cpp Sat Oct 13 20:18:28 2012 +0200 +++ b/mm7_1.cpp Sun Oct 14 00:27:38 2012 +0200 @@ -865,7 +865,7 @@ v15 = v13 + 32; if ( v9 < 14 ) v14 = 14; - v16 = v5->uAttributtes; + v16 = v5->uAttributes; v17 = a2a + ((v15 - v10) >> 1) + pSRZBufferLineOffsets[a3 + ((((v14 - 14) & 0xFFFFFFE0) - v9 + 32) >> 1)]; if ( !(v16 & 0xF0) ) { @@ -904,7 +904,7 @@ if ( dword_50C9A8 <= 0 ) { dword_50C9A8 = 0; - LOBYTE(v25->uAttributtes) &= 0xFu; + LOBYTE(v25->uAttributes) &= 0xFu; ptr_50C9A4 = 0; } v19 = (double)GetTickCount() * 0.1; @@ -1180,7 +1180,7 @@ 84, 0); v32 = v45 + v31; - v48 = pPlayer->GetMajorConditionrIdx(); + v48 = pPlayer->GetMajorConditionIdx(); if ( !v43 ) pGUIWindow_CurrentMenu->DrawTextInRect( pFontArrus, @@ -2536,8 +2536,8 @@ v81 >>= 1; v8 = _this; if ( !v3[46] ) - _this->uAttributtes |= 1u; - v9 = v8->uAttributtes; + _this->uAttributes |= 1u; + v9 = v8->uAttributes; v77 = 0; a2.y = v9 & 2; if ( pItemsTable->pItems[v8->uItemID].uEquipType == 18 ) @@ -2549,8 +2549,8 @@ v10 = pPlayers[uActiveCharacter]->CanIdentify(_this) == 1; v11 = _this; if ( v10 ) - _this->uAttributtes |= 1u; - v10 = (v11->uAttributtes & 1) == 0; + _this->uAttributes |= 1u; + v10 = (v11->uAttributes & 1) == 0; v83 = (char *)9; if ( v10 ) { @@ -2574,8 +2574,8 @@ v10 = pPlayers[uActiveCharacter]->CanRepair(_this) == 1; v12 = _this; if ( v10 ) - _this->uAttributtes = _this->uAttributtes & 0xFFFFFFFD | 1; - v10 = (v12->uAttributtes & 2) == 0; + _this->uAttributes = _this->uAttributes & 0xFFFFFFFD | 1; + v10 = (v12->uAttributes & 2) == 0; v83 = (char *)11; if ( v10 ) v83 = (char *)10; @@ -2588,9 +2588,9 @@ } } } - v13 = _this->uAttributtes; - v14 = _this->uAttributtes & 1; - a2.y = _this->uAttributtes & 1; + v13 = _this->uAttributes; + v14 = _this->uAttributes & 1; + a2.y = _this->uAttributes & 1; if ( v13 & 2 ) { v79._415551(0); @@ -2725,7 +2725,7 @@ v79.uFrameHeight = v73->uTextureHeight + v81 + 54; if ( (signed int)Str > (signed int)v79.uFrameHeight ) v79.uFrameHeight = (unsigned int)Str; - if ( _this->uAttributtes & 8 && (_this->uAdditionalValue || _this->_bonus_type) ) + if ( _this->uAttributes & 8 && (_this->uAdditionalValue || _this->_bonus_type) ) v79.uFrameHeight += LOBYTE(v82->uFontHeight); v83 = 0; if ( LOBYTE(pFontArrus->uFontHeight) ) @@ -2795,7 +2795,7 @@ } else { - if ( _this->uAttributtes & 8 && (_this->uAdditionalValue || _this->_bonus_type) ) + if ( _this->uAttributes & 8 && (_this->uAdditionalValue || _this->_bonus_type) ) { sub_493F79((stru351 *)&v67, _this->uExpireTime - pParty->uTimePlayed); strcpy(pTmpBuf, "Duration:"); @@ -2819,7 +2819,7 @@ v37 = _this->GetValue(); sprintfex(pTmpBuf, "%s: %lu", pGlobalTXT_LocalizationStrings[465], v37); v79.DrawText(v82, 100, v79.uFrameHeight - LOBYTE(v82->uFontHeight), 0, pTmpBuf, 0, 0, 0); - v38 = _this->uAttributtes; + v38 = _this->uAttributes; if ( BYTE1(v38) & 1 ) { v61 = 0; @@ -4379,7 +4379,7 @@ v11 = 0; if ( uChestArea > 0 ) { - v12 = &pChests[v3].mm7__vector_pItems[0].uAttributtes; + v12 = &pChests[v3].mm7__vector_pItems[0].uAttributes; do { v9 = *(v12 - 5); @@ -5171,7 +5171,7 @@ v14 = pRenderer->pActiveZBuffer[pX + pSRZBufferLineOffsets[pY]]; if ( v14 == zero || v14 == -65536 || (unsigned int)v14 >= 0x1388 ) goto _return; - v15 = (ItemGen *)&pPlayers[uActiveCharacter]->pDarkSpellbook.bIsSpellAvailable[36 * v14 + 5]; + v15 = (ItemGen *)&pPlayers[uActiveCharacter]->spellbook.pDarkSpellbook.bIsSpellAvailable[36 * v14 + 5]; goto LABEL_49; } _click_on_game_ui: @@ -5528,7 +5528,7 @@ if ( uActiveCharacter && (v2 = pPlayers[uActiveCharacter]->AddItem(0xFFFFFFFFu, pParty->pPickedItem.uItemID)) != 0 ) { - memcpy(&pPlayers[uActiveCharacter]->pDarkSpellbook.bIsSpellAvailable[36 * v2 + 5], &pParty->pPickedItem, 0x24u); + memcpy(&pPlayers[uActiveCharacter]->spellbook.pDarkSpellbook.bIsSpellAvailable[36 * v2 + 5], &pParty->pPickedItem, 0x24u); } else { @@ -5544,7 +5544,7 @@ if ( (signed int)v3 >= (signed int)pParty->pHirelings ) goto LABEL_10; } - memcpy(&pParty->pPlayers[v12].pDarkSpellbook.bIsSpellAvailable[36 * v4 + 5], &pParty->pPickedItem, 0x24u); + memcpy(&pParty->pPlayers[v12].spellbook.pDarkSpellbook.bIsSpellAvailable[36 * v4 + 5], &pParty->pPickedItem, 0x24u); pMouse->RemoveHoldingItem(); LABEL_10: if ( v12 != 4 ) @@ -5612,7 +5612,7 @@ v3 = pPlayers[v1]; if ( v2 ) { - memcpy(&v3->pDarkSpellbook.bIsSpellAvailable[36 * v2 + 5], &pParty->pPickedItem, 0x24u); + memcpy(&v3->spellbook.pDarkSpellbook.bIsSpellAvailable[36 * v2 + 5], &pParty->pPickedItem, 0x24u); viewparams->bRedrawGameUI = 1; pMouse->RemoveHoldingItem(); return; @@ -5737,7 +5737,7 @@ *((short *)ptr_507BD4->ptr_1C + 2) = uActiveCharacter - 1; *((int *)ptr_507BD4->ptr_1C + 3) = v6 - 1; *((short *)ptr_507BD4->ptr_1C + 3) = a4; - ptr_50C9A4 = (ItemGen *)&v0->pDarkSpellbook.bIsSpellAvailable[36 * v6 + 5]; + ptr_50C9A4 = (ItemGen *)&v0->spellbook.pDarkSpellbook.bIsSpellAvailable[36 * v6 + 5]; unk_50C9A0 = 0; if ( pMessageQueue_50CBD0->uNumMessages ) pMessageQueue_50CBD0->uNumMessages = pMessageQueue_50CBD0->pMessages[0].field_8 != 0; @@ -5756,7 +5756,7 @@ { if ( !v8 ) return; - memcpy(&pParty->pPickedItem, &v0->pDarkSpellbook.bIsSpellAvailable[36 * v8 + 5], sizeof(pParty->pPickedItem)); + memcpy(&pParty->pPickedItem, &v0->spellbook.pDarkSpellbook.bIsSpellAvailable[36 * v8 + 5], sizeof(pParty->pPickedItem)); v0->RemoveItemAtInventoryIndex(a4); v9 = pParty->pPickedItem.uItemID; goto LABEL_24; @@ -5764,7 +5764,7 @@ v13 = v8; if ( v8 ) { - a2.y = (LONG)&v0->pDarkSpellbook.bIsSpellAvailable[36 * v8 + 5]; + a2.y = (LONG)&v0->spellbook.pDarkSpellbook.bIsSpellAvailable[36 * v8 + 5]; memcpy(&this_, (const void *)a2.y, sizeof(this_)); v0->RemoveItemAtInventoryIndex(a4); pX = v0->AddItem2(a4, &pParty->pPickedItem); @@ -5788,7 +5788,7 @@ pX = v10; if ( v10 || (v10 = v0->AddItem(0xFFFFFFFFu, pParty->pPickedItem.uItemID), (pX = v10) != 0) ) { - memcpy(&v0->pDarkSpellbook.bIsSpellAvailable[36 * v10 + 5], &pParty->pPickedItem, 0x24u); + memcpy(&v0->spellbook.pDarkSpellbook.bIsSpellAvailable[36 * v10 + 5], &pParty->pPickedItem, 0x24u); pMouse->RemoveHoldingItem(); } }