diff options
author | Hop311 <Hop3114@gmail.com> | 2024-01-07 22:43:14 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-01-07 22:43:14 +0100 |
commit | 400469f08f10ffd044d9948c3f0db340c8a60db0 (patch) | |
tree | a7cf192c714aa5553a244d7b16c04f833b626cb6 /src/openvic-simulation/map/Province.cpp | |
parent | 004abc9951d0a20d09027cde1d9b5b02bcc99fa0 (diff) | |
parent | 34d9e9318387f2b2a0ae924a512f352540b84e07 (diff) |
Merge pull request #122 from OpenVicProject/more-impassable-adjacencies
More impassable adjacencies + WVPM mod fixes
Diffstat (limited to 'src/openvic-simulation/map/Province.cpp')
-rw-r--r-- | src/openvic-simulation/map/Province.cpp | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/src/openvic-simulation/map/Province.cpp b/src/openvic-simulation/map/Province.cpp index a9bf329..1c3c76f 100644 --- a/src/openvic-simulation/map/Province.cpp +++ b/src/openvic-simulation/map/Province.cpp @@ -141,17 +141,6 @@ std::string_view Province::adjacency_t::get_type_name(type_t type) { } } -Province::adjacency_t* Province::get_adjacency_to(Province const* province) { - const std::vector<adjacency_t>::iterator it = std::find_if(adjacencies.begin(), adjacencies.end(), - [province](adjacency_t const& adj) -> bool { return adj.get_to() == province; } - ); - if (it != adjacencies.end()) { - return &*it; - } else { - return nullptr; - } -} - Province::adjacency_t const* Province::get_adjacency_to(Province const* province) const { const std::vector<adjacency_t>::const_iterator it = std::find_if(adjacencies.begin(), adjacencies.end(), [province](adjacency_t const& adj) -> bool { return adj.get_to() == province; } |