comparison mm7_6.cpp @ 574:f90753ebabe3

Merge
author Nomad
date Wed, 06 Mar 2013 06:41:36 +0200
parents 7c0763248a87 f54481c85df8
children c03428cb4119
comparison
equal deleted inserted replaced
573:7c0763248a87 574:f90753ebabe3
1429 Dst.uNumCharges = v6; 1429 Dst.uNumCharges = v6;
1430 Dst.uMaxCharges = v6; 1430 Dst.uMaxCharges = v6;
1431 v4 = Dst.uItemID; 1431 v4 = Dst.uItemID;
1432 } 1432 }
1433 if ( pItemsTable->pItems[v5].uEquipType == 14 && v4 != 220 ) 1433 if ( pItemsTable->pItems[v5].uEquipType == 14 && v4 != 220 )
1434 Dst.uEncantmentType = 2 * rand() % 4 + 2; 1434 Dst.uEnchantmentType = 2 * rand() % 4 + 2;
1435 pItemsTable->SetSpecialBonus(&Dst); 1435 pItemsTable->SetSpecialBonus(&Dst);
1436 if ( !pParty->AddItem(&Dst) ) 1436 if ( !pParty->AddItem(&Dst) )
1437 pParty->SetHoldingItem(&Dst); 1437 pParty->SetHoldingItem(&Dst);
1438 pActor->uCarriedItemID = 0; 1438 pActor->uCarriedItemID = 0;
1439 if ( pActor->array_000234[0].uItemID ) 1439 if ( pActor->array_000234[0].uItemID )
3978 { 3978 {
3979 if (!v730c->Broken()) 3979 if (!v730c->Broken())
3980 { 3980 {
3981 if (!v730c->uSpecEnchantmentType) 3981 if (!v730c->uSpecEnchantmentType)
3982 { 3982 {
3983 if (!v730c->uEncantmentType) 3983 if (!v730c->uEnchantmentType)
3984 { 3984 {
3985 v68 = BYTE4(v726->pConditions[3]); 3985 v68 = BYTE4(v726->pConditions[3]);
3986 if ( !v68 || v68 == 1 || v68 == 2 ) 3986 if ( !v68 || v68 == 1 || v68 == 2 )
3987 { 3987 {
3988 if ( !pItemsTable->IsMaterialNonCommon(v730c) ) 3988 if ( !pItemsTable->IsMaterialNonCommon(v730c) )
5305 else 5305 else
5306 { 5306 {
5307 if ( v731 != 4 5307 if ( v731 != 4
5308 || (v245 = (int)&v726->pInventoryItems[a2], v246 = *(int *)v245, *(int *)v245 > 134) 5308 || (v245 = (int)&v726->pInventoryItems[a2], v246 = *(int *)v245, *(int *)v245 > 134)
5309 || v726->pInventoryItems[a2].uSpecEnchantmentType != 0 5309 || v726->pInventoryItems[a2].uSpecEnchantmentType != 0
5310 || v726->pInventoryItems[a2].uEncantmentType != 0 5310 || v726->pInventoryItems[a2].uEnchantmentType != 0
5311 || v726->pInventoryItems[a2]._bonus_strength != 0 5311 || v726->pInventoryItems[a2]._bonus_strength != 0
5312 || (_this = (ItemGen *)((char *)&v726->pInventoryItems[a2] + 20), v726->pInventoryItems[a2].Broken()) ) 5312 || (_this = (ItemGen *)((char *)&v726->pInventoryItems[a2] + 20), v726->pInventoryItems[a2].Broken()) )
5313 goto LABEL_616; 5313 goto LABEL_616;
5314 v247 = (char *)&pItemsTable->pItems[v246].pIconName; 5314 v247 = (char *)&pItemsTable->pItems[v246].pIconName;
5315 LODWORD(v725) = (int)v247; 5315 LODWORD(v725) = (int)v247;
5410 _this = v289; 5410 _this = v289;
5411 v290 = v289->uItemID; 5411 v290 = v289->uItemID;
5412 LODWORD(v725) = (int)(char *)&pItemsTable + 48 * v290 + 4; 5412 LODWORD(v725) = (int)(char *)&pItemsTable + 48 * v290 + 4;
5413 if ( v290 > 134 5413 if ( v290 > 134
5414 || _this->uSpecEnchantmentType != 0 5414 || _this->uSpecEnchantmentType != 0
5415 || _this->uEncantmentType != 0 5415 || _this->uEnchantmentType != 0
5416 || _this->_bonus_strength != 0 5416 || _this->_bonus_strength != 0
5417 || (v291 = pItemsTable->pItems[v290].uEquipType) == 0 5417 || (v291 = pItemsTable->pItems[v290].uEquipType) == 0
5418 || v291 == 1 5418 || v291 == 1
5419 || v291 == 2 5419 || v291 == 2
5420 || _this->Broken()) 5420 || _this->Broken())
5485 else 5485 else
5486 { 5486 {
5487 v293 = rand(); 5487 v293 = rand();
5488 v294 = _this; 5488 v294 = _this;
5489 v295 = v293 % 10;// pItemsTable->field_116D8[pItemsTable->pItems[_this->uItemID].uEquipType]; 5489 v295 = v293 % 10;// pItemsTable->field_116D8[pItemsTable->pItems[_this->uItemID].uEquipType];
5490 _this->uEncantmentType = 0; 5490 _this->uEnchantmentType = 0;
5491 for ( kk = pItemsTable->pEnchantments[0].to_item[pItemsTable->pItems[v294->uItemID].uEquipType + 1]; 5491 for ( kk = pItemsTable->pEnchantments[0].to_item[pItemsTable->pItems[v294->uItemID].uEquipType + 1];
5492 ; 5492 ;
5493 kk += pItemsTable->pEnchantments[v294->uEncantmentType].to_item[pItemsTable->pItems[v294->uItemID].uEquipType 5493 kk += pItemsTable->pEnchantments[v294->uEnchantmentType].to_item[pItemsTable->pItems[v294->uItemID].uEquipType
5494 + 1] ) 5494 + 1] )
5495 { 5495 {
5496 ++v294->uEncantmentType; 5496 ++v294->uEnchantmentType;
5497 if ( kk >= v295 ) 5497 if ( kk >= v295 )
5498 break; 5498 break;
5499 } 5499 }
5500 v294->_bonus_strength = 10//pItemsTable->field_116D8[18] 5500 v294->_bonus_strength = 10//pItemsTable->field_116D8[18]
5501 + rand() % 10;//(pItemsTable->field_116D8[19] - pItemsTable->field_116D8[18] + 1); 5501 + rand() % 10;//(pItemsTable->field_116D8[19] - pItemsTable->field_116D8[18] + 1);