mirror of
https://github.com/1dot13/source.git
synced 2026-08-05 14:00:23 +02:00
New option SHOW_BACKPACK_OWNER (TRUE by default): show backpack owner's name on the ground and in taking items interface.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@8735 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -5776,7 +5776,6 @@ void UpdateAttachmentTooltips(OBJECTTYPE *pObject, UINT8 ubStatusIndex)
|
||||
|
||||
UINT16 usLoopSlotID = usAttachmentSlotIndexVector[slotCount];
|
||||
attachList.clear();
|
||||
|
||||
//Print all attachments that fit on this item.
|
||||
for(UINT16 usLoop = 0; usLoop < MAXATTACHMENTS; ++usLoop)
|
||||
{ //We no longer find valid attachments from AttachmentSlots.xml so we need to work a bit harder to get our list
|
||||
@@ -11473,7 +11472,16 @@ void RenderItemPickupMenu( )
|
||||
}
|
||||
else
|
||||
{
|
||||
swprintf( pStr, L"%s", ShortItemNames[ pObject->usItem ] );
|
||||
if (gGameExternalOptions.gfShowBackpackOwner &&
|
||||
!gfStealing &&
|
||||
Item[gWorldItems[gItemPickupMenu.ItemPoolSlots[cnt]->iItemIndex].object.usItem].usItemClass == IC_LBEGEAR &&
|
||||
LoadBearingEquipment[Item[gWorldItems[gItemPickupMenu.ItemPoolSlots[cnt]->iItemIndex].object.usItem].ubClassIndex].lbeClass == BACKPACK &&
|
||||
gWorldItems[gItemPickupMenu.ItemPoolSlots[cnt]->iItemIndex].soldierID != -1 &&
|
||||
MercPtrs[gWorldItems[gItemPickupMenu.ItemPoolSlots[cnt]->iItemIndex].soldierID])
|
||||
//swprintf(pStr, L"%s (%s)", ShortItemNames[pObject->usItem], MercPtrs[gWorldItems[gItemPickupMenu.ItemPoolSlots[cnt]->iItemIndex].soldierID]->GetName());
|
||||
swprintf(pStr, L"(%s)", MercPtrs[gWorldItems[gItemPickupMenu.ItemPoolSlots[cnt]->iItemIndex].soldierID]->GetName());
|
||||
else
|
||||
swprintf( pStr, L"%s", ShortItemNames[ pObject->usItem ] );
|
||||
}
|
||||
VarFindFontCenterCoordinates( sCenX, sCenY, ITEMPICK_TEXT_WIDTH, 1 , ITEMDESC_FONT, &sFontX, &sFontY, pStr );
|
||||
mprintf_buffer( pDestBuf, uiDestPitchBYTES, ITEMDESC_FONT, sFontX, sFontY, pStr );
|
||||
@@ -11483,14 +11491,9 @@ void RenderItemPickupMenu( )
|
||||
}
|
||||
|
||||
SetFontShadow( DEFAULT_SHADOW );
|
||||
|
||||
|
||||
UnLockVideoSurface( FRAME_BUFFER );
|
||||
|
||||
InvalidateRegion( gItemPickupMenu.sX, gItemPickupMenu.sY, gItemPickupMenu.sX + gItemPickupMenu.sWidth, gItemPickupMenu.sY + gItemPickupMenu.sHeight );
|
||||
|
||||
gItemPickupMenu.fDirtyLevel = 0;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user