diff --git a/Tactical/Interface Enhanced.cpp b/Tactical/Interface Enhanced.cpp index d9c6c936..a33a27e1 100644 --- a/Tactical/Interface Enhanced.cpp +++ b/Tactical/Interface Enhanced.cpp @@ -4321,7 +4321,7 @@ void DrawAmmoStats( OBJECTTYPE * gpItemDescObject ) } //////////////// POISON PERCENTAGE - BltVideoObjectFromIndex( guiSAVEBUFFER, guiItemInfoWH40KIcon, 6, gItemDescGenRegions[4][0].sLeft+sOffsetX, gItemDescGenRegions[4][0].sTop+sOffsetY, VO_BLT_SRCTRANSPARENCY, NULL ); + BltVideoObjectFromIndex( guiSAVEBUFFER, guiItemInfoWH40KIcon, 0, gItemDescGenRegions[4][0].sLeft+sOffsetX, gItemDescGenRegions[4][0].sTop+sOffsetY, VO_BLT_SRCTRANSPARENCY, NULL ); if ( gGameExternalOptions.fDirtSystem ) // Flugente { @@ -5233,7 +5233,7 @@ void DrawAdvancedStats( OBJECTTYPE * gpItemDescObject ) { if (cnt >= sFirstLine && cnt < sLastLine) { - BltVideoObjectFromIndex( guiSAVEBUFFER, guiItemInfoWH40KIcon, 6, gItemDescAdvRegions[cnt-sFirstLine][0].sLeft + sOffsetX, gItemDescAdvRegions[cnt-sFirstLine][0].sTop + sOffsetY, VO_BLT_SRCTRANSPARENCY, NULL ); + BltVideoObjectFromIndex( guiSAVEBUFFER, guiItemInfoWH40KIcon, 0, gItemDescAdvRegions[cnt-sFirstLine][0].sLeft + sOffsetX, gItemDescAdvRegions[cnt-sFirstLine][0].sTop + sOffsetY, VO_BLT_SRCTRANSPARENCY, NULL ); } cnt++; } diff --git a/Tactical/LOS.cpp b/Tactical/LOS.cpp index b80484c9..e46ba8cf 100644 --- a/Tactical/LOS.cpp +++ b/Tactical/LOS.cpp @@ -5810,7 +5810,7 @@ INT8 FireBulletGivenTargetTrapOnly( SOLDIERTYPE* pThrower, OBJECTTYPE* pObj, INT iOverheatReliabilityMalus = (INT16)floor(overheatjampercentage*overheatjampercentage); } - GunIncreaseHeat( pObj ); + GunIncreaseHeat( pObj, pThrower ); // Flugente : Added a malus to reliability for overheated guns // HEADROCK HAM 5: Variable NCTH base change diff --git a/Tactical/Weapons.cpp b/Tactical/Weapons.cpp index 98d0c7c6..3e3989dd 100644 --- a/Tactical/Weapons.cpp +++ b/Tactical/Weapons.cpp @@ -2167,7 +2167,7 @@ BOOLEAN UseGunNCTH( SOLDIERTYPE *pSoldier , INT32 sTargetGridNo ) iOverheatReliabilityMalus = (INT16)floor(overheatjampercentage*overheatjampercentage); } - GunIncreaseHeat( pObjAttHand ); + GunIncreaseHeat( pObjAttHand, pSoldier ); // CJC: since jamming is no longer affected by reliability, increase chance of status going down for really unreliabile guns //INT16 ammoReliability = 0; // Madd: ammo reliability affects gun @@ -2779,7 +2779,7 @@ BOOLEAN UseGun( SOLDIERTYPE *pSoldier , INT32 sTargetGridNo ) } INT16 iOverheatReliabilityMalus = 0; - // Flugente FTW 1: Increase Weapon Temperature + // Flugente: Increase Weapon Temperature if ( gGameOptions.fWeaponOverheating ) { FLOAT overheatjampercentage = GetGunOverheatDamagePercentage( pObjUsed ); // ... how much above the gun's usOverheatingDamageThreshold are we? ... @@ -2788,7 +2788,7 @@ BOOLEAN UseGun( SOLDIERTYPE *pSoldier , INT32 sTargetGridNo ) iOverheatReliabilityMalus = (INT16)floor(overheatjampercentage*overheatjampercentage); } - GunIncreaseHeat( pObjUsed ); + GunIncreaseHeat( pObjUsed, pSoldier ); /* //WarmSteel - Replaced with GetReliability( pObj ) // CJC: since jamming is no longer affected by reliability, increase chance of status going down for really unreliabile guns @@ -3905,7 +3905,7 @@ BOOLEAN UseLauncher( SOLDIERTYPE *pSoldier, INT32 sTargetGridNo ) // ATE: Check here if the launcher should fail 'cause of bad status..... if ( WillExplosiveWeaponFail( pSoldier, pgunobj ) ) { - GunIncreaseHeat( pgunobj ); + GunIncreaseHeat( pgunobj, pSoldier ); // Explode dude! // So we still should have ABC > 0 @@ -3922,7 +3922,7 @@ BOOLEAN UseLauncher( SOLDIERTYPE *pSoldier, INT32 sTargetGridNo ) return( FALSE ); } - GunIncreaseHeat( pgunobj ); + GunIncreaseHeat( pgunobj, pSoldier ); // Flugente: if we are using a rifle grenade, we also use up one of the gun's bullets if ( IsAttachmentClass(pgunobj->usItem, AC_RIFLEGRENADE) ) @@ -3931,7 +3931,7 @@ BOOLEAN UseLauncher( SOLDIERTYPE *pSoldier, INT32 sTargetGridNo ) (*pObj)[0]->data.gun.ubGunShotsLeft--; // increase heat, as we 'fired' a bullet - GunIncreaseHeat( pObj ); + GunIncreaseHeat( pObj, pSoldier ); } if ( Weapon[ usItemNum ].sSound != NO_WEAPON_SOUND ) @@ -11411,7 +11411,7 @@ void CalcMagFactorSimple( SOLDIERTYPE *pSoldier, FLOAT d2DDistance, INT16 bAimTi } // Flugente: Increase temperature/dirt of gun in ubAttackingHand due to firing a shot -void GunIncreaseHeat( OBJECTTYPE *pObj ) +void GunIncreaseHeat( OBJECTTYPE *pObj, SOLDIERTYPE* pSoldier ) { if ( gGameOptions.fWeaponOverheating ) { diff --git a/Tactical/Weapons.h b/Tactical/Weapons.h index 40b8e61f..fedda90e 100644 --- a/Tactical/Weapons.h +++ b/Tactical/Weapons.h @@ -527,10 +527,10 @@ void CalcMagFactorSimple( SOLDIERTYPE *pSoldier, FLOAT d2DDistance, INT16 bAimTi FLOAT GetTargetZPos( SOLDIERTYPE *pShooter, INT32 sTargetGridNo ); // Flugente: Overheating Weapons -void GunIncreaseHeat( OBJECTTYPE *pObj ); +void GunIncreaseHeat( OBJECTTYPE *pObj, SOLDIERTYPE* pSoldier ); // adding pSoldier allows soldier-specific modification of generated heat FLOAT GetSingleShotTemperature( OBJECTTYPE *pObj ); -FLOAT GetGunOverheatDamagePercentage( OBJECTTYPE * pObj ); // Flugente FTW 1: Get percentage: temperature/damagethreshold -FLOAT GetGunOverheatJamPercentage( OBJECTTYPE * pObj ); // Flugente FTW 1: Get percentage: temperature/jamthreshold +FLOAT GetGunOverheatDamagePercentage( OBJECTTYPE * pObj ); // Flugente: Get percentage: temperature/damagethreshold +FLOAT GetGunOverheatJamPercentage( OBJECTTYPE * pObj ); // Flugente: Get percentage: temperature/jamthreshold FLOAT GetOverheatJamThreshold( OBJECTTYPE *pObj ); FLOAT GetOverheatDamageThreshold( OBJECTTYPE *pObj );