Skip to content

Commit

Permalink
Fix custom empires sometimes adding sand and stone when they shouldn't
Browse files Browse the repository at this point in the history
  • Loading branch information
crudelios committed Aug 10, 2023
1 parent e0ac415 commit b0fc340
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/empire/city.c
Original file line number Diff line number Diff line change
Expand Up @@ -608,10 +608,10 @@ void empire_city_update_trading_data(int empire_id)
change_selling_of_resource(city, RESOURCE_FISH, !NOT_SELLING);
}
}
} else if (empire_id == SCENARIO_CUSTOM_EMPIRE) {
continue;
}
update_trading_data(empire_id, city);
if (empire_id != SCENARIO_CUSTOM_EMPIRE) {
update_trading_data(empire_id, city);
}
}
}

Expand Down
2 changes: 2 additions & 0 deletions src/widget/top_menu_editor.c
Original file line number Diff line number Diff line change
Expand Up @@ -303,6 +303,7 @@ static void menu_empire_choose(int param)
clear_state();
window_go_back();
scenario_editor_unset_custom_empire();
resource_set_mapping(RESOURCE_ORIGINAL_VERSION);
empire_load(1, scenario_empire_id());
empire_object_init_cities(scenario_empire_id());
window_editor_empire_show();
Expand All @@ -312,5 +313,6 @@ static void menu_empire_custom(int param)
{
clear_state();
window_go_back();
resource_set_mapping(RESOURCE_CURRENT_VERSION);
window_file_dialog_show(FILE_TYPE_EMPIRE, FILE_DIALOG_LOAD);
}

0 comments on commit b0fc340

Please sign in to comment.