- new feature: we can now equip militia with gear from sectors, see http://www.bears-pit.com/board/ubbthreads.php/topics/315664.html#Post315664 for more information

- increased the object flag size to UINT64, this breaks savegame compatibility

git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@5869 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
Flugente
2013-02-23 18:32:55 +00:00
parent 01e2d1b29c
commit 59b2549bd6
38 changed files with 1425 additions and 49 deletions
+31
View File
@@ -10219,3 +10219,34 @@ void HandleSurrenderOffer( SOLDIERTYPE* pSoldier )
wcscpy( gzUserDefinedButton[3], TacticalStr[ PRISONER_TALK_STR ] );
DoMessageBox( MSG_BOX_BASIC_MEDIUM_BUTTONS, TacticalStr[ PRISONER_OFFER_SURRENDER ], guiCurrentScreen, MSG_BOX_FLAG_GENERIC_FOUR_BUTTONS, PrisonerSurrenderMessageBoxCallBack, NULL );
}
void TeamDropAll(UINT8 bTeam)
{
if ( bTeam > PLAYER_PLAN )
return;
// not if there is a battle going on, or this team is hostile to us
if ( (gTacticalStatus.uiFlags & INCOMBAT ) )
return;
if ( gTacticalStatus.Team[ gbPlayerNum ].bSide != gTacticalStatus.Team[ bTeam ].bSide )
return;
SOLDIERTYPE *pSoldier;
#ifdef JA2BETAVERSION
ScreenMsg( FONT_MCOLOR_LTYELLOW, MSG_TESTVERSION, L"Team %d drops all items for inspection!", bTeam );
#endif
UINT32 uiCnt = 0;
UINT32 firstid = gTacticalStatus.Team[ bTeam ].bFirstID;
UINT32 lastid = gTacticalStatus.Team[ bTeam ].bLastID;
for ( uiCnt = firstid, pSoldier = MercPtrs[ uiCnt ]; uiCnt <= lastid; ++uiCnt, ++pSoldier)
{
// if soldier is in the current sector, drop all equipment (that has the TAKEN_BY_MILITIA-flag set)
if( pSoldier->bActive && ( pSoldier->sSectorX == gWorldSectorX ) && ( pSoldier->sSectorY == gWorldSectorY ) && ( pSoldier->bSectorZ == gbWorldSectorZ) )
{
pSoldier->DropSectorEquipment();
}
}
}