Mercurial > mm7
comparison mm7_1.cpp @ 600:db4a23580e6c
Chest item view fixed, gold can be taken
author | Gloval |
---|---|
date | Thu, 07 Mar 2013 00:35:10 +0400 |
parents | 55d6b756e03a |
children | 628694cd5744 |
comparison
equal
deleted
inserted
replaced
599:deb559e4fe47 | 600:db4a23580e6c |
---|---|
2508 case EQUIP_RING: | 2508 case EQUIP_RING: |
2509 case EQUIP_AMULET: | 2509 case EQUIP_AMULET: |
2510 if (item_desc->uDamageDice) //"Armor" | 2510 if (item_desc->uDamageDice) //"Armor" |
2511 sprintfex(out_text + 100, "%s: +%d", pGlobalTXT_LocalizationStrings[11], item_desc->uDamageDice + item_desc->uDamageMod); | 2511 sprintfex(out_text + 100, "%s: +%d", pGlobalTXT_LocalizationStrings[11], item_desc->uDamageDice + item_desc->uDamageMod); |
2512 break; | 2512 break; |
2513 case EQUIP_POTION: | 2513 |
2514 if ( inspect_item->uEnchantmentType ) | |
2515 sprintf(out_text + 200, "%s: %d",pGlobalTXT_LocalizationStrings[449] , inspect_item->uEnchantmentType); //"Power" | |
2516 break; | |
2517 case EQUIP_REAGENT: | |
2518 sprintf(out_text + 200, "%s: %d", pGlobalTXT_LocalizationStrings[449], pItemsTable->pItems[inspect_item->uItemID].uDamageDice); //"Power" | |
2519 break; | |
2520 } | 2514 } |
2521 | 2515 |
2522 if ( !v77 ) | 2516 if ( !v77 ) |
2523 { | 2517 { |
2524 //v23 = item_desc->uEquipType; | 2518 if (item_desc->uEquipType ==EQUIP_POTION) //this is CORRECT! do not move to switch! |
2525 if ( inspect_item->uEnchantmentType ) | 2519 { |
2520 if ( inspect_item->uEnchantmentType ) | |
2521 sprintf(out_text + 200, "%s: %d",pGlobalTXT_LocalizationStrings[449] , inspect_item->uEnchantmentType); //"Power" | |
2522 } | |
2523 else if (item_desc->uEquipType == EQUIP_REAGENT) | |
2524 { | |
2525 sprintf(out_text + 200, "%s: %d", pGlobalTXT_LocalizationStrings[449], pItemsTable->pItems[inspect_item->uItemID].uDamageDice); //"Power" | |
2526 } | |
2527 | |
2528 else if ( inspect_item->uEnchantmentType ) | |
2526 { | 2529 { |
2527 sprintf(out_text + 200, "%s: %s +%d", pGlobalTXT_LocalizationStrings[210], | 2530 sprintf(out_text + 200, "%s: %s +%d", pGlobalTXT_LocalizationStrings[210], |
2528 pItemsTable->pEnchantments[inspect_item->uEnchantmentType-1].pBonusStat, inspect_item->_bonus_strength); //"Special" | 2531 pItemsTable->pEnchantments[inspect_item->uEnchantmentType-1].pBonusStat, inspect_item->_bonus_strength); //"Special" |
2529 } | 2532 } |
2530 else if ( inspect_item->uSpecEnchantmentType ) | 2533 else if ( inspect_item->uSpecEnchantmentType ) |
3982 if ( v2 ) | 3985 if ( v2 ) |
3983 v3 = v2 - 1; | 3986 v3 = v2 - 1; |
3984 else | 3987 else |
3985 v3 = -1; | 3988 v3 = -1; |
3986 v4 = pChests[chest_id].pInventoryIndices[v3] - 1; | 3989 v4 = pChests[chest_id].pInventoryIndices[v3] - 1; |
3987 if ( pItemsTable->pItems[pChests[chest_id].igChestItems[v4].uItemID].uEquipType == 18 ) | 3990 if ( pItemsTable->pItems[pChests[chest_id].igChestItems[v4].uItemID].uEquipType == EQUIP_GOLD ) |
3988 { | 3991 { |
3989 party_finds_gold(pItemsTable->pItems[pChests[chest_id].igChestItems[v4].uItemID].uValue, 0); //recheck | 3992 party_finds_gold(pChests[chest_id].igChestItems[v4].uSpecEnchantmentType, 0); |
3990 viewparams->bRedrawGameUI = 1; | 3993 viewparams->bRedrawGameUI = 1; |
3991 } | 3994 } |
3992 else | 3995 else |
3993 { | 3996 { |
3994 pParty->SetHoldingItem(&pChests[chest_id].igChestItems[v4]); | 3997 pParty->SetHoldingItem(&pChests[chest_id].igChestItems[v4]); |