mirror of
https://github.com/1dot13/source.git
synced 2026-08-19 14:20:30 +02:00
Suppression:
- disabled ubAdjacentSoldierCnt check as it doesn't work correctly - improved adjacent tile check to avoid out of bounds values git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@8891 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -3373,28 +3373,14 @@ void GetKeyboardInput( UINT32 *puiNewEvent )
|
||||
//Get the gridno the cursor is at
|
||||
GetMouseMapPos( &usGridNo );
|
||||
|
||||
// code to test friendly fire detection
|
||||
//if there is a selected soldier, and the cursor location is valid
|
||||
/*if (gusSelectedSoldier != NOBODY && !TileIsOutOfBounds(usGridNo) && gfUIFullTargetFound)
|
||||
{
|
||||
SOLDIERTYPE *pSoldier = MercPtrs[gusSelectedSoldier];
|
||||
SOLDIERTYPE *pOpponent = MercPtrs[gusUIFullTargetID];
|
||||
UINT8 ubChanceToGetThrough;
|
||||
|
||||
if (pSoldier && pOpponent)
|
||||
{
|
||||
gUnderFire.Clear();
|
||||
gUnderFire.Enable();
|
||||
ubChanceToGetThrough = AISoldierToSoldierChanceToGetThrough(pSoldier, pOpponent);
|
||||
gUnderFire.Disable();
|
||||
|
||||
ScreenMsg(FONT_ORANGE, MSG_INTERFACE, L"friendly fire chance %d count %d", gUnderFire.Chance(pSoldier->bTeam, pSoldier->bSide, TRUE), gUnderFire.Count(pSoldier->bTeam));
|
||||
}
|
||||
}*/
|
||||
|
||||
// if the cursor location is valid
|
||||
if ( !TileIsOutOfBounds(usGridNo) )
|
||||
{
|
||||
// sevenfm: code to check ubAdjacentSoldierCnt
|
||||
/*MAP_ELEMENT *pMapElement;
|
||||
pMapElement = &(gpWorldLevelData[usGridNo]);
|
||||
ScreenMsg(FONT_ORANGE, MSG_INTERFACE, L"adjacent soldiers %d", pMapElement->ubAdjacentSoldierCnt);*/
|
||||
|
||||
// if there is a selected soldier
|
||||
if ( gusSelectedSoldier != NOBODY )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user