mirror of
https://github.com/1dot13/source.git
synced 2026-07-22 13:40:22 +02:00
- updated Shadow Warrior's tooltip code
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@536 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -49,7 +49,8 @@ void SoldierTooltip( SOLDIERTYPE* pSoldier )
|
||||
if ( gusSelectedSoldier != NOBODY )
|
||||
iRangeToTarget = GetRangeInCellCoordsFromGridNoDiff( MercPtrs[ gusSelectedSoldier ]->sGridNo, sSoldierGridNo ) / 10;
|
||||
|
||||
if ( gGameExternalOptions.fEnableDynamicSoldierTooltips )
|
||||
// WANNE NEW
|
||||
//if ( gGameExternalOptions.fEnableDynamicSoldierTooltips )
|
||||
{
|
||||
for ( INT32 cnt = 0; cnt < MAX_ATTACHMENTS; cnt++ )
|
||||
{
|
||||
@@ -297,10 +298,6 @@ void SoldierTooltip( SOLDIERTYPE* pSoldier )
|
||||
|
||||
void DisplayWeaponInfo( SOLDIERTYPE* pSoldier, CHAR16* pStrInfo, UINT8 ubSlot, UINT8 ubTooltipDetailLevel )
|
||||
{
|
||||
const int TriggerGroup = 1026;
|
||||
const int GunBarrelExtender = 310;
|
||||
const int CMagAdapter556mm = 1001;
|
||||
const int CMagAdapter9mm = 1002;
|
||||
INT32 iNumAttachments = 0;
|
||||
BOOLEAN fDisplayAttachment = FALSE;
|
||||
|
||||
@@ -358,31 +355,9 @@ void DisplayWeaponInfo( SOLDIERTYPE* pSoldier, CHAR16* pStrInfo, UINT8 ubSlot, U
|
||||
if ( ubTooltipDetailLevel == DL_Basic )
|
||||
{
|
||||
// display only externally-visible weapon attachments
|
||||
// don't display inseparable attachments such as the integral GLs on OICW & AICW
|
||||
if ( !Item[pSoldier->inv[ubSlot].usAttachItem[ cnt ]].inseparable )
|
||||
{
|
||||
if ( pSoldier->inv[ubSlot].usAttachItem[ cnt ] != TriggerGroup )
|
||||
if ( !Item[pSoldier->inv[ubSlot].usAttachItem[ cnt ]].hiddenattachment )
|
||||
{
|
||||
fDisplayAttachment = TRUE;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// display C-mags and barrel extensions
|
||||
switch( pSoldier->inv[ubSlot].usAttachItem[ cnt ] )
|
||||
{
|
||||
case GunBarrelExtender:
|
||||
fDisplayAttachment = TRUE;
|
||||
break;
|
||||
case CMagAdapter556mm:
|
||||
fDisplayAttachment = TRUE;
|
||||
break;
|
||||
case CMagAdapter9mm:
|
||||
fDisplayAttachment = TRUE;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user