Mercurial > mm7
comparison Player.cpp @ 1041:c5498375832a
m
author | Gloval |
---|---|
date | Thu, 23 May 2013 08:26:51 +0400 |
parents | 4430136083a6 |
children | d36681a9e4f8 |
comparison
equal
deleted
inserted
replaced
1040:4430136083a6 | 1041:c5498375832a |
---|---|
5423 { | 5423 { |
5424 if ( CheckHiredNPCSpeciality(Hunter) ) | 5424 if ( CheckHiredNPCSpeciality(Hunter) ) |
5425 v2 = 6; | 5425 v2 = 6; |
5426 if ( CheckHiredNPCSpeciality(Sage) ) | 5426 if ( CheckHiredNPCSpeciality(Sage) ) |
5427 v2 += 6; | 5427 v2 += 6; |
5428 v8 = (CHARACTER_ATTRIBUTE_TYPE)20; | 5428 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_MONSTER_ID, 0); |
5429 v2 += GetItemsBonus(v8, 0); | |
5430 } | 5429 } |
5431 break; | 5430 break; |
5432 | 5431 |
5433 case PLAYER_SKILL_ARMSMASTER: | 5432 case PLAYER_SKILL_ARMSMASTER: |
5434 { | 5433 { |
5435 if ( CheckHiredNPCSpeciality(Armsmaster) ) | 5434 if ( CheckHiredNPCSpeciality(Armsmaster) ) |
5436 v2 = 2; | 5435 v2 = 2; |
5437 if ( CheckHiredNPCSpeciality(Weaponsmaster) ) | 5436 if ( CheckHiredNPCSpeciality(Weaponsmaster) ) |
5438 v2 += 3; | 5437 v2 += 3; |
5439 v8 = (CHARACTER_ATTRIBUTE_TYPE)21; | 5438 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_ARMSMASTER, 0); |
5440 v2 += GetItemsBonus(v8, 0); | |
5441 } | 5439 } |
5442 break; | 5440 break; |
5443 | 5441 |
5444 case PLAYER_SKILL_STEALING: | 5442 case PLAYER_SKILL_STEALING: |
5445 { | 5443 { |
5446 if (CheckHiredNPCSpeciality(Burglar)) | 5444 if (CheckHiredNPCSpeciality(Burglar)) |
5447 v2 = 8; | 5445 v2 = 8; |
5448 v8 = (CHARACTER_ATTRIBUTE_TYPE)17; | 5446 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_STEALING, 0); |
5449 v2 += GetItemsBonus(v8, 0); | |
5450 } | 5447 } |
5451 break; | 5448 break; |
5452 | 5449 |
5453 | 5450 |
5454 case PLAYER_SKILL_ALCHEMY: | 5451 case PLAYER_SKILL_ALCHEMY: |
5455 { | 5452 { |
5456 if ( CheckHiredNPCSpeciality(Herbalist) ) | 5453 if ( CheckHiredNPCSpeciality(Herbalist) ) |
5457 v2 = 4; | 5454 v2 = 4; |
5458 if ( CheckHiredNPCSpeciality(Apothecary) ) | 5455 if ( CheckHiredNPCSpeciality(Apothecary) ) |
5459 v2 += 8; | 5456 v2 += 8; |
5460 v8 = (CHARACTER_ATTRIBUTE_TYPE)16; | 5457 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_ALCHEMY, 0); |
5461 v2 += GetItemsBonus(v8, 0); | |
5462 } | 5458 } |
5463 break; | 5459 break; |
5464 | 5460 |
5465 case PLAYER_SKILL_LEARNING: | 5461 case PLAYER_SKILL_LEARNING: |
5466 { | 5462 { |
5468 v2 = 10; | 5464 v2 = 10; |
5469 if ( CheckHiredNPCSpeciality(Instructor) ) | 5465 if ( CheckHiredNPCSpeciality(Instructor) ) |
5470 v2 += 15; | 5466 v2 += 15; |
5471 if ( CheckHiredNPCSpeciality(Scholar) ) | 5467 if ( CheckHiredNPCSpeciality(Scholar) ) |
5472 v2 += 5; | 5468 v2 += 5; |
5473 v8 = (CHARACTER_ATTRIBUTE_TYPE)46; | 5469 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_LEARNING, 0); |
5474 v2 += GetItemsBonus(v8, 0); | |
5475 } | 5470 } |
5476 break; | 5471 break; |
5477 | 5472 |
5478 case PLAYER_SKILL_UNARMED: | 5473 case PLAYER_SKILL_UNARMED: |
5479 { | 5474 { |
5480 if (CheckHiredNPCSpeciality(Monk) ) | 5475 if (CheckHiredNPCSpeciality(Monk) ) |
5481 v2 = 2; | 5476 v2 = 2; |
5482 v8 = (CHARACTER_ATTRIBUTE_TYPE)23; | 5477 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_UNARMED, 0); |
5483 v2 += GetItemsBonus(v8, 0); | |
5484 } | 5478 } |
5485 break; | 5479 break; |
5486 | 5480 |
5487 case PLAYER_SKILL_DODGE: | 5481 case PLAYER_SKILL_DODGE: |
5488 { | 5482 { |
5489 if ( CheckHiredNPCSpeciality(Monk) ) | 5483 if ( CheckHiredNPCSpeciality(Monk) ) |
5490 v2 = 2; | 5484 v2 = 2; |
5491 v8 = (CHARACTER_ATTRIBUTE_TYPE)22; | 5485 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_DODGE, 0); |
5492 v2 += GetItemsBonus(v8, 0); | |
5493 } | 5486 } |
5494 break; | 5487 break; |
5495 | 5488 |
5496 case PLAYER_SKILL_BOW: | 5489 case PLAYER_SKILL_BOW: |
5497 v8 = (CHARACTER_ATTRIBUTE_TYPE)44; | 5490 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_BOW, 0); |
5498 v2 += GetItemsBonus(v8, 0); | |
5499 break; | 5491 break; |
5500 case PLAYER_SKILL_SHIELD: | 5492 case PLAYER_SKILL_SHIELD: |
5501 v8 = (CHARACTER_ATTRIBUTE_TYPE)45; | 5493 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_SHIELD, 0); |
5502 v2 += GetItemsBonus(v8, 0); | |
5503 break; | 5494 break; |
5504 | 5495 |
5505 case PLAYER_SKILL_EARTH: | 5496 case PLAYER_SKILL_EARTH: |
5506 if ( CheckHiredNPCSpeciality(Apprentice) ) | 5497 if ( CheckHiredNPCSpeciality(Apprentice) ) |
5507 v2 = 2; | 5498 v2 = 2; |
5509 v2 += 3; | 5500 v2 += 3; |
5510 if ( CheckHiredNPCSpeciality(Spellmaster) ) | 5501 if ( CheckHiredNPCSpeciality(Spellmaster) ) |
5511 v2 += 4; | 5502 v2 += 4; |
5512 if ( classType == PLAYER_CLASS_WARLOCK && PartyHasDragon() ) | 5503 if ( classType == PLAYER_CLASS_WARLOCK && PartyHasDragon() ) |
5513 v2 += 3; | 5504 v2 += 3; |
5514 v8 = (CHARACTER_ATTRIBUTE_TYPE)37; | 5505 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_EARTH, 0); |
5515 v2 += GetItemsBonus(v8, 0); | |
5516 break; | 5506 break; |
5517 case PLAYER_SKILL_FIRE: | 5507 case PLAYER_SKILL_FIRE: |
5518 if ( CheckHiredNPCSpeciality(Apprentice) ) | 5508 if ( CheckHiredNPCSpeciality(Apprentice) ) |
5519 v2 = 2; | 5509 v2 = 2; |
5520 if ( CheckHiredNPCSpeciality(Mystic) ) | 5510 if ( CheckHiredNPCSpeciality(Mystic) ) |
5521 v2 += 3; | 5511 v2 += 3; |
5522 if ( CheckHiredNPCSpeciality(Spellmaster) ) | 5512 if ( CheckHiredNPCSpeciality(Spellmaster) ) |
5523 v2 += 4; | 5513 v2 += 4; |
5524 if ( classType == PLAYER_CLASS_WARLOCK && PartyHasDragon() ) | 5514 if ( classType == PLAYER_CLASS_WARLOCK && PartyHasDragon() ) |
5525 v2 += 3; | 5515 v2 += 3; |
5526 v8 = (CHARACTER_ATTRIBUTE_TYPE)34; | 5516 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_FIRE, 0); |
5527 v2 += GetItemsBonus(v8, 0); | |
5528 break; | 5517 break; |
5529 case PLAYER_SKILL_AIR: | 5518 case PLAYER_SKILL_AIR: |
5530 if ( CheckHiredNPCSpeciality(Apprentice) ) | 5519 if ( CheckHiredNPCSpeciality(Apprentice) ) |
5531 v2 = 2; | 5520 v2 = 2; |
5532 if ( CheckHiredNPCSpeciality(Mystic) ) | 5521 if ( CheckHiredNPCSpeciality(Mystic) ) |
5533 v2 += 3; | 5522 v2 += 3; |
5534 if ( CheckHiredNPCSpeciality(Spellmaster) ) | 5523 if ( CheckHiredNPCSpeciality(Spellmaster) ) |
5535 v2 += 4; | 5524 v2 += 4; |
5536 if ( classType == PLAYER_CLASS_WARLOCK && PartyHasDragon() ) | 5525 if ( classType == PLAYER_CLASS_WARLOCK && PartyHasDragon() ) |
5537 v2 += 3; | 5526 v2 += 3; |
5538 v8 = (CHARACTER_ATTRIBUTE_TYPE)35; | 5527 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_AIR, 0); |
5539 v2 += GetItemsBonus(v8, 0); | |
5540 break; | 5528 break; |
5541 case PLAYER_SKILL_WATER: | 5529 case PLAYER_SKILL_WATER: |
5542 if ( CheckHiredNPCSpeciality(Apprentice) ) | 5530 if ( CheckHiredNPCSpeciality(Apprentice) ) |
5543 v2 = 2; | 5531 v2 = 2; |
5544 if ( CheckHiredNPCSpeciality(Mystic) ) | 5532 if ( CheckHiredNPCSpeciality(Mystic) ) |
5545 v2 += 3; | 5533 v2 += 3; |
5546 if ( CheckHiredNPCSpeciality(Spellmaster) ) | 5534 if ( CheckHiredNPCSpeciality(Spellmaster) ) |
5547 v2 += 4; | 5535 v2 += 4; |
5548 if ( classType == PLAYER_CLASS_WARLOCK && PartyHasDragon() ) | 5536 if ( classType == PLAYER_CLASS_WARLOCK && PartyHasDragon() ) |
5549 v2 += 3; | 5537 v2 += 3; |
5550 v8 = (CHARACTER_ATTRIBUTE_TYPE)36; | 5538 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_WATER, 0); |
5551 v2 += GetItemsBonus(v8, 0); | |
5552 break; | 5539 break; |
5553 case PLAYER_SKILL_SPIRIT: | 5540 case PLAYER_SKILL_SPIRIT: |
5554 if ( CheckHiredNPCSpeciality(Acolyte2) ) | 5541 if ( CheckHiredNPCSpeciality(Acolyte2) ) |
5555 v2 = 2; | 5542 v2 = 2; |
5556 if ( CheckHiredNPCSpeciality(Initiate) ) | 5543 if ( CheckHiredNPCSpeciality(Initiate) ) |
5557 v2 += 3; | 5544 v2 += 3; |
5558 if ( CheckHiredNPCSpeciality(Prelate) ) | 5545 if ( CheckHiredNPCSpeciality(Prelate) ) |
5559 v2 += 4; | 5546 v2 += 4; |
5560 v8 = (CHARACTER_ATTRIBUTE_TYPE)38; | 5547 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_SPIRIT, 0); |
5561 v2 += GetItemsBonus(v8, 0); | |
5562 break; | 5548 break; |
5563 case PLAYER_SKILL_MIND: | 5549 case PLAYER_SKILL_MIND: |
5564 if ( CheckHiredNPCSpeciality(Acolyte2) ) | 5550 if ( CheckHiredNPCSpeciality(Acolyte2) ) |
5565 v2 = 2; | 5551 v2 = 2; |
5566 if ( CheckHiredNPCSpeciality(Initiate) ) | 5552 if ( CheckHiredNPCSpeciality(Initiate) ) |
5567 v2 += 3; | 5553 v2 += 3; |
5568 if ( CheckHiredNPCSpeciality(Prelate) ) | 5554 if ( CheckHiredNPCSpeciality(Prelate) ) |
5569 v2 += 4; | 5555 v2 += 4; |
5570 v8 = (CHARACTER_ATTRIBUTE_TYPE)39; | 5556 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_MIND, 0); |
5571 v2 += GetItemsBonus(v8, 0); | |
5572 break; | 5557 break; |
5573 case PLAYER_SKILL_BODY: | 5558 case PLAYER_SKILL_BODY: |
5574 if ( CheckHiredNPCSpeciality(Acolyte2) ) | 5559 if ( CheckHiredNPCSpeciality(Acolyte2) ) |
5575 v2 = 2; | 5560 v2 = 2; |
5576 if ( CheckHiredNPCSpeciality(Initiate) ) | 5561 if ( CheckHiredNPCSpeciality(Initiate) ) |
5577 v2 += 3; | 5562 v2 += 3; |
5578 if ( CheckHiredNPCSpeciality(Prelate) ) | 5563 if ( CheckHiredNPCSpeciality(Prelate) ) |
5579 v2 += 4; | 5564 v2 += 4; |
5580 v8 = (CHARACTER_ATTRIBUTE_TYPE)40; | 5565 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_BODY, 0); |
5581 v2 += GetItemsBonus(v8, 0); | |
5582 break; | 5566 break; |
5583 case PLAYER_SKILL_LIGHT: | 5567 case PLAYER_SKILL_LIGHT: |
5584 v8 = (CHARACTER_ATTRIBUTE_TYPE)41; | 5568 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_LIGHT, 0); |
5585 v2 += GetItemsBonus(v8, 0); | |
5586 break; | 5569 break; |
5587 case PLAYER_SKILL_DARK: | 5570 case PLAYER_SKILL_DARK: |
5588 { | 5571 { |
5589 v8 = (CHARACTER_ATTRIBUTE_TYPE)42; | 5572 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_DARK, 0); |
5590 v2 += GetItemsBonus(v8, 0); | |
5591 } | 5573 } |
5592 break; | 5574 break; |
5593 | 5575 |
5594 case PLAYER_SKILL_MERCHANT: | 5576 case PLAYER_SKILL_MERCHANT: |
5595 { | 5577 { |
5612 v2 += 5; | 5594 v2 += 5; |
5613 } | 5595 } |
5614 break; | 5596 break; |
5615 | 5597 |
5616 case PLAYER_SKILL_ITEM_ID: | 5598 case PLAYER_SKILL_ITEM_ID: |
5617 v8 = (CHARACTER_ATTRIBUTE_TYPE)19; | 5599 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_ITEM_ID, 0); |
5618 v2 += GetItemsBonus(v8, 0); | |
5619 break; | 5600 break; |
5620 case PLAYER_SKILL_MEDITATION: | 5601 case PLAYER_SKILL_MEDITATION: |
5621 v8 = (CHARACTER_ATTRIBUTE_TYPE)43; | 5602 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_MEDITATION, 0); |
5622 v2 += GetItemsBonus(v8, 0); | |
5623 break; | 5603 break; |
5624 case PLAYER_SKILL_TRAP_DISARM: | 5604 case PLAYER_SKILL_TRAP_DISARM: |
5625 { | 5605 { |
5626 if ( CheckHiredNPCSpeciality(Tinker) ) | 5606 if ( CheckHiredNPCSpeciality(Tinker) ) |
5627 v2 = 4; | 5607 v2 = 4; |
5628 if ( CheckHiredNPCSpeciality(Locksmith) ) | 5608 if ( CheckHiredNPCSpeciality(Locksmith) ) |
5629 v2 += 6; | 5609 v2 += 6; |
5630 if ( CheckHiredNPCSpeciality(Burglar) ) | 5610 if ( CheckHiredNPCSpeciality(Burglar) ) |
5631 v2 += 8; | 5611 v2 += 8; |
5632 v8 = (CHARACTER_ATTRIBUTE_TYPE)18; | 5612 v2 += GetItemsBonus(CHARACTER_ATTRIBUTE_SKILL_TRAP_DISARM, 0); |
5633 v2 += GetItemsBonus(v8, 0); | |
5634 } | 5613 } |
5635 break; | 5614 break; |
5636 } | 5615 } |
5637 | 5616 |
5638 v3 = pActiveSkills[uSkillType]; | 5617 v3 = pActiveSkills[uSkillType]; |