OpenXcom  1.0
Open-source clone of the original X-Com
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
AlienBase.h
1 /*
2  * Copyright 2010-2014 OpenXcom Developers.
3  *
4  * This file is part of OpenXcom.
5  *
6  * OpenXcom is free software: you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation, either version 3 of the License, or
9  * (at your option) any later version.
10  *
11  * OpenXcom is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with OpenXcom. If not, see <http://www.gnu.org/licenses/>.
18  */
19 #ifndef OPENXCOM_ALIENBASE_H
20 #define OPENXCOM_ALIENBASE_H
21 
22 #include "Target.h"
23 #include <string>
24 #include <yaml-cpp/yaml.h>
25 
26 namespace OpenXcom
27 {
28 
32 class AlienBase : public Target
33 {
34 private:
35  int _id;
36  std::string _race;
37  bool _inBattlescape, _discovered;
38 public:
40  AlienBase();
42  ~AlienBase();
44  void load(const YAML::Node& node);
46  YAML::Node save() const;
48  YAML::Node saveId() const;
50  int getId() const;
52  void setId(int id);
54  std::wstring getName(Language *lang) const;
56  std::string getAlienRace() const;
58  void setAlienRace(const std::string &race);
60  void setInBattlescape(bool inbattle);
62  bool isInBattlescape() const;
64  bool isDiscovered() const;
66  void setDiscovered(bool discovered);
67 };
68 
69 }
70 
71 #endif
bool isDiscovered() const
Gets the alien base's discovered status.
Definition: AlienBase.cpp:149
void load(const YAML::Node &node)
Loads the alien base from YAML.
Definition: AlienBase.cpp:44
bool isInBattlescape() const
Gets the alien base's battlescape status.
Definition: AlienBase.cpp:131
Represents an alien base on the world.
Definition: AlienBase.h:32
YAML::Node save() const
Saves the alien base to YAML.
Definition: AlienBase.cpp:57
int getId() const
Gets the alien base's ID.
Definition: AlienBase.cpp:85
void setAlienRace(const std::string &race)
Sets the alien base's alien race.
Definition: AlienBase.cpp:122
~AlienBase()
Cleans up the alien base.
Definition: AlienBase.cpp:36
void setInBattlescape(bool inbattle)
Sets the alien base's battlescape status.
Definition: AlienBase.cpp:140
Contains strings used throughout the game for localization.
Definition: Language.h:42
void setDiscovered(bool discovered)
Sets the alien base's discovered status.
Definition: AlienBase.cpp:158
AlienBase()
Creates an alien base.
Definition: AlienBase.cpp:29
void setId(int id)
Sets the alien base's ID.
Definition: AlienBase.cpp:94
YAML::Node saveId() const
Saves the alien base's ID to YAML.
Definition: AlienBase.cpp:73
std::string getAlienRace() const
Gets the alien base's amount of active hours..
Definition: AlienBase.cpp:113
Base class for targets on the globe with a set of radian coordinates.
Definition: Target.h:35
std::wstring getName(Language *lang) const
Gets the alien base's name.
Definition: AlienBase.cpp:104