- external feeding checks for invalid gridno

- reordered xmls
- new feature: class specific gun and item choices allows finetuning of a soldier's equipment

WARNING! This exe needs GameDir revision >= 1584, as xmls have been reordered!
More info under http://www.bears-pit.com/board/ubbthreads.php/topics/313782/Re_New_feature_Class_specific_.html#Post313782

git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@5764 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
Flugente
2013-01-04 23:25:35 +00:00
parent 695a5013c0
commit 79d6bb46ed
13 changed files with 245 additions and 133 deletions
+7 -3
View File
@@ -13807,7 +13807,7 @@ void SOLDIERTYPE::SoldierInventoryCoolDown(void)
}
}
// Flugente: determine if we can rest our weapon on something. This ca6n only happen when STANDING/CROUCHED. As a result, we get superior handling modifiers (we apply the PRONE modfiers)
// Flugente: determine if we can rest our weapon on something. This can only happen when STANDING/CROUCHED. As a result, we get superior handling modifiers (we apply the PRONE modfiers)
BOOLEAN SOLDIERTYPE::IsWeaponMounted( void )
{
BOOLEAN applybipod = FALSE;
@@ -14201,10 +14201,14 @@ BOOLEAN SOLDIERTYPE::IsFeedingExternal(UINT8* pubId1, UINT16* pGunSlot1, UINT16
if ( gGameExternalOptions.ubExternalFeeding == 0 )
return( FALSE );
// basic check if are up to this task
// basic check if we are up to this task
if ( !this->bActive || !this->bInSector || this->stats.bLife < OKLIFE )
return( FALSE );
// this is odd - invalid GridNo... well, no feeding then
if ( TileIsOutOfBounds(this->sGridNo) )
return( FALSE );
BOOLEAN isFeeding = FALSE;
UINT16 usGunItem = 0;
@@ -14847,7 +14851,7 @@ BOOLEAN SOLDIERTYPE::EquipmentTooGood( BOOLEAN fCloselook )
++numberofattachments;
// no ordinary soldier is allowed that many attachments > not covert
// no ordinary soldier is allowed that many attachments -> not covert
if ( numberofattachments > gGameExternalOptions.iMaxEnemyAttachments )
{
ScreenMsg( FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, szCovertTextStr[STR_COVERT_TOOMANYATTACHMENTS], this->name, Item[pObj->usItem].szItemName );