UFO: Alien Invasion
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
cp_mission_recon.cpp File Reference

Campaign mission. More...

#include "../../../cl_shared.h"
#include "../cp_campaign.h"
#include "../cp_alienbase.h"
#include "../cp_geoscape.h"
#include "../cp_ufo.h"
#include "../cp_missions.h"
#include "../cp_time.h"
#include "../cp_xvi.h"
#include "../cp_alien_interest.h"
#include "cp_mission_recon.h"

Go to the source code of this file.

Functions

static void CP_ReconMissionIsSuccess (mission_t *mission)
 Recon mission is over and is a success: change interest values. More...
 
void CP_ReconMissionIsFailure (mission_t *mission)
 Recon mission is over and is a failure: change interest values. More...
 
void CP_ReconMissionLeave (mission_t *mission)
 Recon mission ends: UFO leave earth. More...
 
static bool CP_ReconMissionChoose (mission_t *mission)
 Choose between aerial and ground mission. More...
 
void CP_ReconMissionAerial (mission_t *mission)
 Set aerial mission. More...
 
void CP_ReconMissionGroundGo (mission_t *mission)
 Set ground mission, and go to ground mission pos. More...
 
static void CP_ReconMissionGround (mission_t *mission)
 Start ground mission. More...
 
static bool CP_ReconMissionNewGroundMission (mission_t *mission)
 Choose if a new ground mission should be started. More...
 
static void CP_ReconMissionSelect (mission_t *mission)
 Set recon mission type (aerial or ground). More...
 
void CP_ReconMissionNextStage (mission_t *mission)
 Determine what action should be performed when a Recon mission stage ends. More...
 

Detailed Description

Campaign mission.

Definition in file cp_mission_recon.cpp.

Function Documentation

void CP_ReconMissionAerial ( mission_t mission)

Set aerial mission.

Note
Recon mission – Stage 1
See also
CP_ReconMissionSelect

Definition at line 106 of file cp_mission_recon.cpp.

References ccs, ccs_s::date, Date_Add(), Date_Random(), mission_s::finalDate, mission_s::stage, STAGE_RECON_AIR, and mission_s::ufo.

Referenced by CP_ReconMissionSelect().

static bool CP_ReconMissionChoose ( mission_t mission)
static

Choose between aerial and ground mission.

Note
Recon mission – Stage 1
Returns
true if recon mission is aerial, false if this is a ground mission
See also
CP_ReconMissionSelect

Definition at line 92 of file cp_mission_recon.cpp.

References f, frand(), and mission_s::ufo.

Referenced by CP_ReconMissionSelect().

static void CP_ReconMissionGround ( mission_t mission)
static
void CP_ReconMissionIsFailure ( mission_t mission)

Recon mission is over and is a failure: change interest values.

Note
Recon mission

Definition at line 57 of file cp_mission_recon.cpp.

References CP_MissionRemove(), f, INT_ChangeIndividualInterest(), INTERESTCATEGORY_INTERCEPT, INTERESTCATEGORY_RECON, and INTERESTCATEGORY_TERROR_ATTACK.

Referenced by CP_MissionIsOver().

static void CP_ReconMissionIsSuccess ( mission_t mission)
static

Recon mission is over and is a success: change interest values.

Note
Recon mission

Definition at line 41 of file cp_mission_recon.cpp.

References AB_GetAlienBaseNumber(), CP_IsXVIStarted, CP_MissionRemove(), f, INT_ChangeIndividualInterest(), INTERESTCATEGORY_HARVEST, INTERESTCATEGORY_RECON, INTERESTCATEGORY_SUPPLY, and INTERESTCATEGORY_XVI.

Referenced by CP_ReconMissionNextStage().

static bool CP_ReconMissionNewGroundMission ( mission_t mission)
static

Choose if a new ground mission should be started.

Note
Recon mission – Stage 1
Already one ground mission has been made
See also
CP_ReconMissionSelect

Definition at line 192 of file cp_mission_recon.cpp.

References f, and frand().

Referenced by CP_ReconMissionSelect().

void CP_ReconMissionNextStage ( mission_t mission)

Determine what action should be performed when a Recon mission stage ends.

Parameters
[in]missionPointer to the mission which stage ended.

Definition at line 224 of file cp_mission_recon.cpp.

References cgi, CP_MissionBegin(), CP_MissionRemove(), CP_ReconMissionGround(), CP_ReconMissionIsSuccess(), CP_ReconMissionLeave(), CP_ReconMissionSelect(), mission_s::stage, STAGE_COME_FROM_ORBIT, STAGE_MISSION_GOTO, STAGE_NOT_ACTIVE, STAGE_RECON_AIR, STAGE_RECON_GROUND, and STAGE_RETURN_TO_ORBIT.

Referenced by CP_MissionStageEnd().

static void CP_ReconMissionSelect ( mission_t mission)
static