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

Method setRegion

src/Savegame/AlienMission.cpp:663–673  ·  view source on GitHub ↗

* Sets the mission's region. if the region is incompatible with * actually carrying out an attack, use the "fallback" region as * defined in the ruleset. * (this is a slight difference from the original, which just * defaulted them to zone[0], North America) * @param region the region we want to try to set the mission to. * @param rules the ruleset, in case we need to swap out the region. *

Source from the content-addressed store, hash-verified

661 * @param rules the ruleset, in case we need to swap out the region.
662 */
663void AlienMission::setRegion(const std::string &region, const Ruleset &rules)
664{
665 if (rules.getRegion(region)->getMissionRegion() != "")
666 {
667 _region = rules.getRegion(region)->getMissionRegion();
668 }
669 else
670 {
671 _region = region;
672 }
673}
674
675/**
676 * Select a destination based on the criteria of our trajectory and desired waypoint.

Callers 5

operator()Method · 0.80
time1MonthMethod · 0.80
setupTerrorMissionMethod · 0.80
moveMethod · 0.80

Calls 1

getRegionMethod · 0.80

Tested by

no test coverage detected