src/game/Strategic/Strategic_Movement.cc
static void ResetMovementForEnemyGroup(GROUP* pGroup)
{
	//Validate that the group is an enemy group and that it is moving.
	if( pGroup->fPlayer )
	{
		return;
	}
	if( !pGroup->fBetweenSectors || !pGroup->ubNextX || !pGroup->ubNextY )
	{ //Reset the group's assignment by moving it to the group's original sector as it's pending group.
		RepollSAIGroup( pGroup );
		return;
	}

	//Cancel the event that is posted.
	DeleteStrategicEvent( EVENT_GROUP_ARRIVAL, pGroup->ubGroupID );

	//Calculate the new arrival time (all data pertaining to movement should be valid)
	if( pGroup->uiTraverseTime > 400 )
	{ //The group was likely sleeping which makes for extremely long arrival times.  Shorten it
		//arbitrarily.  Doesn't really matter if this isn't accurate.
		pGroup->uiTraverseTime = 90;
	}
	pGroup->setArrivalTime(GetWorldTotalMin() + pGroup->uiTraverseTime);

	//Add a new event
	AddStrategicEvent( EVENT_GROUP_ARRIVAL, pGroup->uiArrivalTime, pGroup->ubGroupID );
}
//This function is used to reset the location of the enemy group if they are
//currently between sectors.  If they were 50% of the way from sector A10 to A11,
//then after this function is called, then that group would be 0% of the way from
//sector A10 to A11.  In no way does this function effect the strategic path for
//the group.
This function is used to reset the location of the enemy group if they are
currently between sectors.  If they were 50% of the way from sector A10 to A11,
then after this function is called, then that group would be 0% of the way from
sector A10 to A11.  In no way does this function effect the strategic path for
the group.
This function is used to reset the location of the enemy group if they are currently between sectors . If they were 50% of the way from sector A10 to A11 then after this function is called then that group would be 0% of the way from sector A10 to A11 . In no way does this function effect the strategic path for the group .
static void ResetMovementForEnemyGroup(GROUP* pGroup)
{
	if( pGroup->fPlayer )
	{
		return;
	}
	if( !pGroup->fBetweenSectors || !pGroup->ubNextX || !pGroup->ubNextY )
	{ 
		RepollSAIGroup( pGroup );
		return;
	}
	DeleteStrategicEvent( EVENT_GROUP_ARRIVAL, pGroup->ubGroupID );
	if( pGroup->uiTraverseTime > 400 )
	{ 
		pGroup->uiTraverseTime = 90;
	}
	pGroup->setArrivalTime(GetWorldTotalMin() + pGroup->uiTraverseTime);
	AddStrategicEvent( EVENT_GROUP_ARRIVAL, pGroup->uiArrivalTime, pGroup->ubGroupID );
}
static void ResetMovementForEnemyGroup ( GROUP * pGroup ) { if ( pGroup -> fPlayer ) { return ; } if ( ! pGroup -> fBetweenSectors || ! pGroup -> ubNextX || ! pGroup -> ubNextY ) { RepollSAIGroup ( pGroup ) ; return ; } DeleteStrategicEvent ( EVENT_GROUP_ARRIVAL , pGroup -> ubGroupID ) ; if ( pGroup -> uiTraverseTime > 400 ) { pGroup -> uiTraverseTime = 90 ; } pGroup -> setArrivalTime ( GetWorldTotalMin ( ) + pGroup -> uiTraverseTime ) ; AddStrategicEvent ( EVENT_GROUP_ARRIVAL , pGroup -> uiArrivalTime , pGroup -> ubGroupID ) ; }
This function is used to reset the location of the enemy group if they are
currently between sectors.
This function is used to reset the location of the enemy group if they are currently between sectors .
//Validate that the group is an enemy group and that it is moving. //Reset the group's assignment by moving it to the group's original sector as it's pending group. //Cancel the event that is posted. //Calculate the new arrival time (all data pertaining to movement should be valid) //The group was likely sleeping which makes for extremely long arrival times.  Shorten it //arbitrarily.  Doesn't really matter if this isn't accurate. //Add a new event