aboutsummaryrefslogtreecommitdiff
path: root/src/openvic-simulation/map/Province.hpp
diff options
context:
space:
mode:
author hop311 <hop3114@gmail.com>2023-12-06 23:10:53 +0100
committer hop311 <hop3114@gmail.com>2023-12-07 21:38:17 +0100
commit398377011cb3d3c970451dcd215f3610159f1ae2 (patch)
tree2a73255f595eabb1441419a08bd0d5e5407213e7 /src/openvic-simulation/map/Province.hpp
parent48a3f1729d709847d7cad33f594c77cac414e802 (diff)
Vec/set callbacks + crime file + prov building pos
Diffstat (limited to 'src/openvic-simulation/map/Province.hpp')
-rw-r--r--src/openvic-simulation/map/Province.hpp13
1 files changed, 5 insertions, 8 deletions
diff --git a/src/openvic-simulation/map/Province.hpp b/src/openvic-simulation/map/Province.hpp
index dd440fa..b45dd9c 100644
--- a/src/openvic-simulation/map/Province.hpp
+++ b/src/openvic-simulation/map/Province.hpp
@@ -11,6 +11,7 @@ namespace OpenVic {
struct Map;
struct Region;
struct State;
+ struct Crime;
struct Good;
struct TerrainType;
struct TerrainTypeMapping;
@@ -50,12 +51,8 @@ namespace OpenVic {
fvec2_t factory;
fvec2_t building_construction;
fvec2_t military_construction;
- fvec2_t fort;
- fixed_point_t fort_rotation;
- fvec2_t railroad;
- fixed_point_t railroad_rotation;
- fvec2_t navalbase;
- fixed_point_t navalbase_rotation;
+ std::map<BuildingType const*, fvec2_t> building_position;
+ fixed_point_map_t<BuildingType const*> building_rotation;
};
static constexpr index_t NULL_INDEX = 0, MAX_INDEX = std::numeric_limits<index_t>::max();
@@ -99,7 +96,7 @@ namespace OpenVic {
std::string to_string() const;
- bool load_positions(BuildingManager const& building_manager, ast::NodeCPtr root);
+ bool load_positions(BuildingTypeManager const& building_type_manager, ast::NodeCPtr root);
IDENTIFIER_REGISTRY_ACCESSORS(building)
bool expand_building(std::string_view building_type_identifier);
@@ -115,7 +112,7 @@ namespace OpenVic {
bool is_adjacent_to(Province const* province);
bool add_adjacency(Province const* province, distance_t distance, flags_t flags);
- bool reset(BuildingManager const& building_manager);
+ bool reset(BuildingTypeManager const& building_type_manager);
bool apply_history_to_province(ProvinceHistoryEntry const* entry);
};
}