FS2_Open
Open source remastering of the Freespace 2 engine
awacs.cpp File Reference
#include "globalincs/linklist.h"
#include "iff_defs/iff_defs.h"
#include "io/timer.h"
#include "mission/missionparse.h"
#include "nebula/neb.h"
#include "network/multi.h"
#include "ship/awacs.h"
#include "ship/ship.h"
#include "species_defs/species_defs.h"

Go to the source code of this file.

Classes

struct  awacs_entry
 

Macros

#define AWACS_STAMP_TIME   1000
 
#define MAX_AWACS   30
 
#define ALWAYS_TARGETABLE   1.5f
 
#define MARGINALLY_TARGETABLE   0.5f
 
#define UNTARGETABLE   -1.0f
 
#define FULLY_TARGETABLE   (viewer_has_primitive_sensors ? ((distance < viewer->primitive_sensor_range) ? MARGINALLY_TARGETABLE : UNTARGETABLE) : ALWAYS_TARGETABLE)
 

Typedefs

typedef struct awacs_entry awacs_entry
 

Functions

void awacs_update_all_levels ()
 
void team_visibility_update ()
 
void awacs_level_init ()
 
void awacs_process ()
 
float awacs_get_level (object *target, ship *viewer, int use_awacs)
 
int ship_is_visible_by_team (object *target, ship *viewer)
 

Variables

int Awacs_stamp = -1
 
float Awacs_team [MAX_IFFS]
 
float Awacs_level
 
awacs_entry Awacs [MAX_AWACS]
 
int Awacs_count = 0
 
ubyte Ship_visibility_by_team [MAX_IFFS][MAX_SHIPS]
 

Macro Definition Documentation

#define ALWAYS_TARGETABLE   1.5f
#define AWACS_STAMP_TIME   1000

Definition at line 29 of file awacs.cpp.

#define FULLY_TARGETABLE   (viewer_has_primitive_sensors ? ((distance < viewer->primitive_sensor_range) ? MARGINALLY_TARGETABLE : UNTARGETABLE) : ALWAYS_TARGETABLE)
#define MARGINALLY_TARGETABLE   0.5f
#define MAX_AWACS   30

Definition at line 37 of file awacs.cpp.

#define UNTARGETABLE   -1.0f

Typedef Documentation

typedef struct awacs_entry awacs_entry

Function Documentation

float awacs_get_level ( object target,
ship viewer,
int  use_awacs 
)

Definition at line 168 of file awacs.cpp.

void awacs_level_init ( )

Definition at line 67 of file awacs.cpp.

void awacs_process ( )

Definition at line 74 of file awacs.cpp.

void awacs_update_all_levels ( )

Definition at line 96 of file awacs.cpp.

int ship_is_visible_by_team ( object target,
ship viewer 
)

Definition at line 442 of file awacs.cpp.

void team_visibility_update ( )

Definition at line 349 of file awacs.cpp.

Variable Documentation

Definition at line 43 of file awacs.cpp.

int Awacs_count = 0

Definition at line 44 of file awacs.cpp.

float Awacs_level

Definition at line 34 of file awacs.cpp.

int Awacs_stamp = -1

Definition at line 30 of file awacs.cpp.

float Awacs_team[MAX_IFFS]

Definition at line 33 of file awacs.cpp.

ubyte Ship_visibility_by_team[MAX_IFFS][MAX_SHIPS]

Definition at line 49 of file awacs.cpp.