aboutsummaryrefslogtreecommitdiff
path: root/src/openvic2/map/Region.cpp
diff options
context:
space:
mode:
author Hop311 <Hop3114@gmail.com>2023-05-09 21:10:02 +0200
committer GitHub <noreply@github.com>2023-05-09 21:10:02 +0200
commit339e0278a2064f7eeb152fe8c5778840b609e9f3 (patch)
tree05bb2635d921de9ad138736d49e4b5ea7a419c23 /src/openvic2/map/Region.cpp
parent1838e79d6af83dbed2f1b387acf02aacca0eb4bc (diff)
parent3550c455526eb6f8935f488810e73fe01a1177a9 (diff)
Merge pull request #2 from OpenVic2Project/goods
Added GoodManager
Diffstat (limited to 'src/openvic2/map/Region.cpp')
-rw-r--r--src/openvic2/map/Region.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/openvic2/map/Region.cpp b/src/openvic2/map/Region.cpp
index da0dfdd..d6d8dcc 100644
--- a/src/openvic2/map/Region.cpp
+++ b/src/openvic2/map/Region.cpp
@@ -12,13 +12,13 @@ bool ProvinceSet::contains_province(Province const* province) const {
return province && std::find(provinces.begin(), provinces.end(), province) != provinces.end();
}
-std::set<Province*> const& ProvinceSet::get_provinces() const {
+std::vector<Province*> const& ProvinceSet::get_provinces() const {
return provinces;
}
Region::Region(std::string const& new_identifier) : HasIdentifier{ new_identifier } {}
colour_t Region::get_colour() const {
- if (provinces.empty()) return 0xFF0000;
- return (*provinces.cbegin())->get_colour();
+ if (provinces.empty()) return FULL_COLOUR << 16;
+ return provinces.front()->get_colour();
}