Skip to content

Commit 06a2fa4

Browse files
dependabot[bot]wvpm
authored andcommitted
Bump extension/deps/openvic-simulation from ba96203 to b6de9bf
Bumps [extension/deps/openvic-simulation](https://github.com/OpenVicProject/OpenVic-Simulation) from `ba96203` to `b6de9bf`. - [Commits](OpenVicProject/OpenVic-Simulation@ba96203...b6de9bf) --- updated-dependencies: - dependency-name: extension/deps/openvic-simulation dependency-version: b6de9bf8f36d614df69ee61b83d2bb84c65afb93 dependency-type: direct:production ... Signed-off-by: dependabot[bot] <support@github.com>
1 parent a7edcfd commit 06a2fa4

15 files changed

Lines changed: 79 additions & 79 deletions

extension/deps/openvic-simulation

Submodule openvic-simulation updated 93 files

extension/src/openvic-extension/classes/GFXMaskedFlagTexture.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ Error GFXMaskedFlagTexture::set_flag_country_and_type(
178178
GameSingleton const* game_singleton = GameSingleton::get_singleton();
179179
ERR_FAIL_NULL_V(game_singleton, FAILED);
180180

181-
flag_image_rect = game_singleton->get_flag_sheet_rect(new_flag_country->get_index(), new_flag_type);
181+
flag_image_rect = game_singleton->get_flag_sheet_rect(new_flag_country->index, new_flag_type);
182182
ERR_FAIL_COND_V(!flag_image_rect.has_area(), FAILED);
183183

184184
flag_country = new_flag_country;
@@ -225,7 +225,7 @@ Error GFXMaskedFlagTexture::set_flag_country(CountryInstance* new_flag_country)
225225
? StringName { convert_to<String>(government_type->get_flag_type()) }
226226
: StringName {};
227227

228-
return set_flag_country_and_type(&new_flag_country->get_country_definition(), new_flag_type);
228+
return set_flag_country_and_type(&new_flag_country->country_definition, new_flag_type);
229229
}
230230

231231
Error GFXMaskedFlagTexture::set_flag_country_name(String const& new_flag_country_name) {

extension/src/openvic-extension/classes/GUILabel.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -702,7 +702,7 @@ GUILabel::flag_segment_t GUILabel::make_flag_segment(String const& identifier) {
702702
);
703703

704704
if (country_instance != nullptr) {
705-
country_index = country_instance->get_country_definition().get_index();
705+
country_index = country_instance->country_definition.index;
706706

707707
GovernmentType const* government_type = country_instance->flag_government_type.get_untracked();
708708
if (government_type != nullptr) {
@@ -716,7 +716,7 @@ GUILabel::flag_segment_t GUILabel::make_flag_segment(String const& identifier) {
716716
);
717717

718718
if (country_definition != nullptr) {
719-
country_index = country_definition->get_index();
719+
country_index = country_definition->index;
720720
}
721721
}
722722

extension/src/openvic-extension/components/budget/AdministrationBudget.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,11 +112,11 @@ fixed_point_t AdministrationBudget::calculate_budget_and_update_custom(
112112

113113
godot::String reforms_part = "";
114114
for (auto const& [group, reform] : country.get_reforms()) {
115-
if (!group.get_is_administrative() || reform == nullptr) {
115+
if (!group.is_administrative || reform == nullptr) {
116116
continue;
117117
}
118118

119-
const fixed_point_t administrative_multiplier = reform->get_administrative_multiplier();
119+
const fixed_point_t administrative_multiplier = reform->administrative_multiplier;
120120
if (administrative_multiplier == 0) {
121121
continue;
122122
}

extension/src/openvic-extension/components/budget/StrataTaxBudget.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ StrataTaxBudget::StrataTaxBudget(
2323
parent,
2424
generate_slider_tooltip_localisation_key(new_strata),
2525
BALANCE,
26-
Utilities::format("./country_budget/tax_%d_slider", static_cast<uint64_t>(new_strata.get_index())),
27-
Utilities::format("./country_budget/tax_%d_inc", static_cast<uint64_t>(new_strata.get_index()))
26+
Utilities::format("./country_budget/tax_%d_slider", static_cast<uint64_t>(new_strata.index)),
27+
Utilities::format("./country_budget/tax_%d_inc", static_cast<uint64_t>(new_strata.index))
2828
),
2929
BudgetIncomeComponent(generate_summary_localisation_key(new_strata), 1),
3030
strata{new_strata},
@@ -37,7 +37,7 @@ StrataTaxBudget::StrataTaxBudget(
3737

3838
GUILabel::set_text_and_tooltip(
3939
parent,
40-
Utilities::format("./country_budget/tax_%d_desc", static_cast<uint64_t>(new_strata.get_index())),
40+
Utilities::format("./country_budget/tax_%d_desc", static_cast<uint64_t>(new_strata.index)),
4141
generate_slider_tooltip_localisation_key(new_strata),
4242
Utilities::format(
4343
"TAX_%s_DESC",

extension/src/openvic-extension/components/overview/ScoreOverview.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ void ScoreOverview::update() {
152152

153153
InstanceManager const& instance_manager = *game_singleton.get_instance_manager();
154154
ModifierEffect const* const colonial_points_modifier = instance_manager
155-
.get_definition_manager()
155+
.definition_manager
156156
.get_modifier_manager()
157157
.get_modifier_effect_cache()
158158
.get_colonial_points();

extension/src/openvic-extension/singletons/GameSingleton.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ TypedArray<Dictionary> GameSingleton::get_bookmark_info() const {
194194
Dictionary bookmark_info;
195195

196196
bookmark_info[bookmark_info_name_key] = convert_to<String>(bookmark.get_name());
197-
bookmark_info[bookmark_info_date_key] = Utilities::date_to_formatted_string(bookmark.get_date(), false);
197+
bookmark_info[bookmark_info_date_key] = Utilities::date_to_formatted_string(bookmark.date, false);
198198

199199
results.push_back(std::move(bookmark_info));
200200
}
@@ -214,7 +214,7 @@ Error GameSingleton::setup_game(int32_t bookmark_index) {
214214
ERR_FAIL_NULL_V_MSG(instance_manager, FAILED, "Failed to setup instance manager!");
215215
for (ProvinceInstance& province : instance_manager->get_map_instance().get_province_instances()) {
216216
province.set_crime(get_definition_manager().get_crime_manager().get_crime_modifier_by_index(
217-
province.get_index() % get_definition_manager().get_crime_manager().get_crime_modifier_count()
217+
province.index % get_definition_manager().get_crime_manager().get_crime_modifier_count()
218218
));
219219
}
220220

@@ -299,7 +299,7 @@ Vector2 GameSingleton::get_bookmark_start_position() const {
299299
Bookmark const* bookmark = instance_manager->get_bookmark();
300300
ERR_FAIL_NULL_V(bookmark, {});
301301

302-
return normalise_map_position(bookmark->get_initial_camera_position());
302+
return normalise_map_position(bookmark->initial_camera_position);
303303
}
304304

305305
Ref<Texture2DArray> GameSingleton::get_terrain_texture() const {
@@ -453,15 +453,15 @@ String GameSingleton::get_mapmode_localisation_key(int32_t index) const {
453453
}
454454

455455
int32_t GameSingleton::get_current_mapmode_index() const {
456-
return mapmode->get_index();
456+
return mapmode->index;
457457
}
458458

459459
Error GameSingleton::set_mapmode(int32_t index) {
460460
Mapmode const* new_mapmode = get_definition_manager().get_mapmode_manager().get_mapmode_by_index(index);
461461
ERR_FAIL_NULL_V_MSG(new_mapmode, FAILED, Utilities::format("Failed to find mapmode with index: %d", index));
462462
mapmode = new_mapmode;
463463
const Error err = _update_colour_image();
464-
emit_signal(_signal_mapmode_changed(), mapmode->get_index());
464+
emit_signal(_signal_mapmode_changed(), mapmode->index);
465465
return err;
466466
}
467467

extension/src/openvic-extension/singletons/MapItemSingleton.cpp

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ PackedVector2Array MapItemSingleton::get_capital_positions() const {
172172
continue;
173173
}
174174

175-
billboard_pos[index++] = game_singleton->get_billboard_pos(country.get_capital()->get_province_definition());
175+
billboard_pos[index++] = game_singleton->get_billboard_pos(country.get_capital()->province_definition);
176176
}
177177

178178
billboard_pos.resize(index);
@@ -189,18 +189,18 @@ PackedByteArray MapItemSingleton::get_crime_icons() const {
189189

190190
PackedByteArray icons {};
191191

192-
icons.resize(map_instance.get_map_definition().get_land_province_count());
192+
icons.resize(instance_manager->definition_manager.get_map_definition().get_land_province_count());
193193

194194
int64_t index = 0;
195195

196196
for (ProvinceInstance const& prov_inst : map_instance.get_province_instances()) {
197-
if (prov_inst.get_province_definition().is_water()) {
197+
if (prov_inst.province_definition.is_water()) {
198198
// billboards dont appear over water, skip
199199
continue;
200200
}
201201

202202
Crime const* crime = prov_inst.get_crime();
203-
icons[index++] = crime != nullptr ? crime->get_icon() : 0; // 0 if no crime in the province
203+
icons[index++] = crime != nullptr ? crime->icon : 0; // 0 if no crime in the province
204204
}
205205

206206
return icons;
@@ -215,18 +215,18 @@ PackedByteArray MapItemSingleton::get_rgo_icons() const {
215215

216216
PackedByteArray icons {};
217217

218-
icons.resize(map_instance.get_map_definition().get_land_province_count());
218+
icons.resize(instance_manager->definition_manager.get_map_definition().get_land_province_count());
219219

220220
int64_t index = 0;
221221

222222
for (ProvinceInstance const& prov_inst : map_instance.get_province_instances()) {
223-
if (prov_inst.get_province_definition().is_water()) {
223+
if (prov_inst.province_definition.is_water()) {
224224
// billboards dont appear over water, skip
225225
continue;
226226
}
227227

228228
GoodDefinition const* rgo_good = prov_inst.get_rgo_good();
229-
icons[index++] = rgo_good != nullptr ? rgo_good->get_index() + 1 : 0; // 0 if no rgo good in the province
229+
icons[index++] = rgo_good != nullptr ? rgo_good->index + 1 : 0; // 0 if no rgo good in the province
230230
}
231231

232232
return icons;
@@ -250,12 +250,12 @@ PackedByteArray MapItemSingleton::get_national_focus_icons() const {
250250

251251
PackedByteArray icons {};
252252

253-
icons.resize(map_instance.get_map_definition().get_land_province_count());
253+
icons.resize(instance_manager->definition_manager.get_map_definition().get_land_province_count());
254254

255255
int64_t index = 0;
256256

257257
for (ProvinceInstance const& prov_inst : map_instance.get_province_instances()) {
258-
if (prov_inst.get_province_definition().is_water()) {
258+
if (prov_inst.province_definition.is_water()) {
259259
// billboards dont appear over water, skip
260260
continue;
261261
}

extension/src/openvic-extension/singletons/MenuSingleton.cpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -539,7 +539,7 @@ Dictionary MenuSingleton::get_province_info_from_number(int32_t province_number)
539539
ProductionType const& production_type = *rgo.get_production_type_nullable();
540540
GoodDefinition const& rgo_good = *province->get_rgo_good();
541541

542-
ret[province_info_rgo_icon_key] = static_cast<int32_t>(rgo_good.get_index());
542+
ret[province_info_rgo_icon_key] = static_cast<int32_t>(rgo_good.index);
543543

544544
ret[province_info_rgo_output_quantity_yesterday_key] = static_cast<real_t>(rgo.get_output_quantity_yesterday());
545545
ret[province_info_rgo_revenue_yesterday_key] = static_cast<real_t>(rgo.get_revenue_yesterday());
@@ -751,7 +751,7 @@ Dictionary MenuSingleton::get_province_info_from_number(int32_t province_number)
751751
}
752752

753753
ModifierEffectCache::good_effects_t const& good_effects =
754-
modifier_effect_cache.get_good_effects(production_type.get_output_good());
754+
modifier_effect_cache.get_good_effects(production_type.output_good);
755755

756756
fixed_point_t output_from_tech =
757757
province->get_modifier_effect_value(*modifier_effect_cache.get_rgo_output_tech()) +
@@ -838,7 +838,7 @@ Dictionary MenuSingleton::get_province_info_from_number(int32_t province_number)
838838

839839
const fixed_point_t throughput_efficiency = throughput_from_workers * throughput_multiplier;
840840
const fixed_point_t output_efficiency = output_from_workers * output_multiplier;
841-
const fixed_point_t base_output = production_type.get_base_output_quantity();
841+
const fixed_point_t base_output = production_type.base_output_quantity;
842842
const fixed_point_t max_output = base_output * throughput_efficiency * output_efficiency;
843843

844844
ret[province_info_rgo_production_tooltip_key] = Utilities::format(
@@ -882,7 +882,7 @@ Dictionary MenuSingleton::get_province_info_from_number(int32_t province_number)
882882
),
883883
amount_of_employees_by_pop_type,
884884
tr(rgo_workforce_localisation_key),
885-
production_type.get_base_workforce_size(),
885+
production_type.base_workforce_size,
886886
size_string,
887887
tr(province_size_localisation_key),
888888
static_cast<int32_t>(rgo.get_size_multiplier()) // TODO - remove cast once variable is an int32_t
@@ -892,7 +892,7 @@ Dictionary MenuSingleton::get_province_info_from_number(int32_t province_number)
892892
Crime const* crime = province->get_crime();
893893
if (crime != nullptr) {
894894
ret[province_info_crime_name_key] = convert_to<String>(crime->get_identifier());
895-
ret[province_info_crime_icon_key] = static_cast<int32_t>(crime->get_icon());
895+
ret[province_info_crime_icon_key] = static_cast<int32_t>(crime->icon);
896896
}
897897

898898
ret[province_info_total_population_key] = province->get_total_population();
@@ -1100,7 +1100,7 @@ Dictionary MenuSingleton::get_topbar_info() const {
11001100
fixed_point_t::_100 * country->get_population_by_type(*pop_type) / country->get_total_population(), 2
11011101
)
11021102
).replace(
1103-
optimal_replace_key, Utilities::fixed_point_to_string_dp(100 * pop_type->get_research_leadership_optimum(), 2)
1103+
optimal_replace_key, Utilities::fixed_point_to_string_dp(100 * pop_type->research_leadership_optimum, 2)
11041104
) + "\n";
11051105
}
11061106

@@ -1205,7 +1205,7 @@ Dictionary MenuSingleton::get_topbar_info() const {
12051205
fixed_point_t::_100 * country->get_population_by_type(*pop_type) / country->get_total_population(), 2
12061206
)
12071207
).replace(
1208-
optimal_replace_key, Utilities::fixed_point_to_string_dp(100 * pop_type->get_research_leadership_optimum(), 2)
1208+
optimal_replace_key, Utilities::fixed_point_to_string_dp(100 * pop_type->research_leadership_optimum, 2)
12091209
) + "\n";
12101210
}
12111211

@@ -1480,7 +1480,7 @@ Vector2 MenuSingleton::get_search_result_position(int32_t result_index) const {
14801480

14811481
struct entry_visitor_t {
14821482
fvec2_t operator()(ProvinceInstance const* province) {
1483-
return province->get_province_definition().get_centre();
1483+
return province->province_definition.get_centre();
14841484
}
14851485

14861486
fvec2_t operator()(State const* state) {

extension/src/openvic-extension/singletons/MilitaryMenu.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,8 @@ Dictionary MenuSingleton::make_leader_dict(LeaderInstance const& leader) {
6060

6161
{
6262
// Generic data
63-
leader_dict[military_info_leader_id_key] = leader.get_unique_id();
64-
leader_dict[military_info_leader_branch_key] = static_cast<int32_t>(leader.get_branch());
63+
leader_dict[military_info_leader_id_key] = leader.unique_id;
64+
leader_dict[military_info_leader_branch_key] = static_cast<int32_t>(leader.branch);
6565

6666
leader_dict[military_info_leader_can_be_used_key] = leader.get_can_be_used();
6767

@@ -81,7 +81,7 @@ Dictionary MenuSingleton::make_leader_dict(LeaderInstance const& leader) {
8181
// Title
8282
using enum unit_branch_t;
8383

84-
switch (leader.get_branch()) {
84+
switch (leader.branch) {
8585
case LAND: {
8686
static const StringName general_localisation_key = "MILITARY_GENERAL_TOOLTIP";
8787
tooltip = tr(general_localisation_key) + " ";
@@ -94,7 +94,7 @@ Dictionary MenuSingleton::make_leader_dict(LeaderInstance const& leader) {
9494

9595
default:
9696
UtilityFunctions::push_error(
97-
"Invalid branch type \"", static_cast<int64_t>(leader.get_branch()), "\" for leader \"",
97+
"Invalid branch type \"", static_cast<int64_t>(leader.branch), "\" for leader \"",
9898
convert_to<String>(leader.get_name()), "\""
9999
);
100100
}
@@ -325,7 +325,7 @@ Dictionary MenuSingleton::make_in_progress_unit_dict() const {
325325
Dictionary in_progress_unit_dict;
326326

327327
in_progress_unit_dict[military_info_unit_progress_key] = static_cast<real_t>(progress);
328-
in_progress_unit_dict[military_info_unit_icon_key] = unit_type->get_icon();
328+
in_progress_unit_dict[military_info_unit_icon_key] = unit_type->icon;
329329
in_progress_unit_dict[military_info_unit_name_key] = convert_to<String>(unit_type->get_identifier());
330330
if (location != nullptr) {
331331
in_progress_unit_dict[military_info_unit_location_key] = convert_to<String>(location->get_identifier());

0 commit comments

Comments
 (0)