12#define FACTION_PLAYER faction_player
13#define FACTION_LOGO_SM 64
15typedef struct FactionGenerator_ {
88int faction_dynAdd(
int base,
const char* name,
const char* display,
const char* ai,
const glColour* colour );
const char * faction_getStandingBroad(int f, int bribed, int override)
Gets the broad faction standing.
const char * faction_longname(int f)
Gets the faction's long name (formal, human-readable).
const glColour * faction_getColour(int f)
Gets the colour of the faction based on it's standing with the player.
int faction_isPlayerEnemy(int f)
Gets whether or not the player is an enemy of the faction.
int faction_exists(const char *name)
Checks to see if a faction exists by name.
const char * faction_default_ai(int f)
Gets the name of the default AI profile for the faction's pilots.
const int * faction_getEnemies(int f)
Gets the list of enemies of a faction.
int faction_dynAdd(int base, const char *name, const char *display, const char *ai, const glColour *colour)
Dynamically add a faction.
void faction_rmAlly(int f, int o)
Removes an ally from the faction's allies list.
int faction_isKnown(int id)
Is the faction known?
char faction_getColourChar(int f)
Gets the faction character associated to its standing with the player.
int faction_isFaction(int f)
Checks whether or not a faction is valid.
const glTexture * faction_logo(int f)
Gets the faction's logo (ideally 256x256).
nlua_env faction_getEquipper(int f)
Gets the equipper state associated to the faction scheduler.
int factions_load(void)
Loads up all the factions from the data file.
void faction_clearEnemy(int f)
Clears all the enemies of a dynamic faction.
void factions_reset(void)
Resets player standing and flags of factions to default.
void faction_rmEnemy(int f, int o)
Removes an enemy from the faction's enemies list.
int faction_isPlayerFriend(int f)
Gets whether or not the player is a friend of the faction.
void faction_setPlayer(int f, double value)
Sets the player's standing with a faction.
int areEnemies(int a, int b)
Checks whether two factions are enemies.
void factions_clearDynamic(void)
Clears dynamic factions.
int * faction_getGroup(int which)
Returns an array of faction ids.
const char * faction_name(int f)
Gets a factions "real" (internal) name.
const char * faction_shortname(int f)
Gets a factions short name (human-readable).
const char * faction_getStandingText(int f)
Gets the player's standing in human readable form.
double faction_getPlayer(int f)
Gets the player's standing with a faction.
int faction_isDynamic(int id)
Is faction dynamic.
void factions_free(void)
Frees the factions.
const int * faction_getAllies(int f)
Gets the list of allies of a faction.
void faction_modPlayerRaw(int f, double mod)
Modifies the player's standing without affecting others.
const FactionGenerator * faction_generators(int f)
Gets the faction's generators.
int faction_usesHiddenJumps(int f)
Checks to see if a faction uses hidden jumps.
int * faction_getKnown()
Gets all the known factions in an array (array.h).
int faction_isInvisible(int id)
Is the faction invisible?
const glColour * faction_colour(int f)
Gets the colour of the faction.
const char * faction_getStandingTextAtValue(int f, double value)
Gets the player's standing in human readable form.
void faction_clearAlly(int f)
Clears all the ally of a dynamic faction.
double faction_lane_base_cost(int f)
Gets the faction's weight for patrolled safe-lane construction;.
void faction_modPlayer(int f, double mod, const char *source)
Modifies the player's standing with a faction.
const char ** faction_tags(int f)
Gets the tags the faction has.
double faction_getPlayerDef(int f)
Gets the player's default standing with a faction.
int * faction_getAll(void)
Returns all faction IDs in an array (array.h).
void faction_modPlayerSingle(int f, double mod, const char *source)
Modifies the player's standing without affecting others.
int faction_setInvisible(int id, int state)
Sets the faction's invisible state.
int faction_setKnown(int id, int state)
Sets the factions known state.
double faction_lane_length_per_presence(int f)
Gets the faction's weight for patrolled safe-lane construction (0 means they don't build lanes).
int * faction_getAllVisible(void)
Returns all non-invisible faction IDs in an array (array.h).
const char * faction_mapname(int f)
Gets the faction's map name (translated).
double faction_reputationMax(int f)
Gets the maximum reputation of a faction.
void faction_addAlly(int f, int o)
Adds an ally to the faction's allies list.
nlua_env faction_getScheduler(int f)
Gets the state associated to the faction scheduler.
const char * faction_description(int f)
Gets the faction's description (translated).
void faction_clearKnown()
Clears the known factions.
int faction_isStatic(int id)
Is the faction static?
void faction_addEnemy(int f, int o)
Adds an enemy to the faction's enemies list.
int faction_get(const char *name)
Gets a faction ID by name.
int areAllies(int a, int b)
Checks whether two factions are allies or not.
Abstraction for rendering sprite sheets.