Open source remastering of the Freespace 2 engine
missionparse.h File Reference
#include <setjmp.h>
#include "ai/ai.h"
#include "ai/ai_profiles.h"
#include "graphics/2d.h"
#include "io/keycontrol.h"
#include "model/model.h"
#include "object/object.h"
#include "parse/sexp.h"
#include "sound/sound.h"

Go to the source code of this file.


struct  support_ship_info
struct  mission_cutscene
struct  mission
struct  path_restriction_t
struct  subsys_status
struct  texture_replace
struct  alt_class
class  p_object
struct  team_data


#define FS_MISSION_FILE_EXT   NOX(".fs2")
#define NUM_NEBULAS   3
#define DEFAULT_AMBIENT_LIGHT_LEVEL   0x00787878
#define MISSION_VERSION   0.10f
#define FRED_MISSION_VERSION   0.10f
#define WING_PLAYER_BASE   0x80000
#define MPF_ONLY_MISSION_INFO   (1 << 0)
#define MPF_IMPORT_FSM   (1 << 1)
#define OLD_MAX_GAME_TYPES   4
#define MISSION_TYPE_SINGLE   (1<<0)
#define MISSION_TYPE_MULTI   (1<<1)
#define MISSION_TYPE_TRAINING   (1<<2)
#define MISSION_TYPE_MULTI_COOP   (1<<3)
#define MISSION_FLAG_SUBSPACE   (1<<0)
#define MISSION_FLAG_FULLNEB   (1<<2)
#define MISSION_FLAG_NO_TRAITOR   (1<<4)
#define MISSION_FLAG_NO_BRIEFING   (1<<10)
#define MISSION_FLAG_2D_MISSION   (1<<14)
#define MISSION_FLAG_RED_ALERT   (1<<16)
#define MISSION_FLAG_SCRAMBLE   (1<<17)
#define MISSION_FLAG_ALL_ATTACK   (1<<20)
#define IS_MISSION_MULTI_COOP   (The_mission.game_type & MISSION_TYPE_MULTI_COOP)
#define IS_MISSION_MULTI_TEAMS   (The_mission.game_type & MISSION_TYPE_MULTI_TEAMS)
#define MOVIE_PRE_BRIEF   2
#define MOVIE_PRE_GAME   3
#define CARGO_NO_DEPLETE   0x40
#define MAX_CARGO   30
#define MAX_STATUS_NAMES   3
#define ARRIVE_NEAR_SHIP   1
#define DEPART_AT_DOCK_BAY   1
#define MAX_ALT_TYPE_NAMES   100
#define MAX_CALLSIGNS   100
#define MAX_OBJECT_STATUS   10
#define P_SF_CARGO_KNOWN   (1<<0)
#define P_SF_IGNORE_COUNT   (1<<1)
#define P_OF_PROTECTED   (1<<2)
#define P_SF_REINFORCEMENT   (1<<3)
#define P_OF_NO_SHIELDS   (1<<4)
#define P_SF_ESCORT   (1<<5)
#define P_OF_PLAYER_START   (1<<6)
#define P_SF_NO_ARRIVAL_MUSIC   (1<<7)
#define P_SF_NO_ARRIVAL_WARP   (1<<8)
#define P_SF_NO_DEPARTURE_WARP   (1<<9)
#define P_SF_LOCKED   (1<<10)
#define P_OF_INVULNERABLE   (1<<11)
#define P_SF_HIDDEN_FROM_SENSORS   (1<<12)
#define P_SF_SCANNABLE   (1<<13)
#define P_AIF_KAMIKAZE   (1<<14)
#define P_AIF_NO_DYNAMIC   (1<<15)
#define P_SF_RED_ALERT_STORE_STATUS   (1<<16)
#define P_OF_BEAM_PROTECTED   (1<<17)
#define P_OF_FLAK_PROTECTED   (1<<18)
#define P_OF_LASER_PROTECTED   (1<<19)
#define P_OF_MISSILE_PROTECTED   (1<<20)
#define P_SF_GUARDIAN   (1<<21)
#define P_KNOSSOS_WARP_IN   (1<<22)
#define P_SF_VAPORIZE   (1<<23)
#define P_SF2_STEALTH   (1<<24)
#define P_SF2_FRIENDLY_STEALTH_INVIS   (1<<25)
#define P_SF2_DONT_COLLIDE_INVIS   (1<<26)
#define P_SF_USE_UNIQUE_ORDERS   (1<<27)
#define P_SF_DOCK_LEADER   (1<<28)
#define P_SF_CANNOT_ARRIVE   (1<<29)
#define P_SF_WARP_BROKEN   (1<<30)
#define P_SF_WARP_NEVER   (1<<31)
#define P2_SF2_PRIMITIVE_SENSORS   (1<<0)
#define P2_SF2_NO_SUBSPACE_DRIVE   (1<<1)
#define P2_SF2_NAV_CARRY_STATUS   (1<<2)
#define P2_SF2_AFFECTED_BY_GRAVITY   (1<<3)
#define P2_OF_TARGETABLE_AS_BOMB   (1<<5)
#define P2_SF2_NO_BUILTIN_MESSAGES   (1<<6)
#define P2_SF2_PRIMARIES_LOCKED   (1<<7)
#define P2_SF2_SECONDARIES_LOCKED   (1<<8)
#define P2_SF2_NO_DEATH_SCREAM   (1<<9)
#define P2_SF2_ALWAYS_DEATH_SCREAM   (1<<10)
#define P2_SF2_NAV_NEEDSLINK   (1<<11)
#define P2_SF2_HIDE_SHIP_NAME   (1<<12)
#define P2_SF2_SET_CLASS_DYNAMICALLY   (1<<13)
#define P2_SF2_AFTERBURNER_LOCKED   (1<<15)
#define P2_OF_FORCE_SHIELDS_ON   (1<<16)
#define P2_OF_IMMOBILE   (1<<17)
#define P2_SF2_NO_ETS   (1<<18)
#define P2_SF2_CLOAKED   (1<<19)
#define P2_SF2_SHIP_LOCKED   (1<<20)
#define P2_SF2_WEAPONS_LOCKED   (1<<21)
#define P2_SF2_SCRAMBLE_MESSAGES   (1<<22)
#define P2_OF_NO_COLLIDE   (1<<23)
#define P2_SF2_NO_DISABLED_SELF_DESTRUCT   (1<<24)
#define P2_RED_ALERT_DELETED   (1<<30)
#define P2_ALREADY_HANDLED   (1<<31)
#define POBJ_INDEX(pobjp)   (pobjp - &Parse_objects[0])
#define MAX_P_WINGS   16
#define MAX_SHIP_LIST   16


typedef struct support_ship_info support_ship_info
typedef struct mission_cutscene mission_cutscene
typedef struct mission mission
typedef struct path_restriction_t path_restriction_t
typedef struct subsys_status subsys_status
typedef struct texture_replace texture_replace
typedef struct alt_class alt_class


int parse_main (const char *mission_name, int flags=0)
p_objectmission_parse_get_arrival_ship (ushort net_signature)
 Returns the parse object on the ship arrival list associated with the given net signature. More...
p_objectmission_parse_get_arrival_ship (const char *name)
 Returns the parse object on the ship arrival list associated with the given name. More...
p_objectmission_parse_get_parse_object (ushort net_signature)
p_objectmission_parse_get_parse_object (const char *name)
int parse_create_object (p_object *objp)
void resolve_parse_flags (object *objp, int parse_flags, int parse_flags2)
void mission_parse_close ()
int parse_wing_create_ships (wing *wingp, int num_to_create, int force=0, int specific_instance=-1)
 Tries to create a wing of ships. More...
int mission_parse_is_multi (const char *filename, char *mission_name)
int mission_parse_get_multi_mission_info (const char *filename)
int mission_do_departure (object *objp, bool goal_is_to_warp=false)
void mission_parse_fixup_players (void)
int get_parse_name_index (const char *name)
void mission_parse_eval_stuff ()
void mission_parse_set_end_time (int seconds)
void mission_bring_in_support_ship (object *requester_objp)
int mission_is_support_ship_arriving (void)
void mission_add_to_arriving_support (object *requester_objp)
int mission_is_repair_scheduled (object *objp)
int mission_remove_scheduled_repair (object *objp)
void mission_parse_support_arrived (int objnum)
int mission_parse_lookup_alt (const char *name)
void mission_parse_lookup_alt_index (int index, char *out)
int mission_parse_add_alt (const char *name)
void mission_parse_remove_alt (const char *name)
void mission_parse_reset_alt ()
int mission_parse_lookup_callsign (const char *name)
void mission_parse_lookup_callsign_index (int index, char *out)
int mission_parse_add_callsign (const char *name)
void mission_parse_remove_callsign (const char *name)
void mission_parse_reset_callsign ()
int is_training_mission ()
int get_mission_info (const char *filename, mission *missionp=NULL, bool basic=true)
void parse_dock_one_docked_object (p_object *pobjp, p_object *parent_pobjp)
void swap_parse_object (p_object *p_obj, int ship_class)
void clear_texture_replacements ()
subsys_statusparse_get_subsys_status (p_object *pobjp, char *subsys_name)


mission The_mission
char Mission_filename [80]
char Mission_alt_types [MAX_ALT_TYPE_NAMES][NAME_LENGTH]
int Mission_alt_type_count
char Mission_callsigns [MAX_CALLSIGNS][NAME_LENGTH]
int Mission_callsign_count
char * Ship_class_names [MAX_SHIP_CLASSES]
char * Ai_behavior_names [MAX_AI_BEHAVIORS]
char * Formation_names [MAX_FORMATION_NAMES]
char * Status_desc_names [MAX_STATUS_NAMES]
char * Status_type_names [MAX_STATUS_NAMES]
char * Status_target_names [MAX_STATUS_NAMES]
char * Arrival_location_names [MAX_ARRIVAL_NAMES]
char * Departure_location_names [MAX_DEPARTURE_NAMES]
char * Goal_type_names [MAX_GOAL_TYPE_NAMES]
char * Reinforcement_type_names []
char * Object_flags []
char * Parse_object_flags []
char * Parse_object_flags_2 []
char * Icon_names []
char * Mission_event_log_flags []
char * Cargo_names [MAX_CARGO]
char Cargo_names_buf [MAX_CARGO][NAME_LENGTH]
char Mission_parse_storm_name [NAME_LENGTH]
int Num_iff
int Num_ai_behaviors
int Num_ai_classes
int Num_cargo
int Num_status_names
int Num_arrival_names
int Num_formation_names
int Num_goal_type_names
int Num_reinforcement_type_names
int Player_starts
fix Entry_delay_time
int Loading_screen_bm_index
int Num_unknown_ship_classes
int Num_unknown_weapon_classes
int Num_unknown_loadout_classes
ushort Current_file_checksum
int Current_file_length
SCP_vector< texture_replaceFred_texture_replacements
SCP_vector< p_objectParse_objects
p_object Support_ship_pobj
p_object Ship_arrival_list
team_data Team_data [MAX_TVT_TEAMS]
int Subsys_index
vec3d Parse_viewer_pos
matrix Parse_viewer_orient
int Mission_arrival_timestamp
int Mission_departure_timestamp
fix Mission_end_time
int Num_parse_names
int Num_teams
char Player_start_shipname [NAME_LENGTH]
int Player_start_shipnum
int Mission_palette
int Nebula_index
char * Nebula_filenames [NUM_NEBULAS]
char * Nebula_colors [NUM_NEBULA_COLORS]
char Neb2_texture_name [MAX_FILENAME_LEN]
int Knossos_warp_ani_used

Macro Definition Documentation


Definition at line 237 of file missionparse.h.


Definition at line 240 of file missionparse.h.


Definition at line 239 of file missionparse.h.

#define ARRIVE_NEAR_SHIP   1

Definition at line 238 of file missionparse.h.


Definition at line 220 of file missionparse.h.

#define CARGO_NO_DEPLETE   0x40

Definition at line 221 of file missionparse.h.


Definition at line 226 of file missionparse.h.

#define DEFAULT_AMBIENT_LIGHT_LEVEL   0x00787878

Definition at line 33 of file missionparse.h.

#define DEPART_AT_DOCK_BAY   1

Definition at line 246 of file missionparse.h.


Definition at line 245 of file missionparse.h.

#define FRED_MISSION_VERSION   0.10f

Definition at line 45 of file missionparse.h.

#define FS_MISSION_FILE_EXT   NOX(".fs2")

Definition at line 25 of file missionparse.h.

#define IS_MISSION_MULTI_COOP   (The_mission.game_type & MISSION_TYPE_MULTI_COOP)

Definition at line 95 of file missionparse.h.


Definition at line 97 of file missionparse.h.

#define IS_MISSION_MULTI_TEAMS   (The_mission.game_type & MISSION_TYPE_MULTI_TEAMS)

Definition at line 96 of file missionparse.h.

#define MAX_ALT_TYPE_NAMES   100

Definition at line 251 of file missionparse.h.


Definition at line 236 of file missionparse.h.

#define MAX_CALLSIGNS   100

Definition at line 256 of file missionparse.h.

#define MAX_CARGO   30

Definition at line 222 of file missionparse.h.


Definition at line 244 of file missionparse.h.


Definition at line 231 of file missionparse.h.


Definition at line 248 of file missionparse.h.


Definition at line 60 of file missionparse.h.

#define MAX_OBJECT_STATUS   10

Definition at line 338 of file missionparse.h.

#define MAX_P_WINGS   16

Definition at line 547 of file missionparse.h.


Definition at line 445 of file missionparse.h.


Definition at line 486 of file missionparse.h.


Definition at line 261 of file missionparse.h.

#define MAX_SHIP_LIST   16

Definition at line 548 of file missionparse.h.

#define MAX_STATUS_NAMES   3

Definition at line 232 of file missionparse.h.

#define MISSION_FLAG_2D_MISSION   (1<<14)

Definition at line 82 of file missionparse.h.

#define MISSION_FLAG_ALL_ATTACK   (1<<20)

Definition at line 88 of file missionparse.h.


Definition at line 81 of file missionparse.h.


Definition at line 91 of file missionparse.h.


Definition at line 75 of file missionparse.h.


Definition at line 76 of file missionparse.h.


Definition at line 77 of file missionparse.h.


Definition at line 80 of file missionparse.h.


Definition at line 83 of file missionparse.h.


Definition at line 90 of file missionparse.h.


Definition at line 92 of file missionparse.h.

#define MISSION_FLAG_FULLNEB   (1<<2)

Definition at line 70 of file missionparse.h.

#define MISSION_FLAG_NO_BRIEFING   (1<<10)

Definition at line 78 of file missionparse.h.


Definition at line 86 of file missionparse.h.


Definition at line 71 of file missionparse.h.


Definition at line 69 of file missionparse.h.

#define MISSION_FLAG_NO_TRAITOR   (1<<4)

Definition at line 72 of file missionparse.h.


Definition at line 87 of file missionparse.h.

#define MISSION_FLAG_RED_ALERT   (1<<16)

Definition at line 84 of file missionparse.h.

#define MISSION_FLAG_SCRAMBLE   (1<<17)

Definition at line 85 of file missionparse.h.

#define MISSION_FLAG_SUBSPACE   (1<<0)

Definition at line 68 of file missionparse.h.


Definition at line 74 of file missionparse.h.


Definition at line 79 of file missionparse.h.


Definition at line 73 of file missionparse.h.


Definition at line 89 of file missionparse.h.

#define MISSION_TYPE_MULTI   (1<<1)

Definition at line 62 of file missionparse.h.

#define MISSION_TYPE_MULTI_COOP   (1<<3)

Definition at line 64 of file missionparse.h.


Definition at line 66 of file missionparse.h.


Definition at line 65 of file missionparse.h.

#define MISSION_TYPE_SINGLE   (1<<0)

Definition at line 61 of file missionparse.h.

#define MISSION_TYPE_TRAINING   (1<<2)

Definition at line 63 of file missionparse.h.

#define MISSION_VERSION   0.10f

Definition at line 44 of file missionparse.h.


Definition at line 121 of file missionparse.h.

#define MOVIE_PRE_BRIEF   2

Definition at line 118 of file missionparse.h.


Definition at line 117 of file missionparse.h.


Definition at line 120 of file missionparse.h.


Definition at line 116 of file missionparse.h.

#define MOVIE_PRE_GAME   3

Definition at line 119 of file missionparse.h.

#define MPF_IMPORT_FSM   (1 << 1)

Definition at line 51 of file missionparse.h.

#define MPF_ONLY_MISSION_INFO   (1 << 0)

Definition at line 50 of file missionparse.h.


Definition at line 31 of file missionparse.h.

#define NUM_NEBULAS   3

Definition at line 30 of file missionparse.h.


Definition at line 56 of file missionparse.h.


Definition at line 57 of file missionparse.h.


Definition at line 55 of file missionparse.h.


Definition at line 58 of file missionparse.h.

#define OLD_MAX_GAME_TYPES   4

Definition at line 54 of file missionparse.h.

#define P2_ALREADY_HANDLED   (1<<31)

Definition at line 518 of file missionparse.h.

#define P2_OF_FORCE_SHIELDS_ON   (1<<16)

Definition at line 504 of file missionparse.h.

#define P2_OF_IMMOBILE   (1<<17)

Definition at line 505 of file missionparse.h.

#define P2_OF_NO_COLLIDE   (1<<23)

Definition at line 511 of file missionparse.h.

#define P2_OF_TARGETABLE_AS_BOMB   (1<<5)

Definition at line 493 of file missionparse.h.

#define P2_RED_ALERT_DELETED   (1<<30)

Definition at line 517 of file missionparse.h.

#define P2_SF2_AFFECTED_BY_GRAVITY   (1<<3)

Definition at line 491 of file missionparse.h.

#define P2_SF2_AFTERBURNER_LOCKED   (1<<15)

Definition at line 503 of file missionparse.h.

#define P2_SF2_ALWAYS_DEATH_SCREAM   (1<<10)

Definition at line 498 of file missionparse.h.

#define P2_SF2_CLOAKED   (1<<19)

Definition at line 507 of file missionparse.h.

#define P2_SF2_HIDE_SHIP_NAME   (1<<12)

Definition at line 500 of file missionparse.h.


Definition at line 502 of file missionparse.h.

#define P2_SF2_NAV_CARRY_STATUS   (1<<2)

Definition at line 490 of file missionparse.h.

#define P2_SF2_NAV_NEEDSLINK   (1<<11)

Definition at line 499 of file missionparse.h.

#define P2_SF2_NO_BUILTIN_MESSAGES   (1<<6)

Definition at line 494 of file missionparse.h.

#define P2_SF2_NO_DEATH_SCREAM   (1<<9)

Definition at line 497 of file missionparse.h.

#define P2_SF2_NO_DISABLED_SELF_DESTRUCT   (1<<24)

Definition at line 512 of file missionparse.h.

#define P2_SF2_NO_ETS   (1<<18)

Definition at line 506 of file missionparse.h.

#define P2_SF2_NO_SUBSPACE_DRIVE   (1<<1)

Definition at line 489 of file missionparse.h.

#define P2_SF2_PRIMARIES_LOCKED   (1<<7)

Definition at line 495 of file missionparse.h.

#define P2_SF2_PRIMITIVE_SENSORS   (1<<0)

Definition at line 488 of file missionparse.h.

#define P2_SF2_SCRAMBLE_MESSAGES   (1<<22)

Definition at line 510 of file missionparse.h.

#define P2_SF2_SECONDARIES_LOCKED   (1<<8)

Definition at line 496 of file missionparse.h.

#define P2_SF2_SET_CLASS_DYNAMICALLY   (1<<13)

Definition at line 501 of file missionparse.h.

#define P2_SF2_SHIP_LOCKED   (1<<20)

Definition at line 508 of file missionparse.h.


Definition at line 492 of file missionparse.h.

#define P2_SF2_WEAPONS_LOCKED   (1<<21)

Definition at line 509 of file missionparse.h.

#define P_AIF_KAMIKAZE   (1<<14)

Definition at line 461 of file missionparse.h.

#define P_AIF_NO_DYNAMIC   (1<<15)

Definition at line 462 of file missionparse.h.

#define P_KNOSSOS_WARP_IN   (1<<22)

Definition at line 469 of file missionparse.h.

#define P_OF_BEAM_PROTECTED   (1<<17)

Definition at line 464 of file missionparse.h.

#define P_OF_FLAK_PROTECTED   (1<<18)

Definition at line 465 of file missionparse.h.

#define P_OF_INVULNERABLE   (1<<11)

Definition at line 458 of file missionparse.h.

#define P_OF_LASER_PROTECTED   (1<<19)

Definition at line 466 of file missionparse.h.

#define P_OF_MISSILE_PROTECTED   (1<<20)

Definition at line 467 of file missionparse.h.

#define P_OF_NO_SHIELDS   (1<<4)

Definition at line 451 of file missionparse.h.

#define P_OF_PLAYER_START   (1<<6)

Definition at line 453 of file missionparse.h.

#define P_OF_PROTECTED   (1<<2)

Definition at line 449 of file missionparse.h.

#define P_SF2_DONT_COLLIDE_INVIS   (1<<26)

Definition at line 473 of file missionparse.h.

#define P_SF2_FRIENDLY_STEALTH_INVIS   (1<<25)

Definition at line 472 of file missionparse.h.

#define P_SF2_STEALTH   (1<<24)

Definition at line 471 of file missionparse.h.

#define P_SF_CANNOT_ARRIVE   (1<<29)

Definition at line 478 of file missionparse.h.

#define P_SF_CARGO_KNOWN   (1<<0)

Definition at line 447 of file missionparse.h.

#define P_SF_DOCK_LEADER   (1<<28)

Definition at line 477 of file missionparse.h.

#define P_SF_ESCORT   (1<<5)

Definition at line 452 of file missionparse.h.

#define P_SF_GUARDIAN   (1<<21)

Definition at line 468 of file missionparse.h.

#define P_SF_HIDDEN_FROM_SENSORS   (1<<12)

Definition at line 459 of file missionparse.h.

#define P_SF_IGNORE_COUNT   (1<<1)

Definition at line 448 of file missionparse.h.

#define P_SF_LOCKED   (1<<10)

Definition at line 457 of file missionparse.h.

#define P_SF_NO_ARRIVAL_MUSIC   (1<<7)

Definition at line 454 of file missionparse.h.

#define P_SF_NO_ARRIVAL_WARP   (1<<8)

Definition at line 455 of file missionparse.h.

#define P_SF_NO_DEPARTURE_WARP   (1<<9)

Definition at line 456 of file missionparse.h.

#define P_SF_RED_ALERT_STORE_STATUS   (1<<16)

Definition at line 463 of file missionparse.h.

#define P_SF_REINFORCEMENT   (1<<3)

Definition at line 450 of file missionparse.h.

#define P_SF_SCANNABLE   (1<<13)

Definition at line 460 of file missionparse.h.

#define P_SF_USE_UNIQUE_ORDERS   (1<<27)

Definition at line 476 of file missionparse.h.

#define P_SF_VAPORIZE   (1<<23)

Definition at line 470 of file missionparse.h.

#define P_SF_WARP_BROKEN   (1<<30)

Definition at line 479 of file missionparse.h.

#define P_SF_WARP_NEVER   (1<<31)

Definition at line 480 of file missionparse.h.

#define POBJ_INDEX (   pobjp)    (pobjp - &Parse_objects[0])

Definition at line 523 of file missionparse.h.


Definition at line 37 of file missionparse.h.


Definition at line 38 of file missionparse.h.


Definition at line 310 of file missionparse.h.

#define WING_PLAYER_BASE   0x80000

Definition at line 47 of file missionparse.h.

Typedef Documentation

typedef struct alt_class alt_class
typedef struct mission mission
typedef struct subsys_status subsys_status

Function Documentation

void clear_texture_replacements ( )

Definition at line 7996 of file missionparse.cpp.

int get_mission_info ( const char *  filename,
mission missionp = NULL,
bool  basic = true 

Definition at line 5881 of file missionparse.cpp.

int get_parse_name_index ( const char *  name)

Definition at line 7341 of file missionparse.cpp.

int is_training_mission ( )

Definition at line 7944 of file missionparse.cpp.

void mission_add_to_arriving_support ( object requester_objp)

Adds requester_objp onto the queue of ships for the arriving support ship to service

Definition at line 7474 of file missionparse.cpp.

void mission_bring_in_support_ship ( object requester_objp)

Modified by Goober5000 to allow more flexibility in support ships

Definition at line 7534 of file missionparse.cpp.

int mission_do_departure ( object objp,
bool  goal_is_to_warp 

Called to make object objp depart. Rewritten and expanded by Goober5000.

Definition at line 7012 of file missionparse.cpp.

int mission_is_repair_scheduled ( object objp)

Returns true if the given ship is scheduled to be repaired by the arriving support ship

Definition at line 7716 of file missionparse.cpp.

int mission_is_support_ship_arriving ( void  )

Returns true if a support ship is currently in the process of warping in.

Definition at line 7705 of file missionparse.cpp.

int mission_parse_add_alt ( const char *  name)

Definition at line 7811 of file missionparse.cpp.

int mission_parse_add_callsign ( const char *  name)

Definition at line 7899 of file missionparse.cpp.

void mission_parse_close ( )

Definition at line 6016 of file missionparse.cpp.

void mission_parse_eval_stuff ( )

Called from high level game loop to do mission evaluation stuff

Definition at line 7224 of file missionparse.cpp.

void mission_parse_fixup_players ( void  )

Fixup the goals/ai references for player objects in the mission

Definition at line 7450 of file missionparse.cpp.

p_object* mission_parse_get_arrival_ship ( ushort  net_signature)

Returns the parse object on the ship arrival list associated with the given net signature.

[in]net_signatureThe net signature of the object
The parse object, or NULL if no object with the given signature is on the arrival list
This function is used to determine whether a ship has arrived. Ships on the arrival list are considered to not be in the game; In order to make respawns work in multiplayer, player ships (those marked with the P_OF_PLAYER_START flag) are never removed from it.

Definition at line 6449 of file missionparse.cpp.

p_object* mission_parse_get_arrival_ship ( const char *  name)

Returns the parse object on the ship arrival list associated with the given name.

[in]nameThe name of the object
The parse object, or NULL if no object with the given name is on the arrival list
This function is used to determine whether a ship has arrived. Ships on the arrival list are considered to not be in the game; In order to make respawns work in multiplayer, player ships (those marked with the P_OF_PLAYER_START flag) are never removed from it.

Definition at line 6423 of file missionparse.cpp.

int mission_parse_get_multi_mission_info ( const char *  filename)

Called to retrieve useful information about a mission.

We will get the name, description, and number of players for a mission. Probably used for multiplayer only? The calling function can use the information in The_mission to get the name/description of the mission if needed.

Definition at line 6401 of file missionparse.cpp.

p_object* mission_parse_get_parse_object ( ushort  net_signature)

Definition at line 3885 of file missionparse.cpp.

p_object* mission_parse_get_parse_object ( const char *  name)

Definition at line 3899 of file missionparse.cpp.

int mission_parse_is_multi ( const char *  filename,
char *  mission_name 

Returns true or false if the given mission support multiplayers

Definition at line 6346 of file missionparse.cpp.

int mission_parse_lookup_alt ( const char *  name)

Alternate name stuff

Definition at line 7771 of file missionparse.cpp.

void mission_parse_lookup_alt_index ( int  index,
char *  out 

Definition at line 7791 of file missionparse.cpp.

int mission_parse_lookup_callsign ( const char *  name)

Callsign stuff

Definition at line 7859 of file missionparse.cpp.

void mission_parse_lookup_callsign_index ( int  index,
char *  out 

Definition at line 7879 of file missionparse.cpp.

void mission_parse_remove_alt ( const char *  name)

Definition at line 7830 of file missionparse.cpp.

void mission_parse_remove_callsign ( const char *  name)

Definition at line 7918 of file missionparse.cpp.

void mission_parse_reset_alt ( )

Definition at line 7851 of file missionparse.cpp.

void mission_parse_reset_callsign ( )

Definition at line 7939 of file missionparse.cpp.

void mission_parse_set_end_time ( int  seconds)
void mission_parse_support_arrived ( int  objnum)

Deal with support ship arrival. This function can get called from either single or multiplayer. Needed to that clients can know when to abort rearm.

objnumis the object number of the arriving support ship

Definition at line 6784 of file missionparse.cpp.

int mission_remove_scheduled_repair ( object objp)

Removed the given ship from the list of ships that are to get repair by arriving support ship

Definition at line 7737 of file missionparse.cpp.

int parse_create_object ( p_object pobjp)

This is a bit tricky because of the way initial docking is now handled. Docking groups require special treatment.

Definition at line 1746 of file missionparse.cpp.

void parse_dock_one_docked_object ( p_object pobjp,
p_object parent_pobjp 

This is conceptually almost the same as obj_move_one_docked_object and is used in the same way.

Definition at line 1675 of file missionparse.cpp.

subsys_status* parse_get_subsys_status ( p_object pobjp,
char *  subsys_name 

Definition at line 7324 of file missionparse.cpp.

int parse_main ( const char *  mission_name,
int  flags = 0 

Definition at line 5947 of file missionparse.cpp.

int parse_wing_create_ships ( wing wingp,
int  num_to_create,
int  force,
int  specific_instance 

Tries to create a wing of ships.

[in,out]wingpPointer to the wing structure of the wing to be created
[in]num_to_createNumber of ships to create
[in]forceIf set to 1, the wing will be created regardless of whether or not the arrival conditions have been met yet.
[in]specific_instanceSet this to create a specific ship from this wing
Number of ships created

Definition at line 3934 of file missionparse.cpp.

void resolve_parse_flags ( object objp,
int  parse_flags,
int  parse_flags2 

Definition at line 2491 of file missionparse.cpp.

void swap_parse_object ( p_object p_obj,
int  new_ship_class 

Replaces a p_object with a new one based on a Ship_info index.

Definition at line 3802 of file missionparse.cpp.

Variable Documentation

char* Ai_behavior_names[MAX_AI_BEHAVIORS]

Definition at line 184 of file missionparse.cpp.

char* Arrival_location_names[MAX_ARRIVAL_NAMES]

Definition at line 236 of file missionparse.cpp.

p_object* Arriving_support_ship

Definition at line 573 of file missionparse.h.

char* Cargo_names[MAX_CARGO]

Definition at line 208 of file missionparse.cpp.

char Cargo_names_buf[MAX_CARGO][NAME_LENGTH]

Definition at line 209 of file missionparse.cpp.

ushort Current_file_checksum

Definition at line 105 of file missionparse.cpp.

int Current_file_length

Definition at line 107 of file missionparse.cpp.

char* Departure_location_names[MAX_DEPARTURE_NAMES]

Definition at line 240 of file missionparse.cpp.

fix Entry_delay_time

Definition at line 99 of file missionparse.cpp.

char* Formation_names[MAX_FORMATION_NAMES]
SCP_vector<texture_replace> Fred_texture_replacements

Definition at line 152 of file missionparse.cpp.

char* Goal_type_names[MAX_GOAL_TYPE_NAMES]

Definition at line 244 of file missionparse.cpp.

char* Icon_names[]

Definition at line 213 of file missionparse.cpp.

int Knossos_warp_ani_used

Definition at line 33 of file fireballs.cpp.

int Loading_screen_bm_index

Definition at line 338 of file missionparse.cpp.

int Mission_alt_type_count

Definition at line 111 of file missionparse.cpp.

char Mission_alt_types[MAX_ALT_TYPE_NAMES][NAME_LENGTH]

Definition at line 110 of file missionparse.cpp.

int Mission_arrival_timestamp

Definition at line 341 of file missionparse.cpp.

int Mission_callsign_count

Definition at line 115 of file missionparse.cpp.

char Mission_callsigns[MAX_CALLSIGNS][NAME_LENGTH]

Definition at line 114 of file missionparse.cpp.

int Mission_departure_timestamp

Definition at line 342 of file missionparse.cpp.

fix Mission_end_time

Definition at line 343 of file missionparse.cpp.

char* Mission_event_log_flags[]

Definition at line 318 of file missionparse.cpp.

char Mission_filename[80]

Definition at line 87 of file missionparse.cpp.

int Mission_palette

Definition at line 89 of file missionparse.cpp.

char Mission_parse_storm_name[NAME_LENGTH]

Definition at line 138 of file missionparse.cpp.

char Neb2_texture_name[MAX_FILENAME_LEN]

Definition at line 75 of file neb.cpp.

char* Nebula_colors[NUM_NEBULA_COLORS]

Definition at line 172 of file missionparse.cpp.

char* Nebula_filenames[NUM_NEBULAS]

Definition at line 159 of file missionparse.cpp.

int Nebula_index

Definition at line 90 of file missionparse.cpp.

int Num_ai_behaviors

Definition at line 91 of file missionparse.cpp.

int Num_ai_classes

Definition at line 195 of file aicode.cpp.

int Num_arrival_names

Definition at line 94 of file missionparse.cpp.

int Num_cargo

Definition at line 92 of file missionparse.cpp.

int Num_formation_names
int Num_goal_type_names

Definition at line 95 of file missionparse.cpp.

int Num_iff
int Num_parse_names

Definition at line 150 of file missionparse.cpp.

int Num_reinforcement_type_names

Definition at line 333 of file missionparse.cpp.

int Num_status_names

Definition at line 93 of file missionparse.cpp.

int Num_teams

Definition at line 98 of file missionparse.cpp.

int Num_unknown_loadout_classes

Definition at line 103 of file missionparse.cpp.

int Num_unknown_ship_classes

Definition at line 101 of file missionparse.cpp.

int Num_unknown_weapon_classes

Definition at line 102 of file missionparse.cpp.

char* Object_flags[]

Definition at line 149 of file missionparse.cpp.

char* Parse_object_flags[]

Definition at line 260 of file missionparse.cpp.

char* Parse_object_flags_2[]

Definition at line 290 of file missionparse.cpp.

SCP_vector<p_object> Parse_objects

Definition at line 124 of file missionparse.cpp.

matrix Parse_viewer_orient

Definition at line 336 of file missionparse.cpp.

vec3d Parse_viewer_pos

Definition at line 335 of file missionparse.cpp.

p_object* Player_start_pobject

Definition at line 145 of file missionparse.cpp.

char Player_start_shipname[NAME_LENGTH]

Definition at line 143 of file missionparse.cpp.

int Player_start_shipnum

Definition at line 144 of file missionparse.cpp.

int Player_starts

Definition at line 97 of file missionparse.cpp.

char* Reinforcement_type_names[]

Definition at line 248 of file missionparse.cpp.

p_object Ship_arrival_list

Definition at line 121 of file missionparse.cpp.

char* Ship_class_names[MAX_SHIP_CLASSES]

Definition at line 211 of file missionparse.cpp.

char* Status_desc_names[MAX_STATUS_NAMES]

Definition at line 223 of file missionparse.cpp.

char* Status_target_names[MAX_STATUS_NAMES]

Definition at line 231 of file missionparse.cpp.

char* Status_type_names[MAX_STATUS_NAMES]

Definition at line 227 of file missionparse.cpp.

int Subsys_index

Definition at line 135 of file missionparse.cpp.

subsys_status* Subsys_status

Definition at line 134 of file missionparse.cpp.

p_object Support_ship_pobj

Definition at line 128 of file missionparse.cpp.

Definition at line 140 of file missionparse.cpp.

mission The_mission

Definition at line 86 of file missionparse.cpp.