MCPcopy Create free account
hub / github.com/OpenXcom/OpenXcom / save

Method save

src/Savegame/Country.cpp:65–81  ·  view source on GitHub ↗

* Saves the country to a YAML file. * @return YAML node. */

Source from the content-addressed store, hash-verified

63 * @return YAML node.
64 */
65YAML::Node Country::save() const
66{
67 YAML::Node node;
68 node["type"] = _rules->getType();
69 node["funding"] = _funding;
70 node["activityXcom"] = _activityXcom;
71 node["activityAlien"] = _activityAlien;
72 if (_pact)
73 {
74 node["pact"] = _pact;
75 }
76 else if (_newPact)
77 {
78 node["newPact"] = _newPact;
79 }
80 return node;
81}
82
83/**
84 * Returns the ruleset for the country's type.

Callers

nothing calls this directly

Calls 1

getTypeMethod · 0.45

Tested by

no test coverage detected