![]() |
OpenXcom
1.0
Open-source clone of the original X-Com
|
Represents an alien mission site on the world. More...
#include <MissionSite.h>
Public Member Functions | |
MissionSite (const RuleAlienMission *rules, const AlienDeployment *deployment) | |
Creates a mission site. More... | |
~MissionSite () | |
Cleans up the mission site. | |
void | load (const YAML::Node &node) |
Loads the mission site from YAML. More... | |
YAML::Node | save () const |
Saves the mission site to YAML. More... | |
std::string | getType () const |
Gets the waypoint's type. More... | |
const RuleAlienMission * | getRules () const |
Gets the mission site's ruleset. More... | |
const AlienDeployment * | getDeployment () const |
Gets the mission site's deployment. More... | |
std::string | getMarkerName () const |
Gets the mission site's marker name. More... | |
int | getMarker () const |
Gets the mission site's marker sprite. More... | |
size_t | getSecondsRemaining () const |
Gets the seconds until this mission site expires. More... | |
void | setSecondsRemaining (size_t seconds) |
Sets the seconds until this mission site expires. More... | |
std::string | getAlienRace () const |
Gets the mission site's alien race. More... | |
void | setAlienRace (const std::string &race) |
Sets the mission site's alien race. More... | |
void | setInBattlescape (bool inbattle) |
Sets the mission site's battlescape status. More... | |
bool | isInBattlescape () const |
Gets if the mission site is in battlescape. More... | |
int | getTexture () const |
Gets the mission site's texture. More... | |
void | setTexture (int texture) |
Sets the mission site's texture. More... | |
std::string | getCity () const |
Gets the mission site's city. More... | |
void | setCity (const std::string &city) |
Sets the mission site's city. More... | |
bool | getDetected () const |
Gets the mission site's detection state. More... | |
void | setDetected (bool detected) |
Sets the mission site's detection state. More... | |
![]() | |
virtual | ~Target () |
Cleans up the target. More... | |
YAML::Node | saveId () const |
Saves the target's ID to YAML. More... | |
double | getLongitude () const |
Gets the target's longitude. More... | |
void | setLongitude (double lon) |
Sets the target's longitude. More... | |
double | getLatitude () const |
Gets the target's latitude. More... | |
void | setLatitude (double lat) |
Sets the target's latitude. More... | |
int | getId () const |
Gets the target's ID. More... | |
void | setId (int id) |
Sets the target's ID. More... | |
virtual std::string | getName (Language *lang) const |
Gets the target's name. More... | |
void | setName (const std::string &newName) |
Sets the target's name. More... | |
virtual std::string | getDefaultName (Language *lang) const |
Gets the target's default name. More... | |
std::vector< MovingTarget * > * | getFollowers () |
Gets the target's followers. More... | |
std::vector< Craft * > | getCraftFollowers () const |
Gets the target's craft followers. More... | |
double | getDistance (const Target *target) const |
Gets the distance to another target. More... | |
Additional Inherited Members | |
![]() | |
Target () | |
Creates a target. More... | |
Represents an alien mission site on the world.
OpenXcom::MissionSite::MissionSite | ( | const RuleAlienMission * | rules, |
const AlienDeployment * | deployment | ||
) |
Creates a mission site.
Initializes a mission site.
std::string OpenXcom::MissionSite::getAlienRace | ( | ) | const |
Gets the mission site's alien race.
Returns the alien race currently residing in the mission site.
std::string OpenXcom::MissionSite::getCity | ( | ) | const |
Gets the mission site's city.
Gets the mission site's associated city, if any.
const AlienDeployment * OpenXcom::MissionSite::getDeployment | ( | ) | const |
Gets the mission site's deployment.
Returns the ruleset for the mission's deployment.
bool OpenXcom::MissionSite::getDetected | ( | ) | const |
Gets the mission site's detection state.
Gets the detection state for this mission site.
used for popups of sites spawned directly rather than by UFOs.
|
virtual |
Gets the mission site's marker sprite.
Returns the globe marker for the mission site.
Implements OpenXcom::Target.
|
virtual |
Gets the mission site's marker name.
Returns the name on the globe for the mission.
Reimplemented from OpenXcom::Target.
const RuleAlienMission * OpenXcom::MissionSite::getRules | ( | ) | const |
Gets the mission site's ruleset.
Returns the ruleset for the mission's type.
size_t OpenXcom::MissionSite::getSecondsRemaining | ( | ) | const |
Gets the seconds until this mission site expires.
Returns the number of seconds remaining before the mission site expires.
int OpenXcom::MissionSite::getTexture | ( | ) | const |
|
virtual |
Gets the waypoint's type.
Returns the mission's unique type used for savegame purposes.
Implements OpenXcom::Target.
bool OpenXcom::MissionSite::isInBattlescape | ( | ) | const |
Gets if the mission site is in battlescape.
Gets the mission site's battlescape status.
|
virtual |
Loads the mission site from YAML.
Loads the mission site from a YAML file.
node | YAML node. |
Reimplemented from OpenXcom::Target.
|
virtual |
Saves the mission site to YAML.
Saves the mission site to a YAML file.
Reimplemented from OpenXcom::Target.
void OpenXcom::MissionSite::setAlienRace | ( | const std::string & | race | ) |
Sets the mission site's alien race.
Changes the alien race currently residing in the mission site.
race | Alien race. |
void OpenXcom::MissionSite::setCity | ( | const std::string & | city | ) |
Sets the mission site's city.
Sets the mission site's associated city, if any.
city | String ID for the city, "" if none. |
void OpenXcom::MissionSite::setDetected | ( | bool | detected | ) |
Sets the mission site's detection state.
detected | whether we want this site to show on the geoscape or not. |
void OpenXcom::MissionSite::setInBattlescape | ( | bool | inbattle | ) |
Sets the mission site's battlescape status.
inbattle | True if it's in battle, False otherwise. |
void OpenXcom::MissionSite::setSecondsRemaining | ( | size_t | seconds | ) |
Sets the seconds until this mission site expires.
Changes the number of seconds before the mission site expires.
seconds | Amount of seconds. |
void OpenXcom::MissionSite::setTexture | ( | int | texture | ) |
Sets the mission site's texture.
Sets the mission site's associated texture.
texture | Texture ID. |