Project Alice
|
Namespaces | |
namespace | border |
Classes | |
struct | global_provincial_state |
struct | province_and_distance |
struct | queue_node |
struct | retreat_province_and_distance |
Functions | |
template auto | is_overseas< ve::tagged_vector< dcon::province_id > > (sys::state const &, ve::tagged_vector< dcon::province_id >) |
template void | for_each_province_in_state_instance< std::function< void(dcon::province_id)> > (sys::state &, dcon::state_instance_id, std::function< void(dcon::province_id)> const &) |
bool | is_overseas (sys::state const &state, dcon::province_id ids) |
bool | nations_are_adjacent (sys::state &state, dcon::nation_id a, dcon::nation_id b) |
void | update_connected_regions (sys::state &state) |
dcon::province_id | pick_capital (sys::state &state, dcon::nation_id n) |
void | set_province_controller (sys::state &state, dcon::province_id p, dcon::nation_id n) |
void | set_province_controller (sys::state &state, dcon::province_id p, dcon::rebel_faction_id rf) |
void | restore_cached_values (sys::state &state) |
void | update_cached_values (sys::state &state) |
void | update_blockaded_cache (sys::state &state) |
void | restore_unsaved_values (sys::state &state) |
bool | has_railroads_being_built (sys::state &state, dcon::province_id id) |
bool | generic_can_build_railroads (sys::state &state, dcon::province_id id, dcon::nation_id n) |
bool | can_build_railroads (sys::state &state, dcon::province_id id, dcon::nation_id n) |
bool | has_fort_being_built (sys::state &state, dcon::province_id id) |
bool | can_build_fort (sys::state &state, dcon::province_id id, dcon::nation_id n) |
bool | has_naval_base_being_built (sys::state &state, dcon::province_id id) |
bool | can_build_naval_base (sys::state &state, dcon::province_id id, dcon::nation_id n) |
bool | has_province_building_being_built (sys::state &state, dcon::province_id id, economy::province_building_type t) |
bool | can_build_province_building (sys::state &state, dcon::province_id id, dcon::nation_id n, economy::province_building_type t) |
bool | has_an_owner (sys::state &state, dcon::province_id id) |
float | land_maximum_employment (sys::state &state, dcon::province_id id) |
float | land_employment (sys::state &state, dcon::province_id id) |
float | rgo_maximum_employment (sys::state &state, dcon::province_id id) |
float | rgo_employment (sys::state &state, dcon::province_id id) |
float | rgo_income (sys::state &state, dcon::province_id id) |
float | rgo_production_quantity (sys::state &state, dcon::province_id id, dcon::commodity_id c) |
float | rgo_size (sys::state &state, dcon::province_id prov_id) |
float | state_accepted_bureaucrat_size (sys::state &state, dcon::state_instance_id id) |
float | state_admin_efficiency (sys::state &state, dcon::state_instance_id id) |
float | crime_fighting_efficiency (sys::state &state, dcon::province_id id) |
float | revolt_risk (sys::state &state, dcon::province_id id) |
dcon::province_id | get_connected_province (sys::state &state, dcon::province_adjacency_id adj, dcon::province_id curr) |
float | state_distance (sys::state &state, dcon::state_instance_id state_id, dcon::province_id prov_id) |
float | state_sorting_distance (sys::state &state, dcon::state_instance_id state_id, dcon::province_id prov_id) |
bool | can_integrate_colony (sys::state &state, dcon::state_instance_id id) |
float | colony_integration_cost (sys::state &state, dcon::state_instance_id id) |
void | upgrade_colonial_state (sys::state &state, dcon::nation_id source, dcon::state_instance_id si) |
void | change_province_owner (sys::state &state, dcon::province_id id, dcon::nation_id new_owner) |
void | conquer_province (sys::state &state, dcon::province_id id, dcon::nation_id new_owner) |
void | update_nationalism (sys::state &state) |
void | update_crimes (sys::state &state) |
bool | is_colonizing (sys::state &state, dcon::nation_id n, dcon::state_definition_id d) |
bool | can_invest_in_colony (sys::state &state, dcon::nation_id n, dcon::state_definition_id d) |
bool | state_borders_nation (sys::state &state, dcon::nation_id n, dcon::state_instance_id si) |
bool | can_start_colony (sys::state &state, dcon::nation_id n, dcon::state_definition_id d) |
bool | fast_can_start_colony (sys::state &state, dcon::nation_id n, dcon::state_definition_id d, int32_t free_points, dcon::province_id coastal_target, bool &adjacent) |
void | increase_colonial_investment (sys::state &state, dcon::nation_id source, dcon::state_definition_id state_def) |
void | update_colonization (sys::state &state) |
bool | state_is_coastal (sys::state &state, dcon::state_instance_id s) |
bool | state_is_coastal_non_core_nb (sys::state &state, dcon::state_instance_id s) |
void | add_core (sys::state &state, dcon::province_id prov, dcon::national_identity_id tag) |
void | remove_core (sys::state &state, dcon::province_id prov, dcon::national_identity_id tag) |
void | set_rgo (sys::state &state, dcon::province_id prov, dcon::commodity_id c) |
void | enable_canal (sys::state &state, int32_t id) |
float | distance (sys::state &state, dcon::province_adjacency_id pair) |
float | direct_distance (sys::state &state, dcon::province_id a, dcon::province_id b) |
float | sorting_distance (sys::state &state, dcon::province_id a, dcon::province_id b) |
bool | has_naval_access_to_province (sys::state &state, dcon::nation_id nation_as, dcon::province_id prov) |
bool | has_access_to_province (sys::state &state, dcon::nation_id nation_as, dcon::province_id prov) |
bool | has_safe_access_to_province (sys::state &state, dcon::nation_id nation_as, dcon::province_id prov) |
std::vector< dcon::province_id > | make_land_path (sys::state &state, dcon::province_id start, dcon::province_id end, dcon::nation_id nation_as, dcon::army_id a) |
std::vector< dcon::province_id > | make_safe_land_path (sys::state &state, dcon::province_id start, dcon::province_id end, dcon::nation_id nation_as) |
std::vector< dcon::province_id > | make_unowned_land_path (sys::state &state, dcon::province_id start, dcon::province_id end) |
std::vector< dcon::province_id > | make_naval_path (sys::state &state, dcon::province_id start, dcon::province_id end) |
std::vector< dcon::province_id > | make_naval_retreat_path (sys::state &state, dcon::nation_id nation_as, dcon::province_id start) |
std::vector< dcon::province_id > | make_land_retreat_path (sys::state &state, dcon::nation_id nation_as, dcon::province_id start) |
std::vector< dcon::province_id > | make_path_to_nearest_coast (sys::state &state, dcon::nation_id nation_as, dcon::province_id start) |
std::vector< dcon::province_id > | make_unowned_path_to_nearest_coast (sys::state &state, dcon::province_id start) |
void | restore_distances (sys::state &state) |
constexpr uint16_t | to_map_id (dcon::province_id id) |
constexpr dcon::province_id | from_map_id (uint16_t id) |
template<typename T > | |
auto | is_overseas (sys::state const &state, T ids) |
template<typename F > | |
void | for_each_land_province (sys::state &state, F const &func) |
template<typename F > | |
void | ve_for_each_land_province (sys::state &state, F const &func) |
template<typename F > | |
void | for_each_sea_province (sys::state &state, F const &func) |
template<typename F > | |
void | for_each_province_in_state_instance (sys::state &state, dcon::state_instance_id s, F const &func) |
Variables | |
constexpr float | world_circumference = 40075.0f / 10.0f |
void province::add_core | ( | sys::state & | state, |
dcon::province_id | prov, | ||
dcon::national_identity_id | tag | ||
) |
Definition at line 1504 of file province.cpp.
bool province::can_build_fort | ( | sys::state & | state, |
dcon::province_id | id, | ||
dcon::nation_id | n | ||
) |
Definition at line 370 of file province.cpp.
bool province::can_build_naval_base | ( | sys::state & | state, |
dcon::province_id | id, | ||
dcon::nation_id | n | ||
) |
Definition at line 391 of file province.cpp.
bool province::can_build_province_building | ( | sys::state & | state, |
dcon::province_id | id, | ||
dcon::nation_id | n, | ||
economy::province_building_type | t | ||
) |
Definition at line 418 of file province.cpp.
bool province::can_build_railroads | ( | sys::state & | state, |
dcon::province_id | id, | ||
dcon::nation_id | n | ||
) |
Definition at line 330 of file province.cpp.
bool province::can_integrate_colony | ( | sys::state & | state, |
dcon::state_instance_id | id | ||
) |
Definition at line 593 of file province.cpp.
bool province::can_invest_in_colony | ( | sys::state & | state, |
dcon::nation_id | n, | ||
dcon::state_definition_id | d | ||
) |
Definition at line 1023 of file province.cpp.
bool province::can_start_colony | ( | sys::state & | state, |
dcon::nation_id | n, | ||
dcon::state_definition_id | d | ||
) |
Definition at line 1097 of file province.cpp.
void province::change_province_owner | ( | sys::state & | state, |
dcon::province_id | id, | ||
dcon::nation_id | new_owner | ||
) |
Definition at line 666 of file province.cpp.
float province::colony_integration_cost | ( | sys::state & | state, |
dcon::state_instance_id | id | ||
) |
Definition at line 609 of file province.cpp.
void province::conquer_province | ( | sys::state & | state, |
dcon::province_id | id, | ||
dcon::nation_id | new_owner | ||
) |
Definition at line 907 of file province.cpp.
float province::crime_fighting_efficiency | ( | sys::state & | state, |
dcon::province_id | id | ||
) |
Definition at line 536 of file province.cpp.
float province::direct_distance | ( | sys::state & | state, |
dcon::province_id | a, | ||
dcon::province_id | b | ||
) |
Definition at line 1555 of file province.cpp.
float province::distance | ( | sys::state & | state, |
dcon::province_adjacency_id | pair | ||
) |
Definition at line 1550 of file province.cpp.
void province::enable_canal | ( | sys::state & | state, |
int32_t | id | ||
) |
Definition at line 1545 of file province.cpp.
bool province::fast_can_start_colony | ( | sys::state & | state, |
dcon::nation_id | n, | ||
dcon::state_definition_id | d, | ||
int32_t | free_points, | ||
dcon::province_id | coastal_target, | ||
bool & | adjacent | ||
) |
Definition at line 1223 of file province.cpp.
void province::for_each_land_province | ( | sys::state & | state, |
F const & | func | ||
) |
void province::for_each_province_in_state_instance | ( | sys::state & | state, |
dcon::state_instance_id | s, | ||
F const & | func | ||
) |
Definition at line 39 of file province_templates.hpp.
template void province::for_each_province_in_state_instance< std::function< void(dcon::province_id)> > | ( | sys::state & | , |
dcon::state_instance_id | , | ||
std::function< void(dcon::province_id)> const & | |||
) |
void province::for_each_sea_province | ( | sys::state & | state, |
F const & | func | ||
) |
Definition at line 30 of file province_templates.hpp.
|
inlineconstexpr |
bool province::generic_can_build_railroads | ( | sys::state & | state, |
dcon::province_id | id, | ||
dcon::nation_id | n | ||
) |
Definition at line 317 of file province.cpp.
dcon::province_id province::get_connected_province | ( | sys::state & | state, |
dcon::province_adjacency_id | adj, | ||
dcon::province_id | curr | ||
) |
Definition at line 571 of file province.cpp.
bool province::has_access_to_province | ( | sys::state & | state, |
dcon::nation_id | nation_as, | ||
dcon::province_id | prov | ||
) |
Definition at line 1597 of file province.cpp.
bool province::has_an_owner | ( | sys::state & | state, |
dcon::province_id | id | ||
) |
Definition at line 452 of file province.cpp.
bool province::has_fort_being_built | ( | sys::state & | state, |
dcon::province_id | id | ||
) |
Definition at line 363 of file province.cpp.
bool province::has_naval_access_to_province | ( | sys::state & | state, |
dcon::nation_id | nation_as, | ||
dcon::province_id | prov | ||
) |
Definition at line 1570 of file province.cpp.
bool province::has_naval_base_being_built | ( | sys::state & | state, |
dcon::province_id | id | ||
) |
Definition at line 384 of file province.cpp.
bool province::has_province_building_being_built | ( | sys::state & | state, |
dcon::province_id | id, | ||
economy::province_building_type | t | ||
) |
Definition at line 410 of file province.cpp.
bool province::has_railroads_being_built | ( | sys::state & | state, |
dcon::province_id | id | ||
) |
Definition at line 309 of file province.cpp.
bool province::has_safe_access_to_province | ( | sys::state & | state, |
dcon::nation_id | nation_as, | ||
dcon::province_id | prov | ||
) |
Definition at line 1626 of file province.cpp.
void province::increase_colonial_investment | ( | sys::state & | state, |
dcon::nation_id | source, | ||
dcon::state_definition_id | state_def | ||
) |
Definition at line 1323 of file province.cpp.
bool province::is_colonizing | ( | sys::state & | state, |
dcon::nation_id | n, | ||
dcon::state_definition_id | d | ||
) |
Definition at line 1014 of file province.cpp.
bool province::is_overseas | ( | sys::state const & | state, |
dcon::province_id | ids | ||
) |
auto province::is_overseas | ( | sys::state const & | state, |
T | ids | ||
) |
Definition at line 7 of file province_templates.hpp.
template auto province::is_overseas< ve::tagged_vector< dcon::province_id > > | ( | sys::state const & | , |
ve::tagged_vector< dcon::province_id > | |||
) |
float province::land_employment | ( | sys::state & | state, |
dcon::province_id | id | ||
) |
Definition at line 459 of file province.cpp.
float province::land_maximum_employment | ( | sys::state & | state, |
dcon::province_id | id | ||
) |
Definition at line 455 of file province.cpp.
std::vector< dcon::province_id > province::make_land_path | ( | sys::state & | state, |
dcon::province_id | start, | ||
dcon::province_id | end, | ||
dcon::nation_id | nation_as, | ||
dcon::army_id | a | ||
) |
Definition at line 1673 of file province.cpp.
std::vector< dcon::province_id > province::make_land_retreat_path | ( | sys::state & | state, |
dcon::nation_id | nation_as, | ||
dcon::province_id | start | ||
) |
Definition at line 1986 of file province.cpp.
std::vector< dcon::province_id > province::make_naval_path | ( | sys::state & | state, |
dcon::province_id | start, | ||
dcon::province_id | end | ||
) |
Definition at line 1848 of file province.cpp.
std::vector< dcon::province_id > province::make_naval_retreat_path | ( | sys::state & | state, |
dcon::nation_id | nation_as, | ||
dcon::province_id | start | ||
) |
Definition at line 1932 of file province.cpp.
std::vector< dcon::province_id > province::make_path_to_nearest_coast | ( | sys::state & | state, |
dcon::nation_id | nation_as, | ||
dcon::province_id | start | ||
) |
Definition at line 2036 of file province.cpp.
std::vector< dcon::province_id > province::make_safe_land_path | ( | sys::state & | state, |
dcon::province_id | start, | ||
dcon::province_id | end, | ||
dcon::nation_id | nation_as | ||
) |
Definition at line 1740 of file province.cpp.
std::vector< dcon::province_id > province::make_unowned_land_path | ( | sys::state & | state, |
dcon::province_id | start, | ||
dcon::province_id | end | ||
) |
Definition at line 1798 of file province.cpp.
std::vector< dcon::province_id > province::make_unowned_path_to_nearest_coast | ( | sys::state & | state, |
dcon::province_id | start | ||
) |
Definition at line 2088 of file province.cpp.
bool province::nations_are_adjacent | ( | sys::state & | state, |
dcon::nation_id | a, | ||
dcon::nation_id | b | ||
) |
Definition at line 25 of file province.cpp.
dcon::province_id province::pick_capital | ( | sys::state & | state, |
dcon::nation_id | n | ||
) |
Definition at line 89 of file province.cpp.
void province::remove_core | ( | sys::state & | state, |
dcon::province_id | prov, | ||
dcon::national_identity_id | tag | ||
) |
Definition at line 1514 of file province.cpp.
void province::restore_cached_values | ( | sys::state & | state | ) |
void province::restore_distances | ( | sys::state & | state | ) |
Definition at line 2137 of file province.cpp.
void province::restore_unsaved_values | ( | sys::state & | state | ) |
Definition at line 280 of file province.cpp.
float province::revolt_risk | ( | sys::state & | state, |
dcon::province_id | id | ||
) |
Definition at line 561 of file province.cpp.
float province::rgo_employment | ( | sys::state & | state, |
dcon::province_id | id | ||
) |
Definition at line 467 of file province.cpp.
float province::rgo_income | ( | sys::state & | state, |
dcon::province_id | id | ||
) |
Definition at line 470 of file province.cpp.
float province::rgo_maximum_employment | ( | sys::state & | state, |
dcon::province_id | id | ||
) |
Definition at line 463 of file province.cpp.
float province::rgo_production_quantity | ( | sys::state & | state, |
dcon::province_id | id, | ||
dcon::commodity_id | c | ||
) |
Definition at line 473 of file province.cpp.
float province::rgo_size | ( | sys::state & | state, |
dcon::province_id | prov_id | ||
) |
Definition at line 477 of file province.cpp.
void province::set_province_controller | ( | sys::state & | state, |
dcon::province_id | p, | ||
dcon::nation_id | n | ||
) |
Definition at line 107 of file province.cpp.
void province::set_province_controller | ( | sys::state & | state, |
dcon::province_id | p, | ||
dcon::rebel_faction_id | rf | ||
) |
void province::set_rgo | ( | sys::state & | state, |
dcon::province_id | prov, | ||
dcon::commodity_id | c | ||
) |
Definition at line 1525 of file province.cpp.
float province::sorting_distance | ( | sys::state & | state, |
dcon::province_id | a, | ||
dcon::province_id | b | ||
) |
Definition at line 1562 of file province.cpp.
float province::state_accepted_bureaucrat_size | ( | sys::state & | state, |
dcon::state_instance_id | id | ||
) |
Definition at line 490 of file province.cpp.
float province::state_admin_efficiency | ( | sys::state & | state, |
dcon::state_instance_id | id | ||
) |
Definition at line 503 of file province.cpp.
bool province::state_borders_nation | ( | sys::state & | state, |
dcon::nation_id | n, | ||
dcon::state_instance_id | si | ||
) |
Definition at line 1079 of file province.cpp.
float province::state_distance | ( | sys::state & | state, |
dcon::state_instance_id | state_id, | ||
dcon::province_id | prov_id | ||
) |
Definition at line 585 of file province.cpp.
bool province::state_is_coastal | ( | sys::state & | state, |
dcon::state_instance_id | s | ||
) |
Definition at line 1476 of file province.cpp.
bool province::state_is_coastal_non_core_nb | ( | sys::state & | state, |
dcon::state_instance_id | s | ||
) |
Definition at line 1488 of file province.cpp.
float province::state_sorting_distance | ( | sys::state & | state, |
dcon::state_instance_id | state_id, | ||
dcon::province_id | prov_id | ||
) |
Definition at line 589 of file province.cpp.
|
inlineconstexpr |
Definition at line 10 of file province.hpp.
void province::update_blockaded_cache | ( | sys::state & | state | ) |
Definition at line 264 of file province.cpp.
void province::update_cached_values | ( | sys::state & | state | ) |
void province::update_colonization | ( | sys::state & | state | ) |
Definition at line 1386 of file province.cpp.
void province::update_connected_regions | ( | sys::state & | state | ) |
Definition at line 29 of file province.cpp.
void province::update_crimes | ( | sys::state & | state | ) |
Definition at line 965 of file province.cpp.
void province::update_nationalism | ( | sys::state & | state | ) |
Definition at line 957 of file province.cpp.
void province::upgrade_colonial_state | ( | sys::state & | state, |
dcon::nation_id | source, | ||
dcon::state_instance_id | si | ||
) |
Definition at line 629 of file province.cpp.
void province::ve_for_each_land_province | ( | sys::state & | state, |
F const & | func | ||
) |
|
inlineconstexpr |
Definition at line 8 of file province.hpp.