mirror of
https://github.com/1dot13/source.git
synced 2026-07-29 13:52:17 +02:00
- if MERCS_CAN_DO_ADVANCED_REPAIRS is TRUE, mercs with the technician trait can raise an item's damage threshold(by merc05)
- Fix: blade weapons ignored their damage chance git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@5917 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -2941,7 +2941,8 @@ BOOLEAN UseBlade( SOLDIERTYPE *pSoldier , INT32 sTargetGridNo )
|
||||
|
||||
(*pObj)[0]->data.objectStatus -= (INT8) Random( bMaxDrop ); // 0 to (maxDrop - 1)
|
||||
|
||||
if ( bMaxDrop > 0 )
|
||||
// Flugente: reduce repair threshold
|
||||
if ( bMaxDrop > 0 && Random(100) < Item[pObj->usItem].usDamageChance )
|
||||
{
|
||||
(*pObj)[0]->data.sRepairThreshold = max((*pObj)[0]->data.objectStatus, (*pObj)[0]->data.sRepairThreshold - 1);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user