22 #include <yaml-cpp/yaml.h> 39 std::vector<Target*> _followers;
46 virtual void load(
const YAML::Node& node);
48 virtual YAML::Node
save()
const;
50 virtual YAML::Node
saveId()
const;
62 void setName(
const std::wstring &newName);
virtual YAML::Node save() const
Saves the target to YAML.
Definition: Target.cpp:70
double getDistance(const Target *target) const
Gets the distance to another target.
Definition: Target.cpp:185
Contains strings used throughout the game for localization.
Definition: Language.h:39
void setLatitude(double lat)
Sets the target's latitude.
Definition: Target.cpp:131
double getLatitude() const
Gets the target's latitude.
Definition: Target.cpp:122
virtual YAML::Node saveId() const
Saves the target's ID to YAML.
Definition: Target.cpp:86
double getLongitude() const
Gets the target's longitude.
Definition: Target.cpp:98
void setName(const std::wstring &newName)
Sets the target's name.
Definition: Target.cpp:164
virtual std::wstring getName(Language *lang) const
Gets the target's name.
Definition: Target.cpp:153
std::vector< Target * > * getFollowers()
Gets the target's followers.
Definition: Target.cpp:174
void setLongitude(double lon)
Sets the target's longitude.
Definition: Target.cpp:107
virtual void load(const YAML::Node &node)
Loads the moving target from YAML.
Definition: Target.cpp:55
Base class for targets on the globe with a set of radian coordinates.
Definition: Target.h:33
Target()
Creates a target.
Definition: Target.cpp:31
virtual std::wstring getDefaultName(Language *lang) const =0
Gets the target's default name.
Definition: BaseInfoState.cpp:40
virtual ~Target()
Cleans up the target.
Definition: Target.cpp:38
virtual int getMarker() const =0
Gets the target's marker.