private:
public:
// Transmittable data
short
flags;
short
squadrons;
// Number of available friendly squadrons
short
averageCAStrength;
// Rolling average CA strength of CA missions
short
averageCAMissions;
// Average # of CA missions being flow per hour
uchar
currentCAMissions;
// # of CA missions planned so far during current cycle
uchar
sampleCycles;
// # of cycles we've averaged missions over
// Anything below here doesn't get transmitted
int
missionsToFill;
// Amount of missions above to actually task.
int
missionsFilled;
// # actually filled to date
List
awacsList;
// List of awacs/jstar locations
List
tankerList;
// List of tanker track locations
List
ecmList;
// List of standoff jammer locations
List
requestList;
// List of mission requests yet to be processed.
List
delayedList;
// List of mission requests already handled, but not filled
F4PFList
squadronList;
// List of this team's squadrons
F4PFList
packageList;
// List of all active packages
ATMAirbaseClass *airbaseList;
// List of active airbases
uchar
supplyBase;
uchar
cycle;
// which planning block we're in.
CampaignTime scheduleTime;
// Last time we updated our blocks
public:
// constructors & serial functions
AirTaskingManagerClass(ushort type, Team t);
AirTaskingManagerClass(VU_BYTE **stream);
AirTaskingManagerClass(FILE *file);
virtual ~AirTaskingManagerClass();
virtual int SaveSize (void);
virtual int Save (VU_BYTE **stream);
virtual int Save (FILE *file);
// Required pure virtuals
virtual int Task();
virtual void DoCalculations();
virtual int Handle(VuFullUpdateEvent *event);
// core functions
int BuildPackage (Package *pc, MissionRequest mis);
int BuildDivert(MissionRequest mis);
int BuildSpecificDivert(Flight flight);
void ProcessRequest(MissionRequest request);
Squadron FindBestAir(MissionRequest mis, GridIndex bx, GridIndex by);
Flight FindBestAirFlight(MissionRequest mis);
void SendATMMessage(VU_ID from, Team to, short msg, short d1, short d2,
void* d3, int flags);
int FindTakeoffSlot(VU_ID abid, WayPoint w);
void ScheduleAircraft(VU_ID abid, WayPoint wp, int aircraft);
void ZapAirbase(VU_ID abid);
void ZapSchedule(int rw, ATMAirbaseClass *airbase, int tilblock);
ATMAirbaseClass* FindATMAirbase(VU_ID abid);
ATMAirbaseClass* AddToAirbaseList (CampEntity airbase);
int FindNearestActiveTanker(GridIndex *x, GridIndex *y, CampaignTime *time);
int FindNearestActiveJammer(GridIndex *x, GridIndex *y, CampaignTime *time);