rem: mycon_intelligence (ShipPtr, ObjectsOfConcern, ConcernCounter) PELEMENT ShipPtr; PEVALUATE_DESC ObjectsOfConcern; COUNT ConcernCounter;
add: mycon_intelligence (PELEMENT ShipPtr, PEVALUATE_DESC ObjectsOfConcern, COUNT ConcernCounter)
context: mycon_intelligence (ShipPtr, ObjectsOfConcern, ConcernCounter)PELEMENT ShipPtr;PEVALUATE_DESC ObjectsOfConcern;COUNT ConcernCounter;{	STARSHIPPTR StarShipPtr;	PEVALUATE_DESC lpEvalDesc;	lpEvalDesc = &ObjectsOfConcern[ENEMY_WEAPON_INDEX];	if (lpEvalDesc->ObjectPtr && lpEvalDesc->MoveState == ENTICE)	{		if ((lpEvalDesc->ObjectPtr->state_flags & FINITE_LIFE)				&& !(lpEvalDesc->ObjectPtr->state_flags & CREW_OBJECT))			lpEvalDesc->MoveState = AVOID;		else			lpEvalDesc->MoveState = PURSUE;	}	ship_intelligence (ShipPtr, ObjectsOfConcern, ConcernCounter);	GetElementStarShip (ShipPtr, &StarShipPtr);	if (ObjectsOfConcern[ENEMY_WEAPON_INDEX].MoveState == PURSUE)		StarShipPtr->ship_input_state &= ~THRUST; /* don't pursue seekers */	lpEvalDesc = &ObjectsOfConcern[ENEMY_SHIP_INDEX];	if (StarShipPtr->weapon_counter == 0			&& lpEvalDesc->ObjectPtr			&& (lpEvalDesc->which_turn <= 16			|| ShipPtr->crew_level == StarShipPtr->RaceDescPtr->ship_info.max_crew))	{		COUNT travel_facing, direction_facing;		SIZE delta_x, delta_y;		travel_facing = NORMALIZE_FACING (				ANGLE_TO_FACING (GetVelocityTravelAngle (&ShipPtr->velocity)				+ HALF_CIRCLE)				);		delta_x = lpEvalDesc->ObjectPtr->current.location.x				- ShipPtr->current.location.x;		delta_y = lpEvalDesc->ObjectPtr->current.location.y				- ShipPtr->current.location.y;		direction_facing = NORMALIZE_FACING (				ANGLE_TO_FACING (ARCTAN (delta_x, delta_y))				);		if (NORMALIZE_FACING (direction_facing				- StarShipPtr->ShipFacing				+ ANGLE_TO_FACING (QUADRANT))				<= ANGLE_TO_FACING (HALF_CIRCLE)				&& (!(StarShipPtr->cur_status_flags &				(SHIP_BEYOND_MAX_SPEED | SHIP_IN_GRAVITY_WELL))				|| NORMALIZE_FACING (direction_facing				- travel_facing + ANGLE_TO_FACING (OCTANT))				<= ANGLE_TO_FACING (QUADRANT)))			StarShipPtr->ship_input_state |= WEAPON;	}	if (StarShipPtr->special_counter == 0)	{		StarShipPtr->ship_input_state &= ~SPECIAL;		StarShipPtr->RaceDescPtr->cyborg_control.WeaponRange = DISPLAY_TO_WORLD (800);		if (ShipPtr->crew_level < StarShipPtr->RaceDescPtr->ship_info.max_crew)		{			StarShipPtr->RaceDescPtr->cyborg_control.WeaponRange = MISSILE_SPEED * MISSILE_LIFE;			if (StarShipPtr->RaceDescPtr->ship_info.energy_level >= SPECIAL_ENERGY_COST					&& !(StarShipPtr->ship_input_state & WEAPON))				StarShipPtr->ship_input_state |= SPECIAL;		}	}}