From 76c8b7ad54c5e0b83b64e2b1317adab60dd10459 Mon Sep 17 00:00:00 2001 From: William Hardy Gest Date: Sat, 14 Feb 2026 15:24:34 -0600 Subject: [PATCH 01/12] Reworked venus GT with replacement building/modules --- src/building/building.c | 10 +++++++ src/building/building.h | 2 ++ src/building/construction_building.c | 1 + src/building/count.c | 2 +- src/building/figure.c | 1 + src/building/house_service.c | 11 ++++++++ src/building/image.c | 1 + src/building/menu.c | 7 ++++- src/building/monument.c | 9 ++++++ src/building/monument.h | 2 ++ src/building/properties.c | 12 ++++++++ src/building/type.h | 3 +- src/city/culture.c | 4 ++- src/city/finance.c | 1 + src/city/gods.c | 2 +- src/city/labor.c | 1 + src/city/ratings.c | 1 + src/city/trade.c | 2 +- src/core/lang.c | 2 ++ src/figure/roamer_preview.c | 1 + src/figure/service.c | 1 + src/game/cheats.c | 20 +++++++++++-- src/game/cheats.h | 2 ++ src/map/desirability.c | 23 ++++++++++++++- src/map/image_context.c | 2 +- src/scenario/allowed_building.c | 2 +- src/translation/english.c | 7 +++++ src/translation/translation.h | 7 +++++ src/widget/city_overlay_other.c | 2 +- src/window/advisor/religion.c | 2 +- src/window/building/culture.c | 42 +++++++++++++++++++++++++--- src/window/building/culture.h | 2 ++ src/window/building/house.c | 27 ++++++++++++++++++ src/window/building_info.c | 7 +++-- src/window/city.c | 1 + 35 files changed, 203 insertions(+), 19 deletions(-) diff --git a/src/building/building.c b/src/building/building.c index f3d90278b5..4ab97322d6 100644 --- a/src/building/building.c +++ b/src/building/building.c @@ -850,6 +850,16 @@ int building_is_venus_temple(building_type type) return (type == BUILDING_SMALL_TEMPLE_VENUS || type == BUILDING_LARGE_TEMPLE_VENUS); } +int building_is_temple(building_type type) +{ + return building_is_ceres_temple(type) || building_is_neptune_temple(type) || + building_is_mercury_temple(type) || building_is_mars_temple(type) || + building_is_venus_temple(type) || + type == BUILDING_GRAND_TEMPLE_CERES || type == BUILDING_GRAND_TEMPLE_NEPTUNE || + type == BUILDING_GRAND_TEMPLE_MERCURY || type == BUILDING_GRAND_TEMPLE_MARS || + type == BUILDING_GRAND_TEMPLE_VENUS || type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED; +} + // All buildings capable of collecting and storing goods as a market int building_has_supplier_inventory(building_type type) { diff --git a/src/building/building.h b/src/building/building.h index d43d68ddd1..b503d2bc88 100644 --- a/src/building/building.h +++ b/src/building/building.h @@ -272,6 +272,8 @@ int building_is_mars_temple(building_type type); int building_is_venus_temple(building_type type); +int building_is_temple(building_type type); + int building_has_supplier_inventory(building_type type); int building_is_house_group(house_groups group, building_type type); diff --git a/src/building/construction_building.c b/src/building/construction_building.c index 583b279a88..dae794dcf2 100644 --- a/src/building/construction_building.c +++ b/src/building/construction_building.c @@ -327,6 +327,7 @@ static void add_to_map(int type, building *b, int size, int orientation, int wat case BUILDING_GRAND_TEMPLE_MERCURY: case BUILDING_GRAND_TEMPLE_MARS: case BUILDING_GRAND_TEMPLE_VENUS: + case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: case BUILDING_PANTHEON: map_tiles_update_area_roads(b->x, b->y, 9); building_monument_set_phase(b, MONUMENT_START); diff --git a/src/building/count.c b/src/building/count.c index 2275910ea1..423accb79a 100644 --- a/src/building/count.c +++ b/src/building/count.c @@ -51,7 +51,7 @@ static const building_type building_set_large_temples[] = { static const building_type building_set_grand_temples[] = { BUILDING_GRAND_TEMPLE_CERES, BUILDING_GRAND_TEMPLE_NEPTUNE, BUILDING_GRAND_TEMPLE_MERCURY, BUILDING_GRAND_TEMPLE_MARS, - BUILDING_GRAND_TEMPLE_VENUS, BUILDING_PANTHEON + BUILDING_GRAND_TEMPLE_VENUS, BUILDING_GRAND_TEMPLE_VENUS_REWORKED, BUILDING_PANTHEON }; #define BUILDING_SET_SIZE_GRAND_TEMPLES (sizeof(building_set_grand_temples) / sizeof(building_type)) diff --git a/src/building/figure.c b/src/building/figure.c index ac1e98971f..3d3d523037 100644 --- a/src/building/figure.c +++ b/src/building/figure.c @@ -2131,6 +2131,7 @@ void building_figure_generate(void) case BUILDING_GRAND_TEMPLE_NEPTUNE: case BUILDING_GRAND_TEMPLE_MERCURY: case BUILDING_GRAND_TEMPLE_VENUS: + case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: case BUILDING_PANTHEON: spawn_figure_temple(b); break; diff --git a/src/building/house_service.c b/src/building/house_service.c index 72af823b34..26596fb001 100644 --- a/src/building/house_service.c +++ b/src/building/house_service.c @@ -78,6 +78,7 @@ void house_service_decay_houses_covered(void) void house_service_calculate_culture_aggregates(void) { int venus_module2 = building_monument_gt_module_is_active(VENUS_MODULE_2_DESIRABILITY_ENTERTAINMENT); + int venus_module4 = building_monument_gt_module_is_active(VENUS_MODULE_4_THEATER_TAVERN); int completed_colosseum = building_monument_working(BUILDING_COLOSSEUM); int completed_hippodrome = building_monument_working(BUILDING_HIPPODROME); @@ -138,6 +139,16 @@ void house_service_calculate_culture_aggregates(void) b->data.house.entertainment += 10; } + // Venus Module 4 Theater/Tavern Bonus + if (venus_module4) { + if (b->data.house.theater) { + b->data.house.entertainment += 5; + } + if (b->house_tavern_wine_access) { + b->data.house.entertainment += 5; + } + } + // Education b->data.house.education = 0; if (b->data.house.school || b->data.house.library) { diff --git a/src/building/image.c b/src/building/image.c index 0b6512a272..8818ee1a0a 100644 --- a/src/building/image.c +++ b/src/building/image.c @@ -668,6 +668,7 @@ int building_image_get(const building *b) } } case BUILDING_GRAND_TEMPLE_VENUS: + case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: switch (b->monument.phase) { case MONUMENT_START: return assets_get_image_id("Monuments", "Venus Complex Const 01"); diff --git a/src/building/menu.c b/src/building/menu.c index 2eb64bcfb1..13a42352c2 100644 --- a/src/building/menu.c +++ b/src/building/menu.c @@ -5,6 +5,7 @@ #include "city/buildings.h" #include "core/config.h" #include "empire/city.h" +#include "game/cheats.h" #include "game/tutorial.h" #include "scenario/allowed_building.h" #include "scenario/property.h" @@ -51,7 +52,7 @@ static const building_type MENU_BUILDING_TYPE[BUILD_MENU_MAX][BUILD_MENU_ITEM_MA {BUILDING_MENU_PATHS, BUILDING_GARDEN_PATH, BUILDING_PINE_PATH , BUILDING_FIR_PATH, BUILDING_OAK_PATH, BUILDING_ELM_PATH, BUILDING_FIG_PATH, BUILDING_PLUM_PATH, BUILDING_PALM_PATH, BUILDING_DATE_PATH, 0}, {BUILDING_PANTHEON, BUILDING_GRAND_TEMPLE_CERES, BUILDING_GRAND_TEMPLE_NEPTUNE, BUILDING_GRAND_TEMPLE_MERCURY, - BUILDING_GRAND_TEMPLE_MARS, BUILDING_GRAND_TEMPLE_VENUS, 0}, + BUILDING_GRAND_TEMPLE_MARS, BUILDING_GRAND_TEMPLE_VENUS, BUILDING_GRAND_TEMPLE_VENUS_REWORKED, 0}, {BUILDING_SMALL_STATUE, BUILDING_GODDESS_STATUE, BUILDING_SENATOR_STATUE, BUILDING_GLADIATOR_STATUE, BUILDING_DECORATIVE_COLUMN, BUILDING_MEDIUM_STATUE, BUILDING_LEGION_STATUE, BUILDING_OBELISK, BUILDING_LARGE_STATUE, BUILDING_HORSE_STATUE, 0}, {BUILDING_GOVERNORS_HOUSE, BUILDING_GOVERNORS_VILLA, BUILDING_GOVERNORS_PALACE, 0}, @@ -136,6 +137,10 @@ static int can_get_required_resource(building_type type) static int is_building_type_allowed(building_type type) { + // BUILDING_GRAND_TEMPLE_VENUS requires the legacy venus cheat to be active + if (type == BUILDING_GRAND_TEMPLE_VENUS) { + return game_cheat_legacy_venus_enabled() && scenario_allowed_building(type) && can_get_required_resource(type); + } return scenario_allowed_building(type) && can_get_required_resource(type); } diff --git a/src/building/monument.c b/src/building/monument.c index 17aeabda7c..8a6ff874d3 100644 --- a/src/building/monument.c +++ b/src/building/monument.c @@ -160,6 +160,7 @@ static const monument_type *MONUMENT_TYPES[BUILDING_TYPE_MAX] = { [BUILDING_GRAND_TEMPLE_MERCURY] = &grand_temple, [BUILDING_GRAND_TEMPLE_MARS] = &grand_temple, [BUILDING_GRAND_TEMPLE_VENUS] = &grand_temple, + [BUILDING_GRAND_TEMPLE_VENUS_REWORKED] = &grand_temple, [BUILDING_PANTHEON] = &pantheon, [BUILDING_ORACLE] = &oracle, [BUILDING_LARGE_TEMPLE_CERES] = &large_temple, @@ -283,6 +284,7 @@ int building_monument_is_limited(building_type type) case BUILDING_GRAND_TEMPLE_MERCURY: case BUILDING_GRAND_TEMPLE_MARS: case BUILDING_GRAND_TEMPLE_VENUS: + case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: case BUILDING_PANTHEON: case BUILDING_LIGHTHOUSE: case BUILDING_CARAVANSERAI: @@ -398,6 +400,7 @@ int building_monument_is_grand_temple(building_type type) case BUILDING_GRAND_TEMPLE_MERCURY: case BUILDING_GRAND_TEMPLE_MARS: case BUILDING_GRAND_TEMPLE_VENUS: + case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: return 1; default: return 0; @@ -722,6 +725,12 @@ int building_monument_gt_module_is_active(int module) int module_num = module % MODULES_PER_TEMPLE + 1; int temple_type = module / MODULES_PER_TEMPLE + BUILDING_GRAND_TEMPLE_CERES; + // Special handling for reworked Venus temple modules + if (module == VENUS_MODULE_3_WINE_TEMPLE || module == VENUS_MODULE_4_THEATER_TAVERN) { + temple_type = BUILDING_GRAND_TEMPLE_VENUS_REWORKED; + module_num = (module == VENUS_MODULE_3_WINE_TEMPLE) ? 1 : 2; + } + return building_monument_module_type(temple_type) == module_num; } diff --git a/src/building/monument.h b/src/building/monument.h index 750cf0ad18..5d4fc8d91d 100644 --- a/src/building/monument.h +++ b/src/building/monument.h @@ -19,6 +19,8 @@ typedef enum { MARS_MODULE_2_ALL_GOODS, VENUS_MODULE_1_DISTRIBUTE_WINE, VENUS_MODULE_2_DESIRABILITY_ENTERTAINMENT, + VENUS_MODULE_3_WINE_TEMPLE, + VENUS_MODULE_4_THEATER_TAVERN, PANTHEON_MODULE_1_DESTINATION_PRIESTS, PANTHEON_MODULE_2_HOUSING_EVOLUTION } module_type; diff --git a/src/building/properties.c b/src/building/properties.c index 1fc339e0b1..547ecbd585 100644 --- a/src/building/properties.c +++ b/src/building/properties.c @@ -1395,6 +1395,18 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .building_model_data = {.cost = 2500, .desirability_value = 20, .desirability_step = 2, .desirability_step_size = -4, .desirability_range = 8, .laborers = 50} }, + [BUILDING_GRAND_TEMPLE_VENUS_REWORKED] = { + .venus_gt_bonus = 1, + .size = 7, + .fire_proof = 1, + .sound_id = SOUND_CITY_TEMPLE_VENUS, + .draw_desirability_range = 1, + .custom_asset.group = "Monuments", + .custom_asset.id = "Venus Complex Off", + .event_data.attr = "grand_temple_venus_reworked", + .building_model_data = {.cost = 2500, .desirability_value = 20, .desirability_step = 2, + .desirability_step_size = -4, .desirability_range = 8, .laborers = 50} + }, [BUILDING_MENU_GRAND_TEMPLES] = { .event_data.attr = "grand_temples|all_grand_temples", .event_data.key = TR_PARAMETER_VALUE_BUILDING_MENU_GRAND_TEMPLES diff --git a/src/building/type.h b/src/building/type.h index 1cc274a688..ebbf8b3add 100644 --- a/src/building/type.h +++ b/src/building/type.h @@ -222,8 +222,9 @@ typedef enum { BUILDING_NATIVE_MONUMENT = 208, BUILDING_NATIVE_DECORATION = 209, BUILDING_REPAIR_LAND = 210, // tool, not an actual building + BUILDING_GRAND_TEMPLE_VENUS_REWORKED = 211, // helper constants - BUILDING_TYPE_MAX = 211 + BUILDING_TYPE_MAX = 212 } building_type; /** diff --git a/src/city/culture.c b/src/city/culture.c index 6f165f3a49..b4e6d513b0 100644 --- a/src/city/culture.c +++ b/src/city/culture.c @@ -201,8 +201,10 @@ void city_culture_update_coverage(void) SMALL_TEMPLE_COVERAGE * building_count_active(BUILDING_SMALL_TEMPLE_VENUS) + LARGE_TEMPLE_COVERAGE * building_count_active(BUILDING_LARGE_TEMPLE_VENUS) + PANTHEON_COVERAGE * building_count_active(BUILDING_PANTHEON) + - GRAND_TEMPLE_COVERAGE * building_count_active(BUILDING_GRAND_TEMPLE_VENUS), + GRAND_TEMPLE_COVERAGE * building_count_active(BUILDING_GRAND_TEMPLE_VENUS)+ + GRAND_TEMPLE_COVERAGE * building_count_active(BUILDING_GRAND_TEMPLE_VENUS_REWORKED), population)); + coverage.oracle = top(calc_percentage(ORACLE_COVERAGE * oracles, population)); city_data.culture.religion_coverage = diff --git a/src/city/finance.c b/src/city/finance.c index 5372a7f6f2..1f5fd7c1ee 100644 --- a/src/city/finance.c +++ b/src/city/finance.c @@ -42,6 +42,7 @@ static building_levy_for_type building_levies[] = { {BUILDING_GRAND_TEMPLE_MERCURY, GRAND_TEMPLE_LEVY_MONTHLY}, {BUILDING_GRAND_TEMPLE_MARS, GRAND_TEMPLE_LEVY_MONTHLY}, {BUILDING_GRAND_TEMPLE_VENUS, GRAND_TEMPLE_LEVY_MONTHLY}, + {BUILDING_GRAND_TEMPLE_VENUS_REWORKED, GRAND_TEMPLE_LEVY_MONTHLY}, {BUILDING_PANTHEON, PANTHEON_LEVY_MONTHLY}, // 20 {BUILDING_COLOSSEUM, COLOSSEUM_LEVY_MONTHLY}, {BUILDING_HIPPODROME, HIPPODROME_LEVY_MONTHLY}, diff --git a/src/city/gods.c b/src/city/gods.c index 50d655715a..42e152b1af 100644 --- a/src/city/gods.c +++ b/src/city/gods.c @@ -324,7 +324,7 @@ void city_gods_calculate_moods(int update_moods) num_temples = building_count_active(BUILDING_SMALL_TEMPLE_MARS) + building_count_active(BUILDING_LARGE_TEMPLE_MARS) + building_count_active(BUILDING_GRAND_TEMPLE_MARS); break; case GOD_VENUS: - num_temples = building_count_active(BUILDING_SMALL_TEMPLE_VENUS) + building_count_active(BUILDING_LARGE_TEMPLE_VENUS) + building_count_active(BUILDING_GRAND_TEMPLE_VENUS); + num_temples = building_count_active(BUILDING_SMALL_TEMPLE_VENUS) + building_count_active(BUILDING_LARGE_TEMPLE_VENUS) + building_count_active(BUILDING_GRAND_TEMPLE_VENUS)+ building_count_active(BUILDING_GRAND_TEMPLE_VENUS_REWORKED); break; } if (num_temples == max_temples) { diff --git a/src/city/labor.c b/src/city/labor.c index ff6192f393..0c55724d3d 100644 --- a/src/city/labor.c +++ b/src/city/labor.c @@ -118,6 +118,7 @@ static const int CATEGORY_FOR_BUILDING_TYPE[BUILDING_TYPE_MAX] = { [BUILDING_GRAND_TEMPLE_MERCURY] = LABOR_CATEGORY_GOVERNANCE_RELIGION, [BUILDING_GRAND_TEMPLE_MARS] = LABOR_CATEGORY_GOVERNANCE_RELIGION, [BUILDING_GRAND_TEMPLE_VENUS] = LABOR_CATEGORY_GOVERNANCE_RELIGION, + [BUILDING_GRAND_TEMPLE_VENUS_REWORKED] = LABOR_CATEGORY_GOVERNANCE_RELIGION, [BUILDING_PANTHEON] = LABOR_CATEGORY_GOVERNANCE_RELIGION, [BUILDING_SENATE] = LABOR_CATEGORY_GOVERNANCE_RELIGION, [BUILDING_FORUM] = LABOR_CATEGORY_GOVERNANCE_RELIGION, diff --git a/src/city/ratings.c b/src/city/ratings.c index 8811181333..9bb5ce591a 100644 --- a/src/city/ratings.c +++ b/src/city/ratings.c @@ -441,6 +441,7 @@ static void update_culture_rating(void) city_data.ratings.culture += building_count_active(BUILDING_GRAND_TEMPLE_MERCURY) * MONUMENT_CULTURE_BONUS; city_data.ratings.culture += building_count_active(BUILDING_GRAND_TEMPLE_MARS) * MONUMENT_CULTURE_BONUS; city_data.ratings.culture += building_count_active(BUILDING_GRAND_TEMPLE_VENUS) * MONUMENT_CULTURE_BONUS; + city_data.ratings.culture += building_count_active(BUILDING_GRAND_TEMPLE_VENUS_REWORKED) * MONUMENT_CULTURE_BONUS; city_data.ratings.culture += building_count_active(BUILDING_PANTHEON) * MONUMENT_CULTURE_BONUS; city_data.ratings.culture += building_count_active(BUILDING_COLOSSEUM) * MONUMENT_CULTURE_BONUS; city_data.ratings.culture += building_count_active(BUILDING_HIPPODROME) * MONUMENT_CULTURE_BONUS; diff --git a/src/city/trade.c b/src/city/trade.c index 62d3bd79e3..d7b4c5748f 100644 --- a/src/city/trade.c +++ b/src/city/trade.c @@ -16,7 +16,7 @@ void city_trade_update(void) city_data.trade.num_land_routes = 0; // Wine types city_data.resource.wine_types_available = building_count_total(resource_get_data(RESOURCE_WINE)->industry) > 0 ? 1 : 0; - if (building_monument_gt_module_is_active(VENUS_MODULE_1_DISTRIBUTE_WINE)) { + if (building_monument_gt_module_is_active(VENUS_MODULE_1_DISTRIBUTE_WINE) || building_monument_gt_module_is_active(VENUS_MODULE_3_WINE_TEMPLE)) { city_data.resource.wine_types_available += 1; } diff --git a/src/core/lang.c b/src/core/lang.c index 5ba4e33cb8..1cfe47d062 100644 --- a/src/core/lang.c +++ b/src/core/lang.c @@ -419,6 +419,8 @@ const uint8_t *lang_get_string(int group, int index) case BUILDING_GRAND_TEMPLE_MARS: return translation_for(TR_BUILDING_GRAND_TEMPLE_MARS); case BUILDING_GRAND_TEMPLE_VENUS: + return translation_for(TR_BUILDING_GRAND_TEMPLE_VENUS_LEGACY); + case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: return translation_for(TR_BUILDING_GRAND_TEMPLE_VENUS); case BUILDING_PANTHEON: return translation_for(TR_BUILDING_PANTHEON); diff --git a/src/figure/roamer_preview.c b/src/figure/roamer_preview.c index 8e82d3b3ba..75d7ca759b 100644 --- a/src/figure/roamer_preview.c +++ b/src/figure/roamer_preview.c @@ -66,6 +66,7 @@ static figure_type building_type_to_figure_type(building_type type) case BUILDING_GRAND_TEMPLE_MERCURY: case BUILDING_GRAND_TEMPLE_NEPTUNE: case BUILDING_GRAND_TEMPLE_VENUS: + case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: case BUILDING_LARGE_TEMPLE_CERES: case BUILDING_LARGE_TEMPLE_MARS: case BUILDING_LARGE_TEMPLE_MERCURY: diff --git a/src/figure/service.c b/src/figure/service.c index 31a0e110d3..56bb7d58b5 100644 --- a/src/figure/service.c +++ b/src/figure/service.c @@ -613,6 +613,7 @@ int figure_service_provide_coverage(figure *f) } break; case BUILDING_GRAND_TEMPLE_VENUS: + case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: houses_serviced = provide_culture(x, y, religion_coverage_venus); break; case BUILDING_PANTHEON: diff --git a/src/game/cheats.c b/src/game/cheats.c index a7285f1acc..0c6bd44c68 100644 --- a/src/game/cheats.c +++ b/src/game/cheats.c @@ -56,6 +56,7 @@ static void game_cheat_disable_legions_consumption(uint8_t *); static void game_cheat_disable_invasions(uint8_t *); static void game_cheat_change_weather(uint8_t *); static void game_cheat_destroy_building(uint8_t *); +static void game_cheat_enable_legacy_venus(uint8_t *); static void (*const execute_command[])(uint8_t *args) = { game_cheat_add_money, @@ -77,7 +78,8 @@ static void (*const execute_command[])(uint8_t *args) = { game_cheat_disable_legions_consumption, game_cheat_disable_invasions, game_cheat_change_weather, - game_cheat_destroy_building + game_cheat_destroy_building, + game_cheat_enable_legacy_venus }; static const char *commands[] = { @@ -100,7 +102,8 @@ static const char *commands[] = { "breadandfish", "leavemealone", "weather", // syntax: weather - "destroy" // syntax: destroy + "destroy", // syntax: destroy + "genetrix" }; #define NUMBER_OF_COMMANDS sizeof (commands) / sizeof (commands[0]) @@ -111,6 +114,7 @@ static struct { int extra_legions_unlocked; int disabled_legions_consumption; int disabled_invasions; + int legacy_venus_temple_enabled; } data; static int parse_word(uint8_t *string, uint8_t *word) @@ -415,3 +419,15 @@ int game_cheat_disabled_invasions(void) { return data.disabled_invasions; } + +static void game_cheat_enable_legacy_venus(uint8_t *args) +{ + data.legacy_venus_temple_enabled = 1; + building_menu_update(); + show_warning(TR_CHEAT_LEGACY_VENUS_ENABLED); +} + +int game_cheat_legacy_venus_enabled(void) +{ + return data.legacy_venus_temple_enabled; +} diff --git a/src/game/cheats.h b/src/game/cheats.h index dde8359d6e..f36afdf022 100644 --- a/src/game/cheats.h +++ b/src/game/cheats.h @@ -28,6 +28,8 @@ int game_cheat_disabled_legions_consumption(void); int game_cheat_disabled_invasions(void); +int game_cheat_legacy_venus_enabled(void); + void game_cheat_show_custom_events(uint8_t *args); void game_cheat_show_editor(uint8_t *args); diff --git a/src/map/desirability.c b/src/map/desirability.c index 0996503648..7a0592b470 100644 --- a/src/map/desirability.c +++ b/src/map/desirability.c @@ -76,7 +76,9 @@ static void update_buildings(void) int step_size; int range; int venus_module2 = building_monument_gt_module_is_active(VENUS_MODULE_2_DESIRABILITY_ENTERTAINMENT); + int venus_module3 = building_monument_gt_module_is_active(VENUS_MODULE_3_WINE_TEMPLE); int venus_gt = building_monument_working(BUILDING_GRAND_TEMPLE_VENUS); + int venus_gt_reworked = building_monument_working(BUILDING_GRAND_TEMPLE_VENUS_REWORKED); for (int i = 1; i < building_count(); i++) { building *b = building_get(i); if (b->state == BUILDING_STATE_IN_USE) { @@ -87,6 +89,18 @@ static void update_buildings(void) step_size = model->desirability_step_size; range = model->desirability_range; + // Venus GT Reworked Base Bonus + if (building_is_house(b->type) && b->data.house.temple_venus && venus_gt_reworked) { + if (b->subtype.house_level >= HOUSE_SMALL_VILLA) { + value += 4; + range += 1; + } else if (b->subtype.house_level >= HOUSE_SMALL_CASA) { + value += 2; + } + + } + + // Venus Module 2 House Desirability Bonus if (building_is_house(b->type) && b->data.house.temple_venus && venus_module2) { if (b->subtype.house_level >= HOUSE_SMALL_VILLA) { @@ -112,7 +126,7 @@ static void update_buildings(void) range = 0; } - // Venus GT Base Bonus + // Legacy Venus GT Base Bonus if (building_is_statue_garden_temple(b->type) && venus_gt) { value_bonus = ((value / 4) > 1) ? (value / 4) : 1; value += value_bonus; @@ -120,6 +134,13 @@ static void update_buildings(void) range += 1; } + // Venus Module 3 Temple Bonus + if (building_is_temple(b->type) && venus_module3) { + value += value; + step += 1; + range += 2; + } + add_to_terrain( b->x, b->y, b->size, value, diff --git a/src/map/image_context.c b/src/map/image_context.c index 41bd5f4f89..2447ae70ae 100644 --- a/src/map/image_context.c +++ b/src/map/image_context.c @@ -443,7 +443,7 @@ static void set_tiles_road(int grid_offset, int tiles[MAX_TILES]) int base = b_main->grid_offset; tiles[i] = (offset == base) ? 1 : 0; } - if ((b->type >= BUILDING_GRAND_TEMPLE_CERES && b->type <= BUILDING_GRAND_TEMPLE_VENUS) || (b->type == BUILDING_PANTHEON)) { + if ((b->type >= BUILDING_GRAND_TEMPLE_CERES && b->type <= BUILDING_GRAND_TEMPLE_VENUS) || (b->type == BUILDING_PANTHEON) || (b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED)) { tiles[i] = (offset == b->grid_offset + map_grid_delta(3, 0)) ? 1 : 0; tiles[i] |= (offset == b->grid_offset + map_grid_delta(0, 3)) ? 1 : 0; tiles[i] |= (offset == b->grid_offset + map_grid_delta(6, 3)) ? 1 : 0; diff --git a/src/scenario/allowed_building.c b/src/scenario/allowed_building.c index 930a2b68d7..fb973d2e07 100644 --- a/src/scenario/allowed_building.c +++ b/src/scenario/allowed_building.c @@ -58,7 +58,7 @@ static const building_type CONVERSION_FROM_ORIGINAL[MAX_ORIGINAL_ALLOWED_BUILDIN { BUILDING_LOW_BRIDGE, BUILDING_SHIP_BRIDGE }, { BUILDING_BARRACKS, BUILDING_ARMOURY }, { BUILDING_MILITARY_ACADEMY }, - { BUILDING_GRAND_TEMPLE_CERES, BUILDING_GRAND_TEMPLE_NEPTUNE, BUILDING_GRAND_TEMPLE_MERCURY, BUILDING_GRAND_TEMPLE_MARS, BUILDING_GRAND_TEMPLE_VENUS }, + { BUILDING_GRAND_TEMPLE_CERES, BUILDING_GRAND_TEMPLE_NEPTUNE, BUILDING_GRAND_TEMPLE_MERCURY, BUILDING_GRAND_TEMPLE_MARS, BUILDING_GRAND_TEMPLE_VENUS, BUILDING_GRAND_TEMPLE_VENUS_REWORKED }, }; static uint8_t allowed_buildings[BUILDING_TYPE_MAX]; diff --git a/src/translation/english.c b/src/translation/english.c index 14f9552997..204fd747fc 100644 --- a/src/translation/english.c +++ b/src/translation/english.c @@ -193,6 +193,7 @@ static translation_string all_strings[] = { {TR_BUILDING_GRAND_TEMPLE_MERCURY, "Mercury grand temple" }, {TR_BUILDING_GRAND_TEMPLE_MARS, "Mars grand temple" }, {TR_BUILDING_GRAND_TEMPLE_VENUS, "Venus grand temple" }, + {TR_BUILDING_GRAND_TEMPLE_VENUS_LEGACY, "Venus ancient temple" }, {TR_BUILDING_PANTHEON, "Pantheon" }, {TR_BUILDING_GRAND_TEMPLE_CERES_DESC, "Grand temple of Ceres" }, {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_DESC, "Grand temple of Neptune" }, @@ -205,12 +206,15 @@ static translation_string all_strings[] = { {TR_BUILDING_GRAND_TEMPLE_MERCURY_BONUS_DESC, "Mercury blesses your traders by land and sea with an additional 50% capacity, and inspires land traders to move 25% faster." }, // Note to translators: This one changed from the previous version, please update. {TR_BUILDING_GRAND_TEMPLE_MARS_BONUS_DESC, "Mars exhorts your citizens to enlist, dispatching recruits to your city's forts, and allowing four additional forts to be built." }, // Note to translators: This one changed from the previous version, please update. {TR_BUILDING_GRAND_TEMPLE_VENUS_BONUS_DESC, "Venus graces your city's gardens, statues and temples to glow with beauty, improving their desirability. Houses also hold more goods, and devolve more slowly." }, // Note to translators: This one changed from the previous version, please update. + {TR_BUILDING_GRAND_TEMPLE_VENUS_REWORKED_BONUS_DESC, "Priests of Venus bless houses to glow with additional desirability." }, {TR_BUILDING_PANTHEON_BONUS_DESC, "The Pantheon provides access to your citizens to worship all the gods. Annual festivals are also held here, and religious and cultural building levies are reduced by 25%." }, // Note to translators: This one changed from the previous version, please update. {TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_1_DESC, "Priests reduce food consumption by 20%." }, {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_1_DESC, "Temples produce charioteers for the Hippodrome." }, {TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_1_DESC, "Priests reduce pottery and furniture consumption by 20%." }, {TR_BUILDING_GRAND_TEMPLE_MARS_MODULE_1_DESC, "Temples generate food, in an amount based on the number of houses they cover, and deliver it to the supply post. Fort levies reduced by 25%." }, // Note to translators: This one changed from the previous version, please update. {TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_1_DESC, "The Grand temple produces wine in a quantity scaled to city population with Venus temple access. Temples collect and distribute it to houses and taverns." }, + {TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_3_DESC, "Provides a second wine type. All small, large, and grand temples gain increased desirability." }, + {TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_4_DESC, "All houses gain additional entertainment from theaters and working taverns." }, {TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_2_DESC, "Priests collect and distribute both oil and one food type from city storage." }, {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_2_DESC, "Priests expand housing capacity by 5%. Grand temple provides water like a filled reservoir." }, {TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_2_DESC, "Priests reduce oil and wine consumption by 20%." }, @@ -228,6 +232,8 @@ static translation_string all_strings[] = { {TR_BUILDING_GRAND_TEMPLE_MARS_DESC_MODULE_2, "Temple of Mars Quirinus" }, {TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_1, "Temple of Venus Verticordia" }, {TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_2, "Temple of Venus Genetrix" }, + {TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_3, "Temple of Venus Cloacina" }, + {TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_4, "Temple of Venus Felix" }, {TR_BUILDING_PANTHEON_DESC_MODULE_1, "Pantheum Ara Maxima" }, {TR_BUILDING_PANTHEON_DESC_MODULE_2, "Pantheum Roma Aeterna" }, {TR_BUILDING_GRAND_TEMPLE_MENU, "Grand temple" }, @@ -1653,6 +1659,7 @@ static translation_string all_strings[] = { {TR_CONDITION_TEXT_TIME_LEFT_UNTIL_VICTORY, "Time until victory:" }, {TR_CHEAT_DISABLE_INVASIONS, "Disable invasions"}, {TR_CHEAT_DISABLE_LEGIONS_CONSUMPTION, "Disable soldier food consumption"}, + {TR_CHEAT_LEGACY_VENUS_ENABLED, "Legacy Venus Grand Temple unlocked in build menu"}, {TR_ACTION_TYPE_CHANGE_TERRAIN, "Add/remove terrain" }, {TR_PARAMETER_TERRAIN, "Terrain" }, {TR_PARAMETER_ADD, "Add" }, diff --git a/src/translation/translation.h b/src/translation/translation.h index 4bd0c28fd5..e4aba825ec 100644 --- a/src/translation/translation.h +++ b/src/translation/translation.h @@ -189,6 +189,7 @@ typedef enum { TR_BUILDING_GRAND_TEMPLE_MERCURY, TR_BUILDING_GRAND_TEMPLE_MARS, TR_BUILDING_GRAND_TEMPLE_VENUS, + TR_BUILDING_GRAND_TEMPLE_VENUS_LEGACY, TR_BUILDING_PANTHEON, TR_BUILDING_GRAND_TEMPLE_CERES_DESC, TR_BUILDING_GRAND_TEMPLE_NEPTUNE_DESC, @@ -201,12 +202,15 @@ typedef enum { TR_BUILDING_GRAND_TEMPLE_MERCURY_BONUS_DESC, TR_BUILDING_GRAND_TEMPLE_MARS_BONUS_DESC, TR_BUILDING_GRAND_TEMPLE_VENUS_BONUS_DESC, + TR_BUILDING_GRAND_TEMPLE_VENUS_REWORKED_BONUS_DESC, TR_BUILDING_PANTHEON_BONUS_DESC, TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_1_DESC, TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_1_DESC, TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_1_DESC, TR_BUILDING_GRAND_TEMPLE_MARS_MODULE_1_DESC, TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_1_DESC, + TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_3_DESC, + TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_4_DESC, TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_2_DESC, TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_2_DESC, TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_2_DESC, @@ -224,6 +228,8 @@ typedef enum { TR_BUILDING_GRAND_TEMPLE_MARS_DESC_MODULE_2, TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_1, TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_2, + TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_3, + TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_4, TR_BUILDING_PANTHEON_DESC_MODULE_1, TR_BUILDING_PANTHEON_DESC_MODULE_2, TR_BUILDING_GRAND_TEMPLE_MENU, @@ -1660,6 +1666,7 @@ typedef enum { TR_CONDITION_TEXT_TIME_LEFT_UNTIL_VICTORY, TR_CHEAT_DISABLE_INVASIONS, TR_CHEAT_DISABLE_LEGIONS_CONSUMPTION, + TR_CHEAT_LEGACY_VENUS_ENABLED, TR_TOOLTIP_BUTTON_ACCEPT_ALL, TR_TOOLTIP_BUTTON_REJECT_ALL, TR_TOOLTIP_OVERLAY_PROBLEMS_NO_ROAD_ACCESS, diff --git a/src/widget/city_overlay_other.c b/src/widget/city_overlay_other.c index efe28e7468..5b02a8e0a8 100644 --- a/src/widget/city_overlay_other.c +++ b/src/widget/city_overlay_other.c @@ -48,7 +48,7 @@ static int show_building_religion(const building *b) b->type == BUILDING_SMALL_MAUSOLEUM || b->type == BUILDING_LARGE_MAUSOLEUM || b->type == BUILDING_LARGE_TEMPLE_VENUS || b->type == BUILDING_GRAND_TEMPLE_CERES || b->type == BUILDING_GRAND_TEMPLE_NEPTUNE || b->type == BUILDING_GRAND_TEMPLE_MERCURY || - b->type == BUILDING_GRAND_TEMPLE_MARS || b->type == BUILDING_GRAND_TEMPLE_VENUS || + b->type == BUILDING_GRAND_TEMPLE_MARS || b->type == BUILDING_GRAND_TEMPLE_VENUS || b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED || b->type == BUILDING_PANTHEON || b->type == BUILDING_NYMPHAEUM || b->type == BUILDING_SHRINE_CERES || b->type == BUILDING_SHRINE_MARS || b->type == BUILDING_SHRINE_MERCURY || b->type == BUILDING_SHRINE_VENUS || diff --git a/src/window/advisor/religion.c b/src/window/advisor/religion.c index 241dbb6097..d0984ec955 100644 --- a/src/window/advisor/religion.c +++ b/src/window/advisor/religion.c @@ -151,7 +151,7 @@ static int draw_background(void) draw_god_row(GOD_MARS, 126, BUILDING_SHRINE_MARS, BUILDING_SMALL_TEMPLE_MARS, BUILDING_LARGE_TEMPLE_MARS, BUILDING_GRAND_TEMPLE_MARS); draw_god_row(GOD_VENUS, 146, BUILDING_SHRINE_VENUS, BUILDING_SMALL_TEMPLE_VENUS, - BUILDING_LARGE_TEMPLE_VENUS, BUILDING_GRAND_TEMPLE_VENUS); + BUILDING_LARGE_TEMPLE_VENUS, BUILDING_GRAND_TEMPLE_VENUS_REWORKED); // oracles draw_oracle_row(); diff --git a/src/window/building/culture.c b/src/window/building/culture.c index 59372c80dc..f8ad3c13d3 100644 --- a/src/window/building/culture.c +++ b/src/window/building/culture.c @@ -59,7 +59,7 @@ static struct { option_menu_item option; const building_type required_building; const char image_id[32]; -} temple_module_options[12] = { +} temple_module_options[14] = { { { TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_1, TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_1_DESC }, BUILDING_NONE, @@ -119,6 +119,16 @@ static struct { { TR_BUILDING_PANTHEON_DESC_MODULE_2, TR_BUILDING_PANTHEON_MODULE_2_DESC }, BUILDING_NONE, "Panth M2 Icon" + }, + { + { TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_3, TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_3_DESC }, + BUILDING_NONE, + "Venus M Icon" + }, + { + { TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_4, TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_4_DESC }, + BUILDING_NONE, + "Venus M2 Icon" } }; @@ -746,7 +756,12 @@ static void draw_grand_temple(building_info_context *c, const char *sound_file, window_building_draw_monument_temple_construction_process(c); } if (b->monument.upgrades) { - int module_name = temple_module_options[data.god_id * 2 + (b->monument.upgrades - 1)].option.header; + int module_index = data.god_id * 2 + (b->monument.upgrades - 1); + // Special handling for reworked Venus temple + if (b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { + module_index = 12 + (b->monument.upgrades - 1); + } + int module_name = temple_module_options[module_index].option.header; text_draw_centered(translation_for(module_name), c->x_offset, c->y_offset + 12, BLOCK_SIZE * c->width_blocks, FONT_LARGE_BLACK, 0); } else { @@ -762,7 +777,12 @@ static void draw_grand_temple(building_info_context *c, const char *sound_file, height = text_draw_multiline(translation_for(bonus_desc), c->x_offset + 22, c->y_offset + 56 + extra_y, 15 * c->width_blocks, 0, FONT_NORMAL_BLACK, 0); if (b->monument.upgrades) { - int module_desc = temple_module_options[data.god_id * 2 + (b->monument.upgrades - 1)].option.desc; + int module_index = data.god_id * 2 + (b->monument.upgrades - 1); + // Special handling for reworked Venus temple + if (b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { + module_index = 12 + (b->monument.upgrades - 1); + } + int module_desc = temple_module_options[module_index].option.desc; height += text_draw_multiline(translation_for(module_desc), c->x_offset + 22, c->y_offset + 66 + height + extra_y, 15 * c->width_blocks, 0, FONT_NORMAL_GREEN, 0); @@ -771,7 +791,7 @@ static void draw_grand_temple(building_info_context *c, const char *sound_file, if (b->type == BUILDING_GRAND_TEMPLE_MARS) { draw_grand_temple_mars_military(c); } else if (b->type == BUILDING_GRAND_TEMPLE_VENUS && - (building_monument_gt_module_is_active(VENUS_MODULE_1_DISTRIBUTE_WINE))) { + building_monument_gt_module_is_active(VENUS_MODULE_1_DISTRIBUTE_WINE)) { draw_grand_temple_venus_wine(c); } inner_panel_draw(c->x_offset + 16, c->y_offset + 86 + height + extra_y, c->width_blocks - 2, 4); @@ -863,6 +883,14 @@ void window_building_draw_grand_temple_venus(building_info_context *c) TR_BUILDING_VENUS_TEMPLE_QUOTE, GOD_VENUS, 20); } +void window_building_draw_grand_temple_venus_reworked(building_info_context *c) +{ + draw_grand_temple(c, "wavs/temple_love.wav", TR_BUILDING_GRAND_TEMPLE_VENUS_DESC, + TR_BUILDING_GRAND_TEMPLE_VENUS_REWORKED_BONUS_DESC, + assets_get_image_id("UI", "Venus L Banner"), + TR_BUILDING_VENUS_TEMPLE_QUOTE, GOD_VENUS, 20); +} + void window_building_draw_pantheon(building_info_context *c) { draw_grand_temple(c, "wavs/oracle.wav", TR_BUILDING_PANTHEON_DESC, TR_BUILDING_PANTHEON_BONUS_DESC, @@ -1340,6 +1368,12 @@ static void button_add_module_prompt(const generic_button *button) int num_options = 0; int option_id = data.god_id * 2; + // Special handling for reworked Venus temple + building *b = building_get(data.building_id); + if (b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { + option_id = 12; + } + static option_menu_item options[2]; if (scenario_allowed_building(temple_module_options[option_id].required_building)) { diff --git a/src/window/building/culture.h b/src/window/building/culture.h index d2337a3567..7c90a0429a 100644 --- a/src/window/building/culture.h +++ b/src/window/building/culture.h @@ -77,6 +77,8 @@ void window_building_draw_grand_temple_mars(building_info_context* c); void window_building_draw_grand_temple_venus(building_info_context* c); +void window_building_draw_grand_temple_venus_reworked(building_info_context* c); + void window_building_draw_pantheon(building_info_context* c); void window_building_draw_work_camp(building_info_context* c); diff --git a/src/window/building/house.c b/src/window/building/house.c index 84097507b1..6c8c3683f6 100644 --- a/src/window/building/house.c +++ b/src/window/building/house.c @@ -12,6 +12,7 @@ #include "graphics/lang_text.h" #include "graphics/panel.h" #include "graphics/text.h" +#include "map/desirability.h" #include "map/road_access.h" #include "sound/speech.h" #include "translation/translation.h" @@ -128,6 +129,31 @@ static void draw_happiness_info(building_info_context *c, int y_offset) } } +static void draw_debug_info(building_info_context *c, int y_offset) +{ + // DEBUG: Display entertainment and desirability values + building *b = building_get(c->building_id); + + // Entertainment value + int width = text_draw(string_from_ascii("DEBUG - Entertainment: "), + c->x_offset + 36, y_offset, FONT_NORMAL_RED, 0); + text_draw_number(b->data.house.entertainment, '@', " ", + c->x_offset + 36 + width, y_offset, FONT_NORMAL_RED, 0); + + // Desirability (from building) + width = text_draw(string_from_ascii("Desirability (cached): "), + c->x_offset + 36, y_offset + 16, FONT_NORMAL_RED, 0); + text_draw_number(b->desirability, '@', " ", + c->x_offset + 36 + width, y_offset + 16, FONT_NORMAL_RED, 0); + + // Desirability (from map) + int map_desir = map_desirability_get(b->grid_offset); + width = text_draw(string_from_ascii("Desirability (map): "), + c->x_offset + 36, y_offset + 32, FONT_NORMAL_RED, 0); + text_draw_number(map_desir, '@', " ", + c->x_offset + 36 + width, y_offset + 32, FONT_NORMAL_RED, 0); +} + void window_building_draw_house(building_info_context *c) { c->advisor_button = ADVISOR_HOUSING; @@ -147,6 +173,7 @@ void window_building_draw_house(building_info_context *c) draw_population_info(c, c->y_offset + 134); draw_tax_info(c, c->y_offset + 174); draw_happiness_info(c, c->y_offset + 194); + //draw_debug_info(c, c->y_offset + 305); int x_offset = 32; int y_content = 259; diff --git a/src/window/building_info.c b/src/window/building_info.c index 7f605f0ec9..023464c907 100644 --- a/src/window/building_info.c +++ b/src/window/building_info.c @@ -244,6 +244,7 @@ static int get_height_id(void) case BUILDING_GRAND_TEMPLE_NEPTUNE: case BUILDING_GRAND_TEMPLE_MERCURY: case BUILDING_GRAND_TEMPLE_VENUS: + case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: case BUILDING_PANTHEON: case BUILDING_HIPPODROME: case BUILDING_COLOSSEUM: @@ -721,6 +722,8 @@ static void draw_background(void) window_building_draw_grand_temple_mars(&context); } else if (btype == BUILDING_GRAND_TEMPLE_VENUS) { window_building_draw_grand_temple_venus(&context); + } else if (btype == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { + window_building_draw_grand_temple_venus_reworked(&context); } else if (btype == BUILDING_PANTHEON) { window_building_draw_pantheon(&context); } else if (btype == BUILDING_LIGHTHOUSE) { @@ -920,7 +923,7 @@ static void draw_foreground(void) } else if (btype == BUILDING_BARRACKS) { window_building_draw_barracks_foreground(&context); } else if ((btype >= BUILDING_GRAND_TEMPLE_CERES && btype <= BUILDING_GRAND_TEMPLE_VENUS) || - btype == BUILDING_PANTHEON) { + btype == BUILDING_PANTHEON || btype == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { window_building_draw_grand_temple_foreground(&context); } else if (btype == BUILDING_CARAVANSERAI && b->monument.phase == MONUMENT_FINISHED) { @@ -1034,7 +1037,7 @@ static int handle_specific_building_info_mouse(const mouse *m) return window_building_handle_mouse_storage(m, &context); } } else if ((btype >= BUILDING_GRAND_TEMPLE_CERES && btype <= BUILDING_GRAND_TEMPLE_VENUS) || - btype == BUILDING_PANTHEON) { + btype == BUILDING_PANTHEON || btype == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { return window_building_handle_mouse_grand_temple(m, &context); } else if (btype == BUILDING_DEPOT) { if (context.depot_selection == 2) { diff --git a/src/window/city.c b/src/window/city.c index 551eb4005f..c41d65fa70 100644 --- a/src/window/city.c +++ b/src/window/city.c @@ -460,6 +460,7 @@ static void show_overlay_from_grid_offset(int grid_offset) case BUILDING_GRAND_TEMPLE_MERCURY: case BUILDING_GRAND_TEMPLE_MARS: case BUILDING_GRAND_TEMPLE_VENUS: + case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: case BUILDING_PANTHEON: case BUILDING_LARARIUM: case BUILDING_NYMPHAEUM: From 7ae69279584f416985063628f05ae3933ab04f0e Mon Sep 17 00:00:00 2001 From: William Hardy Gest Date: Sun, 15 Feb 2026 13:32:22 -0600 Subject: [PATCH 02/12] Fix bugged small temple desirability. Fix house desirability step sizes that had no effect. Buff small temple desirability slightly as an early game boost. --- src/building/building.c | 9 ++++++--- src/building/properties.c | 40 ++++++++++++++++++------------------- src/map/desirability.c | 7 ++++--- src/window/building/house.c | 40 ++++++++++++++++--------------------- 4 files changed, 47 insertions(+), 49 deletions(-) diff --git a/src/building/building.c b/src/building/building.c index 4ab97322d6..4457a09b98 100644 --- a/src/building/building.c +++ b/src/building/building.c @@ -855,10 +855,13 @@ int building_is_temple(building_type type) return building_is_ceres_temple(type) || building_is_neptune_temple(type) || building_is_mercury_temple(type) || building_is_mars_temple(type) || building_is_venus_temple(type) || - type == BUILDING_GRAND_TEMPLE_CERES || type == BUILDING_GRAND_TEMPLE_NEPTUNE || + type == BUILDING_GRAND_TEMPLE_CERES || type == BUILDING_GRAND_TEMPLE_NEPTUNE || type == BUILDING_PANTHEON || type == BUILDING_GRAND_TEMPLE_MERCURY || type == BUILDING_GRAND_TEMPLE_MARS || - type == BUILDING_GRAND_TEMPLE_VENUS || type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED; -} + type == BUILDING_GRAND_TEMPLE_VENUS || type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED || + type == BUILDING_ORACLE || type == BUILDING_LARARIUM || type == BUILDING_NYMPHAEUM || + type == BUILDING_SHRINE_CERES || type == BUILDING_SHRINE_NEPTUNE || type == BUILDING_SHRINE_MERCURY || + type == BUILDING_SHRINE_MARS || type == BUILDING_SHRINE_VENUS; + } // All buildings capable of collecting and storing goods as a market int building_has_supplier_inventory(building_type type) diff --git a/src/building/properties.c b/src/building/properties.c index 547ecbd585..6ae925d0c0 100644 --- a/src/building/properties.c +++ b/src/building/properties.c @@ -230,7 +230,7 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .sound_id = SOUND_CITY_HOUSE_POOR, .event_data.attr = "house_small_casa", .building_model_data = {.cost = 0, .desirability_value = -1, .desirability_step = 1, - .desirability_step_size = 1, .desirability_range = 1, .laborers = 0}, + .desirability_step_size = 0, .desirability_range = 1, .laborers = 0}, .house_model_data = { .devolve_desirability = 10, .evolve_desirability = 16, @@ -255,7 +255,7 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .sound_id = SOUND_CITY_HOUSE_POOR, .event_data.attr = "house_large_casa", .building_model_data = {.cost = 0, .desirability_value = -1, .desirability_step = 1, - .desirability_step_size = 1, .desirability_range = 1, .laborers = 0}, + .desirability_step_size = 0, .desirability_range = 1, .laborers = 0}, .house_model_data = { .devolve_desirability = 14, .evolve_desirability = 20, @@ -280,7 +280,7 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .sound_id = SOUND_CITY_HOUSE_MEDIUM, .event_data.attr = "house_small_insula", .building_model_data = {.cost = 0, .desirability_value = 0, .desirability_step = 1, - .desirability_step_size = 1, .desirability_range = 1, .laborers = 0}, + .desirability_step_size = 0, .desirability_range = 1, .laborers = 0}, .house_model_data = { .devolve_desirability = 18, .evolve_desirability = 25, @@ -305,7 +305,7 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .sound_id = SOUND_CITY_HOUSE_MEDIUM, .event_data.attr = "house_medium_insula", .building_model_data = {.cost = 0, .desirability_value = 0, .desirability_step = 1, - .desirability_step_size = 1, .desirability_range = 1, .laborers = 0}, + .desirability_step_size = 0, .desirability_range = 1, .laborers = 0}, .house_model_data = { .devolve_desirability = 22, .evolve_desirability = 32, @@ -380,7 +380,7 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .sound_id = SOUND_CITY_HOUSE_GOOD, .event_data.attr = "house_small_villa", .building_model_data = {.cost = 0, .desirability_value = 1, .desirability_step = 2, - .desirability_step_size = -1, .desirability_range = 2, .laborers = 0}, + .desirability_step_size = 0, .desirability_range = 2, .laborers = 0}, .house_model_data = { .devolve_desirability = 45, .evolve_desirability = 53, @@ -405,7 +405,7 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .sound_id = SOUND_CITY_HOUSE_GOOD, .event_data.attr = "house_medium_villa", .building_model_data = {.cost = 0, .desirability_value = 1, .desirability_step = 2, - .desirability_step_size = -1, .desirability_range = 2, .laborers = 0}, + .desirability_step_size = 0, .desirability_range = 2, .laborers = 0}, .house_model_data = { .devolve_desirability = 50, .evolve_desirability = 58, @@ -430,7 +430,7 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .sound_id = SOUND_CITY_HOUSE_GOOD, .event_data.attr = "house_large_villa", .building_model_data = {.cost = 0, .desirability_value = 2, .desirability_step = 2, - .desirability_step_size = -2, .desirability_range = 2, .laborers = 0}, + .desirability_step_size = 0, .desirability_range = 2, .laborers = 0}, .house_model_data = { .devolve_desirability = 55, .evolve_desirability = 63, @@ -455,7 +455,7 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .sound_id = SOUND_CITY_HOUSE_GOOD, .event_data.attr = "house_grand_villa", .building_model_data = {.cost = 0, .desirability_value = 2, .desirability_step = 2, - .desirability_step_size = -2, .desirability_range = 2, .laborers = 0}, + .desirability_step_size = 0, .desirability_range = 2, .laborers = 0}, .house_model_data = { .devolve_desirability = 60, .evolve_desirability = 68, @@ -860,8 +860,8 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .draw_desirability_range = 1, .event_data.attr = "small_temple_ceres", .event_data.key = TR_PARAMETER_VALUE_BUILDING_SMALL_TEMPLE_CERES, - .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 2, - .desirability_step_size = 6, .desirability_range = 2, .laborers = 2} + .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 1, + .desirability_step_size = -1, .desirability_range = 4, .laborers = 2} }, [BUILDING_SMALL_TEMPLE_NEPTUNE] = { .venus_gt_bonus = 1, @@ -871,8 +871,8 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .draw_desirability_range = 1, .event_data.attr = "small_temple_neptune", .event_data.key = TR_PARAMETER_VALUE_BUILDING_SMALL_TEMPLE_NEPTUNE, - .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 2, - .desirability_step_size = 6, .desirability_range = 2, .laborers = 2} + .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 1, + .desirability_step_size = -1, .desirability_range = 4, .laborers = 2} }, [BUILDING_SMALL_TEMPLE_MERCURY] = { .venus_gt_bonus = 1, @@ -882,8 +882,8 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .draw_desirability_range = 1, .event_data.attr = "small_temple_mercury", .event_data.key = TR_PARAMETER_VALUE_BUILDING_SMALL_TEMPLE_MERCURY, - .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 2, - .desirability_step_size = 6, .desirability_range = 2, .laborers = 2} + .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 1, + .desirability_step_size = -1, .desirability_range = 4, .laborers = 2} }, [BUILDING_SMALL_TEMPLE_MARS] = { .venus_gt_bonus = 1, @@ -893,8 +893,8 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .draw_desirability_range = 1, .event_data.attr = "small_temple_mars", .event_data.key = TR_PARAMETER_VALUE_BUILDING_SMALL_TEMPLE_MARS, - .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 2, - .desirability_step_size = 6, .desirability_range = 2, .laborers = 2} + .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 1, + .desirability_step_size = -1, .desirability_range = 4, .laborers = 2} }, [BUILDING_SMALL_TEMPLE_VENUS] = { .venus_gt_bonus = 1, @@ -904,8 +904,8 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .draw_desirability_range = 1, .event_data.attr = "small_temple_venus", .event_data.key = TR_PARAMETER_VALUE_BUILDING_SMALL_TEMPLE_VENUS, - .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 2, - .desirability_step_size = 6, .desirability_range = 2, .laborers = 2} + .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 1, + .desirability_step_size = -1, .desirability_range = 4, .laborers = 2} }, [BUILDING_LARGE_TEMPLE_CERES] = { .venus_gt_bonus = 1, @@ -1095,8 +1095,8 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .image_group = 63, .sound_id = SOUND_CITY_FORUM, .event_data.attr = "forum", - .building_model_data = {.cost = 75, .desirability_value = 3, .desirability_step = 2, - .desirability_step_size = -1, .desirability_range = 2, .laborers = 6} + .building_model_data = {.cost = 75, .desirability_value = 3, .desirability_step = 1, + .desirability_step_size = -1, .desirability_range = 3, .laborers = 6} }, [BUILDING_NATIVE_HUT] = { .size = 1, diff --git a/src/map/desirability.c b/src/map/desirability.c index 7a0592b470..2c05a6a490 100644 --- a/src/map/desirability.c +++ b/src/map/desirability.c @@ -136,9 +136,10 @@ static void update_buildings(void) // Venus Module 3 Temple Bonus if (building_is_temple(b->type) && venus_module3) { - value += value; - step += 1; - range += 2; + value = (value * 3) / 2; + if (b->size > 1) { + range += 1; + } } add_to_terrain( diff --git a/src/window/building/house.c b/src/window/building/house.c index 6c8c3683f6..d966b0f0cd 100644 --- a/src/window/building/house.c +++ b/src/window/building/house.c @@ -129,30 +129,24 @@ static void draw_happiness_info(building_info_context *c, int y_offset) } } -static void draw_debug_info(building_info_context *c, int y_offset) -{ - // DEBUG: Display entertainment and desirability values - building *b = building_get(c->building_id); +// static void draw_debug_info(building_info_context *c, int y_offset) +// { +// // DEBUG: Display entertainment and desirability values +// building *b = building_get(c->building_id); - // Entertainment value - int width = text_draw(string_from_ascii("DEBUG - Entertainment: "), - c->x_offset + 36, y_offset, FONT_NORMAL_RED, 0); - text_draw_number(b->data.house.entertainment, '@', " ", - c->x_offset + 36 + width, y_offset, FONT_NORMAL_RED, 0); +// // Desirability (from building) +// int width = text_draw(string_from_ascii("Desirability (actual): "), +// c->x_offset + 36, y_offset + 16, FONT_NORMAL_RED, 0); +// text_draw_number(b->desirability, '@', " ", +// c->x_offset + 36 + width, y_offset + 16, FONT_NORMAL_RED, 0); - // Desirability (from building) - width = text_draw(string_from_ascii("Desirability (cached): "), - c->x_offset + 36, y_offset + 16, FONT_NORMAL_RED, 0); - text_draw_number(b->desirability, '@', " ", - c->x_offset + 36 + width, y_offset + 16, FONT_NORMAL_RED, 0); - - // Desirability (from map) - int map_desir = map_desirability_get(b->grid_offset); - width = text_draw(string_from_ascii("Desirability (map): "), - c->x_offset + 36, y_offset + 32, FONT_NORMAL_RED, 0); - text_draw_number(map_desir, '@', " ", - c->x_offset + 36 + width, y_offset + 32, FONT_NORMAL_RED, 0); -} +// // Desirability (from map) +// int map_desir = map_desirability_get_max(b->x, b->y, b->size); +// width = text_draw(string_from_ascii("Desirability (map): "), +// c->x_offset + 36, y_offset + 32, FONT_NORMAL_RED, 0); +// text_draw_number(map_desir, '@', " ", +// c->x_offset + 36 + width, y_offset + 32, FONT_NORMAL_RED, 0); +// } void window_building_draw_house(building_info_context *c) { @@ -173,7 +167,7 @@ void window_building_draw_house(building_info_context *c) draw_population_info(c, c->y_offset + 134); draw_tax_info(c, c->y_offset + 174); draw_happiness_info(c, c->y_offset + 194); - //draw_debug_info(c, c->y_offset + 305); + // draw_debug_info(c, c->y_offset + 305); int x_offset = 32; int y_content = 259; From 7ade6617dbd27245f99345d1847d4503d7e2efe8 Mon Sep 17 00:00:00 2001 From: William Hardy Gest Date: Tue, 17 Feb 2026 19:55:46 -0600 Subject: [PATCH 03/12] Implement the other five grand temple reworks, base buildings only for now (no modules/nbonuses) --- src/building/building.c | 9 ++- src/building/construction_building.c | 7 ++- src/building/count.c | 4 +- src/building/figure.c | 5 ++ src/building/image.c | 5 ++ src/building/menu.c | 17 +++-- src/building/monument.c | 14 +++++ src/building/properties.c | 92 +++++++++++++++++++++++----- src/building/type.h | 7 ++- src/city/culture.c | 7 ++- src/city/finance.c | 7 ++- src/city/gods.c | 8 +-- src/city/labor.c | 5 ++ src/city/ratings.c | 5 ++ src/core/lang.c | 20 ++++-- src/figure/service.c | 5 ++ src/game/cheats.c | 11 ++-- src/game/cheats.h | 2 +- src/map/image_context.c | 6 +- src/scenario/allowed_building.c | 2 +- src/translation/english.c | 12 +++- src/translation/translation.h | 10 +++ src/widget/city_overlay_other.c | 5 +- src/window/advisor/religion.c | 8 +-- src/window/building/culture.c | 40 ++++++++++++ src/window/building/culture.h | 10 +++ src/window/building_info.c | 15 +++++ 27 files changed, 286 insertions(+), 52 deletions(-) diff --git a/src/building/building.c b/src/building/building.c index 4457a09b98..5edd463a12 100644 --- a/src/building/building.c +++ b/src/building/building.c @@ -857,9 +857,12 @@ int building_is_temple(building_type type) building_is_venus_temple(type) || type == BUILDING_GRAND_TEMPLE_CERES || type == BUILDING_GRAND_TEMPLE_NEPTUNE || type == BUILDING_PANTHEON || type == BUILDING_GRAND_TEMPLE_MERCURY || type == BUILDING_GRAND_TEMPLE_MARS || - type == BUILDING_GRAND_TEMPLE_VENUS || type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED || - type == BUILDING_ORACLE || type == BUILDING_LARARIUM || type == BUILDING_NYMPHAEUM || - type == BUILDING_SHRINE_CERES || type == BUILDING_SHRINE_NEPTUNE || type == BUILDING_SHRINE_MERCURY || + type == BUILDING_GRAND_TEMPLE_VENUS || type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED || + type == BUILDING_GRAND_TEMPLE_CERES_REWORKED || type == BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED || + type == BUILDING_GRAND_TEMPLE_MERCURY_REWORKED || type == BUILDING_GRAND_TEMPLE_MARS_REWORKED || + type == BUILDING_PANTHEON_REWORKED || + type == BUILDING_ORACLE || type == BUILDING_LARARIUM || type == BUILDING_NYMPHAEUM || + type == BUILDING_SHRINE_CERES || type == BUILDING_SHRINE_NEPTUNE || type == BUILDING_SHRINE_MERCURY || type == BUILDING_SHRINE_MARS || type == BUILDING_SHRINE_VENUS; } diff --git a/src/building/construction_building.c b/src/building/construction_building.c index dae794dcf2..5d72bfef4a 100644 --- a/src/building/construction_building.c +++ b/src/building/construction_building.c @@ -328,10 +328,15 @@ static void add_to_map(int type, building *b, int size, int orientation, int wat case BUILDING_GRAND_TEMPLE_MARS: case BUILDING_GRAND_TEMPLE_VENUS: case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: + case BUILDING_GRAND_TEMPLE_CERES_REWORKED: + case BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED: + case BUILDING_GRAND_TEMPLE_MERCURY_REWORKED: + case BUILDING_GRAND_TEMPLE_MARS_REWORKED: case BUILDING_PANTHEON: + case BUILDING_PANTHEON_REWORKED: map_tiles_update_area_roads(b->x, b->y, 9); building_monument_set_phase(b, MONUMENT_START); - if (type == BUILDING_GRAND_TEMPLE_MARS) { + if (type == BUILDING_GRAND_TEMPLE_MARS || type == BUILDING_GRAND_TEMPLE_MARS_REWORKED) { b->accepted_goods[RESOURCE_WEAPONS] = 1; b->accepted_goods[RESOURCE_NONE] = 1; } diff --git a/src/building/count.c b/src/building/count.c index 423accb79a..78cf67b161 100644 --- a/src/building/count.c +++ b/src/building/count.c @@ -51,7 +51,9 @@ static const building_type building_set_large_temples[] = { static const building_type building_set_grand_temples[] = { BUILDING_GRAND_TEMPLE_CERES, BUILDING_GRAND_TEMPLE_NEPTUNE, BUILDING_GRAND_TEMPLE_MERCURY, BUILDING_GRAND_TEMPLE_MARS, - BUILDING_GRAND_TEMPLE_VENUS, BUILDING_GRAND_TEMPLE_VENUS_REWORKED, BUILDING_PANTHEON + BUILDING_GRAND_TEMPLE_VENUS, BUILDING_PANTHEON, + BUILDING_GRAND_TEMPLE_CERES_REWORKED, BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED, BUILDING_GRAND_TEMPLE_MERCURY_REWORKED, + BUILDING_GRAND_TEMPLE_MARS_REWORKED, BUILDING_GRAND_TEMPLE_VENUS_REWORKED, BUILDING_PANTHEON_REWORKED }; #define BUILDING_SET_SIZE_GRAND_TEMPLES (sizeof(building_set_grand_temples) / sizeof(building_type)) diff --git a/src/building/figure.c b/src/building/figure.c index 3d3d523037..b4ea7ddede 100644 --- a/src/building/figure.c +++ b/src/building/figure.c @@ -2132,7 +2132,12 @@ void building_figure_generate(void) case BUILDING_GRAND_TEMPLE_MERCURY: case BUILDING_GRAND_TEMPLE_VENUS: case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: + case BUILDING_GRAND_TEMPLE_CERES_REWORKED: + case BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED: + case BUILDING_GRAND_TEMPLE_MERCURY_REWORKED: + case BUILDING_GRAND_TEMPLE_MARS_REWORKED: case BUILDING_PANTHEON: + case BUILDING_PANTHEON_REWORKED: spawn_figure_temple(b); break; case BUILDING_LIGHTHOUSE: diff --git a/src/building/image.c b/src/building/image.c index 8818ee1a0a..6229178acb 100644 --- a/src/building/image.c +++ b/src/building/image.c @@ -580,6 +580,7 @@ int building_image_get(const building *b) case BUILDING_NATIVE_CROPS: return image_group(GROUP_BUILDING_FARM_CROPS); case BUILDING_GRAND_TEMPLE_CERES: + case BUILDING_GRAND_TEMPLE_CERES_REWORKED: switch (b->monument.phase) { case MONUMENT_START: return assets_get_image_id("Monuments", "Ceres Complex Const 01"); @@ -602,6 +603,7 @@ int building_image_get(const building *b) } } case BUILDING_GRAND_TEMPLE_NEPTUNE: + case BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED: switch (b->monument.phase) { case MONUMENT_START: return assets_get_image_id("Monuments", "Neptune Complex Const 01"); @@ -624,6 +626,7 @@ int building_image_get(const building *b) } } case BUILDING_GRAND_TEMPLE_MERCURY: + case BUILDING_GRAND_TEMPLE_MERCURY_REWORKED: switch (b->monument.phase) { case MONUMENT_START: return assets_get_image_id("Monuments", "Mercury Complex Const 01"); @@ -646,6 +649,7 @@ int building_image_get(const building *b) } } case BUILDING_GRAND_TEMPLE_MARS: + case BUILDING_GRAND_TEMPLE_MARS_REWORKED: switch (b->monument.phase) { case MONUMENT_START: return assets_get_image_id("Monuments", "Mars Complex Const 01"); @@ -691,6 +695,7 @@ int building_image_get(const building *b) } } case BUILDING_PANTHEON: + case BUILDING_PANTHEON_REWORKED: switch (b->monument.phase) { case MONUMENT_START: return assets_get_image_id("Monuments", "Pantheon Const 01"); diff --git a/src/building/menu.c b/src/building/menu.c index 13a42352c2..5410aca0fb 100644 --- a/src/building/menu.c +++ b/src/building/menu.c @@ -51,8 +51,10 @@ static const building_type MENU_BUILDING_TYPE[BUILD_MENU_MAX][BUILD_MENU_ITEM_MA BUILDING_PALM_TREE, BUILDING_DATE_TREE, 0}, {BUILDING_MENU_PATHS, BUILDING_GARDEN_PATH, BUILDING_PINE_PATH , BUILDING_FIR_PATH, BUILDING_OAK_PATH, BUILDING_ELM_PATH, BUILDING_FIG_PATH, BUILDING_PLUM_PATH, BUILDING_PALM_PATH, BUILDING_DATE_PATH, 0}, - {BUILDING_PANTHEON, BUILDING_GRAND_TEMPLE_CERES, BUILDING_GRAND_TEMPLE_NEPTUNE, BUILDING_GRAND_TEMPLE_MERCURY, - BUILDING_GRAND_TEMPLE_MARS, BUILDING_GRAND_TEMPLE_VENUS, BUILDING_GRAND_TEMPLE_VENUS_REWORKED, 0}, + {BUILDING_PANTHEON, BUILDING_PANTHEON_REWORKED, BUILDING_GRAND_TEMPLE_CERES, BUILDING_GRAND_TEMPLE_CERES_REWORKED, + BUILDING_GRAND_TEMPLE_NEPTUNE, BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED, BUILDING_GRAND_TEMPLE_MERCURY, + BUILDING_GRAND_TEMPLE_MERCURY_REWORKED, BUILDING_GRAND_TEMPLE_MARS, BUILDING_GRAND_TEMPLE_MARS_REWORKED, + BUILDING_GRAND_TEMPLE_VENUS, BUILDING_GRAND_TEMPLE_VENUS_REWORKED, 0}, {BUILDING_SMALL_STATUE, BUILDING_GODDESS_STATUE, BUILDING_SENATOR_STATUE, BUILDING_GLADIATOR_STATUE, BUILDING_DECORATIVE_COLUMN, BUILDING_MEDIUM_STATUE, BUILDING_LEGION_STATUE, BUILDING_OBELISK, BUILDING_LARGE_STATUE, BUILDING_HORSE_STATUE, 0}, {BUILDING_GOVERNORS_HOUSE, BUILDING_GOVERNORS_VILLA, BUILDING_GOVERNORS_PALACE, 0}, @@ -137,9 +139,14 @@ static int can_get_required_resource(building_type type) static int is_building_type_allowed(building_type type) { - // BUILDING_GRAND_TEMPLE_VENUS requires the legacy venus cheat to be active - if (type == BUILDING_GRAND_TEMPLE_VENUS) { - return game_cheat_legacy_venus_enabled() && scenario_allowed_building(type) && can_get_required_resource(type); + // All 6 old grand temples require a cheat to be active + if (type == BUILDING_PANTHEON || + type == BUILDING_GRAND_TEMPLE_CERES || + type == BUILDING_GRAND_TEMPLE_NEPTUNE || + type == BUILDING_GRAND_TEMPLE_MERCURY || + type == BUILDING_GRAND_TEMPLE_MARS || + type == BUILDING_GRAND_TEMPLE_VENUS) { + return game_cheat_legacy_gts_enabled() && scenario_allowed_building(type) && can_get_required_resource(type); } return scenario_allowed_building(type) && can_get_required_resource(type); } diff --git a/src/building/monument.c b/src/building/monument.c index 8a6ff874d3..bc9b637e33 100644 --- a/src/building/monument.c +++ b/src/building/monument.c @@ -161,6 +161,11 @@ static const monument_type *MONUMENT_TYPES[BUILDING_TYPE_MAX] = { [BUILDING_GRAND_TEMPLE_MARS] = &grand_temple, [BUILDING_GRAND_TEMPLE_VENUS] = &grand_temple, [BUILDING_GRAND_TEMPLE_VENUS_REWORKED] = &grand_temple, + [BUILDING_GRAND_TEMPLE_CERES_REWORKED] = &grand_temple, + [BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED] = &grand_temple, + [BUILDING_GRAND_TEMPLE_MERCURY_REWORKED] = &grand_temple, + [BUILDING_GRAND_TEMPLE_MARS_REWORKED] = &grand_temple, + [BUILDING_PANTHEON_REWORKED] = &pantheon, [BUILDING_PANTHEON] = &pantheon, [BUILDING_ORACLE] = &oracle, [BUILDING_LARGE_TEMPLE_CERES] = &large_temple, @@ -285,7 +290,12 @@ int building_monument_is_limited(building_type type) case BUILDING_GRAND_TEMPLE_MARS: case BUILDING_GRAND_TEMPLE_VENUS: case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: + case BUILDING_GRAND_TEMPLE_CERES_REWORKED: + case BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED: + case BUILDING_GRAND_TEMPLE_MERCURY_REWORKED: + case BUILDING_GRAND_TEMPLE_MARS_REWORKED: case BUILDING_PANTHEON: + case BUILDING_PANTHEON_REWORKED: case BUILDING_LIGHTHOUSE: case BUILDING_CARAVANSERAI: case BUILDING_COLOSSEUM: @@ -401,6 +411,10 @@ int building_monument_is_grand_temple(building_type type) case BUILDING_GRAND_TEMPLE_MARS: case BUILDING_GRAND_TEMPLE_VENUS: case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: + case BUILDING_GRAND_TEMPLE_CERES_REWORKED: + case BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED: + case BUILDING_GRAND_TEMPLE_MERCURY_REWORKED: + case BUILDING_GRAND_TEMPLE_MARS_REWORKED: return 1; default: return 0; diff --git a/src/building/properties.c b/src/building/properties.c index 6ae925d0c0..893e410a85 100644 --- a/src/building/properties.c +++ b/src/building/properties.c @@ -860,8 +860,8 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .draw_desirability_range = 1, .event_data.attr = "small_temple_ceres", .event_data.key = TR_PARAMETER_VALUE_BUILDING_SMALL_TEMPLE_CERES, - .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 1, - .desirability_step_size = -1, .desirability_range = 4, .laborers = 2} + .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 2, + .desirability_step_size = -1, .desirability_range = 6, .laborers = 2} }, [BUILDING_SMALL_TEMPLE_NEPTUNE] = { .venus_gt_bonus = 1, @@ -871,8 +871,8 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .draw_desirability_range = 1, .event_data.attr = "small_temple_neptune", .event_data.key = TR_PARAMETER_VALUE_BUILDING_SMALL_TEMPLE_NEPTUNE, - .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 1, - .desirability_step_size = -1, .desirability_range = 4, .laborers = 2} + .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 2, + .desirability_step_size = -1, .desirability_range = 6, .laborers = 2} }, [BUILDING_SMALL_TEMPLE_MERCURY] = { .venus_gt_bonus = 1, @@ -882,8 +882,8 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .draw_desirability_range = 1, .event_data.attr = "small_temple_mercury", .event_data.key = TR_PARAMETER_VALUE_BUILDING_SMALL_TEMPLE_MERCURY, - .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 1, - .desirability_step_size = -1, .desirability_range = 4, .laborers = 2} + .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 2, + .desirability_step_size = -1, .desirability_range = 6, .laborers = 2} }, [BUILDING_SMALL_TEMPLE_MARS] = { .venus_gt_bonus = 1, @@ -893,8 +893,8 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .draw_desirability_range = 1, .event_data.attr = "small_temple_mars", .event_data.key = TR_PARAMETER_VALUE_BUILDING_SMALL_TEMPLE_MARS, - .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 1, - .desirability_step_size = -1, .desirability_range = 4, .laborers = 2} + .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 2, + .desirability_step_size = -1, .desirability_range = 6, .laborers = 2} }, [BUILDING_SMALL_TEMPLE_VENUS] = { .venus_gt_bonus = 1, @@ -904,8 +904,8 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .draw_desirability_range = 1, .event_data.attr = "small_temple_venus", .event_data.key = TR_PARAMETER_VALUE_BUILDING_SMALL_TEMPLE_VENUS, - .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 1, - .desirability_step_size = -1, .desirability_range = 4, .laborers = 2} + .building_model_data = {.cost = 50, .desirability_value = 4, .desirability_step = 2, + .desirability_step_size = -1, .desirability_range = 6, .laborers = 2} }, [BUILDING_LARGE_TEMPLE_CERES] = { .venus_gt_bonus = 1, @@ -918,7 +918,7 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .event_data.attr = "large_temple_ceres", .event_data.key = TR_PARAMETER_VALUE_BUILDING_LARGE_TEMPLE_CERES, .building_model_data = {.cost = 150, .desirability_value = 14, .desirability_step = 2, - .desirability_step_size = -2, .desirability_range = 5, .laborers = 5} + .desirability_step_size = -2, .desirability_range = 8, .laborers = 5} }, [BUILDING_LARGE_TEMPLE_NEPTUNE] = { .venus_gt_bonus = 1, @@ -931,7 +931,7 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .event_data.attr = "large_temple_neptune", .event_data.key = TR_PARAMETER_VALUE_BUILDING_LARGE_TEMPLE_NEPTUNE, .building_model_data = {.cost = 150, .desirability_value = 14, .desirability_step = 2, - .desirability_step_size = -2, .desirability_range = 5, .laborers = 5} + .desirability_step_size = -2, .desirability_range = 8, .laborers = 5} }, [BUILDING_LARGE_TEMPLE_MERCURY] = { .venus_gt_bonus = 1, @@ -944,7 +944,7 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .event_data.attr = "large_temple_mercury", .event_data.key = TR_PARAMETER_VALUE_BUILDING_LARGE_TEMPLE_MERCURY, .building_model_data = {.cost = 150, .desirability_value = 14, .desirability_step = 2, - .desirability_step_size = -2, .desirability_range = 5, .laborers = 5} + .desirability_step_size = -2, .desirability_range = 8, .laborers = 5} }, [BUILDING_LARGE_TEMPLE_MARS] = { .venus_gt_bonus = 1, @@ -957,7 +957,7 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .event_data.attr = "large_temple_mars", .event_data.key = TR_PARAMETER_VALUE_BUILDING_LARGE_TEMPLE_MARS, .building_model_data = {.cost = 150, .desirability_value = 14, .desirability_step = 2, - .desirability_step_size = -2, .desirability_range = 5, .laborers = 5} + .desirability_step_size = -2, .desirability_range = 8, .laborers = 5} }, [BUILDING_LARGE_TEMPLE_VENUS] = { .venus_gt_bonus = 1, @@ -970,10 +970,10 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .event_data.attr = "large_temple_venus", .event_data.key = TR_PARAMETER_VALUE_BUILDING_LARGE_TEMPLE_VENUS, .building_model_data = {.cost = 150, .desirability_value = 14, .desirability_step = 2, - .desirability_step_size = -2, .desirability_range = 5, .laborers = 5} + .desirability_step_size = -2, .desirability_range = 8, .laborers = 5} }, [BUILDING_MARKET] = { - .size = 2, + .size = 2, .image_group = 22, .sound_id = SOUND_CITY_MARKET, .event_data.attr = "market", @@ -1407,6 +1407,66 @@ static building_properties properties[BUILDING_TYPE_MAX] = { .building_model_data = {.cost = 2500, .desirability_value = 20, .desirability_step = 2, .desirability_step_size = -4, .desirability_range = 8, .laborers = 50} }, + [BUILDING_GRAND_TEMPLE_CERES_REWORKED] = { + .venus_gt_bonus = 1, + .size = 7, + .fire_proof = 1, + .sound_id = SOUND_CITY_TEMPLE_CERES, + .draw_desirability_range = 1, + .custom_asset.group = "Monuments", + .custom_asset.id = "Ceres Complex Off", + .event_data.attr = "grand_temple_ceres_reworked", + .building_model_data = {.cost = 2500, .desirability_value = 20, .desirability_step = 2, + .desirability_step_size = -4, .desirability_range = 8, .laborers = 50} + }, + [BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED] = { + .venus_gt_bonus = 1, + .size = 7, + .fire_proof = 1, + .sound_id = SOUND_CITY_TEMPLE_NEPTUNE, + .draw_desirability_range = 1, + .custom_asset.group = "Monuments", + .custom_asset.id = "Neptune Complex Off", + .event_data.attr = "grand_temple_neptune_reworked", + .building_model_data = {.cost = 2500, .desirability_value = 20, .desirability_step = 2, + .desirability_step_size = -4, .desirability_range = 8, .laborers = 50} + }, + [BUILDING_GRAND_TEMPLE_MERCURY_REWORKED] = { + .venus_gt_bonus = 1, + .size = 7, + .fire_proof = 1, + .sound_id = SOUND_CITY_TEMPLE_MERCURY, + .draw_desirability_range = 1, + .custom_asset.group = "Monuments", + .custom_asset.id = "Mercury Complex Off", + .event_data.attr = "grand_temple_mercury_reworked", + .building_model_data = {.cost = 2500, .desirability_value = 20, .desirability_step = 2, + .desirability_step_size = -4, .desirability_range = 8, .laborers = 50} + }, + [BUILDING_GRAND_TEMPLE_MARS_REWORKED] = { + .venus_gt_bonus = 1, + .size = 7, + .fire_proof = 1, + .sound_id = SOUND_CITY_TEMPLE_MARS, + .draw_desirability_range = 1, + .custom_asset.group = "Monuments", + .custom_asset.id = "Mars Complex Off", + .event_data.attr = "grand_temple_mars_reworked", + .building_model_data = {.cost = 2500, .desirability_value = 20, .desirability_step = 2, + .desirability_step_size = -4, .desirability_range = 8, .laborers = 50} + }, + [BUILDING_PANTHEON_REWORKED] = { + .venus_gt_bonus = 1, + .size = 7, + .fire_proof = 1, + .sound_id = SOUND_CITY_ORACLE, + .draw_desirability_range = 1, + .custom_asset.group = "Monuments", + .custom_asset.id = "Pantheon Off", + .event_data.attr = "pantheon_reworked", + .building_model_data = {.cost = 3500, .desirability_value = 20, .desirability_step = 2, + .desirability_step_size = -4, .desirability_range = 8, .laborers = 50} + }, [BUILDING_MENU_GRAND_TEMPLES] = { .event_data.attr = "grand_temples|all_grand_temples", .event_data.key = TR_PARAMETER_VALUE_BUILDING_MENU_GRAND_TEMPLES diff --git a/src/building/type.h b/src/building/type.h index ebbf8b3add..7fe6fc10a3 100644 --- a/src/building/type.h +++ b/src/building/type.h @@ -223,8 +223,13 @@ typedef enum { BUILDING_NATIVE_DECORATION = 209, BUILDING_REPAIR_LAND = 210, // tool, not an actual building BUILDING_GRAND_TEMPLE_VENUS_REWORKED = 211, + BUILDING_GRAND_TEMPLE_CERES_REWORKED = 212, + BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED = 213, + BUILDING_GRAND_TEMPLE_MERCURY_REWORKED = 214, + BUILDING_GRAND_TEMPLE_MARS_REWORKED = 215, + BUILDING_PANTHEON_REWORKED = 216, // helper constants - BUILDING_TYPE_MAX = 212 + BUILDING_TYPE_MAX = 217 } building_type; /** diff --git a/src/city/culture.c b/src/city/culture.c index b4e6d513b0..3f2b50f566 100644 --- a/src/city/culture.c +++ b/src/city/culture.c @@ -202,7 +202,12 @@ void city_culture_update_coverage(void) LARGE_TEMPLE_COVERAGE * building_count_active(BUILDING_LARGE_TEMPLE_VENUS) + PANTHEON_COVERAGE * building_count_active(BUILDING_PANTHEON) + GRAND_TEMPLE_COVERAGE * building_count_active(BUILDING_GRAND_TEMPLE_VENUS)+ - GRAND_TEMPLE_COVERAGE * building_count_active(BUILDING_GRAND_TEMPLE_VENUS_REWORKED), + GRAND_TEMPLE_COVERAGE * building_count_active(BUILDING_GRAND_TEMPLE_VENUS_REWORKED) + + GRAND_TEMPLE_COVERAGE * building_count_active(BUILDING_GRAND_TEMPLE_CERES_REWORKED) + + GRAND_TEMPLE_COVERAGE * building_count_active(BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED) + + GRAND_TEMPLE_COVERAGE * building_count_active(BUILDING_GRAND_TEMPLE_MERCURY_REWORKED) + + GRAND_TEMPLE_COVERAGE * building_count_active(BUILDING_GRAND_TEMPLE_MARS_REWORKED) + + GRAND_TEMPLE_COVERAGE * building_count_active(BUILDING_PANTHEON_REWORKED), population)); coverage.oracle = top(calc_percentage(ORACLE_COVERAGE * oracles, population)); diff --git a/src/city/finance.c b/src/city/finance.c index 1f5fd7c1ee..2913719c72 100644 --- a/src/city/finance.c +++ b/src/city/finance.c @@ -43,7 +43,12 @@ static building_levy_for_type building_levies[] = { {BUILDING_GRAND_TEMPLE_MARS, GRAND_TEMPLE_LEVY_MONTHLY}, {BUILDING_GRAND_TEMPLE_VENUS, GRAND_TEMPLE_LEVY_MONTHLY}, {BUILDING_GRAND_TEMPLE_VENUS_REWORKED, GRAND_TEMPLE_LEVY_MONTHLY}, - {BUILDING_PANTHEON, PANTHEON_LEVY_MONTHLY}, // 20 + {BUILDING_GRAND_TEMPLE_CERES_REWORKED, GRAND_TEMPLE_LEVY_MONTHLY}, + {BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED, GRAND_TEMPLE_LEVY_MONTHLY}, + {BUILDING_GRAND_TEMPLE_MERCURY_REWORKED, GRAND_TEMPLE_LEVY_MONTHLY}, + {BUILDING_GRAND_TEMPLE_MARS_REWORKED, GRAND_TEMPLE_LEVY_MONTHLY}, + {BUILDING_PANTHEON, PANTHEON_LEVY_MONTHLY}, + {BUILDING_PANTHEON_REWORKED, PANTHEON_LEVY_MONTHLY}, // 20 {BUILDING_COLOSSEUM, COLOSSEUM_LEVY_MONTHLY}, {BUILDING_HIPPODROME, HIPPODROME_LEVY_MONTHLY}, {BUILDING_SMALL_MAUSOLEUM, SMALL_MAUSOLEUM_LEVY_MONTHLY}, diff --git a/src/city/gods.c b/src/city/gods.c index 42e152b1af..9a61ae05ec 100644 --- a/src/city/gods.c +++ b/src/city/gods.c @@ -312,16 +312,16 @@ void city_gods_calculate_moods(int update_moods) int num_temples = 0; switch (i) { case GOD_CERES: - num_temples = building_count_active(BUILDING_SMALL_TEMPLE_CERES) + building_count_active(BUILDING_LARGE_TEMPLE_CERES) + building_count_active(BUILDING_GRAND_TEMPLE_CERES); + num_temples = building_count_active(BUILDING_SMALL_TEMPLE_CERES) + building_count_active(BUILDING_LARGE_TEMPLE_CERES) + building_count_active(BUILDING_GRAND_TEMPLE_CERES) + building_count_active(BUILDING_GRAND_TEMPLE_CERES_REWORKED); break; case GOD_NEPTUNE: - num_temples = building_count_active(BUILDING_SMALL_TEMPLE_NEPTUNE) + building_count_active(BUILDING_LARGE_TEMPLE_NEPTUNE) + building_count_active(BUILDING_GRAND_TEMPLE_NEPTUNE); + num_temples = building_count_active(BUILDING_SMALL_TEMPLE_NEPTUNE) + building_count_active(BUILDING_LARGE_TEMPLE_NEPTUNE) + building_count_active(BUILDING_GRAND_TEMPLE_NEPTUNE) + building_count_active(BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED); break; case GOD_MERCURY: - num_temples = building_count_active(BUILDING_SMALL_TEMPLE_MERCURY) + building_count_active(BUILDING_LARGE_TEMPLE_MERCURY) + building_count_active(BUILDING_GRAND_TEMPLE_MERCURY); + num_temples = building_count_active(BUILDING_SMALL_TEMPLE_MERCURY) + building_count_active(BUILDING_LARGE_TEMPLE_MERCURY) + building_count_active(BUILDING_GRAND_TEMPLE_MERCURY) + building_count_active(BUILDING_GRAND_TEMPLE_MERCURY_REWORKED); break; case GOD_MARS: - num_temples = building_count_active(BUILDING_SMALL_TEMPLE_MARS) + building_count_active(BUILDING_LARGE_TEMPLE_MARS) + building_count_active(BUILDING_GRAND_TEMPLE_MARS); + num_temples = building_count_active(BUILDING_SMALL_TEMPLE_MARS) + building_count_active(BUILDING_LARGE_TEMPLE_MARS) + building_count_active(BUILDING_GRAND_TEMPLE_MARS) + building_count_active(BUILDING_GRAND_TEMPLE_MARS_REWORKED); break; case GOD_VENUS: num_temples = building_count_active(BUILDING_SMALL_TEMPLE_VENUS) + building_count_active(BUILDING_LARGE_TEMPLE_VENUS) + building_count_active(BUILDING_GRAND_TEMPLE_VENUS)+ building_count_active(BUILDING_GRAND_TEMPLE_VENUS_REWORKED); diff --git a/src/city/labor.c b/src/city/labor.c index 0c55724d3d..451c74f7fa 100644 --- a/src/city/labor.c +++ b/src/city/labor.c @@ -119,7 +119,12 @@ static const int CATEGORY_FOR_BUILDING_TYPE[BUILDING_TYPE_MAX] = { [BUILDING_GRAND_TEMPLE_MARS] = LABOR_CATEGORY_GOVERNANCE_RELIGION, [BUILDING_GRAND_TEMPLE_VENUS] = LABOR_CATEGORY_GOVERNANCE_RELIGION, [BUILDING_GRAND_TEMPLE_VENUS_REWORKED] = LABOR_CATEGORY_GOVERNANCE_RELIGION, + [BUILDING_GRAND_TEMPLE_CERES_REWORKED] = LABOR_CATEGORY_GOVERNANCE_RELIGION, + [BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED] = LABOR_CATEGORY_GOVERNANCE_RELIGION, + [BUILDING_GRAND_TEMPLE_MERCURY_REWORKED] = LABOR_CATEGORY_GOVERNANCE_RELIGION, + [BUILDING_GRAND_TEMPLE_MARS_REWORKED] = LABOR_CATEGORY_GOVERNANCE_RELIGION, [BUILDING_PANTHEON] = LABOR_CATEGORY_GOVERNANCE_RELIGION, + [BUILDING_PANTHEON_REWORKED] = LABOR_CATEGORY_GOVERNANCE_RELIGION, [BUILDING_SENATE] = LABOR_CATEGORY_GOVERNANCE_RELIGION, [BUILDING_FORUM] = LABOR_CATEGORY_GOVERNANCE_RELIGION, [BUILDING_ORACLE] = LABOR_CATEGORY_GOVERNANCE_RELIGION, diff --git a/src/city/ratings.c b/src/city/ratings.c index 9bb5ce591a..641524d6cb 100644 --- a/src/city/ratings.c +++ b/src/city/ratings.c @@ -442,7 +442,12 @@ static void update_culture_rating(void) city_data.ratings.culture += building_count_active(BUILDING_GRAND_TEMPLE_MARS) * MONUMENT_CULTURE_BONUS; city_data.ratings.culture += building_count_active(BUILDING_GRAND_TEMPLE_VENUS) * MONUMENT_CULTURE_BONUS; city_data.ratings.culture += building_count_active(BUILDING_GRAND_TEMPLE_VENUS_REWORKED) * MONUMENT_CULTURE_BONUS; + city_data.ratings.culture += building_count_active(BUILDING_GRAND_TEMPLE_CERES_REWORKED) * MONUMENT_CULTURE_BONUS; + city_data.ratings.culture += building_count_active(BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED) * MONUMENT_CULTURE_BONUS; + city_data.ratings.culture += building_count_active(BUILDING_GRAND_TEMPLE_MERCURY_REWORKED) * MONUMENT_CULTURE_BONUS; + city_data.ratings.culture += building_count_active(BUILDING_GRAND_TEMPLE_MARS_REWORKED) * MONUMENT_CULTURE_BONUS; city_data.ratings.culture += building_count_active(BUILDING_PANTHEON) * MONUMENT_CULTURE_BONUS; + city_data.ratings.culture += building_count_active(BUILDING_PANTHEON_REWORKED) * MONUMENT_CULTURE_BONUS; city_data.ratings.culture += building_count_active(BUILDING_COLOSSEUM) * MONUMENT_CULTURE_BONUS; city_data.ratings.culture += building_count_active(BUILDING_HIPPODROME) * MONUMENT_CULTURE_BONUS; diff --git a/src/core/lang.c b/src/core/lang.c index 1cfe47d062..40bf36b1a3 100644 --- a/src/core/lang.c +++ b/src/core/lang.c @@ -411,19 +411,29 @@ const uint8_t *lang_get_string(int group, int index) case BUILDING_WORKCAMP: return translation_for(TR_BUILDING_WORK_CAMP); case BUILDING_GRAND_TEMPLE_CERES: - return translation_for(TR_BUILDING_GRAND_TEMPLE_CERES); + return translation_for(TR_BUILDING_GRAND_TEMPLE_CERES_LEGACY); case BUILDING_GRAND_TEMPLE_NEPTUNE: - return translation_for(TR_BUILDING_GRAND_TEMPLE_NEPTUNE); + return translation_for(TR_BUILDING_GRAND_TEMPLE_NEPTUNE_LEGACY); case BUILDING_GRAND_TEMPLE_MERCURY: - return translation_for(TR_BUILDING_GRAND_TEMPLE_MERCURY); + return translation_for(TR_BUILDING_GRAND_TEMPLE_MERCURY_LEGACY); case BUILDING_GRAND_TEMPLE_MARS: - return translation_for(TR_BUILDING_GRAND_TEMPLE_MARS); + return translation_for(TR_BUILDING_GRAND_TEMPLE_MARS_LEGACY); case BUILDING_GRAND_TEMPLE_VENUS: return translation_for(TR_BUILDING_GRAND_TEMPLE_VENUS_LEGACY); case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: return translation_for(TR_BUILDING_GRAND_TEMPLE_VENUS); - case BUILDING_PANTHEON: + case BUILDING_GRAND_TEMPLE_CERES_REWORKED: + return translation_for(TR_BUILDING_GRAND_TEMPLE_CERES); + case BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED: + return translation_for(TR_BUILDING_GRAND_TEMPLE_NEPTUNE); + case BUILDING_GRAND_TEMPLE_MERCURY_REWORKED: + return translation_for(TR_BUILDING_GRAND_TEMPLE_MERCURY); + case BUILDING_GRAND_TEMPLE_MARS_REWORKED: + return translation_for(TR_BUILDING_GRAND_TEMPLE_MARS); + case BUILDING_PANTHEON_REWORKED: return translation_for(TR_BUILDING_PANTHEON); + case BUILDING_PANTHEON: + return translation_for(TR_BUILDING_PANTHEON_LEGACY); case BUILDING_MENU_GRAND_TEMPLES: return translation_for(TR_BUILDING_GRAND_TEMPLE_MENU); case BUILDING_ARCHITECT_GUILD: diff --git a/src/figure/service.c b/src/figure/service.c index 56bb7d58b5..5bf1f03902 100644 --- a/src/figure/service.c +++ b/src/figure/service.c @@ -582,16 +582,19 @@ int figure_service_provide_coverage(figure *f) provide_market_goods(f->building_id, x, y); break; case BUILDING_GRAND_TEMPLE_CERES: + case BUILDING_GRAND_TEMPLE_CERES_REWORKED: houses_serviced = provide_culture(x, y, religion_coverage_ceres); break; case BUILDING_SMALL_TEMPLE_NEPTUNE: case BUILDING_LARGE_TEMPLE_NEPTUNE: case BUILDING_GRAND_TEMPLE_NEPTUNE: + case BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED: houses_serviced = provide_culture(x, y, religion_coverage_neptune); break; case BUILDING_SMALL_TEMPLE_MERCURY: case BUILDING_LARGE_TEMPLE_MERCURY: case BUILDING_GRAND_TEMPLE_MERCURY: + case BUILDING_GRAND_TEMPLE_MERCURY_REWORKED: houses_serviced = provide_culture(x, y, religion_coverage_mercury); break; case BUILDING_SMALL_TEMPLE_MARS: @@ -602,6 +605,7 @@ int figure_service_provide_coverage(figure *f) houses_serviced = provide_culture(x, y, religion_coverage_mars); break; case BUILDING_GRAND_TEMPLE_MARS: + case BUILDING_GRAND_TEMPLE_MARS_REWORKED: houses_serviced = provide_culture(x, y, religion_coverage_mars); break; case BUILDING_SMALL_TEMPLE_VENUS: @@ -617,6 +621,7 @@ int figure_service_provide_coverage(figure *f) houses_serviced = provide_culture(x, y, religion_coverage_venus); break; case BUILDING_PANTHEON: + case BUILDING_PANTHEON_REWORKED: houses_serviced = provide_culture(x, y, religion_coverage_ceres); provide_culture(x, y, religion_coverage_neptune); provide_culture(x, y, religion_coverage_mercury); diff --git a/src/game/cheats.c b/src/game/cheats.c index 0c6bd44c68..a84e5522e0 100644 --- a/src/game/cheats.c +++ b/src/game/cheats.c @@ -114,7 +114,7 @@ static struct { int extra_legions_unlocked; int disabled_legions_consumption; int disabled_invasions; - int legacy_venus_temple_enabled; + int legacy_gts_enabled; } data; static int parse_word(uint8_t *string, uint8_t *word) @@ -420,14 +420,15 @@ int game_cheat_disabled_invasions(void) return data.disabled_invasions; } +// Enables all 6 legacy grand temples in the building menu static void game_cheat_enable_legacy_venus(uint8_t *args) { - data.legacy_venus_temple_enabled = 1; + data.legacy_gts_enabled = 1; building_menu_update(); - show_warning(TR_CHEAT_LEGACY_VENUS_ENABLED); + show_warning(TR_CHEAT_LEGACY_GTS_ENABLED); } -int game_cheat_legacy_venus_enabled(void) +int game_cheat_legacy_gts_enabled(void) { - return data.legacy_venus_temple_enabled; + return data.legacy_gts_enabled; } diff --git a/src/game/cheats.h b/src/game/cheats.h index f36afdf022..164860f9e7 100644 --- a/src/game/cheats.h +++ b/src/game/cheats.h @@ -28,7 +28,7 @@ int game_cheat_disabled_legions_consumption(void); int game_cheat_disabled_invasions(void); -int game_cheat_legacy_venus_enabled(void); +int game_cheat_legacy_gts_enabled(void); void game_cheat_show_custom_events(uint8_t *args); diff --git a/src/map/image_context.c b/src/map/image_context.c index 2447ae70ae..d8f8fd4d81 100644 --- a/src/map/image_context.c +++ b/src/map/image_context.c @@ -443,7 +443,11 @@ static void set_tiles_road(int grid_offset, int tiles[MAX_TILES]) int base = b_main->grid_offset; tiles[i] = (offset == base) ? 1 : 0; } - if ((b->type >= BUILDING_GRAND_TEMPLE_CERES && b->type <= BUILDING_GRAND_TEMPLE_VENUS) || (b->type == BUILDING_PANTHEON) || (b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED)) { + if ((b->type >= BUILDING_GRAND_TEMPLE_CERES && b->type <= BUILDING_GRAND_TEMPLE_VENUS) || + (b->type >= BUILDING_GRAND_TEMPLE_CERES_REWORKED && b->type <= BUILDING_GRAND_TEMPLE_MARS_REWORKED) || + (b->type == BUILDING_PANTHEON) || + (b->type == BUILDING_PANTHEON_REWORKED) || + (b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED)) { tiles[i] = (offset == b->grid_offset + map_grid_delta(3, 0)) ? 1 : 0; tiles[i] |= (offset == b->grid_offset + map_grid_delta(0, 3)) ? 1 : 0; tiles[i] |= (offset == b->grid_offset + map_grid_delta(6, 3)) ? 1 : 0; diff --git a/src/scenario/allowed_building.c b/src/scenario/allowed_building.c index fb973d2e07..a636227116 100644 --- a/src/scenario/allowed_building.c +++ b/src/scenario/allowed_building.c @@ -58,7 +58,7 @@ static const building_type CONVERSION_FROM_ORIGINAL[MAX_ORIGINAL_ALLOWED_BUILDIN { BUILDING_LOW_BRIDGE, BUILDING_SHIP_BRIDGE }, { BUILDING_BARRACKS, BUILDING_ARMOURY }, { BUILDING_MILITARY_ACADEMY }, - { BUILDING_GRAND_TEMPLE_CERES, BUILDING_GRAND_TEMPLE_NEPTUNE, BUILDING_GRAND_TEMPLE_MERCURY, BUILDING_GRAND_TEMPLE_MARS, BUILDING_GRAND_TEMPLE_VENUS, BUILDING_GRAND_TEMPLE_VENUS_REWORKED }, + { BUILDING_GRAND_TEMPLE_CERES, BUILDING_GRAND_TEMPLE_NEPTUNE, BUILDING_GRAND_TEMPLE_MERCURY, BUILDING_GRAND_TEMPLE_MARS, BUILDING_GRAND_TEMPLE_VENUS, BUILDING_PANTHEON, BUILDING_GRAND_TEMPLE_CERES_REWORKED, BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED, BUILDING_GRAND_TEMPLE_MERCURY_REWORKED, BUILDING_GRAND_TEMPLE_MARS_REWORKED, BUILDING_GRAND_TEMPLE_VENUS_REWORKED, BUILDING_PANTHEON_REWORKED }, }; static uint8_t allowed_buildings[BUILDING_TYPE_MAX]; diff --git a/src/translation/english.c b/src/translation/english.c index 204fd747fc..162b5d70f8 100644 --- a/src/translation/english.c +++ b/src/translation/english.c @@ -193,6 +193,11 @@ static translation_string all_strings[] = { {TR_BUILDING_GRAND_TEMPLE_MERCURY, "Mercury grand temple" }, {TR_BUILDING_GRAND_TEMPLE_MARS, "Mars grand temple" }, {TR_BUILDING_GRAND_TEMPLE_VENUS, "Venus grand temple" }, + {TR_BUILDING_GRAND_TEMPLE_CERES_LEGACY, "Ceres ancient temple" }, + {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_LEGACY, "Neptune ancient temple" }, + {TR_BUILDING_GRAND_TEMPLE_MERCURY_LEGACY, "Mercury ancient temple" }, + {TR_BUILDING_GRAND_TEMPLE_MARS_LEGACY, "Mars ancient temple" }, + {TR_BUILDING_PANTHEON_LEGACY, "Ancient Pantheon" }, {TR_BUILDING_GRAND_TEMPLE_VENUS_LEGACY, "Venus ancient temple" }, {TR_BUILDING_PANTHEON, "Pantheon" }, {TR_BUILDING_GRAND_TEMPLE_CERES_DESC, "Grand temple of Ceres" }, @@ -207,6 +212,11 @@ static translation_string all_strings[] = { {TR_BUILDING_GRAND_TEMPLE_MARS_BONUS_DESC, "Mars exhorts your citizens to enlist, dispatching recruits to your city's forts, and allowing four additional forts to be built." }, // Note to translators: This one changed from the previous version, please update. {TR_BUILDING_GRAND_TEMPLE_VENUS_BONUS_DESC, "Venus graces your city's gardens, statues and temples to glow with beauty, improving their desirability. Houses also hold more goods, and devolve more slowly." }, // Note to translators: This one changed from the previous version, please update. {TR_BUILDING_GRAND_TEMPLE_VENUS_REWORKED_BONUS_DESC, "Priests of Venus bless houses to glow with additional desirability." }, + {TR_BUILDING_GRAND_TEMPLE_CERES_REWORKED_BONUS_DESC, "Placeholder bonus description for Ceres."}, + {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED_BONUS_DESC, "Placeholder bonus description for Neptune."}, + {TR_BUILDING_GRAND_TEMPLE_MERCURY_REWORKED_BONUS_DESC, "Placeholder bonus description for Mercury."}, + {TR_BUILDING_GRAND_TEMPLE_MARS_REWORKED_BONUS_DESC, "Placeholder bonus description for Mars."}, + {TR_BUILDING_PANTHEON_REWORKED_BONUS_DESC, "Placeholder bonus description for Pantheon."}, {TR_BUILDING_PANTHEON_BONUS_DESC, "The Pantheon provides access to your citizens to worship all the gods. Annual festivals are also held here, and religious and cultural building levies are reduced by 25%." }, // Note to translators: This one changed from the previous version, please update. {TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_1_DESC, "Priests reduce food consumption by 20%." }, {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_1_DESC, "Temples produce charioteers for the Hippodrome." }, @@ -1659,7 +1669,7 @@ static translation_string all_strings[] = { {TR_CONDITION_TEXT_TIME_LEFT_UNTIL_VICTORY, "Time until victory:" }, {TR_CHEAT_DISABLE_INVASIONS, "Disable invasions"}, {TR_CHEAT_DISABLE_LEGIONS_CONSUMPTION, "Disable soldier food consumption"}, - {TR_CHEAT_LEGACY_VENUS_ENABLED, "Legacy Venus Grand Temple unlocked in build menu"}, + {TR_CHEAT_LEGACY_GTS_ENABLED, "Ancient grand temples unlocked"}, {TR_ACTION_TYPE_CHANGE_TERRAIN, "Add/remove terrain" }, {TR_PARAMETER_TERRAIN, "Terrain" }, {TR_PARAMETER_ADD, "Add" }, diff --git a/src/translation/translation.h b/src/translation/translation.h index e4aba825ec..787284c87a 100644 --- a/src/translation/translation.h +++ b/src/translation/translation.h @@ -189,6 +189,11 @@ typedef enum { TR_BUILDING_GRAND_TEMPLE_MERCURY, TR_BUILDING_GRAND_TEMPLE_MARS, TR_BUILDING_GRAND_TEMPLE_VENUS, + TR_BUILDING_GRAND_TEMPLE_CERES_LEGACY, + TR_BUILDING_GRAND_TEMPLE_NEPTUNE_LEGACY, + TR_BUILDING_GRAND_TEMPLE_MERCURY_LEGACY, + TR_BUILDING_GRAND_TEMPLE_MARS_LEGACY, + TR_BUILDING_PANTHEON_LEGACY, TR_BUILDING_GRAND_TEMPLE_VENUS_LEGACY, TR_BUILDING_PANTHEON, TR_BUILDING_GRAND_TEMPLE_CERES_DESC, @@ -203,6 +208,11 @@ typedef enum { TR_BUILDING_GRAND_TEMPLE_MARS_BONUS_DESC, TR_BUILDING_GRAND_TEMPLE_VENUS_BONUS_DESC, TR_BUILDING_GRAND_TEMPLE_VENUS_REWORKED_BONUS_DESC, + TR_BUILDING_GRAND_TEMPLE_CERES_REWORKED_BONUS_DESC, + TR_BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED_BONUS_DESC, + TR_BUILDING_GRAND_TEMPLE_MERCURY_REWORKED_BONUS_DESC, + TR_BUILDING_GRAND_TEMPLE_MARS_REWORKED_BONUS_DESC, + TR_BUILDING_PANTHEON_REWORKED_BONUS_DESC, TR_BUILDING_PANTHEON_BONUS_DESC, TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_1_DESC, TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_1_DESC, diff --git a/src/widget/city_overlay_other.c b/src/widget/city_overlay_other.c index 5b02a8e0a8..aa185ac3a3 100644 --- a/src/widget/city_overlay_other.c +++ b/src/widget/city_overlay_other.c @@ -48,7 +48,10 @@ static int show_building_religion(const building *b) b->type == BUILDING_SMALL_MAUSOLEUM || b->type == BUILDING_LARGE_MAUSOLEUM || b->type == BUILDING_LARGE_TEMPLE_VENUS || b->type == BUILDING_GRAND_TEMPLE_CERES || b->type == BUILDING_GRAND_TEMPLE_NEPTUNE || b->type == BUILDING_GRAND_TEMPLE_MERCURY || - b->type == BUILDING_GRAND_TEMPLE_MARS || b->type == BUILDING_GRAND_TEMPLE_VENUS || b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED || + b->type == BUILDING_GRAND_TEMPLE_MARS || b->type == BUILDING_GRAND_TEMPLE_VENUS || + b->type == BUILDING_GRAND_TEMPLE_CERES_REWORKED || b->type == BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED || + b->type == BUILDING_GRAND_TEMPLE_MERCURY_REWORKED || b->type == BUILDING_GRAND_TEMPLE_MARS_REWORKED || + b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED || b->type == BUILDING_PANTHEON_REWORKED || b->type == BUILDING_PANTHEON || b->type == BUILDING_NYMPHAEUM || b->type == BUILDING_SHRINE_CERES || b->type == BUILDING_SHRINE_MARS || b->type == BUILDING_SHRINE_MERCURY || b->type == BUILDING_SHRINE_VENUS || diff --git a/src/window/advisor/religion.c b/src/window/advisor/religion.c index d0984ec955..1ac72e9873 100644 --- a/src/window/advisor/religion.c +++ b/src/window/advisor/religion.c @@ -143,13 +143,13 @@ static int draw_background(void) // god rows draw_god_row(GOD_CERES, 66, BUILDING_SHRINE_CERES, BUILDING_SMALL_TEMPLE_CERES, - BUILDING_LARGE_TEMPLE_CERES, BUILDING_GRAND_TEMPLE_CERES); + BUILDING_LARGE_TEMPLE_CERES, BUILDING_GRAND_TEMPLE_CERES_REWORKED); draw_god_row(GOD_NEPTUNE, 86, BUILDING_SHRINE_NEPTUNE, BUILDING_SMALL_TEMPLE_NEPTUNE, - BUILDING_LARGE_TEMPLE_NEPTUNE, BUILDING_GRAND_TEMPLE_NEPTUNE); + BUILDING_LARGE_TEMPLE_NEPTUNE, BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED); draw_god_row(GOD_MERCURY, 106, BUILDING_SHRINE_MERCURY, BUILDING_SMALL_TEMPLE_MERCURY, - BUILDING_LARGE_TEMPLE_MERCURY, BUILDING_GRAND_TEMPLE_MERCURY); + BUILDING_LARGE_TEMPLE_MERCURY, BUILDING_GRAND_TEMPLE_MERCURY_REWORKED); draw_god_row(GOD_MARS, 126, BUILDING_SHRINE_MARS, BUILDING_SMALL_TEMPLE_MARS, - BUILDING_LARGE_TEMPLE_MARS, BUILDING_GRAND_TEMPLE_MARS); + BUILDING_LARGE_TEMPLE_MARS, BUILDING_GRAND_TEMPLE_MARS_REWORKED); draw_god_row(GOD_VENUS, 146, BUILDING_SHRINE_VENUS, BUILDING_SMALL_TEMPLE_VENUS, BUILDING_LARGE_TEMPLE_VENUS, BUILDING_GRAND_TEMPLE_VENUS_REWORKED); diff --git a/src/window/building/culture.c b/src/window/building/culture.c index f8ad3c13d3..829062c5ef 100644 --- a/src/window/building/culture.c +++ b/src/window/building/culture.c @@ -891,6 +891,46 @@ void window_building_draw_grand_temple_venus_reworked(building_info_context *c) TR_BUILDING_VENUS_TEMPLE_QUOTE, GOD_VENUS, 20); } +void window_building_draw_grand_temple_ceres_reworked(building_info_context *c) +{ + draw_grand_temple(c, "wavs/temple_farm.wav", TR_BUILDING_GRAND_TEMPLE_CERES_DESC, + TR_BUILDING_GRAND_TEMPLE_CERES_REWORKED_BONUS_DESC, + assets_get_image_id("UI", "Ceres L Banner"), + TR_BUILDING_CERES_TEMPLE_QUOTE, GOD_CERES, 20); +} + +void window_building_draw_grand_temple_neptune_reworked(building_info_context *c) +{ + draw_grand_temple(c, "wavs/temple_ship.wav", TR_BUILDING_GRAND_TEMPLE_NEPTUNE_DESC, + TR_BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED_BONUS_DESC, + assets_get_image_id("UI", "Nept L Banner"), + TR_BUILDING_NEPTUNE_TEMPLE_QUOTE, GOD_NEPTUNE, 20); +} + +void window_building_draw_grand_temple_mercury_reworked(building_info_context *c) +{ + draw_grand_temple(c, "wavs/temple_comm.wav", TR_BUILDING_GRAND_TEMPLE_MERCURY_DESC, + TR_BUILDING_GRAND_TEMPLE_MERCURY_REWORKED_BONUS_DESC, + assets_get_image_id("UI", "Merc L Banner"), + TR_BUILDING_MERCURY_TEMPLE_QUOTE, GOD_MERCURY, 20); +} + +void window_building_draw_grand_temple_mars_reworked(building_info_context *c) +{ + draw_grand_temple(c, "wavs/temple_war.wav", TR_BUILDING_GRAND_TEMPLE_MARS_DESC, + TR_BUILDING_GRAND_TEMPLE_MARS_REWORKED_BONUS_DESC, + assets_get_image_id("UI", "Mars L Banner"), + TR_BUILDING_MARS_TEMPLE_QUOTE, GOD_MARS, 20); +} + +void window_building_draw_pantheon_reworked(building_info_context *c) +{ + draw_grand_temple(c, "wavs/oracle.wav", TR_BUILDING_PANTHEON_DESC, + TR_BUILDING_PANTHEON_REWORKED_BONUS_DESC, + assets_get_image_id("UI", "Panth L Banner"), + TR_BUILDING_PANTHEON_QUOTE, GOD_PANTHEON, 0); +} + void window_building_draw_pantheon(building_info_context *c) { draw_grand_temple(c, "wavs/oracle.wav", TR_BUILDING_PANTHEON_DESC, TR_BUILDING_PANTHEON_BONUS_DESC, diff --git a/src/window/building/culture.h b/src/window/building/culture.h index 7c90a0429a..c9302b45c7 100644 --- a/src/window/building/culture.h +++ b/src/window/building/culture.h @@ -79,6 +79,16 @@ void window_building_draw_grand_temple_venus(building_info_context* c); void window_building_draw_grand_temple_venus_reworked(building_info_context* c); +void window_building_draw_grand_temple_ceres_reworked(building_info_context* c); + +void window_building_draw_grand_temple_neptune_reworked(building_info_context* c); + +void window_building_draw_grand_temple_mercury_reworked(building_info_context* c); + +void window_building_draw_grand_temple_mars_reworked(building_info_context* c); + +void window_building_draw_pantheon_reworked(building_info_context* c); + void window_building_draw_pantheon(building_info_context* c); void window_building_draw_work_camp(building_info_context* c); diff --git a/src/window/building_info.c b/src/window/building_info.c index 023464c907..1a4b612ffc 100644 --- a/src/window/building_info.c +++ b/src/window/building_info.c @@ -245,13 +245,18 @@ static int get_height_id(void) case BUILDING_GRAND_TEMPLE_MERCURY: case BUILDING_GRAND_TEMPLE_VENUS: case BUILDING_GRAND_TEMPLE_VENUS_REWORKED: + case BUILDING_GRAND_TEMPLE_CERES_REWORKED: + case BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED: + case BUILDING_GRAND_TEMPLE_MERCURY_REWORKED: case BUILDING_PANTHEON: + case BUILDING_PANTHEON_REWORKED: case BUILDING_HIPPODROME: case BUILDING_COLOSSEUM: return HEIGHT_8_40_BLOCKS; //736px case BUILDING_GRAND_TEMPLE_MARS: + case BUILDING_GRAND_TEMPLE_MARS_REWORKED: return HEIGHT_10_46_BLOCKS; //448px @@ -724,8 +729,18 @@ static void draw_background(void) window_building_draw_grand_temple_venus(&context); } else if (btype == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { window_building_draw_grand_temple_venus_reworked(&context); + } else if (btype == BUILDING_GRAND_TEMPLE_CERES_REWORKED) { + window_building_draw_grand_temple_ceres_reworked(&context); + } else if (btype == BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED) { + window_building_draw_grand_temple_neptune_reworked(&context); + } else if (btype == BUILDING_GRAND_TEMPLE_MERCURY_REWORKED) { + window_building_draw_grand_temple_mercury_reworked(&context); + } else if (btype == BUILDING_GRAND_TEMPLE_MARS_REWORKED) { + window_building_draw_grand_temple_mars_reworked(&context); } else if (btype == BUILDING_PANTHEON) { window_building_draw_pantheon(&context); + } else if (btype == BUILDING_PANTHEON_REWORKED) { + window_building_draw_pantheon_reworked(&context); } else if (btype == BUILDING_LIGHTHOUSE) { window_building_draw_lighthouse(&context); } else if (btype == BUILDING_GOVERNORS_HOUSE || btype == BUILDING_GOVERNORS_VILLA || From 0603f7e79fedc6e023978070396041f38fc4c616 Mon Sep 17 00:00:00 2001 From: William Hardy Gest Date: Wed, 18 Feb 2026 17:25:33 -0600 Subject: [PATCH 04/12] Ceres bonuses implemented --- src/building/monument.c | 5 +++++ src/building/monument.h | 2 ++ src/city/resource.c | 24 ++++++++++++++++++++---- src/figuretype/cartpusher.c | 6 +++++- src/figuretype/supplier.c | 23 +++++++++++++++++++---- src/translation/english.c | 6 +++++- src/translation/translation.h | 6 +++++- src/window/building/culture.c | 24 +++++++++++++++++++++++- 8 files changed, 84 insertions(+), 12 deletions(-) diff --git a/src/building/monument.c b/src/building/monument.c index bc9b637e33..19c375fd64 100644 --- a/src/building/monument.c +++ b/src/building/monument.c @@ -744,6 +744,11 @@ int building_monument_gt_module_is_active(int module) temple_type = BUILDING_GRAND_TEMPLE_VENUS_REWORKED; module_num = (module == VENUS_MODULE_3_WINE_TEMPLE) ? 1 : 2; } + // Special handling for reworked Ceres temple modules + if (module == CERES_MODULE_3_FARM_SPEED || module == CERES_MODULE_4_MARKET_SPEED) { + temple_type = BUILDING_GRAND_TEMPLE_CERES_REWORKED; + module_num = (module == CERES_MODULE_3_FARM_SPEED) ? 1 : 2; + } return building_monument_module_type(temple_type) == module_num; } diff --git a/src/building/monument.h b/src/building/monument.h index 5d4fc8d91d..facc32e9ab 100644 --- a/src/building/monument.h +++ b/src/building/monument.h @@ -21,6 +21,8 @@ typedef enum { VENUS_MODULE_2_DESIRABILITY_ENTERTAINMENT, VENUS_MODULE_3_WINE_TEMPLE, VENUS_MODULE_4_THEATER_TAVERN, + CERES_MODULE_3_FARM_SPEED, + CERES_MODULE_4_MARKET_SPEED, PANTHEON_MODULE_1_DESTINATION_PRIESTS, PANTHEON_MODULE_2_HOUSING_EVOLUTION } module_type; diff --git a/src/city/resource.c b/src/city/resource.c index 512fcd769c..62e5017655 100644 --- a/src/city/resource.c +++ b/src/city/resource.c @@ -487,24 +487,40 @@ static int house_consume_food(void) { int total_consumed = 0; int ceres_module = (building_monument_gt_module_is_active(CERES_MODULE_1_REDUCE_FOOD)); + int ceres_reworked_base = building_monument_working(BUILDING_GRAND_TEMPLE_CERES_REWORKED); + for (building_type type = BUILDING_HOUSE_SMALL_TENT; type <= BUILDING_HOUSE_LUXURY_PALACE; type++) { for (building *b = building_first_of_type(type); b; b = b->next_of_type) { if (b->state != BUILDING_STATE_IN_USE || !b->house_size) { continue; } int num_types = model_get_house(b->subtype.house_level)->food_types; - int amount_per_type; + + // Calculate base consumption percentage (default 50%) + int consumption_percentage = 50; + + // Old Ceres module: 20% reduction (to 40%) if (ceres_module && b->data.house.temple_ceres) { - amount_per_type = calc_adjust_with_percentage(b->house_population, 40); - } else { - amount_per_type = calc_adjust_with_percentage(b->house_population, 50); + consumption_percentage = 40; } + + // Count available food types (this happens before actual consumption) int foodtypes_available = 0; for (resource_type r = RESOURCE_MIN_FOOD; r < RESOURCE_MAX_FOOD; r++) { if (b->resources[r] && resource_is_inventory(r)) { foodtypes_available++; } } + + // Ceres Reworked base bonus: 5% reduction per food type available + if (ceres_reworked_base && b->data.house.temple_ceres && foodtypes_available > 0) { + int reduction_pct = 5 * foodtypes_available; + consumption_percentage = calc_adjust_with_percentage(consumption_percentage, 100 - reduction_pct); + } + + int amount_per_type = calc_adjust_with_percentage(b->house_population, consumption_percentage); + + // Divide by actual food types available if (foodtypes_available) { amount_per_type /= foodtypes_available; } diff --git a/src/figuretype/cartpusher.c b/src/figuretype/cartpusher.c index 8c1eef064f..9d11387ad9 100644 --- a/src/figuretype/cartpusher.c +++ b/src/figuretype/cartpusher.c @@ -320,13 +320,17 @@ static void update_image(figure *f) static int cartpusher_percentage_speed(figure *f) { - // Ceres grand temple base bonus + // Ceres grand temple base bonus (old temple) building *src_building = building_get(f->building_id); int src_building_type = src_building->type; if (src_building_type >= BUILDING_WHEAT_FARM && src_building_type <= BUILDING_PIG_FARM) { if (building_monument_working(BUILDING_GRAND_TEMPLE_CERES)) { return 50; } + // Ceres Reworked module 1: farm cart speed bonus + if (building_monument_gt_module_is_active(CERES_MODULE_3_FARM_SPEED)) { + return 40; + } } return 0; } diff --git a/src/figuretype/supplier.c b/src/figuretype/supplier.c index a98de8b8eb..6eb8c020d7 100644 --- a/src/figuretype/supplier.c +++ b/src/figuretype/supplier.c @@ -5,6 +5,7 @@ #include "building/distribution.h" #include "building/granary.h" #include "building/market.h" +#include "building/monument.h" #include "building/storage.h" #include "building/warehouse.h" #include "core/config.h" @@ -228,6 +229,16 @@ static int recalculate_market_supplier_destination(figure *f) return change_market_supplier_destination(f, info[fetch_inventory].building_id); } +// Ceres Reworked module 2: market supplier speed bonus +static int market_supplier_bonus_speed(figure *f) +{ + if (f->type == FIGURE_MARKET_SUPPLIER && + building_monument_gt_module_is_active(CERES_MODULE_4_MARKET_SPEED)) { + return 20; + } + return 0; +} + void figure_supplier_action(figure *f) { f->terrain_usage = TERRAIN_USAGE_ROADS_HIGHWAY; @@ -247,8 +258,9 @@ void figure_supplier_action(figure *f) case FIGURE_ACTION_149_CORPSE: figure_combat_handle_corpse(f); break; - case FIGURE_ACTION_145_SUPPLIER_GOING_TO_STORAGE: - figure_movement_move_ticks(f, 1); + case FIGURE_ACTION_145_SUPPLIER_GOING_TO_STORAGE: { + int speed_bonus = market_supplier_bonus_speed(f); + figure_movement_move_ticks_with_percentage(f, 1, speed_bonus); if (f->direction == DIR_FIGURE_AT_DESTINATION) { f->wait_ticks = 0; f->previous_tile_x = f->x; @@ -284,8 +296,10 @@ void figure_supplier_action(figure *f) } } break; - case FIGURE_ACTION_146_SUPPLIER_RETURNING: - figure_movement_move_ticks(f, 1); + } + case FIGURE_ACTION_146_SUPPLIER_RETURNING: { + int speed_bonus = market_supplier_bonus_speed(f); + figure_movement_move_ticks_with_percentage(f, 1, speed_bonus); if (f->direction == DIR_FIGURE_AT_DESTINATION || f->direction == DIR_FIGURE_LOST) { if (f->direction == DIR_FIGURE_AT_DESTINATION && f->type == FIGURE_LIGHTHOUSE_SUPPLIER) { building_get(f->building_id)->resources[RESOURCE_TIMBER] += 100; @@ -295,6 +309,7 @@ void figure_supplier_action(figure *f) figure_route_remove(f); } break; + } } if (f->type == FIGURE_MESS_HALL_SUPPLIER) { int dir = figure_image_normalize_direction(f->direction < 8 ? f->direction : f->previous_tile_direction); diff --git a/src/translation/english.c b/src/translation/english.c index 162b5d70f8..02fd0cb618 100644 --- a/src/translation/english.c +++ b/src/translation/english.c @@ -212,7 +212,7 @@ static translation_string all_strings[] = { {TR_BUILDING_GRAND_TEMPLE_MARS_BONUS_DESC, "Mars exhorts your citizens to enlist, dispatching recruits to your city's forts, and allowing four additional forts to be built." }, // Note to translators: This one changed from the previous version, please update. {TR_BUILDING_GRAND_TEMPLE_VENUS_BONUS_DESC, "Venus graces your city's gardens, statues and temples to glow with beauty, improving their desirability. Houses also hold more goods, and devolve more slowly." }, // Note to translators: This one changed from the previous version, please update. {TR_BUILDING_GRAND_TEMPLE_VENUS_REWORKED_BONUS_DESC, "Priests of Venus bless houses to glow with additional desirability." }, - {TR_BUILDING_GRAND_TEMPLE_CERES_REWORKED_BONUS_DESC, "Placeholder bonus description for Ceres."}, + {TR_BUILDING_GRAND_TEMPLE_CERES_REWORKED_BONUS_DESC, "Priests of Ceres bless houses to consume less food based on variety available."}, {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED_BONUS_DESC, "Placeholder bonus description for Neptune."}, {TR_BUILDING_GRAND_TEMPLE_MERCURY_REWORKED_BONUS_DESC, "Placeholder bonus description for Mercury."}, {TR_BUILDING_GRAND_TEMPLE_MARS_REWORKED_BONUS_DESC, "Placeholder bonus description for Mars."}, @@ -244,6 +244,10 @@ static translation_string all_strings[] = { {TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_2, "Temple of Venus Genetrix" }, {TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_3, "Temple of Venus Cloacina" }, {TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_4, "Temple of Venus Felix" }, + {TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_3, "Temple of Ceres Pervinca" }, + {TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_3_DESC, "Farm carts from all farms move 40% faster." }, + {TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_4, "Temple of Ceres Abundantia" }, + {TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_4_DESC, "Market buyers collecting from granaries and warehouses move 20% faster." }, {TR_BUILDING_PANTHEON_DESC_MODULE_1, "Pantheum Ara Maxima" }, {TR_BUILDING_PANTHEON_DESC_MODULE_2, "Pantheum Roma Aeterna" }, {TR_BUILDING_GRAND_TEMPLE_MENU, "Grand temple" }, diff --git a/src/translation/translation.h b/src/translation/translation.h index 787284c87a..374d67b8c7 100644 --- a/src/translation/translation.h +++ b/src/translation/translation.h @@ -240,6 +240,10 @@ typedef enum { TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_2, TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_3, TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_4, + TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_3, + TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_3_DESC, + TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_4, + TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_4_DESC, TR_BUILDING_PANTHEON_DESC_MODULE_1, TR_BUILDING_PANTHEON_DESC_MODULE_2, TR_BUILDING_GRAND_TEMPLE_MENU, @@ -1676,7 +1680,7 @@ typedef enum { TR_CONDITION_TEXT_TIME_LEFT_UNTIL_VICTORY, TR_CHEAT_DISABLE_INVASIONS, TR_CHEAT_DISABLE_LEGIONS_CONSUMPTION, - TR_CHEAT_LEGACY_VENUS_ENABLED, + TR_CHEAT_LEGACY_GTS_ENABLED, TR_TOOLTIP_BUTTON_ACCEPT_ALL, TR_TOOLTIP_BUTTON_REJECT_ALL, TR_TOOLTIP_OVERLAY_PROBLEMS_NO_ROAD_ACCESS, diff --git a/src/window/building/culture.c b/src/window/building/culture.c index 829062c5ef..58c32b686c 100644 --- a/src/window/building/culture.c +++ b/src/window/building/culture.c @@ -59,7 +59,7 @@ static struct { option_menu_item option; const building_type required_building; const char image_id[32]; -} temple_module_options[14] = { +} temple_module_options[16] = { { { TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_1, TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_1_DESC }, BUILDING_NONE, @@ -129,6 +129,16 @@ static struct { { TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_4, TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_4_DESC }, BUILDING_NONE, "Venus M2 Icon" + }, + { + { TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_3, TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_3_DESC }, + BUILDING_NONE, + "Ceres M Icon" + }, + { + { TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_4, TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_4_DESC }, + BUILDING_NONE, + "Ceres M2 Icon" } }; @@ -761,6 +771,10 @@ static void draw_grand_temple(building_info_context *c, const char *sound_file, if (b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { module_index = 12 + (b->monument.upgrades - 1); } + // Special handling for reworked Ceres temple + if (b->type == BUILDING_GRAND_TEMPLE_CERES_REWORKED) { + module_index = 14 + (b->monument.upgrades - 1); + } int module_name = temple_module_options[module_index].option.header; text_draw_centered(translation_for(module_name), c->x_offset, c->y_offset + 12, BLOCK_SIZE * c->width_blocks, FONT_LARGE_BLACK, 0); @@ -782,6 +796,10 @@ static void draw_grand_temple(building_info_context *c, const char *sound_file, if (b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { module_index = 12 + (b->monument.upgrades - 1); } + // Special handling for reworked Ceres temple + if (b->type == BUILDING_GRAND_TEMPLE_CERES_REWORKED) { + module_index = 14 + (b->monument.upgrades - 1); + } int module_desc = temple_module_options[module_index].option.desc; height += text_draw_multiline(translation_for(module_desc), c->x_offset + 22, c->y_offset + 66 + height + extra_y, 15 * c->width_blocks, @@ -1413,6 +1431,10 @@ static void button_add_module_prompt(const generic_button *button) if (b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { option_id = 12; } + // Special handling for reworked Ceres temple + if (b->type == BUILDING_GRAND_TEMPLE_CERES_REWORKED) { + option_id = 14; + } static option_menu_item options[2]; From 3d98dd7cec82c5e50eb93fbb3ebc0d289c036208 Mon Sep 17 00:00:00 2001 From: William Hardy Gest Date: Wed, 18 Feb 2026 18:31:52 -0600 Subject: [PATCH 05/12] Mercury bonuses implemented --- src/building/house_evolution.c | 10 +++++++++- src/building/monument.c | 5 +++++ src/building/monument.h | 2 ++ src/figuretype/trader.c | 16 ++++++++++++---- src/translation/english.c | 10 +++++++--- src/translation/translation.h | 4 ++++ src/window/building/culture.c | 24 +++++++++++++++++++++++- 7 files changed, 62 insertions(+), 9 deletions(-) diff --git a/src/building/house_evolution.c b/src/building/house_evolution.c index 574c18a23b..9188ec6e4c 100644 --- a/src/building/house_evolution.c +++ b/src/building/house_evolution.c @@ -542,13 +542,21 @@ static void consume_resources(building *b) consumption_reduction[RESOURCE_WINE] += 20; consumption_reduction[RESOURCE_OIL] += 20; } - // mars module 2 - all goods reduced by 10% + // mars module 2 - all goods reduced by 10% if (b->data.house.temple_mars && building_monument_gt_module_is_active(MARS_MODULE_2_ALL_GOODS)) { consumption_reduction[RESOURCE_WINE] += 10; consumption_reduction[RESOURCE_OIL] += 10; consumption_reduction[RESOURCE_POTTERY] += 10; consumption_reduction[RESOURCE_FURNITURE] += 10; } + // Mercury Reworked base bonus - all goods reduced by (house happiness / 10)% + if (b->data.house.temple_mercury && building_monument_working(BUILDING_GRAND_TEMPLE_MERCURY_REWORKED)) { + int sentiment_reduction = b->sentiment.house_happiness / 10; // 0-10% based on house happiness + consumption_reduction[RESOURCE_WINE] += sentiment_reduction; + consumption_reduction[RESOURCE_OIL] += sentiment_reduction; + consumption_reduction[RESOURCE_POTTERY] += sentiment_reduction; + consumption_reduction[RESOURCE_FURNITURE] += sentiment_reduction; + } for (resource_type r = RESOURCE_MIN_NON_FOOD; r < RESOURCE_MAX_NON_FOOD; r++) { if (!resource_is_inventory(r)) { diff --git a/src/building/monument.c b/src/building/monument.c index 19c375fd64..aa78f5bdbe 100644 --- a/src/building/monument.c +++ b/src/building/monument.c @@ -749,6 +749,11 @@ int building_monument_gt_module_is_active(int module) temple_type = BUILDING_GRAND_TEMPLE_CERES_REWORKED; module_num = (module == CERES_MODULE_3_FARM_SPEED) ? 1 : 2; } + // Special handling for reworked Mercury temple modules + if (module == MERCURY_MODULE_3_LAND_TRADER || module == MERCURY_MODULE_4_SEA_TRADER) { + temple_type = BUILDING_GRAND_TEMPLE_MERCURY_REWORKED; + module_num = (module == MERCURY_MODULE_3_LAND_TRADER) ? 1 : 2; + } return building_monument_module_type(temple_type) == module_num; } diff --git a/src/building/monument.h b/src/building/monument.h index facc32e9ab..8062ffafc7 100644 --- a/src/building/monument.h +++ b/src/building/monument.h @@ -23,6 +23,8 @@ typedef enum { VENUS_MODULE_4_THEATER_TAVERN, CERES_MODULE_3_FARM_SPEED, CERES_MODULE_4_MARKET_SPEED, + MERCURY_MODULE_3_LAND_TRADER, + MERCURY_MODULE_4_SEA_TRADER, PANTHEON_MODULE_1_DESTINATION_PRIESTS, PANTHEON_MODULE_2_HOUSING_EVOLUTION } module_type; diff --git a/src/figuretype/trader.c b/src/figuretype/trader.c index 1058e3ab64..4629cd49ca 100644 --- a/src/figuretype/trader.c +++ b/src/figuretype/trader.c @@ -115,21 +115,29 @@ static void resource_multiplier_reset(void) // Mercury Grand Temple base bonus to trader speed static int trader_bonus_speed(void) { + // Old Mercury grand temple base bonus if (building_monument_working(BUILDING_GRAND_TEMPLE_MERCURY)) { return 25; - } else { - return 0; } + // Mercury Reworked module 1: land trader speed bonus + if (building_monument_gt_module_is_active(MERCURY_MODULE_3_LAND_TRADER)) { + return 20; + } + return 0; } // Neptune Grand Temple base bonus to trader speed static int sea_trader_bonus_speed(void) { + // Neptune grand temple base bonus if (building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE)) { return 25; - } else { - return 0; } + // Mercury Reworked module 2: sea trader speed bonus + if (building_monument_gt_module_is_active(MERCURY_MODULE_4_SEA_TRADER)) { + return 20; + } + return 0; } int figure_create_trade_caravan(int x, int y, int city_id) diff --git a/src/translation/english.c b/src/translation/english.c index 02fd0cb618..74d673ad98 100644 --- a/src/translation/english.c +++ b/src/translation/english.c @@ -212,9 +212,9 @@ static translation_string all_strings[] = { {TR_BUILDING_GRAND_TEMPLE_MARS_BONUS_DESC, "Mars exhorts your citizens to enlist, dispatching recruits to your city's forts, and allowing four additional forts to be built." }, // Note to translators: This one changed from the previous version, please update. {TR_BUILDING_GRAND_TEMPLE_VENUS_BONUS_DESC, "Venus graces your city's gardens, statues and temples to glow with beauty, improving their desirability. Houses also hold more goods, and devolve more slowly." }, // Note to translators: This one changed from the previous version, please update. {TR_BUILDING_GRAND_TEMPLE_VENUS_REWORKED_BONUS_DESC, "Priests of Venus bless houses to glow with additional desirability." }, - {TR_BUILDING_GRAND_TEMPLE_CERES_REWORKED_BONUS_DESC, "Priests of Ceres bless houses to consume less food based on variety available."}, + {TR_BUILDING_GRAND_TEMPLE_CERES_REWORKED_BONUS_DESC, "Houses visited by priests of Ceres consume less total food for each food type provided."}, {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED_BONUS_DESC, "Placeholder bonus description for Neptune."}, - {TR_BUILDING_GRAND_TEMPLE_MERCURY_REWORKED_BONUS_DESC, "Placeholder bonus description for Mercury."}, + {TR_BUILDING_GRAND_TEMPLE_MERCURY_REWORKED_BONUS_DESC, "Houses visited by priests of Mercury will consume fewer goods when sentiment is high."}, {TR_BUILDING_GRAND_TEMPLE_MARS_REWORKED_BONUS_DESC, "Placeholder bonus description for Mars."}, {TR_BUILDING_PANTHEON_REWORKED_BONUS_DESC, "Placeholder bonus description for Pantheon."}, {TR_BUILDING_PANTHEON_BONUS_DESC, "The Pantheon provides access to your citizens to worship all the gods. Annual festivals are also held here, and religious and cultural building levies are reduced by 25%." }, // Note to translators: This one changed from the previous version, please update. @@ -244,10 +244,14 @@ static translation_string all_strings[] = { {TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_2, "Temple of Venus Genetrix" }, {TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_3, "Temple of Venus Cloacina" }, {TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_4, "Temple of Venus Felix" }, - {TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_3, "Temple of Ceres Pervinca" }, + {TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_3, "Temple of Ceres Frugifera" }, {TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_3_DESC, "Farm carts from all farms move 40% faster." }, {TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_4, "Temple of Ceres Abundantia" }, {TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_4_DESC, "Market buyers collecting from granaries and warehouses move 20% faster." }, + {TR_BUILDING_GRAND_TEMPLE_MERCURY_DESC_MODULE_3, "Temple of Mercury Mercator" }, + {TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_3_DESC, "Land traders and caravans move 20% faster." }, + {TR_BUILDING_GRAND_TEMPLE_MERCURY_DESC_MODULE_4, "Temple of Mercury Fortunus" }, + {TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_4_DESC, "Sea traders and ships move 20% faster." }, {TR_BUILDING_PANTHEON_DESC_MODULE_1, "Pantheum Ara Maxima" }, {TR_BUILDING_PANTHEON_DESC_MODULE_2, "Pantheum Roma Aeterna" }, {TR_BUILDING_GRAND_TEMPLE_MENU, "Grand temple" }, diff --git a/src/translation/translation.h b/src/translation/translation.h index 374d67b8c7..eac7a8c851 100644 --- a/src/translation/translation.h +++ b/src/translation/translation.h @@ -244,6 +244,10 @@ typedef enum { TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_3_DESC, TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_4, TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_4_DESC, + TR_BUILDING_GRAND_TEMPLE_MERCURY_DESC_MODULE_3, + TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_3_DESC, + TR_BUILDING_GRAND_TEMPLE_MERCURY_DESC_MODULE_4, + TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_4_DESC, TR_BUILDING_PANTHEON_DESC_MODULE_1, TR_BUILDING_PANTHEON_DESC_MODULE_2, TR_BUILDING_GRAND_TEMPLE_MENU, diff --git a/src/window/building/culture.c b/src/window/building/culture.c index 58c32b686c..9e758886c0 100644 --- a/src/window/building/culture.c +++ b/src/window/building/culture.c @@ -59,7 +59,7 @@ static struct { option_menu_item option; const building_type required_building; const char image_id[32]; -} temple_module_options[16] = { +} temple_module_options[18] = { { { TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_1, TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_1_DESC }, BUILDING_NONE, @@ -139,6 +139,16 @@ static struct { { TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_4, TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_4_DESC }, BUILDING_NONE, "Ceres M2 Icon" + }, + { + { TR_BUILDING_GRAND_TEMPLE_MERCURY_DESC_MODULE_3, TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_3_DESC }, + BUILDING_NONE, + "Merc M Icon" + }, + { + { TR_BUILDING_GRAND_TEMPLE_MERCURY_DESC_MODULE_4, TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_4_DESC }, + BUILDING_NONE, + "Merc M2 Icon" } }; @@ -775,6 +785,10 @@ static void draw_grand_temple(building_info_context *c, const char *sound_file, if (b->type == BUILDING_GRAND_TEMPLE_CERES_REWORKED) { module_index = 14 + (b->monument.upgrades - 1); } + // Special handling for reworked Mercury temple + if (b->type == BUILDING_GRAND_TEMPLE_MERCURY_REWORKED) { + module_index = 18 + (b->monument.upgrades - 1); + } int module_name = temple_module_options[module_index].option.header; text_draw_centered(translation_for(module_name), c->x_offset, c->y_offset + 12, BLOCK_SIZE * c->width_blocks, FONT_LARGE_BLACK, 0); @@ -800,6 +814,10 @@ static void draw_grand_temple(building_info_context *c, const char *sound_file, if (b->type == BUILDING_GRAND_TEMPLE_CERES_REWORKED) { module_index = 14 + (b->monument.upgrades - 1); } + // Special handling for reworked Mercury temple + if (b->type == BUILDING_GRAND_TEMPLE_MERCURY_REWORKED) { + module_index = 18 + (b->monument.upgrades - 1); + } int module_desc = temple_module_options[module_index].option.desc; height += text_draw_multiline(translation_for(module_desc), c->x_offset + 22, c->y_offset + 66 + height + extra_y, 15 * c->width_blocks, @@ -1435,6 +1453,10 @@ static void button_add_module_prompt(const generic_button *button) if (b->type == BUILDING_GRAND_TEMPLE_CERES_REWORKED) { option_id = 14; } + // Special handling for reworked Mercury temple + if (b->type == BUILDING_GRAND_TEMPLE_MERCURY_REWORKED) { + option_id = 18; + } static option_menu_item options[2]; From 4903fda389c9a88072de7662e7471be5cfa3b7a9 Mon Sep 17 00:00:00 2001 From: William Hardy Gest Date: Tue, 10 Mar 2026 17:40:31 -0500 Subject: [PATCH 06/12] Grand temple rework fully implemented --- src/building/building.c | 2 +- src/building/figure.c | 30 ++++++++++++++- src/building/house_evolution.c | 18 +++++++-- src/building/house_population.c | 10 +++++ src/building/monument.c | 23 ++++++++++- src/building/monument.h | 11 +++++- src/city/data.c | 4 +- src/city/data_private.h | 2 + src/city/festival.c | 2 +- src/city/figures.c | 1 + src/city/health.c | 4 ++ src/city/labor.c | 6 +++ src/city/military.c | 2 + src/city/population.c | 42 ++++++++++++++++++++ src/city/ratings.c | 6 +++ src/city/sentiment.c | 17 +++++++++ src/city/sentiment.h | 2 + src/figure/service.c | 10 +++++ src/figuretype/cartpusher.c | 51 +++++++++++++++++++++++-- src/figuretype/service.c | 25 +++++++++++- src/figuretype/soldier.c | 6 +++ src/figuretype/trader.c | 4 +- src/game/tick.c | 10 ++++- src/map/water_supply.c | 11 +++++- src/translation/english.c | 28 ++++++++++---- src/translation/translation.h | 12 ++++++ src/window/building/culture.c | 68 ++++++++++++++++++++++++++++++++- 27 files changed, 377 insertions(+), 30 deletions(-) diff --git a/src/building/building.c b/src/building/building.c index 5edd463a12..84f5369629 100644 --- a/src/building/building.c +++ b/src/building/building.c @@ -937,7 +937,7 @@ int building_get_levy(const building *b) // Pantheon base bonus - if (building_monument_working(BUILDING_PANTHEON) && + if ((building_monument_working(BUILDING_PANTHEON) || building_monument_working(BUILDING_PANTHEON_REWORKED)) && ((b->type >= BUILDING_SMALL_TEMPLE_CERES && b->type <= BUILDING_LARGE_TEMPLE_VENUS) || (b->type >= BUILDING_GRAND_TEMPLE_CERES && b->type <= BUILDING_GRAND_TEMPLE_VENUS) || b->type == BUILDING_ORACLE || b->type == BUILDING_NYMPHAEUM || b->type == BUILDING_SMALL_MAUSOLEUM || diff --git a/src/building/figure.c b/src/building/figure.c index b4ea7ddede..232183b12a 100644 --- a/src/building/figure.c +++ b/src/building/figure.c @@ -1336,11 +1336,26 @@ static void spawn_figure_senate_forum(building *b) set_forum_graphic(b); } check_labor_problem(b); + + map_point road; + int has_road = map_has_road_access(b->x, b->y, b->size, &road); + + // Module 1: Senate sends a roaming Pantheon priest (tracked in figure_id2) + if (b->type == BUILDING_SENATE && has_road && + building_monument_gt_module_is_active(PANTHEON_MODULE_3_SENATE)) { + if (!b->figure_id2 || figure_get(b->figure_id2)->state == FIGURE_STATE_DEAD) { + figure *priest = figure_create(FIGURE_PRIEST, road.x, road.y, DIR_0_TOP); + priest->action_state = FIGURE_ACTION_125_ROAMING; + priest->building_id = b->id; + b->figure_id2 = priest->id; + figure_movement_init_roaming(priest); + } + } + if (has_figure_of_type(b, FIGURE_TAX_COLLECTOR)) { return; } - map_point road; - if (map_has_road_access(b->x, b->y, b->size, &road)) { + if (has_road) { spawn_labor_seeker(b, road.x, road.y, 50); int pct_workers = worker_percentage(b); int spawn_delay; @@ -1612,6 +1627,17 @@ static void spawn_figure_barracks(building *b) spawn_delay += city_data.mess_hall.food_stress_cumulative - 20; } + // Mars Reworked Module 2: barracks trains 12% faster per food type at supply post + if (building_monument_gt_module_is_active(MARS_MODULE_4_BARRACKS_VICTORY)) { + int reduction = 12 * city_data.mess_hall.food_types; + if (reduction > 0) { + spawn_delay = calc_adjust_with_percentage(spawn_delay, 100 - reduction); + if (spawn_delay < 1) { + spawn_delay = 1; + } + } + } + b->figure_spawn_delay++; if (b->figure_spawn_delay > spawn_delay) { b->figure_spawn_delay = 0; diff --git a/src/building/house_evolution.c b/src/building/house_evolution.c index 9188ec6e4c..340ba826e6 100644 --- a/src/building/house_evolution.c +++ b/src/building/house_evolution.c @@ -4,6 +4,7 @@ #include "building/monument.h" #include "building/properties.h" #include "city/houses.h" +#include "city/ratings.h" #include "city/resource.h" #include "core/calc.h" #include "core/config.h" @@ -194,7 +195,8 @@ static int has_required_goods_and_services(building *house, int for_upgrade, int static int check_requirements(building *house, house_demands *demands) { int bonus = 0; - if (building_monument_pantheon_module_is_active(PANTHEON_MODULE_2_HOUSING_EVOLUTION) && house->house_pantheon_access) { + if ((building_monument_pantheon_module_is_active(PANTHEON_MODULE_2_HOUSING_EVOLUTION) || + building_monument_working(BUILDING_PANTHEON_REWORKED)) && house->house_pantheon_access) { bonus++; } int status = check_evolve_desirability(house, bonus); @@ -506,7 +508,8 @@ static int evolve_large_palace(building *house, house_demands *demands) static int evolve_luxury_palace(building *house, house_demands *demands) { - int bonus = (int) (building_monument_pantheon_module_is_active(PANTHEON_MODULE_2_HOUSING_EVOLUTION) && house->house_pantheon_access); + int bonus = (int) ((building_monument_pantheon_module_is_active(PANTHEON_MODULE_2_HOUSING_EVOLUTION) || + building_monument_working(BUILDING_PANTHEON_REWORKED)) && house->house_pantheon_access); int status = check_evolve_desirability(house, bonus); if (!has_required_goods_and_services(house, 0, bonus, demands)) { status = DEVOLVE; @@ -557,6 +560,14 @@ static void consume_resources(building *b) consumption_reduction[RESOURCE_POTTERY] += sentiment_reduction; consumption_reduction[RESOURCE_FURNITURE] += sentiment_reduction; } + // Mercury Reworked module 4 bonus - all goods reduced by (city prosperity / 10)% + if (b->data.house.temple_mercury && building_monument_gt_module_is_active(MERCURY_MODULE_4_PROSPERITY)) { + int prosperity_reduction = city_rating_prosperity() / 10; + consumption_reduction[RESOURCE_WINE] += prosperity_reduction; + consumption_reduction[RESOURCE_OIL] += prosperity_reduction; + consumption_reduction[RESOURCE_POTTERY] += prosperity_reduction; + consumption_reduction[RESOURCE_FURNITURE] += prosperity_reduction; + } for (resource_type r = RESOURCE_MIN_NON_FOOD; r < RESOURCE_MAX_NON_FOOD; r++) { if (!resource_is_inventory(r)) { @@ -617,7 +628,8 @@ void building_house_process_evolve_and_consume_goods(void) void building_house_determine_evolve_text(building *house, int worst_desirability_building) { int level = house->subtype.house_level; - if (building_monument_pantheon_module_is_active(PANTHEON_MODULE_2_HOUSING_EVOLUTION) && house->house_pantheon_access) { + if ((building_monument_pantheon_module_is_active(PANTHEON_MODULE_2_HOUSING_EVOLUTION) || + building_monument_working(BUILDING_PANTHEON_REWORKED)) && house->house_pantheon_access) { level--; } level = calc_bound(level, HOUSE_MIN, HOUSE_MAX); diff --git a/src/building/house_population.c b/src/building/house_population.c index 4b10364a58..8ea870e5dc 100644 --- a/src/building/house_population.c +++ b/src/building/house_population.c @@ -66,6 +66,16 @@ int house_population_get_capacity(building *house) house->data.house.temple_neptune) { max_pop += (max_pop + 1) / 20; } + // Pantheon Reworked Module 2: Luxury Palaces +10% capacity + if (building_monument_gt_module_is_active(PANTHEON_MODULE_4_LUXURY_PALACE) && + house->type == BUILDING_HOUSE_LUXURY_PALACE) { + max_pop += max_pop / 10; + } + // Mars Reworked base: +5% capacity for houses with Mars temple access + if (building_monument_working(BUILDING_GRAND_TEMPLE_MARS_REWORKED) && + house->data.house.temple_mars) { + max_pop += (max_pop + 1) / 20; + } return max_pop; } diff --git a/src/building/monument.c b/src/building/monument.c index aa78f5bdbe..4389b824ef 100644 --- a/src/building/monument.c +++ b/src/building/monument.c @@ -453,6 +453,12 @@ int building_monument_get_neptune_gt(void) return monument ? monument->id : 0; } +int building_monument_get_neptune_reworked_gt(void) +{ + building *monument = building_first_of_type(BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED); + return monument ? monument->id : 0; +} + int building_monument_phases(building_type type) { return MONUMENT_TYPES[type] ? MONUMENT_TYPES[type]->phases : 0; @@ -750,10 +756,25 @@ int building_monument_gt_module_is_active(int module) module_num = (module == CERES_MODULE_3_FARM_SPEED) ? 1 : 2; } // Special handling for reworked Mercury temple modules - if (module == MERCURY_MODULE_3_LAND_TRADER || module == MERCURY_MODULE_4_SEA_TRADER) { + if (module == MERCURY_MODULE_3_LAND_TRADER || module == MERCURY_MODULE_4_PROSPERITY) { temple_type = BUILDING_GRAND_TEMPLE_MERCURY_REWORKED; module_num = (module == MERCURY_MODULE_3_LAND_TRADER) ? 1 : 2; } + // Special handling for reworked Neptune temple modules + if (module == NEPTUNE_MODULE_3_FOUNTAIN_RESERVOIR || module == NEPTUNE_MODULE_4_SEA_TRADE) { + temple_type = BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED; + module_num = (module == NEPTUNE_MODULE_3_FOUNTAIN_RESERVOIR) ? 1 : 2; + } + // Special handling for reworked Pantheon modules + if (module == PANTHEON_MODULE_3_SENATE || module == PANTHEON_MODULE_4_LUXURY_PALACE) { + temple_type = BUILDING_PANTHEON_REWORKED; + module_num = (module == PANTHEON_MODULE_3_SENATE) ? 1 : 2; + } + // Special handling for reworked Mars temple modules + if (module == MARS_MODULE_3_SUPPLY_CHAIN || module == MARS_MODULE_4_BARRACKS_VICTORY) { + temple_type = BUILDING_GRAND_TEMPLE_MARS_REWORKED; + module_num = (module == MARS_MODULE_3_SUPPLY_CHAIN) ? 1 : 2; + } return building_monument_module_type(temple_type) == module_num; } diff --git a/src/building/monument.h b/src/building/monument.h index 8062ffafc7..1cd40dbef2 100644 --- a/src/building/monument.h +++ b/src/building/monument.h @@ -24,9 +24,15 @@ typedef enum { CERES_MODULE_3_FARM_SPEED, CERES_MODULE_4_MARKET_SPEED, MERCURY_MODULE_3_LAND_TRADER, - MERCURY_MODULE_4_SEA_TRADER, + MERCURY_MODULE_4_PROSPERITY, + NEPTUNE_MODULE_3_FOUNTAIN_RESERVOIR, + NEPTUNE_MODULE_4_SEA_TRADE, PANTHEON_MODULE_1_DESTINATION_PRIESTS, - PANTHEON_MODULE_2_HOUSING_EVOLUTION + PANTHEON_MODULE_2_HOUSING_EVOLUTION, + PANTHEON_MODULE_3_SENATE, + PANTHEON_MODULE_4_LUXURY_PALACE, + MARS_MODULE_3_SUPPLY_CHAIN, + MARS_MODULE_4_BARRACKS_VICTORY } module_type; int building_monument_access_point(building *b, map_point *dst); @@ -63,6 +69,7 @@ void building_monument_finish_monuments(void); void building_monuments_set_construction_phase(int phase); int building_monument_get_venus_gt(void); int building_monument_get_neptune_gt(void); +int building_monument_get_neptune_reworked_gt(void); void building_monument_initialize_deliveries(void); int building_monument_count_grand_temples(void); void building_monument_delivery_save_state(buffer *list); diff --git a/src/city/data.c b/src/city/data.c index dad1e3d6ec..99696b3f08 100644 --- a/src/city/data.c +++ b/src/city/data.c @@ -489,6 +489,7 @@ static void save_main_data(buffer *main) buffer_write_i32(main, city_data.mission.tutorial_fire_message_shown); buffer_write_i32(main, city_data.mission.tutorial_disease_message_shown); buffer_write_i32(main, city_data.figure.attacking_natives); + buffer_write_i8(main, city_data.sentiment.mars_victory_boost); } static void load_main_data(buffer *main, int version) @@ -1013,8 +1014,9 @@ static void load_main_data(buffer *main, int version) city_data.mission.tutorial_fire_message_shown = buffer_read_i32(main); city_data.mission.tutorial_disease_message_shown = buffer_read_i32(main); city_data.figure.attacking_natives = buffer_read_i32(main); + city_data.sentiment.mars_victory_boost = buffer_read_i8(main); if (!discard_unused_values) { - buffer_skip(main, 232); + buffer_skip(main, 231); } if (!has_separate_import_limits) { for (int i = RESOURCE_MIN; i < RESOURCE_MAX_LEGACY; i++) { diff --git a/src/city/data_private.h b/src/city/data_private.h index 205bbe2824..8feb6b1284 100644 --- a/src/city/data_private.h +++ b/src/city/data_private.h @@ -33,6 +33,7 @@ extern struct city_data_t { int16_t animals; int32_t attacking_natives; int32_t enemies; + int8_t had_enemies_this_month; int32_t imperial_soldiers; int32_t rioters; int32_t robbers; @@ -209,6 +210,7 @@ extern struct city_data_t { int32_t wages; int32_t low_mood_cause; int16_t blessing_festival_boost; + int8_t mars_victory_boost; int32_t protesters; int32_t criminals; // muggers+rioters diff --git a/src/city/festival.c b/src/city/festival.c index d78be30526..f95fc62e9f 100644 --- a/src/city/festival.c +++ b/src/city/festival.c @@ -220,7 +220,7 @@ void city_festival_update(void) } } - if (building_monument_working(BUILDING_PANTHEON)) { + if (building_monument_working(BUILDING_PANTHEON) || building_monument_working(BUILDING_PANTHEON_REWORKED)) { for (int god = 0; god <= 4; ++god) { if (game_time_total_years() % 5 == god && game_time_month() == autofestivals[god].month) { throw_auto_festival(god); diff --git a/src/city/figures.c b/src/city/figures.c index df791edfa5..d0170d998b 100644 --- a/src/city/figures.c +++ b/src/city/figures.c @@ -32,6 +32,7 @@ void city_figures_add_attacking_native(void) void city_figures_add_enemy(void) { city_data.figure.enemies++; + city_data.figure.had_enemies_this_month = 1; } void city_figures_add_imperial_soldier(void) diff --git a/src/city/health.c b/src/city/health.c index 488fec529b..1176c55b2a 100644 --- a/src/city/health.c +++ b/src/city/health.c @@ -264,6 +264,10 @@ static void adjust_sickness_level_in_house(building *b, int health, int populati if (building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE)) { delta -= 5; } + // Neptune Reworked GT reduces the delta by 5 for houses with Neptune access + if (building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED) && b->data.house.temple_neptune) { + delta -= 5; + } // If delta is positive, it is reduced depending on house health, global health and hospital access if (delta > 0) { diff --git a/src/city/labor.c b/src/city/labor.c index 451c74f7fa..c12c2e6b5d 100644 --- a/src/city/labor.c +++ b/src/city/labor.c @@ -1,6 +1,7 @@ #include "labor.h" #include "building/building.h" +#include "building/count.h" #include "building/monument.h" #include "building/properties.h" #include "core/config.h" @@ -231,6 +232,11 @@ void city_labor_calculate_workers(int num_plebs, int num_patricians) city_data.labor.workers_available = calc_adjust_with_percentage( city_data.population.working_age, city_data.population.percentage_plebs); } + // Pantheon Reworked Module 2: each Luxury Palace grants 30 workers + if (building_monument_gt_module_is_active(PANTHEON_MODULE_4_LUXURY_PALACE)) { + city_data.labor.workers_available += + building_count_active(BUILDING_HOUSE_LUXURY_PALACE) * 30; + } } static int is_industry_disabled(building *b) diff --git a/src/city/military.c b/src/city/military.c index e17ba7de3b..2d34dbfe3c 100644 --- a/src/city/military.c +++ b/src/city/military.c @@ -5,6 +5,7 @@ #include "city/data_private.h" #include "city/message.h" #include "city/ratings.h" +#include "city/sentiment.h" #include "city/resource.h" #include "core/calc.h" #include "empire/city.h" @@ -308,6 +309,7 @@ static void fight_distant_battle(void) building_menu_update(); city_data.distant_battle.won_count++; city_data.distant_battle.city_foreign_months_left = 0; + city_sentiment_apply_mars_victory(); city_data.distant_battle.roman_months_to_travel_back = city_data.distant_battle.roman_months_traveled; } city_data.distant_battle.months_until_battle = 0; diff --git a/src/city/population.c b/src/city/population.c index d7854622af..7781e8bc90 100644 --- a/src/city/population.c +++ b/src/city/population.c @@ -2,7 +2,9 @@ #include "building/building.h" #include "building/house_population.h" +#include "building/monument.h" #include "city/data_private.h" +#include "city/health.h" #include "core/calc.h" #include "core/config.h" #include "core/random.h" @@ -216,6 +218,36 @@ void city_population_remove_for_troop_request(int num_people) recalculate_population(); } +// Neptune Reworked base bonus: extends retirement age by +// ceil(0.5 * (city_health/10) * (neptune_houses / total_houses)) years +static int neptune_reworked_retirement_bonus_years(void) +{ + if (!building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED)) { + return 0; + } + int health_factor = city_health() / 10; + if (health_factor == 0) { + return 0; + } + int neptune_houses = 0; + int total_houses = 0; + for (building_type type = BUILDING_HOUSE_SMALL_TENT; type <= BUILDING_HOUSE_LUXURY_PALACE; type++) { + for (building *b = building_first_of_type(type); b; b = b->next_of_type) { + if (b->state == BUILDING_STATE_IN_USE && b->house_population > 0) { + total_houses++; + if (b->data.house.temple_neptune) { + neptune_houses++; + } + } + } + } + if (neptune_houses == 0 || total_houses == 0) { + return 0; + } + // ceil(health_factor * neptune_houses / (total_houses * 2)) + return (health_factor * neptune_houses + total_houses * 2 - 1) / (total_houses * 2); +} + int city_population_people_of_working_age(void) { int total_working_people = city_population_in_age_decennium(2) + city_population_in_age_decennium(3) @@ -223,6 +255,11 @@ int city_population_people_of_working_age(void) if (config_get(CONFIG_GP_CH_RETIRE_AT_60)) { total_working_people += city_population_in_age_decennium(5); } + int base_retirement = config_get(CONFIG_GP_CH_RETIRE_AT_60) ? 60 : 50; + int health_bonus = neptune_reworked_retirement_bonus_years(); + for (int age = base_retirement; age < base_retirement + health_bonus && age < 100; age++) { + total_working_people += city_population_at_age(age); + } return total_working_people; } @@ -233,6 +270,11 @@ int city_population_retired_people(void) if (config_get(CONFIG_GP_CH_RETIRE_AT_60)) { total_retired_people += city_population_in_age_decennium(5); } + int base_retirement = config_get(CONFIG_GP_CH_RETIRE_AT_60) ? 60 : 50; + int health_bonus = neptune_reworked_retirement_bonus_years(); + for (int age = base_retirement; age < base_retirement + health_bonus && age < 100; age++) { + total_retired_people -= city_population_at_age(age); + } return total_retired_people; } diff --git a/src/city/ratings.c b/src/city/ratings.c index 641524d6cb..2f36956941 100644 --- a/src/city/ratings.c +++ b/src/city/ratings.c @@ -2,6 +2,7 @@ #include "building/building.h" #include "building/count.h" +#include "building/monument.h" #include "building/properties.h" #include "city/culture.h" #include "city/data_private.h" @@ -448,6 +449,11 @@ static void update_culture_rating(void) city_data.ratings.culture += building_count_active(BUILDING_GRAND_TEMPLE_MARS_REWORKED) * MONUMENT_CULTURE_BONUS; city_data.ratings.culture += building_count_active(BUILDING_PANTHEON) * MONUMENT_CULTURE_BONUS; city_data.ratings.culture += building_count_active(BUILDING_PANTHEON_REWORKED) * MONUMENT_CULTURE_BONUS; + // Pantheon Reworked Module 2: each Luxury Palace grants +2 culture + if (building_monument_gt_module_is_active(PANTHEON_MODULE_4_LUXURY_PALACE)) { + city_data.ratings.culture += + building_count_active(BUILDING_HOUSE_LUXURY_PALACE) * 2; + } city_data.ratings.culture += building_count_active(BUILDING_COLOSSEUM) * MONUMENT_CULTURE_BONUS; city_data.ratings.culture += building_count_active(BUILDING_HIPPODROME) * MONUMENT_CULTURE_BONUS; diff --git a/src/city/sentiment.c b/src/city/sentiment.c index 68932cbcfc..c4913970cb 100644 --- a/src/city/sentiment.c +++ b/src/city/sentiment.c @@ -1,6 +1,7 @@ #include "sentiment.h" #include "building/building.h" +#include "building/monument.h" #include "building/properties.h" #include "city/constants.h" #include "city/data_private.h" @@ -165,6 +166,20 @@ void city_sentiment_decrement_blessing_boost(void) city_data.sentiment.blessing_festival_boost = new_sentiment; } +void city_sentiment_apply_mars_victory(void) +{ + if (building_monument_gt_module_is_active(MARS_MODULE_4_BARRACKS_VICTORY)) { + city_data.sentiment.mars_victory_boost = 12; + } +} + +void city_sentiment_decrement_mars_victory_boost(void) +{ + if (city_data.sentiment.mars_victory_boost > 0) { + city_data.sentiment.mars_victory_boost--; + } +} + static int get_games_bonus(void) { int bonus = 0; @@ -273,6 +288,7 @@ void city_sentiment_update(void) int sentiment_contribution_unemployment = get_unemployment_sentiment_modifier(); int average_housing_level = get_average_housing_level(); int blessing_festival_boost = city_data.sentiment.blessing_festival_boost; + int mars_victory_boost = city_data.sentiment.mars_victory_boost; int average_squalor_penalty = 0; int games_bonus = get_games_bonus(); @@ -331,6 +347,7 @@ void city_sentiment_update(void) sentiment += games_bonus; sentiment += blessing_festival_boost; + sentiment += mars_victory_boost; // Change sentiment gradually to the new value int sentiment_delta = sentiment - b->sentiment.house_happiness; diff --git a/src/city/sentiment.h b/src/city/sentiment.h index 3af39bf651..b855a21b2c 100644 --- a/src/city/sentiment.h +++ b/src/city/sentiment.h @@ -26,6 +26,8 @@ void city_sentiment_set_crime_cooldown(void); void city_sentiment_reduce_crime_cooldown(void); int city_sentiment_get_blessing_festival_boost(void); void city_sentiment_decrement_blessing_boost(void); +void city_sentiment_apply_mars_victory(void); +void city_sentiment_decrement_mars_victory_boost(void); void city_sentiment_update(void); diff --git a/src/figure/service.c b/src/figure/service.c index 5bf1f03902..48b38f5504 100644 --- a/src/figure/service.c +++ b/src/figure/service.c @@ -629,6 +629,16 @@ int figure_service_provide_coverage(figure *f) provide_culture(x, y, religion_coverage_venus); provide_culture(x, y, religion_coverage_pantheon); break; + case BUILDING_SENATE: + if (building_monument_gt_module_is_active(PANTHEON_MODULE_3_SENATE)) { + houses_serviced = provide_culture(x, y, religion_coverage_ceres); + provide_culture(x, y, religion_coverage_neptune); + provide_culture(x, y, religion_coverage_mercury); + provide_culture(x, y, religion_coverage_mars); + provide_culture(x, y, religion_coverage_venus); + provide_culture(x, y, religion_coverage_pantheon); + } + break; default: break; } diff --git a/src/figuretype/cartpusher.c b/src/figuretype/cartpusher.c index 9d11387ad9..39150c806e 100644 --- a/src/figuretype/cartpusher.c +++ b/src/figuretype/cartpusher.c @@ -318,6 +318,21 @@ static void update_image(figure *f) } } +static int is_workshop_type(building_type type) +{ + return type == BUILDING_WINE_WORKSHOP || type == BUILDING_OIL_WORKSHOP || + type == BUILDING_WEAPONS_WORKSHOP || type == BUILDING_FURNITURE_WORKSHOP || + type == BUILDING_POTTERY_WORKSHOP || type == BUILDING_BRICKWORKS || + type == BUILDING_CONCRETE_MAKER; +} + +static int is_raw_material_for_workshop(building_type type) +{ + return type == BUILDING_TIMBER_YARD || type == BUILDING_CLAY_PIT || + type == BUILDING_SAND_PIT || type == BUILDING_IRON_MINE || + type == BUILDING_OLIVE_FARM || type == BUILDING_VINES_FARM; +} + static int cartpusher_percentage_speed(figure *f) { // Ceres grand temple base bonus (old temple) @@ -327,9 +342,39 @@ static int cartpusher_percentage_speed(figure *f) if (building_monument_working(BUILDING_GRAND_TEMPLE_CERES)) { return 50; } - // Ceres Reworked module 1: farm cart speed bonus - if (building_monument_gt_module_is_active(CERES_MODULE_3_FARM_SPEED)) { - return 40; + // Ceres Reworked module 3: food farm cart speed bonus (wheat, vegetables, fruit, pig only) + if (src_building_type != BUILDING_OLIVE_FARM && src_building_type != BUILDING_VINES_FARM) { + if (building_monument_gt_module_is_active(CERES_MODULE_3_FARM_SPEED)) { + return 40; + } + } + } + // Mars Reworked Module 1: workshop supply chain speed bonus + if (building_monument_gt_module_is_active(MARS_MODULE_3_SUPPLY_CHAIN)) { + if (is_workshop_type(src_building_type)) { + return 10; + } + if (is_raw_material_for_workshop(src_building_type)) { + if (f->action_state == FIGURE_ACTION_23_CARTPUSHER_DELIVERING_TO_WORKSHOP) { + return 10; + } + if (f->action_state == FIGURE_ACTION_27_CARTPUSHER_RETURNING && + f->last_destinatation_id && + is_workshop_type(building_get(f->last_destinatation_id)->type)) { + return 10; + } + } + if (f->type == FIGURE_WAREHOUSEMAN) { + if (f->action_state == FIGURE_ACTION_51_WAREHOUSEMAN_DELIVERING_RESOURCE && + f->destination_building_id && + is_workshop_type(building_get(f->destination_building_id)->type)) { + return 10; + } + if (f->action_state == FIGURE_ACTION_53_WAREHOUSEMAN_RETURNING_EMPTY && + f->last_destinatation_id && + is_workshop_type(building_get(f->last_destinatation_id)->type)) { + return 10; + } } } return 0; diff --git a/src/figuretype/service.c b/src/figuretype/service.c index a2daee208f..b23384f5a4 100644 --- a/src/figuretype/service.c +++ b/src/figuretype/service.c @@ -2,6 +2,7 @@ #include "assets/assets.h" #include "building/building.h" +#include "building/monument.h" #include "building/market.h" #include "city/buildings.h" #include "city/health.h" @@ -170,9 +171,29 @@ void figure_priest_action(figure *f) { if (f->destination_building_id) { figure_destination_priest_action(f); - } else { - culture_action(f, GROUP_FIGURE_PRIEST); + return; } + building *b = building_get(f->building_id); + f->terrain_usage = TERRAIN_USAGE_ROADS; + f->use_cross_country = 0; + figure_image_increase_offset(f, 12); + + int figure_slot_id = b->figure_id; + int max_roam = 384; + + if (b->type == BUILDING_PANTHEON_REWORKED) { + max_roam = 768; + } else if (b->type == BUILDING_SENATE && + building_monument_gt_module_is_active(PANTHEON_MODULE_3_SENATE)) { + figure_slot_id = b->figure_id2; + } + + f->max_roam_length = max_roam; + if (b->state != BUILDING_STATE_IN_USE || figure_slot_id != f->id) { + f->state = FIGURE_STATE_DEAD; + } + roamer_action(f, 1); + figure_image_update(f, image_group(GROUP_FIGURE_PRIEST)); } void figure_school_child_action(figure *f) diff --git a/src/figuretype/soldier.c b/src/figuretype/soldier.c index 5e5fd0e316..745f4ac6a1 100644 --- a/src/figuretype/soldier.c +++ b/src/figuretype/soldier.c @@ -1,6 +1,8 @@ #include "soldier.h" #include "assets/assets.h" +#include "building/monument.h" +#include "city/data_private.h" #include "city/figures.h" #include "city/games.h" #include "city/map.h" @@ -352,6 +354,10 @@ static int soldier_percentage_speed(figure_type type) } else if (type == FIGURE_FORT_ARCHER) { return 25; } + if (type == FIGURE_FORT_LEGIONARY && + building_monument_gt_module_is_active(MARS_MODULE_3_SUPPLY_CHAIN)) { + return 7 * city_data.mess_hall.food_types; + } return 0; } diff --git a/src/figuretype/trader.c b/src/figuretype/trader.c index 4629cd49ca..c8db82707a 100644 --- a/src/figuretype/trader.c +++ b/src/figuretype/trader.c @@ -133,8 +133,8 @@ static int sea_trader_bonus_speed(void) if (building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE)) { return 25; } - // Mercury Reworked module 2: sea trader speed bonus - if (building_monument_gt_module_is_active(MERCURY_MODULE_4_SEA_TRADER)) { + // Neptune Reworked module 2: sea trader speed bonus + if (building_monument_gt_module_is_active(NEPTUNE_MODULE_4_SEA_TRADE)) { return 20; } return 0; diff --git a/src/game/tick.c b/src/game/tick.c index 740cc17c51..35c4ed4d41 100644 --- a/src/game/tick.c +++ b/src/game/tick.c @@ -16,6 +16,8 @@ #include "building/warehouse.h" #include "city/buildings.h" #include "city/culture.h" +#include "city/data_private.h" +#include "city/figures.h" #include "city/emperor.h" #include "city/festival.h" #include "city/finance.h" @@ -83,6 +85,8 @@ static void advance_month(void) scenario_random_event_process(); city_finance_handle_month_change(); city_resource_consume_food(); + city_sentiment_decrement_blessing_boost(); + city_sentiment_decrement_mars_victory_boost(); scenario_distant_battle_process(); scenario_invasion_process(); scenario_request_process(); @@ -91,7 +95,11 @@ static void advance_month(void) city_victory_update_months_to_govern(); formation_update_monthly_morale_at_rest(); city_message_decrease_delays(); - city_sentiment_decrement_blessing_boost(); + // Mars Reworked Module 2: on-map military victory detection + if (city_data.figure.had_enemies_this_month && city_figures_enemies() == 0) { + city_sentiment_apply_mars_victory(); + } + city_data.figure.had_enemies_this_month = 0; building_industry_advance_stats(); building_industry_start_strikes(); building_trim(); diff --git a/src/map/water_supply.c b/src/map/water_supply.c index 944368190c..6e2ffe09a7 100644 --- a/src/map/water_supply.c +++ b/src/map/water_supply.c @@ -233,6 +233,11 @@ void map_water_supply_update_reservoir_fountain(void) building *b = building_get(building_monument_get_neptune_gt()); map_terrain_add_with_radius(b->x, b->y, 7, map_water_supply_reservoir_radius(), TERRAIN_RESERVOIR_RANGE); } + // Neptune Reworked base bonus - grand temple provides water access like a filled reservoir + if (building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED)) { + building *b = building_get(building_monument_get_neptune_reworked_gt()); + map_terrain_add_with_radius(b->x, b->y, 7, map_water_supply_reservoir_radius(), TERRAIN_RESERVOIR_RANGE); + } // fountains for (building *b = building_first_of_type(BUILDING_FOUNTAIN); b; b = b->next_of_type) { @@ -346,7 +351,8 @@ int map_water_supply_is_building_unnecessary(int building_id, int radius) int map_water_supply_fountain_radius(void) { int radius = scenario_property_climate() == CLIMATE_DESERT ? FOUNTAIN_RADIUS - 1 : FOUNTAIN_RADIUS; - if (building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE)) { + if (building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE) || + building_monument_gt_module_is_active(NEPTUNE_MODULE_3_FOUNTAIN_RESERVOIR)) { radius++; } @@ -356,7 +362,8 @@ int map_water_supply_fountain_radius(void) int map_water_supply_reservoir_radius(void) { int radius = RESERVOIR_RADIUS; - if (building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE)) { + if (building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE) || + building_monument_gt_module_is_active(NEPTUNE_MODULE_3_FOUNTAIN_RESERVOIR)) { radius += 2; } diff --git a/src/translation/english.c b/src/translation/english.c index 74d673ad98..d124b85a6e 100644 --- a/src/translation/english.c +++ b/src/translation/english.c @@ -213,10 +213,10 @@ static translation_string all_strings[] = { {TR_BUILDING_GRAND_TEMPLE_VENUS_BONUS_DESC, "Venus graces your city's gardens, statues and temples to glow with beauty, improving their desirability. Houses also hold more goods, and devolve more slowly." }, // Note to translators: This one changed from the previous version, please update. {TR_BUILDING_GRAND_TEMPLE_VENUS_REWORKED_BONUS_DESC, "Priests of Venus bless houses to glow with additional desirability." }, {TR_BUILDING_GRAND_TEMPLE_CERES_REWORKED_BONUS_DESC, "Houses visited by priests of Ceres consume less total food for each food type provided."}, - {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED_BONUS_DESC, "Placeholder bonus description for Neptune."}, + {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED_BONUS_DESC, "Provides water access like a filled reservoir, and priests prevent disease and extend citizens' working years based on city health."}, {TR_BUILDING_GRAND_TEMPLE_MERCURY_REWORKED_BONUS_DESC, "Houses visited by priests of Mercury will consume fewer goods when sentiment is high."}, - {TR_BUILDING_GRAND_TEMPLE_MARS_REWORKED_BONUS_DESC, "Placeholder bonus description for Mars."}, - {TR_BUILDING_PANTHEON_REWORKED_BONUS_DESC, "Placeholder bonus description for Pantheon."}, + {TR_BUILDING_GRAND_TEMPLE_MARS_REWORKED_BONUS_DESC, "Houses visited by priests of Mars receive a blessing of martial strength, housing 5% more residents." }, + {TR_BUILDING_PANTHEON_REWORKED_BONUS_DESC, "The Pantheon provides all citizens with access to all gods and allows house to evolve one additional step. Annual festivals are held and religious building levies are reduced." }, {TR_BUILDING_PANTHEON_BONUS_DESC, "The Pantheon provides access to your citizens to worship all the gods. Annual festivals are also held here, and religious and cultural building levies are reduced by 25%." }, // Note to translators: This one changed from the previous version, please update. {TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_1_DESC, "Priests reduce food consumption by 20%." }, {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_1_DESC, "Temples produce charioteers for the Hippodrome." }, @@ -245,15 +245,27 @@ static translation_string all_strings[] = { {TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_3, "Temple of Venus Cloacina" }, {TR_BUILDING_GRAND_TEMPLE_VENUS_DESC_MODULE_4, "Temple of Venus Felix" }, {TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_3, "Temple of Ceres Frugifera" }, - {TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_3_DESC, "Farm carts from all farms move 40% faster." }, + {TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_3_DESC, "Farm carts from food farms move much faster." }, {TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_4, "Temple of Ceres Abundantia" }, - {TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_4_DESC, "Market buyers collecting from granaries and warehouses move 20% faster." }, + {TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_4_DESC, "Market buyers collecting from granaries and warehouses move faster." }, {TR_BUILDING_GRAND_TEMPLE_MERCURY_DESC_MODULE_3, "Temple of Mercury Mercator" }, - {TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_3_DESC, "Land traders and caravans move 20% faster." }, - {TR_BUILDING_GRAND_TEMPLE_MERCURY_DESC_MODULE_4, "Temple of Mercury Fortunus" }, - {TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_4_DESC, "Sea traders and ships move 20% faster." }, + {TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_3_DESC, "Land traders and caravans move faster." }, + {TR_BUILDING_GRAND_TEMPLE_MERCURY_DESC_MODULE_4, "Temple of Mercury Opulentus" }, + {TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_4_DESC, "Goods consumption is reduced citywide based on Prosperity." }, + {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_DESC_MODULE_3, "Temple of Neptunus Adiutor" }, + {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_3_DESC, "Fountain and reservoir range is increased." }, + {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_DESC_MODULE_4, "Temple of Neptunus Redux" }, + {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_4_DESC, "Sea traders move faster." }, {TR_BUILDING_PANTHEON_DESC_MODULE_1, "Pantheum Ara Maxima" }, {TR_BUILDING_PANTHEON_DESC_MODULE_2, "Pantheum Roma Aeterna" }, + {TR_BUILDING_PANTHEON_DESC_MODULE_3, "Pantheum Imperatorum" }, + {TR_BUILDING_PANTHEON_MODULE_3_DESC, "The Senate also sends a priest of the Pantheon, conveying all of its benefits." }, + {TR_BUILDING_PANTHEON_DESC_MODULE_4, "Pantheum Auratum" }, + {TR_BUILDING_PANTHEON_MODULE_4_DESC, "Luxury palaces house more residents, contribute additional workers to the city, and each grant 2 culture rating." }, + {TR_BUILDING_GRAND_TEMPLE_MARS_DESC_MODULE_3, "Temple of Mars Gradivus" }, + {TR_BUILDING_GRAND_TEMPLE_MARS_MODULE_3_DESC, "Cartpushers supplying workshops move faster. Legionaries march faster for each food type provided at the supply post." }, + {TR_BUILDING_GRAND_TEMPLE_MARS_DESC_MODULE_4, "Temple of Mars Invictus" }, + {TR_BUILDING_GRAND_TEMPLE_MARS_MODULE_4_DESC, "Barracks train troops faster for each food type provided at the supply post. Military victories grant a temporary boost to sentiment." }, {TR_BUILDING_GRAND_TEMPLE_MENU, "Grand temple" }, {TR_BUILDING_WORK_CAMP, "Work camp" }, {TR_BUILDING_WORK_CAMP_DESC, "Laborers gather here to transport materials to construction sites." }, diff --git a/src/translation/translation.h b/src/translation/translation.h index eac7a8c851..ced200199c 100644 --- a/src/translation/translation.h +++ b/src/translation/translation.h @@ -248,8 +248,20 @@ typedef enum { TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_3_DESC, TR_BUILDING_GRAND_TEMPLE_MERCURY_DESC_MODULE_4, TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_4_DESC, + TR_BUILDING_GRAND_TEMPLE_NEPTUNE_DESC_MODULE_3, + TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_3_DESC, + TR_BUILDING_GRAND_TEMPLE_NEPTUNE_DESC_MODULE_4, + TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_4_DESC, TR_BUILDING_PANTHEON_DESC_MODULE_1, TR_BUILDING_PANTHEON_DESC_MODULE_2, + TR_BUILDING_PANTHEON_DESC_MODULE_3, + TR_BUILDING_PANTHEON_MODULE_3_DESC, + TR_BUILDING_PANTHEON_DESC_MODULE_4, + TR_BUILDING_PANTHEON_MODULE_4_DESC, + TR_BUILDING_GRAND_TEMPLE_MARS_DESC_MODULE_3, + TR_BUILDING_GRAND_TEMPLE_MARS_MODULE_3_DESC, + TR_BUILDING_GRAND_TEMPLE_MARS_DESC_MODULE_4, + TR_BUILDING_GRAND_TEMPLE_MARS_MODULE_4_DESC, TR_BUILDING_GRAND_TEMPLE_MENU, TR_BUILDING_ROADBLOCK, TR_BUILDING_ROADBLOCK_DESC, diff --git a/src/window/building/culture.c b/src/window/building/culture.c index 9e758886c0..f74fac0518 100644 --- a/src/window/building/culture.c +++ b/src/window/building/culture.c @@ -59,7 +59,7 @@ static struct { option_menu_item option; const building_type required_building; const char image_id[32]; -} temple_module_options[18] = { +} temple_module_options[24] = { { { TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_1, TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_1_DESC }, BUILDING_NONE, @@ -149,6 +149,36 @@ static struct { { TR_BUILDING_GRAND_TEMPLE_MERCURY_DESC_MODULE_4, TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_4_DESC }, BUILDING_NONE, "Merc M2 Icon" + }, + { + { TR_BUILDING_GRAND_TEMPLE_NEPTUNE_DESC_MODULE_3, TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_3_DESC }, + BUILDING_NONE, + "Nept M Icon" + }, + { + { TR_BUILDING_GRAND_TEMPLE_NEPTUNE_DESC_MODULE_4, TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_4_DESC }, + BUILDING_NONE, + "Nept M2 Icon" + }, + { + { TR_BUILDING_PANTHEON_DESC_MODULE_3, TR_BUILDING_PANTHEON_MODULE_3_DESC }, + BUILDING_NONE, + "Panth M Icon" + }, + { + { TR_BUILDING_PANTHEON_DESC_MODULE_4, TR_BUILDING_PANTHEON_MODULE_4_DESC }, + BUILDING_NONE, + "Panth M2 Icon" + }, + { + { TR_BUILDING_GRAND_TEMPLE_MARS_DESC_MODULE_3, TR_BUILDING_GRAND_TEMPLE_MARS_MODULE_3_DESC }, + BUILDING_NONE, + "Mars M Icon" + }, + { + { TR_BUILDING_GRAND_TEMPLE_MARS_DESC_MODULE_4, TR_BUILDING_GRAND_TEMPLE_MARS_MODULE_4_DESC }, + BUILDING_NONE, + "Mars M2 Icon" } }; @@ -789,6 +819,18 @@ static void draw_grand_temple(building_info_context *c, const char *sound_file, if (b->type == BUILDING_GRAND_TEMPLE_MERCURY_REWORKED) { module_index = 18 + (b->monument.upgrades - 1); } + // Special handling for reworked Neptune temple + if (b->type == BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED) { + module_index = 16 + (b->monument.upgrades - 1); + } + // Special handling for reworked Pantheon + if (b->type == BUILDING_PANTHEON_REWORKED) { + module_index = 20 + (b->monument.upgrades - 1); + } + // Special handling for reworked Mars temple + if (b->type == BUILDING_GRAND_TEMPLE_MARS_REWORKED) { + module_index = 22 + (b->monument.upgrades - 1); + } int module_name = temple_module_options[module_index].option.header; text_draw_centered(translation_for(module_name), c->x_offset, c->y_offset + 12, BLOCK_SIZE * c->width_blocks, FONT_LARGE_BLACK, 0); @@ -818,6 +860,18 @@ static void draw_grand_temple(building_info_context *c, const char *sound_file, if (b->type == BUILDING_GRAND_TEMPLE_MERCURY_REWORKED) { module_index = 18 + (b->monument.upgrades - 1); } + // Special handling for reworked Neptune temple + if (b->type == BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED) { + module_index = 16 + (b->monument.upgrades - 1); + } + // Special handling for reworked Pantheon + if (b->type == BUILDING_PANTHEON_REWORKED) { + module_index = 20 + (b->monument.upgrades - 1); + } + // Special handling for reworked Mars temple + if (b->type == BUILDING_GRAND_TEMPLE_MARS_REWORKED) { + module_index = 22 + (b->monument.upgrades - 1); + } int module_desc = temple_module_options[module_index].option.desc; height += text_draw_multiline(translation_for(module_desc), c->x_offset + 22, c->y_offset + 66 + height + extra_y, 15 * c->width_blocks, @@ -1457,6 +1511,18 @@ static void button_add_module_prompt(const generic_button *button) if (b->type == BUILDING_GRAND_TEMPLE_MERCURY_REWORKED) { option_id = 18; } + // Special handling for reworked Neptune temple + if (b->type == BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED) { + option_id = 16; + } + // Special handling for reworked Pantheon + if (b->type == BUILDING_PANTHEON_REWORKED) { + option_id = 20; + } + // Special handling for reworked Mars temple + if (b->type == BUILDING_GRAND_TEMPLE_MARS_REWORKED) { + option_id = 22; + } static option_menu_item options[2]; From 4f218034556c164d72baeccd281bac4f9aabfff1 Mon Sep 17 00:00:00 2001 From: William Hardy Gest Date: Sat, 14 Mar 2026 11:17:47 -0500 Subject: [PATCH 07/12] First cleanup pass --- src/building/monument.c | 42 ++++--------- src/game/cheats.c | 112 +++++++++++++++++++++++++++++++++- src/map/water_supply.c | 2 +- src/translation/english.c | 2 + src/translation/translation.h | 2 + src/window/building_info.c | 10 ++- 6 files changed, 136 insertions(+), 34 deletions(-) diff --git a/src/building/monument.c b/src/building/monument.c index 4389b824ef..945f792da2 100644 --- a/src/building/monument.c +++ b/src/building/monument.c @@ -745,35 +745,19 @@ int building_monument_gt_module_is_active(int module) int module_num = module % MODULES_PER_TEMPLE + 1; int temple_type = module / MODULES_PER_TEMPLE + BUILDING_GRAND_TEMPLE_CERES; - // Special handling for reworked Venus temple modules - if (module == VENUS_MODULE_3_WINE_TEMPLE || module == VENUS_MODULE_4_THEATER_TAVERN) { - temple_type = BUILDING_GRAND_TEMPLE_VENUS_REWORKED; - module_num = (module == VENUS_MODULE_3_WINE_TEMPLE) ? 1 : 2; - } - // Special handling for reworked Ceres temple modules - if (module == CERES_MODULE_3_FARM_SPEED || module == CERES_MODULE_4_MARKET_SPEED) { - temple_type = BUILDING_GRAND_TEMPLE_CERES_REWORKED; - module_num = (module == CERES_MODULE_3_FARM_SPEED) ? 1 : 2; - } - // Special handling for reworked Mercury temple modules - if (module == MERCURY_MODULE_3_LAND_TRADER || module == MERCURY_MODULE_4_PROSPERITY) { - temple_type = BUILDING_GRAND_TEMPLE_MERCURY_REWORKED; - module_num = (module == MERCURY_MODULE_3_LAND_TRADER) ? 1 : 2; - } - // Special handling for reworked Neptune temple modules - if (module == NEPTUNE_MODULE_3_FOUNTAIN_RESERVOIR || module == NEPTUNE_MODULE_4_SEA_TRADE) { - temple_type = BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED; - module_num = (module == NEPTUNE_MODULE_3_FOUNTAIN_RESERVOIR) ? 1 : 2; - } - // Special handling for reworked Pantheon modules - if (module == PANTHEON_MODULE_3_SENATE || module == PANTHEON_MODULE_4_LUXURY_PALACE) { - temple_type = BUILDING_PANTHEON_REWORKED; - module_num = (module == PANTHEON_MODULE_3_SENATE) ? 1 : 2; - } - // Special handling for reworked Mars temple modules - if (module == MARS_MODULE_3_SUPPLY_CHAIN || module == MARS_MODULE_4_BARRACKS_VICTORY) { - temple_type = BUILDING_GRAND_TEMPLE_MARS_REWORKED; - module_num = (module == MARS_MODULE_3_SUPPLY_CHAIN) ? 1 : 2; + if (module >= VENUS_MODULE_3_WINE_TEMPLE) { + static const building_type reworked_temples[] = { + BUILDING_GRAND_TEMPLE_VENUS_REWORKED, // 10, 11 + BUILDING_GRAND_TEMPLE_CERES_REWORKED, // 12, 13 + BUILDING_GRAND_TEMPLE_MERCURY_REWORKED, // 14, 15 + BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED, // 16, 17 + BUILDING_NONE, // 18, 19 (Pantheon original — unused here) + BUILDING_PANTHEON_REWORKED, // 20, 21 + BUILDING_GRAND_TEMPLE_MARS_REWORKED, // 22, 23 + }; + int idx = (module - VENUS_MODULE_3_WINE_TEMPLE) / MODULES_PER_TEMPLE; + temple_type = reworked_temples[idx]; + module_num = (module - VENUS_MODULE_3_WINE_TEMPLE) % MODULES_PER_TEMPLE + 1; } return building_monument_module_type(temple_type) == module_num; diff --git a/src/game/cheats.c b/src/game/cheats.c index a84e5522e0..1a6584421b 100644 --- a/src/game/cheats.c +++ b/src/game/cheats.c @@ -8,6 +8,7 @@ #include "city/gods.h" #include "city/finance.h" #include "city/data_private.h" +#include "city/health.h" #include "city/sentiment.h" #include "city/victory.h" #include "city/warning.h" @@ -32,8 +33,10 @@ #include "window/console.h" #include "window/editor/attributes.h" #include "window/editor/scenario_events.h" +#include "map/water_supply.h" #include "window/plain_message_dialog.h" +#include #include static int map_editor_warning_shown; @@ -57,6 +60,7 @@ static void game_cheat_disable_invasions(uint8_t *); static void game_cheat_change_weather(uint8_t *); static void game_cheat_destroy_building(uint8_t *); static void game_cheat_enable_legacy_venus(uint8_t *); +static void game_cheat_show_gt_bonuses(uint8_t *); static void (*const execute_command[])(uint8_t *args) = { game_cheat_add_money, @@ -79,7 +83,8 @@ static void (*const execute_command[])(uint8_t *args) = { game_cheat_disable_invasions, game_cheat_change_weather, game_cheat_destroy_building, - game_cheat_enable_legacy_venus + game_cheat_enable_legacy_venus, + game_cheat_show_gt_bonuses }; static const char *commands[] = { @@ -103,7 +108,8 @@ static const char *commands[] = { "leavemealone", "weather", // syntax: weather "destroy", // syntax: destroy - "genetrix" + "genetrix", + "gtbonus" }; #define NUMBER_OF_COMMANDS sizeof (commands) / sizeof (commands[0]) @@ -432,3 +438,105 @@ int game_cheat_legacy_gts_enabled(void) { return data.legacy_gts_enabled; } + +static void game_cheat_show_gt_bonuses(uint8_t *args) +{ + if (!data.is_cheating) { + return; + } + + static uint8_t lines[14][80]; + static const uint8_t *texts[14]; + int n = 0; + + // Venus Reworked + { + int working = building_monument_working(BUILDING_GRAND_TEMPLE_VENUS_REWORKED); + int mod = building_monument_module_type(BUILDING_GRAND_TEMPLE_VENUS_REWORKED); + const char *mod_name = mod == 1 ? "Wine Temple" : mod == 2 ? "Theater+Tavern" : "none"; + snprintf((char *) lines[n], 80, "Venus: %s | Module: %s", + working ? "ACTIVE" : "off", mod_name); + texts[n] = lines[n]; n++; + snprintf((char *) lines[n], 80, " Base: +desirability to nearby houses%s", + working ? "" : " (inactive)"); + texts[n] = lines[n]; n++; + } + // Ceres Reworked + { + int working = building_monument_working(BUILDING_GRAND_TEMPLE_CERES_REWORKED); + int mod = building_monument_module_type(BUILDING_GRAND_TEMPLE_CERES_REWORKED); + const char *mod_name = mod == 1 ? "Farm Speed +40%" : mod == 2 ? "Market Speed +20%" : "none"; + int food_types = city_data.resource.food_types_eaten; + snprintf((char *) lines[n], 80, "Ceres: %s | Module: %s", + working ? "ACTIVE" : "off", mod_name); + texts[n] = lines[n]; n++; + snprintf((char *) lines[n], 80, " Base: -%d%% food consumed (%d food types eaten)", + 5 * food_types, food_types); + texts[n] = lines[n]; n++; + } + // Mercury Reworked + { + int working = building_monument_working(BUILDING_GRAND_TEMPLE_MERCURY_REWORKED); + int mod = building_monument_module_type(BUILDING_GRAND_TEMPLE_MERCURY_REWORKED); + const char *mod_name = mod == 1 ? "Land Trader +20%" : mod == 2 ? "Prosperity" : "none"; + int sentiment = city_data.sentiment.value; + snprintf((char *) lines[n], 80, "Mercury: %s | Module: %s", + working ? "ACTIVE" : "off", mod_name); + texts[n] = lines[n]; n++; + snprintf((char *) lines[n], 80, " Base: -%d%% goods consumed (sentiment=%d)", + sentiment / 10, sentiment); + texts[n] = lines[n]; n++; + } + // Neptune Reworked + { + int working = building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED); + int mod = building_monument_module_type(BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED); + if (mod == 1) { + snprintf((char *) lines[n], 80, "Neptune: %s | Fountain r=%d Reservoir r=%d", + working ? "ACTIVE" : "off", + map_water_supply_fountain_radius(), map_water_supply_reservoir_radius()); + } else { + snprintf((char *) lines[n], 80, "Neptune: %s | Module: %s", + working ? "ACTIVE" : "off", mod == 2 ? "Sea Trade +20%" : "none"); + } + texts[n] = lines[n]; n++; + snprintf((char *) lines[n], 80, " Base: -5 disease delta (health=%d)", + city_health()); + texts[n] = lines[n]; n++; + } + // Pantheon Reworked + { + int working = building_monument_working(BUILDING_PANTHEON_REWORKED); + int mod = building_monument_module_type(BUILDING_PANTHEON_REWORKED); + const char *mod_name = mod == 1 ? "Senate priests" : mod == 2 ? "Luxury Palace +10%" : "none"; + snprintf((char *) lines[n], 80, "Pantheon: %s | Module: %s", + working ? "ACTIVE" : "off", mod_name); + texts[n] = lines[n]; n++; + snprintf((char *) lines[n], 80, " Base: all-god access + house evo bonus%s", + working ? "" : " (inactive)"); + texts[n] = lines[n]; n++; + } + // Mars Reworked + { + int working = building_monument_working(BUILDING_GRAND_TEMPLE_MARS_REWORKED); + int mod = building_monument_module_type(BUILDING_GRAND_TEMPLE_MARS_REWORKED); + int foods = city_data.mess_hall.food_types; + int boost = city_data.sentiment.mars_victory_boost; + if (mod == 1) { + snprintf((char *) lines[n], 80, "Mars: %s | Supply Chain | leg +%d%% (%d foods)", + working ? "ACTIVE" : "off", 7 * foods, foods); + } else if (mod == 2) { + snprintf((char *) lines[n], 80, "Mars: %s | Barracks -%d%% delay | victory=%d", + working ? "ACTIVE" : "off", 12 * foods, boost); + } else { + snprintf((char *) lines[n], 80, "Mars: %s | no module | foods=%d victory_boost=%d", + working ? "ACTIVE" : "off", foods, boost); + } + texts[n] = lines[n]; n++; + snprintf((char *) lines[n], 80, " Base: +5%% pop capacity (houses w/ Mars access)%s", + working ? "" : " (inactive)"); + texts[n] = lines[n]; n++; + } + + window_plain_message_dialog_show_text_list(TR_CHEAT_GT_BONUSES_TITLE, TR_CHEAT_GT_BONUSES_TEXT, texts, n); +} diff --git a/src/map/water_supply.c b/src/map/water_supply.c index 6e2ffe09a7..a7cc2f5c63 100644 --- a/src/map/water_supply.c +++ b/src/map/water_supply.c @@ -233,7 +233,7 @@ void map_water_supply_update_reservoir_fountain(void) building *b = building_get(building_monument_get_neptune_gt()); map_terrain_add_with_radius(b->x, b->y, 7, map_water_supply_reservoir_radius(), TERRAIN_RESERVOIR_RANGE); } - // Neptune Reworked base bonus - grand temple provides water access like a filled reservoir + // Neptune Reworked base bonus if (building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED)) { building *b = building_get(building_monument_get_neptune_reworked_gt()); map_terrain_add_with_radius(b->x, b->y, 7, map_water_supply_reservoir_radius(), TERRAIN_RESERVOIR_RANGE); diff --git a/src/translation/english.c b/src/translation/english.c index d124b85a6e..32cce91fe8 100644 --- a/src/translation/english.c +++ b/src/translation/english.c @@ -1947,6 +1947,8 @@ static translation_string all_strings[] = { {TR_BUILDING_HOUSE_LUXURY_PALACE, "Luxury Palace"}, {TR_CONFIG_UI_BUILD_SHOW_RESERVOIR_RANGES, "Show reservoir range when building fountains"}, {TR_CHEAT_DESTROYED_BUILDING, "Destroyed building"}, + {TR_CHEAT_GT_BONUSES_TITLE, "Grand Temple Bonuses"}, + {TR_CHEAT_GT_BONUSES_TEXT, ""}, {TR_CONFIG_ENABLE_BUILD_MENU_SHORTCUTS, "Enable build menu shortcuts"}, {TR_ACTION_TYPE_LOCK_TRADE_ROUTE, "Lock Trade route"}, {TR_PARAMETER_LOCK, "Lock"}, diff --git a/src/translation/translation.h b/src/translation/translation.h index ced200199c..d882a587ba 100644 --- a/src/translation/translation.h +++ b/src/translation/translation.h @@ -1941,6 +1941,8 @@ typedef enum { TR_BUILDING_HOUSE_LUXURY_PALACE, TR_CONFIG_UI_BUILD_SHOW_RESERVOIR_RANGES, TR_CHEAT_DESTROYED_BUILDING, + TR_CHEAT_GT_BONUSES_TITLE, + TR_CHEAT_GT_BONUSES_TEXT, TR_CONFIG_ENABLE_BUILD_MENU_SHORTCUTS, TR_ACTION_TYPE_LOCK_TRADE_ROUTE, TR_PARAMETER_LOCK, diff --git a/src/window/building_info.c b/src/window/building_info.c index 1a4b612ffc..9d40a8851d 100644 --- a/src/window/building_info.c +++ b/src/window/building_info.c @@ -938,7 +938,10 @@ static void draw_foreground(void) } else if (btype == BUILDING_BARRACKS) { window_building_draw_barracks_foreground(&context); } else if ((btype >= BUILDING_GRAND_TEMPLE_CERES && btype <= BUILDING_GRAND_TEMPLE_VENUS) || - btype == BUILDING_PANTHEON || btype == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { + btype == BUILDING_PANTHEON || btype == BUILDING_GRAND_TEMPLE_VENUS_REWORKED || + btype == BUILDING_GRAND_TEMPLE_CERES_REWORKED || btype == BUILDING_GRAND_TEMPLE_MERCURY_REWORKED || + btype == BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED || btype == BUILDING_PANTHEON_REWORKED || + btype == BUILDING_GRAND_TEMPLE_MARS_REWORKED) { window_building_draw_grand_temple_foreground(&context); } else if (btype == BUILDING_CARAVANSERAI && b->monument.phase == MONUMENT_FINISHED) { @@ -1052,7 +1055,10 @@ static int handle_specific_building_info_mouse(const mouse *m) return window_building_handle_mouse_storage(m, &context); } } else if ((btype >= BUILDING_GRAND_TEMPLE_CERES && btype <= BUILDING_GRAND_TEMPLE_VENUS) || - btype == BUILDING_PANTHEON || btype == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { + btype == BUILDING_PANTHEON || btype == BUILDING_GRAND_TEMPLE_VENUS_REWORKED || + btype == BUILDING_GRAND_TEMPLE_CERES_REWORKED || btype == BUILDING_GRAND_TEMPLE_MERCURY_REWORKED || + btype == BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED || btype == BUILDING_PANTHEON_REWORKED || + btype == BUILDING_GRAND_TEMPLE_MARS_REWORKED) { return window_building_handle_mouse_grand_temple(m, &context); } else if (btype == BUILDING_DEPOT) { if (context.depot_selection == 2) { From b88e0ac162950385df6be145865eba4d0998a60c Mon Sep 17 00:00:00 2001 From: William Hardy Gest Date: Sat, 14 Mar 2026 14:42:40 -0500 Subject: [PATCH 08/12] Cleanup and bugfix for ceres and neptune --- src/building/image.c | 23 ++++++- src/city/population.c | 6 +- src/city/population.h | 2 + src/figuretype/trader.c | 9 +++ src/game/cheats.c | 9 ++- src/translation/english.c | 4 +- src/widget/city_overlay_other.c | 3 +- src/widget/city_water_ghost.c | 17 +++-- src/widget/city_without_overlay.c | 6 +- src/window/building/culture.c | 100 +++++++----------------------- 10 files changed, 87 insertions(+), 92 deletions(-) diff --git a/src/building/image.c b/src/building/image.c index 6229178acb..fe9d4c2ed9 100644 --- a/src/building/image.c +++ b/src/building/image.c @@ -603,7 +603,6 @@ int building_image_get(const building *b) } } case BUILDING_GRAND_TEMPLE_NEPTUNE: - case BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED: switch (b->monument.phase) { case MONUMENT_START: return assets_get_image_id("Monuments", "Neptune Complex Const 01"); @@ -625,6 +624,28 @@ int building_image_get(const building *b) return assets_get_image_id("Monuments", "Neptune Complex On"); } } + case BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED: + switch (b->monument.phase) { + case MONUMENT_START: + return assets_get_image_id("Monuments", "Neptune Complex Const 01"); + case 2: + return assets_get_image_id("Monuments", "Neptune Complex Const 02"); + case 3: + return assets_get_image_id("Monuments", "Neptune Complex Const 03"); + case 4: + return assets_get_image_id("Monuments", "Neptune Complex Const 04"); + case 5: + return assets_get_image_id("Monuments", "Neptune Complex Const 05"); + default: + switch (b->monument.upgrades) { + case 1: + return assets_get_image_id("Monuments", "Neptune Complex Module2"); + case 2: + return assets_get_image_id("Monuments", "Neptune Complex Module"); + default: + return assets_get_image_id("Monuments", "Neptune Complex On"); + } + } case BUILDING_GRAND_TEMPLE_MERCURY: case BUILDING_GRAND_TEMPLE_MERCURY_REWORKED: switch (b->monument.phase) { diff --git a/src/city/population.c b/src/city/population.c index 7781e8bc90..499103184c 100644 --- a/src/city/population.c +++ b/src/city/population.c @@ -220,7 +220,7 @@ void city_population_remove_for_troop_request(int num_people) // Neptune Reworked base bonus: extends retirement age by // ceil(0.5 * (city_health/10) * (neptune_houses / total_houses)) years -static int neptune_reworked_retirement_bonus_years(void) +int city_population_neptune_reworked_retirement_bonus_years(void) { if (!building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED)) { return 0; @@ -256,7 +256,7 @@ int city_population_people_of_working_age(void) total_working_people += city_population_in_age_decennium(5); } int base_retirement = config_get(CONFIG_GP_CH_RETIRE_AT_60) ? 60 : 50; - int health_bonus = neptune_reworked_retirement_bonus_years(); + int health_bonus = city_population_neptune_reworked_retirement_bonus_years(); for (int age = base_retirement; age < base_retirement + health_bonus && age < 100; age++) { total_working_people += city_population_at_age(age); } @@ -271,7 +271,7 @@ int city_population_retired_people(void) total_retired_people += city_population_in_age_decennium(5); } int base_retirement = config_get(CONFIG_GP_CH_RETIRE_AT_60) ? 60 : 50; - int health_bonus = neptune_reworked_retirement_bonus_years(); + int health_bonus = city_population_neptune_reworked_retirement_bonus_years(); for (int age = base_retirement; age < base_retirement + health_bonus && age < 100; age++) { total_retired_people -= city_population_at_age(age); } diff --git a/src/city/population.h b/src/city/population.h index dff3e25c2e..cc62366d81 100644 --- a/src/city/population.h +++ b/src/city/population.h @@ -86,4 +86,6 @@ int city_population_percentage_in_tents_shacks(void); int city_population_percentage_in_villas_palaces(void); +int city_population_neptune_reworked_retirement_bonus_years(void); + #endif // CITY_POPULATION_H diff --git a/src/figuretype/trader.c b/src/figuretype/trader.c index c8db82707a..bb56ff63e3 100644 --- a/src/figuretype/trader.c +++ b/src/figuretype/trader.c @@ -1008,6 +1008,10 @@ int figure_trade_land_trade_units(void) unit += add_unit; } + if (building_monument_gt_module_is_active(MERCURY_MODULE_3_LAND_TRADER)) { + unit += 4; + } + if (building_caravanserai_is_fully_functional()) { building *b = building_get(city_buildings_get_caravanserai()); @@ -1030,6 +1034,7 @@ int figure_trade_land_trade_units(void) int figure_trade_sea_trade_units(void) { int unit = 12; + if (building_monument_working(BUILDING_GRAND_TEMPLE_MERCURY)) { int add_unit = 0; building *b = building_get(building_find(BUILDING_GRAND_TEMPLE_MERCURY)); @@ -1043,6 +1048,10 @@ int figure_trade_sea_trade_units(void) unit += add_unit; } + if (building_monument_gt_module_is_active(NEPTUNE_MODULE_4_SEA_TRADE)) { + unit += 4; + } + if (building_lighthouse_is_fully_functional()) { trade_policy policy = city_trade_policy_get(SEA_TRADE_POLICY); diff --git a/src/game/cheats.c b/src/game/cheats.c index 1a6584421b..7d46001a7b 100644 --- a/src/game/cheats.c +++ b/src/game/cheats.c @@ -9,6 +9,7 @@ #include "city/finance.h" #include "city/data_private.h" #include "city/health.h" +#include "city/population.h" #include "city/sentiment.h" #include "city/victory.h" #include "city/warning.h" @@ -478,7 +479,7 @@ static void game_cheat_show_gt_bonuses(uint8_t *args) { int working = building_monument_working(BUILDING_GRAND_TEMPLE_MERCURY_REWORKED); int mod = building_monument_module_type(BUILDING_GRAND_TEMPLE_MERCURY_REWORKED); - const char *mod_name = mod == 1 ? "Land Trader +20%" : mod == 2 ? "Prosperity" : "none"; + const char *mod_name = mod == 1 ? "Land Trader +20spd +4cap" : mod == 2 ? "Prosperity" : "none"; int sentiment = city_data.sentiment.value; snprintf((char *) lines[n], 80, "Mercury: %s | Module: %s", working ? "ACTIVE" : "off", mod_name); @@ -497,10 +498,12 @@ static void game_cheat_show_gt_bonuses(uint8_t *args) map_water_supply_fountain_radius(), map_water_supply_reservoir_radius()); } else { snprintf((char *) lines[n], 80, "Neptune: %s | Module: %s", - working ? "ACTIVE" : "off", mod == 2 ? "Sea Trade +20%" : "none"); + working ? "ACTIVE" : "off", mod == 2 ? "Sea Trade +20spd +4cap" : "none"); } texts[n] = lines[n]; n++; - snprintf((char *) lines[n], 80, " Base: -5 disease delta (health=%d)", + snprintf((char *) lines[n], 80, " Base: -5 disease | retire age %d+%d (health=%d)", + config_get(CONFIG_GP_CH_RETIRE_AT_60) ? 60 : 50, + city_population_neptune_reworked_retirement_bonus_years(), city_health()); texts[n] = lines[n]; n++; } diff --git a/src/translation/english.c b/src/translation/english.c index 32cce91fe8..6da15a2fed 100644 --- a/src/translation/english.c +++ b/src/translation/english.c @@ -249,13 +249,13 @@ static translation_string all_strings[] = { {TR_BUILDING_GRAND_TEMPLE_CERES_DESC_MODULE_4, "Temple of Ceres Abundantia" }, {TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_4_DESC, "Market buyers collecting from granaries and warehouses move faster." }, {TR_BUILDING_GRAND_TEMPLE_MERCURY_DESC_MODULE_3, "Temple of Mercury Mercator" }, - {TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_3_DESC, "Land traders and caravans move faster." }, + {TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_3_DESC, "Land traders and caravans move faster and carry more goods." }, {TR_BUILDING_GRAND_TEMPLE_MERCURY_DESC_MODULE_4, "Temple of Mercury Opulentus" }, {TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_4_DESC, "Goods consumption is reduced citywide based on Prosperity." }, {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_DESC_MODULE_3, "Temple of Neptunus Adiutor" }, {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_3_DESC, "Fountain and reservoir range is increased." }, {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_DESC_MODULE_4, "Temple of Neptunus Redux" }, - {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_4_DESC, "Sea traders move faster." }, + {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_4_DESC, "Sea traders move faster and carry more goods." }, {TR_BUILDING_PANTHEON_DESC_MODULE_1, "Pantheum Ara Maxima" }, {TR_BUILDING_PANTHEON_DESC_MODULE_2, "Pantheum Roma Aeterna" }, {TR_BUILDING_PANTHEON_DESC_MODULE_3, "Pantheum Imperatorum" }, diff --git a/src/widget/city_overlay_other.c b/src/widget/city_overlay_other.c index aa185ac3a3..e7192f816f 100644 --- a/src/widget/city_overlay_other.c +++ b/src/widget/city_overlay_other.c @@ -72,7 +72,8 @@ static int show_building_tax_income(const building *b) static int show_building_water(const building *b) { return b->type == BUILDING_WELL || b->type == BUILDING_FOUNTAIN || b->type == BUILDING_RESERVOIR || - (b->type == BUILDING_GRAND_TEMPLE_NEPTUNE && building_monument_gt_module_is_active(NEPTUNE_MODULE_2_CAPACITY_AND_WATER)); + (b->type == BUILDING_GRAND_TEMPLE_NEPTUNE && building_monument_gt_module_is_active(NEPTUNE_MODULE_2_CAPACITY_AND_WATER)) || + (b->type == BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED && building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED)); } static int show_building_sentiment(const building *b) diff --git a/src/widget/city_water_ghost.c b/src/widget/city_water_ghost.c index 7aab23bb67..29467532a7 100644 --- a/src/widget/city_water_ghost.c +++ b/src/widget/city_water_ghost.c @@ -66,11 +66,17 @@ static void update_reservoir_access(void) } } int neptune_id = building_monument_upgraded(BUILDING_GRAND_TEMPLE_NEPTUNE); - if (!neptune_id) { - return; + if (neptune_id) { + building *b = building_get(neptune_id); + if (b->monument.upgrades == 2) { + city_view_foreach_tile_in_range(b->grid_offset, 7, map_water_supply_reservoir_radius(), set_reservoir_access); + city_view_foreach_tile_in_range(b->grid_offset, 0, 7, set_reservoir_access); // include the Grand Temple tiles + set_reservoir_access(b->x, b->y, b->grid_offset); // include the reservoir main tile + } } - building *b = building_get(neptune_id); - if (b->monument.upgrades == 2) { + int neptune_reworked_id = building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED); + if (neptune_reworked_id) { + building *b = building_get(neptune_reworked_id); city_view_foreach_tile_in_range(b->grid_offset, 7, map_water_supply_reservoir_radius(), set_reservoir_access); city_view_foreach_tile_in_range(b->grid_offset, 0, 7, set_reservoir_access); // include the Grand Temple tiles set_reservoir_access(b->x, b->y, b->grid_offset); // include the reservoir main tile @@ -133,6 +139,9 @@ void city_water_ghost_draw_reservoir_ranges(void) building_monument_module_type(BUILDING_GRAND_TEMPLE_NEPTUNE) == 2) { num_reservoirs++; } + if (building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED)) { + num_reservoirs++; + } if (type != last_reservoir_building_type || num_reservoirs != last_reservoir_count) { update_reservoir_access(); } diff --git a/src/widget/city_without_overlay.c b/src/widget/city_without_overlay.c index a01f7c9a06..e567c5a2b9 100644 --- a/src/widget/city_without_overlay.c +++ b/src/widget/city_without_overlay.c @@ -838,10 +838,12 @@ static void draw_animation(int x, int y, int grid_offset) if (animation_offset > img->animation->num_sprites) { animation_offset = img->animation->num_sprites; } - if (b->type == BUILDING_GRAND_TEMPLE_CERES && b->monument.upgrades == 1) { + if (b->type == BUILDING_GRAND_TEMPLE_CERES && b->monument.upgrades == 1 || + b->type == BUILDING_GRAND_TEMPLE_CERES_REWORKED && b->monument.upgrades == 1) { draw_ceres_module_crops(x + 190, y + 95 - y_offset, b->monument.secondary_frame, color_mask); } - if (b->type == BUILDING_GRAND_TEMPLE_NEPTUNE && b->monument.upgrades == 2) { + if ((b->type == BUILDING_GRAND_TEMPLE_NEPTUNE && b->monument.upgrades == 2) || + b->type == BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED && b->monument.upgrades == 1) { draw_neptune_fountain(x + 98, y + 87 - y_offset, (animation_offset - 1) % 5, color_mask); } if (b->type == BUILDING_GRANARY) { diff --git a/src/window/building/culture.c b/src/window/building/culture.c index f74fac0518..a15f2e24ff 100644 --- a/src/window/building/culture.c +++ b/src/window/building/culture.c @@ -806,31 +806,8 @@ static void draw_grand_temple(building_info_context *c, const char *sound_file, window_building_draw_monument_temple_construction_process(c); } if (b->monument.upgrades) { - int module_index = data.god_id * 2 + (b->monument.upgrades - 1); - // Special handling for reworked Venus temple - if (b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { - module_index = 12 + (b->monument.upgrades - 1); - } - // Special handling for reworked Ceres temple - if (b->type == BUILDING_GRAND_TEMPLE_CERES_REWORKED) { - module_index = 14 + (b->monument.upgrades - 1); - } - // Special handling for reworked Mercury temple - if (b->type == BUILDING_GRAND_TEMPLE_MERCURY_REWORKED) { - module_index = 18 + (b->monument.upgrades - 1); - } - // Special handling for reworked Neptune temple - if (b->type == BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED) { - module_index = 16 + (b->monument.upgrades - 1); - } - // Special handling for reworked Pantheon - if (b->type == BUILDING_PANTHEON_REWORKED) { - module_index = 20 + (b->monument.upgrades - 1); - } - // Special handling for reworked Mars temple - if (b->type == BUILDING_GRAND_TEMPLE_MARS_REWORKED) { - module_index = 22 + (b->monument.upgrades - 1); - } + int reworked_base = reworked_temple_option_id(b->type); + int module_index = (reworked_base >= 0 ? reworked_base : data.god_id * 2) + (b->monument.upgrades - 1); int module_name = temple_module_options[module_index].option.header; text_draw_centered(translation_for(module_name), c->x_offset, c->y_offset + 12, BLOCK_SIZE * c->width_blocks, FONT_LARGE_BLACK, 0); @@ -847,31 +824,8 @@ static void draw_grand_temple(building_info_context *c, const char *sound_file, height = text_draw_multiline(translation_for(bonus_desc), c->x_offset + 22, c->y_offset + 56 + extra_y, 15 * c->width_blocks, 0, FONT_NORMAL_BLACK, 0); if (b->monument.upgrades) { - int module_index = data.god_id * 2 + (b->monument.upgrades - 1); - // Special handling for reworked Venus temple - if (b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { - module_index = 12 + (b->monument.upgrades - 1); - } - // Special handling for reworked Ceres temple - if (b->type == BUILDING_GRAND_TEMPLE_CERES_REWORKED) { - module_index = 14 + (b->monument.upgrades - 1); - } - // Special handling for reworked Mercury temple - if (b->type == BUILDING_GRAND_TEMPLE_MERCURY_REWORKED) { - module_index = 18 + (b->monument.upgrades - 1); - } - // Special handling for reworked Neptune temple - if (b->type == BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED) { - module_index = 16 + (b->monument.upgrades - 1); - } - // Special handling for reworked Pantheon - if (b->type == BUILDING_PANTHEON_REWORKED) { - module_index = 20 + (b->monument.upgrades - 1); - } - // Special handling for reworked Mars temple - if (b->type == BUILDING_GRAND_TEMPLE_MARS_REWORKED) { - module_index = 22 + (b->monument.upgrades - 1); - } + int reworked_base = reworked_temple_option_id(b->type); + int module_index = (reworked_base >= 0 ? reworked_base : data.god_id * 2) + (b->monument.upgrades - 1); int module_desc = temple_module_options[module_index].option.desc; height += text_draw_multiline(translation_for(module_desc), c->x_offset + 22, c->y_offset + 66 + height + extra_y, 15 * c->width_blocks, @@ -1493,36 +1447,30 @@ static void generate_module_image_id(int index) temple_module_options[index].image_id); } +static int reworked_temple_option_id(building_type type) +{ + static const struct { building_type type; int option_id; } reworked_options[] = { + { BUILDING_GRAND_TEMPLE_VENUS_REWORKED, 12 }, + { BUILDING_GRAND_TEMPLE_CERES_REWORKED, 14 }, + { BUILDING_GRAND_TEMPLE_MERCURY_REWORKED, 16 }, + { BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED, 18 }, + { BUILDING_PANTHEON_REWORKED, 20 }, + { BUILDING_GRAND_TEMPLE_MARS_REWORKED, 22 }, + }; + for (int i = 0; i < (int)(sizeof(reworked_options) / sizeof(reworked_options[0])); i++) { + if (reworked_options[i].type == type) { + return reworked_options[i].option_id; + } + } + return -1; +} + static void button_add_module_prompt(const generic_button *button) { int num_options = 0; - int option_id = data.god_id * 2; - - // Special handling for reworked Venus temple building *b = building_get(data.building_id); - if (b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { - option_id = 12; - } - // Special handling for reworked Ceres temple - if (b->type == BUILDING_GRAND_TEMPLE_CERES_REWORKED) { - option_id = 14; - } - // Special handling for reworked Mercury temple - if (b->type == BUILDING_GRAND_TEMPLE_MERCURY_REWORKED) { - option_id = 18; - } - // Special handling for reworked Neptune temple - if (b->type == BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED) { - option_id = 16; - } - // Special handling for reworked Pantheon - if (b->type == BUILDING_PANTHEON_REWORKED) { - option_id = 20; - } - // Special handling for reworked Mars temple - if (b->type == BUILDING_GRAND_TEMPLE_MARS_REWORKED) { - option_id = 22; - } + int reworked_id = reworked_temple_option_id(b->type); + int option_id = reworked_id >= 0 ? reworked_id : data.god_id * 2; static option_menu_item options[2]; From 294a8cd7354ab68c47cad5a666ee9cb50c726976 Mon Sep 17 00:00:00 2001 From: William Hardy Gest Date: Sat, 14 Mar 2026 15:10:29 -0500 Subject: [PATCH 09/12] Fix warnings --- src/figuretype/trader.c | 2 +- src/widget/city_building_ghost.c | 20 ++++++++++++------ src/window/building/culture.c | 35 ++++++++++++++++---------------- 3 files changed, 33 insertions(+), 24 deletions(-) diff --git a/src/figuretype/trader.c b/src/figuretype/trader.c index bb56ff63e3..f27c5857b9 100644 --- a/src/figuretype/trader.c +++ b/src/figuretype/trader.c @@ -1049,7 +1049,7 @@ int figure_trade_sea_trade_units(void) } if (building_monument_gt_module_is_active(NEPTUNE_MODULE_4_SEA_TRADE)) { - unit += 4; + unit += 6; } if (building_lighthouse_is_fully_functional()) { diff --git a/src/widget/city_building_ghost.c b/src/widget/city_building_ghost.c index 550f99dfc7..5922c0eb63 100644 --- a/src/widget/city_building_ghost.c +++ b/src/widget/city_building_ghost.c @@ -1312,9 +1312,9 @@ static void draw_grand_temple_neptune_range(int x, int y, int grid_offset) image_draw(image_group(GROUP_TERRAIN_FLAT_TILE), x, y, COLOR_MASK_BLUE, data.scale); } -static void draw_grand_temple_neptune(const map_tile *tile, int x, int y) +static void draw_grand_temple_neptune_type(const map_tile *tile, int x, int y, building_type type) { - const building_properties *props = building_properties_for_type(BUILDING_GRAND_TEMPLE_NEPTUNE); + const building_properties *props = building_properties_for_type(type); int num_tiles = props->size * props->size; int blocked[MAX_TILES]; if (city_finance_out_of_money() || is_blocked_for_building(tile->grid_offset, props->size, blocked, 1)) { @@ -1322,13 +1322,18 @@ static void draw_grand_temple_neptune(const map_tile *tile, int x, int y) } int radius = map_water_supply_reservoir_radius(); // need to add 2 for the bonus the Neptune GT will add - if (!building_monument_working(BUILDING_GRAND_TEMPLE_NEPTUNE)) { + if (!building_monument_working(type)) { radius += 2; } city_view_foreach_tile_in_range(tile->grid_offset, props->size, radius, draw_grand_temple_neptune_range); - int image_id = get_new_building_image_id(tile->grid_offset, BUILDING_GRAND_TEMPLE_NEPTUNE); - draw_regular_building(BUILDING_GRAND_TEMPLE_NEPTUNE, image_id, x, y, tile->grid_offset, num_tiles, blocked); - set_roamer_path(BUILDING_GRAND_TEMPLE_NEPTUNE, props->size, tile, has_blocked_tiles(num_tiles, blocked)); + int image_id = get_new_building_image_id(tile->grid_offset, type); + draw_regular_building(type, image_id, x, y, tile->grid_offset, num_tiles, blocked); + set_roamer_path(type, props->size, tile, has_blocked_tiles(num_tiles, blocked)); +} + +static void draw_grand_temple_neptune(const map_tile *tile, int x, int y) +{ + draw_grand_temple_neptune_type(tile, x, y, BUILDING_GRAND_TEMPLE_NEPTUNE); } static void draw_concrete_maker(const map_tile *tile, int x, int y) @@ -1635,6 +1640,9 @@ void city_building_ghost_draw(const map_tile *tile) case BUILDING_GRAND_TEMPLE_NEPTUNE: draw_grand_temple_neptune(tile, x, y); break; + case BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED: + draw_grand_temple_neptune_type(tile, x, y, BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED); + break; case BUILDING_LATRINES: draw_latrines(tile, x, y); break; diff --git a/src/window/building/culture.c b/src/window/building/culture.c index a15f2e24ff..00e63dcb13 100644 --- a/src/window/building/culture.c +++ b/src/window/building/culture.c @@ -777,6 +777,24 @@ void window_building_draw_shrine_mars(building_info_context *c) c->x_offset + 180, c->y_offset + 45, COLOR_MASK_NONE, SCALE_NONE); } +static int reworked_temple_option_id(building_type type) +{ + static const struct { building_type type; int option_id; } reworked_options[] = { + { BUILDING_GRAND_TEMPLE_VENUS_REWORKED, 12 }, + { BUILDING_GRAND_TEMPLE_CERES_REWORKED, 14 }, + { BUILDING_GRAND_TEMPLE_MERCURY_REWORKED, 16 }, + { BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED, 18 }, + { BUILDING_PANTHEON_REWORKED, 20 }, + { BUILDING_GRAND_TEMPLE_MARS_REWORKED, 22 }, + }; + for (int i = 0; i < (int)(sizeof(reworked_options) / sizeof(reworked_options[0])); i++) { + if (reworked_options[i].type == type) { + return reworked_options[i].option_id; + } + } + return -1; +} + void window_building_draw_shrine_venus(building_info_context *c) { c->advisor_button = ADVISOR_RELIGION; @@ -1447,23 +1465,6 @@ static void generate_module_image_id(int index) temple_module_options[index].image_id); } -static int reworked_temple_option_id(building_type type) -{ - static const struct { building_type type; int option_id; } reworked_options[] = { - { BUILDING_GRAND_TEMPLE_VENUS_REWORKED, 12 }, - { BUILDING_GRAND_TEMPLE_CERES_REWORKED, 14 }, - { BUILDING_GRAND_TEMPLE_MERCURY_REWORKED, 16 }, - { BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED, 18 }, - { BUILDING_PANTHEON_REWORKED, 20 }, - { BUILDING_GRAND_TEMPLE_MARS_REWORKED, 22 }, - }; - for (int i = 0; i < (int)(sizeof(reworked_options) / sizeof(reworked_options[0])); i++) { - if (reworked_options[i].type == type) { - return reworked_options[i].option_id; - } - } - return -1; -} static void button_add_module_prompt(const generic_button *button) { From 294161940150eb8b28db7b9147d6fc43f3a133b9 Mon Sep 17 00:00:00 2001 From: William Hardy Gest Date: Sat, 14 Mar 2026 20:38:34 -0500 Subject: [PATCH 10/12] First round of testing and tweaks completed --- src/building/house_service.c | 21 +++++++++++----- src/building/monument.c | 14 +++++++++++ src/building/monument.h | 8 +++++++ src/city/labor.c | 4 ++-- src/figure/formation.c | 2 +- src/translation/english.c | 4 +++- src/translation/translation.h | 2 ++ src/window/building/culture.c | 29 ++++++++++++++++++++-- src/window/building/house.c | 45 ++++++++++++++++++++++------------- 9 files changed, 100 insertions(+), 29 deletions(-) diff --git a/src/building/house_service.c b/src/building/house_service.c index 26596fb001..7c01a0d6a4 100644 --- a/src/building/house_service.c +++ b/src/building/house_service.c @@ -79,6 +79,7 @@ void house_service_calculate_culture_aggregates(void) { int venus_module2 = building_monument_gt_module_is_active(VENUS_MODULE_2_DESIRABILITY_ENTERTAINMENT); int venus_module4 = building_monument_gt_module_is_active(VENUS_MODULE_4_THEATER_TAVERN); + venus_m4_variant venus_m4_type = venus_module4 ? building_monument_venus_m4_variant() : VENUS_M4_THEATER_TAVERN; int completed_colosseum = building_monument_working(BUILDING_COLOSSEUM); int completed_hippodrome = building_monument_working(BUILDING_HIPPODROME); @@ -139,13 +140,21 @@ void house_service_calculate_culture_aggregates(void) b->data.house.entertainment += 10; } - // Venus Module 4 Theater/Tavern Bonus + // Venus Module 4 Bonus (variant depends on scenario) if (venus_module4) { - if (b->data.house.theater) { - b->data.house.entertainment += 5; - } - if (b->house_tavern_wine_access) { - b->data.house.entertainment += 5; + switch (venus_m4_type) { + case VENUS_M4_THEATER_TAVERN: + if (b->data.house.theater) { b->data.house.entertainment += 5; } + if (b->house_tavern_wine_access) { b->data.house.entertainment += 5; } + break; + case VENUS_M4_THEATER_BATHHOUSE: + if (b->data.house.theater) { b->data.house.entertainment += 5; } + if (b->data.house.bathhouse) { b->data.house.entertainment += 5; } + break; + case VENUS_M4_BATHHOUSE_TAVERN: + if (b->data.house.bathhouse) { b->data.house.entertainment += 5; } + if (b->house_tavern_wine_access) { b->data.house.entertainment += 5; } + break; } } diff --git a/src/building/monument.c b/src/building/monument.c index 945f792da2..e5b8ccab19 100644 --- a/src/building/monument.c +++ b/src/building/monument.c @@ -15,6 +15,7 @@ #include "map/orientation.h" #include "map/road_access.h" #include "map/terrain.h" +#include "scenario/allowed_building.h" #include "scenario/property.h" #define DELIVERY_ARRAY_SIZE_STEP 200 @@ -843,3 +844,16 @@ int building_monument_is_unfinished_monument(const building *b) { return building_monument_is_monument(b) && b->monument.phase != MONUMENT_FINISHED; } + +venus_m4_variant building_monument_venus_m4_variant(void) +{ + int has_theater = scenario_allowed_building(BUILDING_THEATER); + int has_tavern = scenario_allowed_building(BUILDING_TAVERN); + if (has_theater && has_tavern) { + return VENUS_M4_THEATER_TAVERN; + } else if (!has_tavern) { + return VENUS_M4_THEATER_BATHHOUSE; + } else { + return VENUS_M4_BATHHOUSE_TAVERN; + } +} diff --git a/src/building/monument.h b/src/building/monument.h index 1cd40dbef2..b8234dc381 100644 --- a/src/building/monument.h +++ b/src/building/monument.h @@ -78,4 +78,12 @@ int building_monument_is_construction_halted(building *b); int building_monument_toggle_construction_halted(building *b); int building_monument_is_unfinished_monument(const building *b); +typedef enum { + VENUS_M4_THEATER_TAVERN = 0, + VENUS_M4_THEATER_BATHHOUSE, + VENUS_M4_BATHHOUSE_TAVERN, +} venus_m4_variant; + +venus_m4_variant building_monument_venus_m4_variant(void); + #endif // BUILDING_MONUMENT_H diff --git a/src/city/labor.c b/src/city/labor.c index c12c2e6b5d..5ccb264bac 100644 --- a/src/city/labor.c +++ b/src/city/labor.c @@ -232,10 +232,10 @@ void city_labor_calculate_workers(int num_plebs, int num_patricians) city_data.labor.workers_available = calc_adjust_with_percentage( city_data.population.working_age, city_data.population.percentage_plebs); } - // Pantheon Reworked Module 2: each Luxury Palace grants 30 workers + // Pantheon Reworked Module 2: each Luxury Palace grants 20 workers if (building_monument_gt_module_is_active(PANTHEON_MODULE_4_LUXURY_PALACE)) { city_data.labor.workers_available += - building_count_active(BUILDING_HOUSE_LUXURY_PALACE) * 30; + building_count_active(BUILDING_HOUSE_LUXURY_PALACE) * 20; } } diff --git a/src/figure/formation.c b/src/figure/formation.c index 8354209c67..6ab8e04636 100644 --- a/src/figure/formation.c +++ b/src/figure/formation.c @@ -381,7 +381,7 @@ int formation_get_max_legions(void) // Mars base bonus if (game_cheat_extra_legions()) { return MAX_LEGIONS + 14; - } else if (building_monument_working(BUILDING_GRAND_TEMPLE_MARS)) { + } else if (building_monument_working(BUILDING_GRAND_TEMPLE_MARS) || building_monument_working(BUILDING_GRAND_TEMPLE_MARS_REWORKED)) { return MAX_LEGIONS + 4; } else { return MAX_LEGIONS; diff --git a/src/translation/english.c b/src/translation/english.c index 6da15a2fed..1b161dc392 100644 --- a/src/translation/english.c +++ b/src/translation/english.c @@ -215,7 +215,7 @@ static translation_string all_strings[] = { {TR_BUILDING_GRAND_TEMPLE_CERES_REWORKED_BONUS_DESC, "Houses visited by priests of Ceres consume less total food for each food type provided."}, {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED_BONUS_DESC, "Provides water access like a filled reservoir, and priests prevent disease and extend citizens' working years based on city health."}, {TR_BUILDING_GRAND_TEMPLE_MERCURY_REWORKED_BONUS_DESC, "Houses visited by priests of Mercury will consume fewer goods when sentiment is high."}, - {TR_BUILDING_GRAND_TEMPLE_MARS_REWORKED_BONUS_DESC, "Houses visited by priests of Mars receive a blessing of martial strength, housing 5% more residents." }, + {TR_BUILDING_GRAND_TEMPLE_MARS_REWORKED_BONUS_DESC, "Houses visited by priests of Mars receive a blessing of martial strength, housing more residents. Four additional forts may be constructed." }, {TR_BUILDING_PANTHEON_REWORKED_BONUS_DESC, "The Pantheon provides all citizens with access to all gods and allows house to evolve one additional step. Annual festivals are held and religious building levies are reduced." }, {TR_BUILDING_PANTHEON_BONUS_DESC, "The Pantheon provides access to your citizens to worship all the gods. Annual festivals are also held here, and religious and cultural building levies are reduced by 25%." }, // Note to translators: This one changed from the previous version, please update. {TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_1_DESC, "Priests reduce food consumption by 20%." }, @@ -225,6 +225,8 @@ static translation_string all_strings[] = { {TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_1_DESC, "The Grand temple produces wine in a quantity scaled to city population with Venus temple access. Temples collect and distribute it to houses and taverns." }, {TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_3_DESC, "Provides a second wine type. All small, large, and grand temples gain increased desirability." }, {TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_4_DESC, "All houses gain additional entertainment from theaters and working taverns." }, + {TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_4_THEATER_BATHHOUSE_DESC, "All houses gain additional entertainment from theaters and bathhouses." }, + {TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_4_BATHHOUSE_TAVERN_DESC, "All houses gain additional entertainment from bathhouses and working taverns." }, {TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_2_DESC, "Priests collect and distribute both oil and one food type from city storage." }, {TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_2_DESC, "Priests expand housing capacity by 5%. Grand temple provides water like a filled reservoir." }, {TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_2_DESC, "Priests reduce oil and wine consumption by 20%." }, diff --git a/src/translation/translation.h b/src/translation/translation.h index d882a587ba..f9abaf3b01 100644 --- a/src/translation/translation.h +++ b/src/translation/translation.h @@ -221,6 +221,8 @@ typedef enum { TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_1_DESC, TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_3_DESC, TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_4_DESC, + TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_4_THEATER_BATHHOUSE_DESC, + TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_4_BATHHOUSE_TAVERN_DESC, TR_BUILDING_GRAND_TEMPLE_CERES_MODULE_2_DESC, TR_BUILDING_GRAND_TEMPLE_NEPTUNE_MODULE_2_DESC, TR_BUILDING_GRAND_TEMPLE_MERCURY_MODULE_2_DESC, diff --git a/src/window/building/culture.c b/src/window/building/culture.c index 00e63dcb13..cd47a9635b 100644 --- a/src/window/building/culture.c +++ b/src/window/building/culture.c @@ -845,9 +845,21 @@ static void draw_grand_temple(building_info_context *c, const char *sound_file, int reworked_base = reworked_temple_option_id(b->type); int module_index = (reworked_base >= 0 ? reworked_base : data.god_id * 2) + (b->monument.upgrades - 1); int module_desc = temple_module_options[module_index].option.desc; + // Venus M4 desc adapts to scenario (theater/tavern availability) + if (b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED && b->monument.upgrades == 2) { + switch (building_monument_venus_m4_variant()) { + case VENUS_M4_THEATER_BATHHOUSE: + module_desc = TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_4_THEATER_BATHHOUSE_DESC; + break; + case VENUS_M4_BATHHOUSE_TAVERN: + module_desc = TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_4_BATHHOUSE_TAVERN_DESC; + break; + default: break; + } + } height += text_draw_multiline(translation_for(module_desc), c->x_offset + 22, c->y_offset + 66 + height + extra_y, 15 * c->width_blocks, - 0, FONT_NORMAL_GREEN, 0); + 0, FONT_NORMAL_BLACK, 0); } } if (b->type == BUILDING_GRAND_TEMPLE_MARS) { @@ -1483,7 +1495,20 @@ static void button_add_module_prompt(const generic_button *button) if (scenario_allowed_building(temple_module_options[option_id + 1].required_building)) { generate_module_image_id(option_id + 1); data.module_choices[num_options] = 2; - options[num_options++] = temple_module_options[option_id + 1].option; + options[num_options] = temple_module_options[option_id + 1].option; + // Venus Reworked M4: adapt desc to scenario (theater/tavern availability) + if (b->type == BUILDING_GRAND_TEMPLE_VENUS_REWORKED) { + switch (building_monument_venus_m4_variant()) { + case VENUS_M4_THEATER_BATHHOUSE: + options[num_options].desc = TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_4_THEATER_BATHHOUSE_DESC; + break; + case VENUS_M4_BATHHOUSE_TAVERN: + options[num_options].desc = TR_BUILDING_GRAND_TEMPLE_VENUS_MODULE_4_BATHHOUSE_TAVERN_DESC; + break; + default: break; + } + } + num_options++; } if (num_options) { diff --git a/src/window/building/house.c b/src/window/building/house.c index d966b0f0cd..4f1ff2919f 100644 --- a/src/window/building/house.c +++ b/src/window/building/house.c @@ -129,24 +129,35 @@ static void draw_happiness_info(building_info_context *c, int y_offset) } } -// static void draw_debug_info(building_info_context *c, int y_offset) -// { -// // DEBUG: Display entertainment and desirability values -// building *b = building_get(c->building_id); +static void draw_debug_info(building_info_context *c, int y_offset) +{ + // DEBUG: Display entertainment and desirability values + building *b = building_get(c->building_id); + + // Desirability (from building) + int width = text_draw(string_from_ascii("Desirability (actual): "), + c->x_offset + 36, y_offset + 16, FONT_NORMAL_RED, 0); + text_draw_number(b->desirability, '@', " ", + c->x_offset + 36 + width, y_offset + 16, FONT_NORMAL_RED, 0); -// // Desirability (from building) -// int width = text_draw(string_from_ascii("Desirability (actual): "), -// c->x_offset + 36, y_offset + 16, FONT_NORMAL_RED, 0); -// text_draw_number(b->desirability, '@', " ", -// c->x_offset + 36 + width, y_offset + 16, FONT_NORMAL_RED, 0); + // Desirability (from map) + int map_desir = map_desirability_get_max(b->x, b->y, b->size); + width = text_draw(string_from_ascii("Desirability (map): "), + c->x_offset + 36, y_offset + 32, FONT_NORMAL_RED, 0); + text_draw_number(map_desir, '@', " ", + c->x_offset + 36 + width, y_offset + 32, FONT_NORMAL_RED, 0); -// // Desirability (from map) -// int map_desir = map_desirability_get_max(b->x, b->y, b->size); -// width = text_draw(string_from_ascii("Desirability (map): "), -// c->x_offset + 36, y_offset + 32, FONT_NORMAL_RED, 0); -// text_draw_number(map_desir, '@', " ", -// c->x_offset + 36 + width, y_offset + 32, FONT_NORMAL_RED, 0); -// } + // Entertainment: current score vs required + int ent_have = b->data.house.entertainment; + int ent_need = model_get_house(b->subtype.house_level)->entertainment; + width = text_draw(string_from_ascii("Entertainment (have/need): "), + c->x_offset + 36, y_offset + 48, FONT_NORMAL_RED, 0); + width += text_draw_number(ent_have, '@', "/", + c->x_offset + 36 + width, y_offset + 48, FONT_NORMAL_RED, 0); + text_draw_number(ent_need, '@', " ", + c->x_offset + 36 + width, y_offset + 48, FONT_NORMAL_RED, 0); + +} void window_building_draw_house(building_info_context *c) { @@ -167,7 +178,7 @@ void window_building_draw_house(building_info_context *c) draw_population_info(c, c->y_offset + 134); draw_tax_info(c, c->y_offset + 174); draw_happiness_info(c, c->y_offset + 194); - // draw_debug_info(c, c->y_offset + 305); + draw_debug_info(c, c->y_offset + 305); int x_offset = 32; int y_content = 259; From d41896569ec7a49418b6ff8b37056e74887f7229 Mon Sep 17 00:00:00 2001 From: William Hardy Gest Date: Sun, 15 Mar 2026 10:26:22 -0500 Subject: [PATCH 11/12] Remove grand temple limit slider setting --- src/building/construction.c | 3 --- src/building/construction_building.c | 5 ----- src/city/warning.c | 2 -- src/city/warning.h | 1 - src/core/config.c | 2 -- src/core/config.h | 1 - src/translation/english.c | 2 -- src/translation/french.c | 2 -- src/translation/german.c | 2 -- src/translation/greek.c | 2 -- src/translation/italian.c | 2 -- src/translation/korean.c | 2 -- src/translation/polish.c | 2 -- src/translation/portuguese.c | 2 -- src/translation/russian.c | 2 -- src/translation/simplified_chinese.c | 2 -- src/translation/spanish.c | 2 -- src/translation/swedish.c | 2 -- src/translation/traditional_chinese.c | 2 -- src/translation/translation.h | 2 -- src/widget/city_building_ghost.c | 4 ---- src/window/config.c | 11 ----------- 22 files changed, 57 deletions(-) diff --git a/src/building/construction.c b/src/building/construction.c index 91e09c65f2..3d60f8fefc 100644 --- a/src/building/construction.c +++ b/src/building/construction.c @@ -783,9 +783,6 @@ static int should_mark_for_construction(building_type type) return 0; } else if (building_monument_get_id(type)) { return 0; - } else if (building_monument_is_grand_temple(type) && - building_monument_count_grand_temples() >= config_get(CONFIG_GP_CH_MAX_GRAND_TEMPLES)) { - return 0; } else if (type == BUILDING_AQUEDUCT) { return 0; } diff --git a/src/building/construction_building.c b/src/building/construction_building.c index 5d72bfef4a..55341eab9e 100644 --- a/src/building/construction_building.c +++ b/src/building/construction_building.c @@ -580,11 +580,6 @@ int building_construction_place_building(building_type type, int x, int y, int e return 0; } - if (building_monument_is_grand_temple(type) && - building_monument_count_grand_temples() >= config_get(CONFIG_GP_CH_MAX_GRAND_TEMPLES)) { - city_warning_show(WARNING_MAX_GRAND_TEMPLES, NEW_WARNING_SLOT); - return 0; - } if (type == BUILDING_COLOSSEUM) { if (building_count_total(BUILDING_COLOSSEUM)) { city_warning_show(WARNING_ONE_BUILDING_OF_TYPE, NEW_WARNING_SLOT); diff --git a/src/city/warning.c b/src/city/warning.c index 6ed2bc4017..ba8aa9998e 100644 --- a/src/city/warning.c +++ b/src/city/warning.c @@ -31,8 +31,6 @@ static const uint8_t *get_text_for_warning(warning_type type) return lang_get_string(17, city_view_orientation()); case WARNING_NO_MESS_HALL: return translation_for(TR_WARNING_NO_MESS_HALL); - case WARNING_MAX_GRAND_TEMPLES: - return translation_for(TR_WARNING_MAX_GRAND_TEMPLES); case WARNING_WATER_NEEDED_FOR_BUILDING: return translation_for(TR_WARNING_WATER_NEEDED_FOR_BUILDING); case WARNING_RESOURCES_NOT_AVAILABLE: diff --git a/src/city/warning.h b/src/city/warning.h index a6466a81d6..4c4c179500 100644 --- a/src/city/warning.h +++ b/src/city/warning.h @@ -58,7 +58,6 @@ typedef enum { WARNING_CITY_BOXED_IN_PEOPLE_WILL_PERISH = 64, WARNING_DATA_LIMIT_REACHED = 65, WARNING_NO_MESS_HALL = 66, - WARNING_MAX_GRAND_TEMPLES = 67, WARNING_WATER_NEEDED_FOR_BUILDING = 68, WARNING_RESOURCES_NOT_AVAILABLE = 69, WARNING_VARIANT_TOGGLE = 70, diff --git a/src/core/config.c b/src/core/config.c index 1016b2b216..9f15249d88 100644 --- a/src/core/config.c +++ b/src/core/config.c @@ -50,7 +50,6 @@ static const char *ini_keys[] = { [CONFIG_UI_DRAW_CLOUD_SHADOWS] = "ui_draw_cloud_shadows", [CONFIG_UI_DISPLAY_FPS] = "ui_display_fps", [CONFIG_UI_ASK_CONFIRMATION_ON_FILE_OVERWRITE] = "ui_ask_confirmation_on_file_overwrite", - [CONFIG_GP_CH_MAX_GRAND_TEMPLES] = "gameplay_change_max_grand_temples", [CONFIG_GP_CH_JEALOUS_GODS] = "gameplay_change_jealous_gods", [CONFIG_GP_CH_GLOBAL_LABOUR] = "gameplay_change_global_labour", [CONFIG_GP_CH_RETIRE_AT_60] = "gameplay_change_retire_at_60", @@ -138,7 +137,6 @@ static int default_values[CONFIG_MAX_ENTRIES] = { [CONFIG_UI_ASK_CONFIRMATION_ON_FILE_OVERWRITE] = 1, [CONFIG_SCREEN_DISPLAY_SCALE] = 100, [CONFIG_SCREEN_CURSOR_SCALE] = 100, - [CONFIG_GP_CH_MAX_GRAND_TEMPLES] = 2, [CONFIG_UI_SHOW_DESIRABILITY_RANGE] = 0, [CONFIG_UI_SHOW_DESIRABILITY_RANGE_ALL] = 0, [CONFIG_UI_HIGHLIGHT_SELECTED_BUILDING] = 1, diff --git a/src/core/config.h b/src/core/config.h index 633f95aed9..d9fe94ba9c 100644 --- a/src/core/config.h +++ b/src/core/config.h @@ -40,7 +40,6 @@ typedef enum { CONFIG_UI_DRAW_CLOUD_SHADOWS, CONFIG_UI_DISPLAY_FPS, CONFIG_UI_ASK_CONFIRMATION_ON_FILE_OVERWRITE, - CONFIG_GP_CH_MAX_GRAND_TEMPLES, CONFIG_GP_CH_JEALOUS_GODS, CONFIG_GP_CH_GLOBAL_LABOUR, CONFIG_GP_CH_RETIRE_AT_60, diff --git a/src/translation/english.c b/src/translation/english.c index 1b161dc392..491d444f1a 100644 --- a/src/translation/english.c +++ b/src/translation/english.c @@ -80,7 +80,6 @@ static translation_string all_strings[] = { {TR_CONFIG_COMPLETE_RATING_COLUMNS, "Fix uncompleted rating columns on low targets"}, {TR_CONFIG_GRANDFESTIVAL, "Grand festivals allow extra blessing from a god"}, {TR_CONFIG_DIFFICULTY, "Difficulty:"}, - {TR_CONFIG_MAX_GRAND_TEMPLES, "Maximum number of grand temples per city:"}, {TR_CONFIG_INFINITE, "Infinite"}, {TR_CONFIG_GODS_EFFECTS, "Enable god curses/blessings"}, {TR_CONFIG_JEALOUS_GODS, "Disable jealousy of gods"}, @@ -407,7 +406,6 @@ static translation_string all_strings[] = { {TR_TEMPLE_SPECIAL_ORDERS_HEADER, "Temple instructions"}, {TR_TAVERN_SPECIAL_ORDERS_HEADER, "Tavern instructions"}, {TR_WARNING_NO_MESS_HALL, "You must first build a supply post to feed your soldiers."}, - {TR_WARNING_MAX_GRAND_TEMPLES, "No more grand temples can be built."}, {TR_CITY_MESSAGE_TITLE_GRAND_TEMPLE_COMPLETE, "Grand temple completed"}, {TR_CITY_MESSAGE_TEXT_GRAND_TEMPLE_COMPLETE, "Priests and worshipers flock to the new Grand temple for the rites of dedication. Your people stand in awe of the majesty of your works, and your chosen deity showers you with their favor."}, {TR_CITY_MESSAGE_TITLE_MERCURY_BLESSING, "A blessing from Mercury" }, diff --git a/src/translation/french.c b/src/translation/french.c index bafeea3b6d..1b184eb0ab 100644 --- a/src/translation/french.c +++ b/src/translation/french.c @@ -80,7 +80,6 @@ static translation_string all_strings[] = { {TR_CONFIG_COMPLETE_RATING_COLUMNS, "Corrige les colonnes d'évaluation incomplètes"}, {TR_CONFIG_GRANDFESTIVAL, "Les grandes fêtes permettent une bénédiction supplémentaire d'un dieu"}, {TR_CONFIG_DIFFICULTY, "Difficulté :"}, - {TR_CONFIG_MAX_GRAND_TEMPLES, "Nombre maximum de temples monumentaux par cité :"}, {TR_CONFIG_INFINITE, "Infini"}, {TR_CONFIG_GODS_EFFECTS, "Activer les malédictions/bénédictions des dieux"}, {TR_CONFIG_JEALOUS_GODS, "Désactiver la jalousie des dieux"}, @@ -369,7 +368,6 @@ static translation_string all_strings[] = { {TR_TEMPLE_SPECIAL_ORDERS_HEADER, "Instructions du temple"}, {TR_TAVERN_SPECIAL_ORDERS_HEADER, "Instructions de la taverne"}, {TR_WARNING_NO_MESS_HALL, "Construisez d'abord un réfectoire pour vos soldats"}, - {TR_WARNING_MAX_GRAND_TEMPLES, "Seuls deux temples monumentaux peuvent être construits"}, {TR_CITY_MESSAGE_TITLE_GRAND_TEMPLE_COMPLETE, "Temple monumental terminé"}, {TR_CITY_MESSAGE_TEXT_GRAND_TEMPLE_COMPLETE, "Les prêtres et les fidèles affluent vers le nouveau temple monumental pour les rites de consécration. Votre peuple est impressionné par la majesté de vos œuvres et la divinité que vous avez choisie vous comble de faveur."}, {TR_CITY_MESSAGE_TITLE_MERCURY_BLESSING, "Bénédiction de Mercure"}, diff --git a/src/translation/german.c b/src/translation/german.c index 28f6450648..8c4fef2607 100644 --- a/src/translation/german.c +++ b/src/translation/german.c @@ -144,7 +144,6 @@ static translation_string all_strings[] = { {TR_CONFIG_LANGUAGE_DEFAULT, "(Standard)"}, {TR_CONFIG_LANGUAGE_LABEL, "Sprache:"}, {TR_CONFIG_DEFAULT_PLAYER_NAME, "Standard-Spielername:"}, - {TR_CONFIG_MAX_GRAND_TEMPLES, "Maximale Anzahl von Prachttempeln pro Stadt: "}, {TR_CONFIG_MORE_STOCKPILE, "Häuser horten mehr Güter von Märkten"}, {TR_CONFIG_MULTIPLE_BARRACKS, "Erlaube das Errichten mehrerer Kasernen"}, {TR_CONFIG_MUSIC, "Musik einschalten"}, @@ -373,7 +372,6 @@ static translation_string all_strings[] = { {TR_CITY_WARNING_WAREHOUSE_BREAKIN, "Ein Lagerhaus wurde geplündert!"}, {TR_CITY_WARNING_GRANARY_BREAKIN, "Ein Silo wurde geplündert!"}, {TR_CITY_WARNING_THEFT, "Gelder wurden aus einem Forum oder dem Senat gestohlen!"}, - {TR_WARNING_MAX_GRAND_TEMPLES, "In einer Stadt können nur zwei Prachttempel gebaut werden."}, {TR_WARNING_NEARBY_WOLF, "Kann nicht gebaut werden, wenn Wölfe in der Nähe sind"}, {TR_WARNING_NO_ARMOURY, "Bauen Sie eine Waffenkammer, um Waffen an Kasernen zu liefern." }, {TR_WARNING_NO_MESS_HALL, "Ihr müsst zunächst einen Versorgungsposten bauen, um Ihre Soldaten zu ernähren."}, diff --git a/src/translation/greek.c b/src/translation/greek.c index 4d1720c2c1..e2db47b064 100644 --- a/src/translation/greek.c +++ b/src/translation/greek.c @@ -79,7 +79,6 @@ static translation_string all_strings[] = { {TR_CONFIG_COMPLETE_RATING_COLUMNS, "Διόρθωση μη ολοκληρωμένων στηλών αξιολόγησης σε χαμηλούς στόχους"}, {TR_CONFIG_GRANDFESTIVAL, "Οι μεγάλες γιορτές επιτρέπουν επιπλέον ευλογία από έναν θεό"}, {TR_CONFIG_DIFFICULTY, "Δυσκολία:"}, - {TR_CONFIG_MAX_GRAND_TEMPLES, "Μέγιστος αριθμός μεγαλοπρεπών ναών ανά πόλη:"}, {TR_CONFIG_INFINITE, "Άπειρη"}, {TR_CONFIG_GODS_EFFECTS, "Ενεργοποιήστε τις κατάρες/ευλογίες των θεών"}, {TR_CONFIG_JEALOUS_GODS, "Απενεργοποίηση της ζήλειας των θεών"}, @@ -363,7 +362,6 @@ static translation_string all_strings[] = { {TR_TEMPLE_SPECIAL_ORDERS_HEADER, "Οδηγίες ναού"}, {TR_TAVERN_SPECIAL_ORDERS_HEADER, "Οδηγίες ταβέρνας"}, {TR_WARNING_NO_MESS_HALL, "Πρέπει πρώτα να χτίσετε ένα σταθμό ανεφοδιασμού για να ταΐσετε τους στρατιώτες σας."}, - {TR_WARNING_MAX_GRAND_TEMPLES, "Δεν μπορούν να χτιστούν άλλοι μεγαλοπρεπείς ναοί."}, {TR_CITY_MESSAGE_TITLE_GRAND_TEMPLE_COMPLETE, "Ολοκληρώθηκε ο μεγαλοπρεπής ναός"}, {TR_CITY_MESSAGE_TEXT_GRAND_TEMPLE_COMPLETE, "Ιερείς και πιστοί συρρέουν στο νέο μεγαλοπρεπή ναό για τις τελετές των εγκαινίων. Ο λαός σας στέκεται με δέος μπροστά στο μεγαλείο των έργων σας και η θεότητα που επιλέξατε σας περιβάλλει με εύνοια."}, {TR_CITY_MESSAGE_TITLE_MERCURY_BLESSING, "Μια ευλογία από τον Ερμή" }, diff --git a/src/translation/italian.c b/src/translation/italian.c index 2b9d851424..c3f325be6c 100755 --- a/src/translation/italian.c +++ b/src/translation/italian.c @@ -80,7 +80,6 @@ static translation_string all_strings[] = { {TR_CONFIG_COMPLETE_RATING_COLUMNS, "Fissa colonne di valutazione non completate su obiettivi bassi"}, {TR_CONFIG_GRANDFESTIVAL, "Le grandi feste permettono una benedizione extra da parte di una divinità"}, {TR_CONFIG_DIFFICULTY, "Difficoltà:"}, - {TR_CONFIG_MAX_GRAND_TEMPLES, "Massimo numero di templi grandi per ogni città:"}, {TR_CONFIG_INFINITE, "Illimitato"}, {TR_CONFIG_GODS_EFFECTS, "Abilità benedizioni/maledizioni delle divinità"}, {TR_CONFIG_JEALOUS_GODS, "Disabilita gelosia delle divinità"}, @@ -369,7 +368,6 @@ static translation_string all_strings[] = { {TR_TEMPLE_SPECIAL_ORDERS_HEADER, "Istruzioni del Tempio"}, {TR_TAVERN_SPECIAL_ORDERS_HEADER, "Istruzioni della taverna"}, {TR_WARNING_NO_MESS_HALL, "Devi prima costruire una stazione di rifornimento per sfamare i tuoi soldati."}, - {TR_WARNING_MAX_GRAND_TEMPLES, "Solo due Templi Grandi possono essere costruiti."}, {TR_CITY_MESSAGE_TITLE_GRAND_TEMPLE_COMPLETE, "Tempio Grandioso completato"}, {TR_CITY_MESSAGE_TEXT_GRAND_TEMPLE_COMPLETE, "I sacerdoti e i fedeli accorrono al nuovo grande tempio per i riti di consacrazione. Il tuo popolo è in visibilio per la maestosità delle tue opere, e la divinità da te scelta ti offre il suo favore."}, {TR_CITY_MESSAGE_TITLE_MERCURY_BLESSING, "Una benedizione da Mercurio" }, diff --git a/src/translation/korean.c b/src/translation/korean.c index 2921c0f5e1..aa26a0f037 100644 --- a/src/translation/korean.c +++ b/src/translation/korean.c @@ -80,7 +80,6 @@ static translation_string all_strings[] = { {TR_CONFIG_COMPLETE_RATING_COLUMNS, "낮은 목표에 대한 미완료 등급 열 수정"}, {TR_CONFIG_GRANDFESTIVAL, "초대형 축제가 추가적인 축복 내리는 것을 허용"}, {TR_CONFIG_DIFFICULTY, "난이도:"}, - {TR_CONFIG_MAX_GRAND_TEMPLES, "건설 가능한 대성전의 최대 갯수:"}, {TR_CONFIG_INFINITE, "무한"}, {TR_CONFIG_GODS_EFFECTS, "신의 축복/저주 활성화"}, {TR_CONFIG_JEALOUS_GODS, "신들의 질투 비활성화"}, @@ -368,7 +367,6 @@ static translation_string all_strings[] = { {TR_TEMPLE_SPECIAL_ORDERS_HEADER, "신전 운영 지침"}, {TR_TAVERN_SPECIAL_ORDERS_HEADER, "선술집 운영 지침"}, {TR_WARNING_NO_MESS_HALL, "먼저 병사들에게 식량을 보급할 보급소를 건설해야합니다."}, - {TR_WARNING_MAX_GRAND_TEMPLES, "더 이상 대성전을 건축할 수 없습니다."}, {TR_CITY_MESSAGE_TITLE_GRAND_TEMPLE_COMPLETE, "대성전 완공"}, {TR_CITY_MESSAGE_TEXT_GRAND_TEMPLE_COMPLETE, "성직자와 신도들이 새로운 대성전의 봉헌 의식을 진행합니다. 시민들이 당신의 업적에 경탄하고 있으며, 선택받은 신은 당신에게 가호를 베풀고 있습니다."}, {TR_CITY_MESSAGE_TITLE_MERCURY_BLESSING, "머큐리의 축복" }, diff --git a/src/translation/polish.c b/src/translation/polish.c index aab5047b27..e846322012 100644 --- a/src/translation/polish.c +++ b/src/translation/polish.c @@ -294,7 +294,6 @@ static translation_string all_strings[] = { { TR_CITY_MESSAGE_TEXT_MESS_HALL_MISSING, "Twoje miasto straciło punkt zaopatrzeniowy i twoi żołnierze głodują. Natychmiast zbuduj nowy." }, { TR_MARKET_SPECIAL_ORDERS_HEADER, "Dobra do zebrania" }, { TR_WARNING_NO_MESS_HALL, "Wpierw zbuduj punkt zaopatrzeniowy dla żołnierzy." }, - { TR_WARNING_MAX_GRAND_TEMPLES, "Można postawić tylko dwie wielkie świątynie." }, { TR_CITY_MESSAGE_TITLE_GRAND_TEMPLE_COMPLETE, "Wielka świątynia ukończona" }, { TR_CITY_MESSAGE_TEXT_GRAND_TEMPLE_COMPLETE, "Kapłani i wyznawcy tłumnie gromadzą się w nowej wielkiej świątyni na ryty poświęcenia. Mieszkańcy są w podziwie majestatu twojej pracy, a wybrane bóstwo obdarza cię swoją łaską." }, { TR_CITY_MESSAGE_TITLE_MERCURY_BLESSING, "Błogosławieństwo Merkurego" }, @@ -515,7 +514,6 @@ static translation_string all_strings[] = { {TR_CONFIG_AUDIO, "Opcje dźwięku"}, {TR_CONFIG_CITY_SOUNDS, "Włącz dźwięki miasta"}, {TR_CONFIG_DIFFICULTY, "Poziom trudności:"}, - {TR_CONFIG_MAX_GRAND_TEMPLES, "Maksymalna liczba wielkich świątyń:" }, {TR_CONFIG_INFINITE, "Bez limitu" }, {TR_CONFIG_USE_COLOR_CURSORS, "Użyj kolorowych kursorów" }, {TR_CONFIG_VIDEO_SOUND, "Włącz dźwięk filmów" }, diff --git a/src/translation/portuguese.c b/src/translation/portuguese.c index 3d0c42b97b..872fbc5cf3 100644 --- a/src/translation/portuguese.c +++ b/src/translation/portuguese.c @@ -334,7 +334,6 @@ static translation_string all_strings[] = { {TR_TEMPLE_SPECIAL_ORDERS_HEADER, "Instruções"}, {TR_TAVERN_SPECIAL_ORDERS_HEADER, "Instruções"}, { TR_WARNING_NO_MESS_HALL, "Construa um posto de suprimentos primeiro, para alimentar os soldados." }, - { TR_WARNING_MAX_GRAND_TEMPLES, "Apenas dois Santuários podem ser construídos." }, { TR_CITY_MESSAGE_TITLE_GRAND_TEMPLE_COMPLETE, "Santuário completado" }, { TR_CITY_MESSAGE_TEXT_GRAND_TEMPLE_COMPLETE, "Sacerdotes e fiéis estão se reunindo no Santuário para os ritos de dedicação. O povo está estasiado diante da majestosidade de teus feitos, e a divindade escolhida te enche de graças." }, { TR_CITY_MESSAGE_TITLE_MERCURY_BLESSING, "Uma bênção de Mercúrio" }, @@ -707,7 +706,6 @@ static translation_string all_strings[] = { {TR_CONFIG_VIDEO_SOUND, "Ativar som do vídeo" }, {TR_BUILDING_WATCHTOWER_DESC_NO_SOLDIERS, "Esta torre precisa de um sentinela do quartel para que possa ser útil na defesa da cidade." }, {TR_CONFIG_INFINITE, "Ilimitado" }, - {TR_CONFIG_MAX_GRAND_TEMPLES, "Número máximo de Santuários por cidade:" }, {TR_HOTKEY_ROTATE_BUILDING_BACK, "Rotação anterior da construção" }, {TR_TOOLTIP_BUTTON_ACCEPT_WORKERS, "Suspender recursos para fábricas e celeiros" }, {TR_TOOLTIP_BUTTON_STOCKPILING_ON, "Permitir estocagem em um armazém" }, diff --git a/src/translation/russian.c b/src/translation/russian.c index 0298f5ea18..07e84a0ce7 100644 --- a/src/translation/russian.c +++ b/src/translation/russian.c @@ -80,7 +80,6 @@ static translation_string all_strings[] = { {TR_CONFIG_COMPLETE_RATING_COLUMNS, "Исправить незавершенные колонны рейтинга"}, {TR_CONFIG_GRANDFESTIVAL, "Великий фестиваль дает дополнительное благословение от божества"}, {TR_CONFIG_DIFFICULTY, "Сложность:"}, - {TR_CONFIG_MAX_GRAND_TEMPLES, "Максимальное количество великих храмов в городе:"}, {TR_CONFIG_INFINITE, "Бесконечно"}, {TR_CONFIG_GODS_EFFECTS, "ВКЛ гнев/благословение богов"}, {TR_CONFIG_JEALOUS_GODS, "ОТКЛ ревность богов"}, @@ -369,7 +368,6 @@ static translation_string all_strings[] = { {TR_TEMPLE_SPECIAL_ORDERS_HEADER, "Указания храму"}, {TR_TAVERN_SPECIAL_ORDERS_HEADER, "Указания таверне"}, {TR_WARNING_NO_MESS_HALL, "Сначала вы должны построить пост снабжения, чтобы кормить своих солдат."}, - {TR_WARNING_MAX_GRAND_TEMPLES, "Больше нельзя строить великие храмы."}, {TR_CITY_MESSAGE_TITLE_GRAND_TEMPLE_COMPLETE, "Великий храм возведен"}, {TR_CITY_MESSAGE_TEXT_GRAND_TEMPLE_COMPLETE, "Жрецы и поклонники приходят к новому великому храму для проведения обрядов посвящения. Ваш народ трепещет перед величием ваших трудов, и ваше избранное божество одаривает вас благосклонностью."}, {TR_CITY_MESSAGE_TITLE_MERCURY_BLESSING, "Благословение Меркурия"}, diff --git a/src/translation/simplified_chinese.c b/src/translation/simplified_chinese.c index 0e913297e1..b9be9fc633 100644 --- a/src/translation/simplified_chinese.c +++ b/src/translation/simplified_chinese.c @@ -73,7 +73,6 @@ static translation_string all_strings[] = { {TR_CONFIG_COMPLETE_RATING_COLUMNS, "修复低目标下无法完成评比任务BUG"}, {TR_CONFIG_GRANDFESTIVAL, "举办豪华节庆获取神灵更多祝福"}, {TR_CONFIG_DIFFICULTY, "游戏难度:"}, - {TR_CONFIG_MAX_GRAND_TEMPLES, "每座城市宏伟神庙数量上限:"}, {TR_CONFIG_INFINITE, "无限"}, {TR_CONFIG_GODS_EFFECTS, "开启神灵诅咒/祝福效果"}, {TR_CONFIG_JEALOUS_GODS, "关闭神灵嫉妒效果"}, @@ -362,7 +361,6 @@ static translation_string all_strings[] = { {TR_TEMPLE_SPECIAL_ORDERS_HEADER, "神庙指令"}, {TR_TAVERN_SPECIAL_ORDERS_HEADER, "酒馆指令"}, {TR_WARNING_NO_MESS_HALL, "你必须先建造军粮站供养士兵。"}, - {TR_WARNING_MAX_GRAND_TEMPLES, "无法建造更多宏伟神庙。"}, {TR_CITY_MESSAGE_TITLE_GRAND_TEMPLE_COMPLETE, "宏伟神庙建造完成"}, {TR_CITY_MESSAGE_TEXT_GRAND_TEMPLE_COMPLETE, "祭司和朝拜者们聚众在宏伟神庙举行献祭仪式,你沐浴在神的关照下,市民对你的丰功伟业深感敬畏。"}, {TR_CITY_MESSAGE_TITLE_MERCURY_BLESSING, "莫丘里的祝福"}, diff --git a/src/translation/spanish.c b/src/translation/spanish.c index 4d43881fc1..d807938c44 100644 --- a/src/translation/spanish.c +++ b/src/translation/spanish.c @@ -79,7 +79,6 @@ static translation_string all_strings[] = { {TR_CONFIG_COMPLETE_RATING_COLUMNS, "Arreglar columnas de puntuación incompletas con objetivos bajos"}, {TR_CONFIG_GRANDFESTIVAL, "Super-Festivales permiten bendiciones extras de un dios"}, {TR_CONFIG_DIFFICULTY, "Dificultad:"}, - {TR_CONFIG_MAX_GRAND_TEMPLES, "Numero máximo de templos magnos por ciudad:"}, {TR_CONFIG_INFINITE, "Infinito"}, {TR_CONFIG_GODS_EFFECTS, "Activar efectos de dioses"}, {TR_CONFIG_JEALOUS_GODS, "Desactivar la envidia entre dioses"}, @@ -364,7 +363,6 @@ static translation_string all_strings[] = { {TR_TEMPLE_SPECIAL_ORDERS_HEADER, "Instrucciones del templo"}, {TR_TAVERN_SPECIAL_ORDERS_HEADER, "Instrucciones de la taberna"}, {TR_WARNING_NO_MESS_HALL, "Debes construir primero un puesto de suministro para alimentar a tus tropas."}, - {TR_WARNING_MAX_GRAND_TEMPLES, "Solo pueden construirse dos Templos magnos."}, {TR_CITY_MESSAGE_TITLE_GRAND_TEMPLE_COMPLETE, "Templo magno completado"}, {TR_CITY_MESSAGE_TEXT_GRAND_TEMPLE_COMPLETE, "Sacerdotes y fieles se congregan en el nuevo templo magno para los ritos de consagración. Tu gente ve asombrada la majestuosidad de tus obras, y tu deidad elegida te colma de su favor."}, {TR_CITY_MESSAGE_TITLE_MERCURY_BLESSING, "Bendición de Mercurio"}, diff --git a/src/translation/swedish.c b/src/translation/swedish.c index dbfc608058..59eed4a16e 100644 --- a/src/translation/swedish.c +++ b/src/translation/swedish.c @@ -339,7 +339,6 @@ static translation_string all_strings[] = { {TR_TEMPLE_SPECIAL_ORDERS_HEADER, "Tempelinstruktioner"}, {TR_TAVERN_SPECIAL_ORDERS_HEADER, "Kroginstruktioner"}, - {TR_WARNING_MAX_GRAND_TEMPLES, "Endast två storslagna tempel kan byggas." }, {TR_CITY_MESSAGE_TITLE_GRAND_TEMPLE_COMPLETE, "Storslaget tempel färdigbyggt"}, {TR_CITY_MESSAGE_TEXT_GRAND_TEMPLE_COMPLETE, "Präster och tillbedjare flockas till det nya storslagna templet för invigningsritualerna. Ditt folk beundrar ditt storslagna arbete, och templets tillägnade gud öser sin ynnest över dig."}, {TR_CITY_MESSAGE_TITLE_MERCURY_BLESSING, "En välsignelse från Merkurius" }, @@ -704,7 +703,6 @@ static translation_string all_strings[] = { {TR_WINDOW_BUILDING_DISTRIBUTION_CART_PUSHER_GETTING, "Vagndragaren hämtar varor från ett annat varuhus."}, {TR_BUILDING_PALISADE, "Palissad" }, {TR_BUILDING_PALISADE_DESC, "Detta gedigna pålverk av trä kommer skydda oss från angripare och fientliga djur."}, - {TR_CONFIG_MAX_GRAND_TEMPLES, "Maximalt antal storslagna tempel per stad:" }, {TR_CONFIG_USE_COLOR_CURSORS, "Använd färgade muspekare" }, {TR_OVERLAY_MOTHBALL, "Ur bruk" }, {TR_OVERLAY_ENEMY, "Fiender" }, diff --git a/src/translation/traditional_chinese.c b/src/translation/traditional_chinese.c index a936ea725f..8538719bf0 100644 --- a/src/translation/traditional_chinese.c +++ b/src/translation/traditional_chinese.c @@ -76,7 +76,6 @@ static translation_string all_strings[] = { {TR_CONFIG_COMPLETE_RATING_COLUMNS, "修復低目標下無法完成評比任務BUG"}, {TR_CONFIG_GRANDFESTIVAL, "舉辦豪華節慶獲取神靈更多祝福"}, {TR_CONFIG_DIFFICULTY, "遊戲難度:"}, - {TR_CONFIG_MAX_GRAND_TEMPLES, "每座城市宏偉神廟數量上限:"}, {TR_CONFIG_INFINITE, "無限"}, {TR_CONFIG_GODS_EFFECTS, "開啟神靈詛咒/祝福效果"}, {TR_CONFIG_JEALOUS_GODS, "關閉神靈嫉妒效果"}, @@ -365,7 +364,6 @@ static translation_string all_strings[] = { {TR_TEMPLE_SPECIAL_ORDERS_HEADER, "神廟指令"}, {TR_TAVERN_SPECIAL_ORDERS_HEADER, "酒館指令"}, {TR_WARNING_NO_MESS_HALL, "你必須先建造軍糧站供養士兵。"}, - {TR_WARNING_MAX_GRAND_TEMPLES, "無法建造更多宏偉神廟。"}, {TR_CITY_MESSAGE_TITLE_GRAND_TEMPLE_COMPLETE, "宏偉神廟建造完成"}, {TR_CITY_MESSAGE_TEXT_GRAND_TEMPLE_COMPLETE, "祭司和朝拜者們聚眾在宏偉神廟舉行獻祭儀式,你沐浴在神的眷顧下,市民對你的豐功偉績深感敬畏。"}, {TR_CITY_MESSAGE_TITLE_MERCURY_BLESSING, "莫丘里的祝福"}, diff --git a/src/translation/translation.h b/src/translation/translation.h index f9abaf3b01..0b2b873a84 100644 --- a/src/translation/translation.h +++ b/src/translation/translation.h @@ -72,7 +72,6 @@ typedef enum { TR_CONFIG_COMPLETE_RATING_COLUMNS, TR_CONFIG_GRANDFESTIVAL, TR_CONFIG_DIFFICULTY, - TR_CONFIG_MAX_GRAND_TEMPLES, TR_CONFIG_INFINITE, TR_CONFIG_GODS_EFFECTS, TR_CONFIG_JEALOUS_GODS, @@ -403,7 +402,6 @@ typedef enum { TR_TEMPLE_SPECIAL_ORDERS_HEADER, TR_TAVERN_SPECIAL_ORDERS_HEADER, TR_WARNING_NO_MESS_HALL, - TR_WARNING_MAX_GRAND_TEMPLES, TR_CITY_MESSAGE_TITLE_GRAND_TEMPLE_COMPLETE, TR_CITY_MESSAGE_TEXT_GRAND_TEMPLE_COMPLETE, TR_CITY_MESSAGE_TITLE_MERCURY_BLESSING, diff --git a/src/widget/city_building_ghost.c b/src/widget/city_building_ghost.c index 5922c0eb63..114cc339f6 100644 --- a/src/widget/city_building_ghost.c +++ b/src/widget/city_building_ghost.c @@ -412,10 +412,6 @@ static int is_fully_blocked(int map_x, int map_y, building_type type, int buildi if (!building_monument_type_is_mini_monument(type) && building_monument_get_id(type)) { return 1; } - if (building_monument_is_grand_temple(type) && - building_monument_count_grand_temples() >= config_get(CONFIG_GP_CH_MAX_GRAND_TEMPLES)) { - return 1; - } if (city_finance_out_of_money()) { return 1; } diff --git a/src/window/config.c b/src/window/config.c index 85cdba5bca..c6109f6f94 100644 --- a/src/window/config.c +++ b/src/window/config.c @@ -95,7 +95,6 @@ enum { RANGE_VIDEO_VOLUME, RANGE_SCROLL_SPEED, RANGE_DIFFICULTY, - RANGE_MAX_GRAND_TEMPLES, RANGE_MAX_AUTOSAVE_SLOTS, RANGE_DEFAULT_GAME_SPEED, }; @@ -152,7 +151,6 @@ static const uint8_t *display_text_city_sounds_volume(void); static const uint8_t *display_text_video_volume(void); static const uint8_t *display_text_scroll_speed(void); static const uint8_t *display_text_difficulty(void); -static const uint8_t *display_text_max_grand_temples(void); static const uint8_t *display_text_autosave_slots(void); static const uint8_t *display_text_default_game_speed(void); @@ -290,8 +288,6 @@ static config_widget page_difficulty[] = { {TYPE_CHECKBOX, CONFIG_GP_CH_MULTIPLE_BARRACKS, TR_CONFIG_MULTIPLE_BARRACKS, NULL, 0, 1, ITEM_BASE_H, CHECKBOX_MARGIN}, {TYPE_CHECKBOX, CONFIG_GP_CH_RANDOM_COLLAPSES_TAKE_MONEY, TR_CONFIG_RANDOM_COLLAPSES_TAKE_MONEY, NULL, 0, 1, ITEM_BASE_H, CHECKBOX_MARGIN}, {TYPE_CHECKBOX, CONFIG_GP_CH_DISABLE_INFINITE_WOLVES_SPAWNING, TR_CONFIG_GP_CH_DISABLE_INFINITE_WOLVES_SPAWNING, NULL, 0, 1, ITEM_BASE_H, CHECKBOX_MARGIN}, - {TYPE_NUMERICAL_DESC, RANGE_MAX_GRAND_TEMPLES, TR_CONFIG_MAX_GRAND_TEMPLES, NULL, 0, 1, ITEM_BASE_H, 10}, - {TYPE_NUMERICAL_RANGE, RANGE_MAX_GRAND_TEMPLES, 0, display_text_max_grand_temples, 0, 1, ITEM_BASE_H, 2}, {TYPE_SPACE, 0, 0, NULL, 0, 1, ITEM_BASE_H, 0}, {TYPE_SPACE, 0, 0, NULL, 0, 1, ITEM_BASE_H, 0}, //two spaces to visually match the padding to the general settings {TYPE_NONE} @@ -421,7 +417,6 @@ static numerical_range_widget ranges[] = { {130, 25, 0, 100, 1, 0}, // video % { 50, 18, 0, 100, 10, 0}, // scroll speed % {146, 24, 0, 4, 1, 0}, // difficulty enum index (0..4) - { 50, 30, 0, 5, 1, 0}, // max grand temples { 50, 30, 1, 20, 1, 0}, // autosave slots { 50, 30, 0, TOTAL_GAME_SPEEDS - 1, 1, 0}, // default game speed index @@ -872,11 +867,6 @@ static const uint8_t *display_text_difficulty(void) { return lang_get_string(153, data.config_values[CONFIG_ORIGINAL_DIFFICULTY].new_value + 1); } -static const uint8_t *display_text_max_grand_temples(void) -{ - string_from_int(data.display_text, data.config_values[CONFIG_GP_CH_MAX_GRAND_TEMPLES].new_value, 0); - return data.display_text; -} static const uint8_t *display_text_autosave_slots(void) { string_from_int(data.display_text, data.config_values[CONFIG_GP_CH_MAX_AUTOSAVE_SLOTS].new_value, 0); @@ -903,7 +893,6 @@ static void set_range_values(void) ranges[RANGE_VIDEO_VOLUME].value = &data.config_values[CONFIG_GENERAL_VIDEO_VOLUME].new_value; ranges[RANGE_SCROLL_SPEED].value = &data.config_values[CONFIG_ORIGINAL_SCROLL_SPEED].new_value; ranges[RANGE_DIFFICULTY].value = &data.config_values[CONFIG_ORIGINAL_DIFFICULTY].new_value; - ranges[RANGE_MAX_GRAND_TEMPLES].value = &data.config_values[CONFIG_GP_CH_MAX_GRAND_TEMPLES].new_value; ranges[RANGE_MAX_AUTOSAVE_SLOTS].value = &data.config_values[CONFIG_GP_CH_MAX_AUTOSAVE_SLOTS].new_value; ranges[RANGE_DEFAULT_GAME_SPEED].value = &data.config_values[CONFIG_GP_CH_DEFAULT_GAME_SPEED].new_value; } From 2729e4f7013cb29427e3e4479b98e7f3d3f6443d Mon Sep 17 00:00:00 2001 From: William Hardy Gest Date: Sun, 15 Mar 2026 11:15:47 -0500 Subject: [PATCH 12/12] Fix build --- src/window/building/house.c | 52 ++++++++++++++++++------------------- src/window/building_info.c | 2 +- 2 files changed, 27 insertions(+), 27 deletions(-) diff --git a/src/window/building/house.c b/src/window/building/house.c index 4f1ff2919f..b7147fdcb7 100644 --- a/src/window/building/house.c +++ b/src/window/building/house.c @@ -129,35 +129,35 @@ static void draw_happiness_info(building_info_context *c, int y_offset) } } -static void draw_debug_info(building_info_context *c, int y_offset) -{ - // DEBUG: Display entertainment and desirability values - building *b = building_get(c->building_id); +// static void draw_debug_info(building_info_context *c, int y_offset) +// { +// // DEBUG: Display entertainment and desirability values +// building *b = building_get(c->building_id); - // Desirability (from building) - int width = text_draw(string_from_ascii("Desirability (actual): "), - c->x_offset + 36, y_offset + 16, FONT_NORMAL_RED, 0); - text_draw_number(b->desirability, '@', " ", - c->x_offset + 36 + width, y_offset + 16, FONT_NORMAL_RED, 0); +// // Desirability (from building) +// int width = text_draw(string_from_ascii("Desirability (actual): "), +// c->x_offset + 36, y_offset + 16, FONT_NORMAL_RED, 0); +// text_draw_number(b->desirability, '@', " ", +// c->x_offset + 36 + width, y_offset + 16, FONT_NORMAL_RED, 0); - // Desirability (from map) - int map_desir = map_desirability_get_max(b->x, b->y, b->size); - width = text_draw(string_from_ascii("Desirability (map): "), - c->x_offset + 36, y_offset + 32, FONT_NORMAL_RED, 0); - text_draw_number(map_desir, '@', " ", - c->x_offset + 36 + width, y_offset + 32, FONT_NORMAL_RED, 0); +// // Desirability (from map) +// int map_desir = map_desirability_get_max(b->x, b->y, b->size); +// width = text_draw(string_from_ascii("Desirability (map): "), +// c->x_offset + 36, y_offset + 32, FONT_NORMAL_RED, 0); +// text_draw_number(map_desir, '@', " ", +// c->x_offset + 36 + width, y_offset + 32, FONT_NORMAL_RED, 0); - // Entertainment: current score vs required - int ent_have = b->data.house.entertainment; - int ent_need = model_get_house(b->subtype.house_level)->entertainment; - width = text_draw(string_from_ascii("Entertainment (have/need): "), - c->x_offset + 36, y_offset + 48, FONT_NORMAL_RED, 0); - width += text_draw_number(ent_have, '@', "/", - c->x_offset + 36 + width, y_offset + 48, FONT_NORMAL_RED, 0); - text_draw_number(ent_need, '@', " ", - c->x_offset + 36 + width, y_offset + 48, FONT_NORMAL_RED, 0); +// // Entertainment: current score vs required +// int ent_have = b->data.house.entertainment; +// int ent_need = model_get_house(b->subtype.house_level)->entertainment; +// width = text_draw(string_from_ascii("Entertainment (have/need): "), +// c->x_offset + 36, y_offset + 48, FONT_NORMAL_RED, 0); +// width += text_draw_number(ent_have, '@', "/", +// c->x_offset + 36 + width, y_offset + 48, FONT_NORMAL_RED, 0); +// text_draw_number(ent_need, '@', " ", +// c->x_offset + 36 + width, y_offset + 48, FONT_NORMAL_RED, 0); -} +// } void window_building_draw_house(building_info_context *c) { @@ -178,7 +178,7 @@ void window_building_draw_house(building_info_context *c) draw_population_info(c, c->y_offset + 134); draw_tax_info(c, c->y_offset + 174); draw_happiness_info(c, c->y_offset + 194); - draw_debug_info(c, c->y_offset + 305); + // draw_debug_info(c, c->y_offset + 305); int x_offset = 32; int y_content = 259; diff --git a/src/window/building_info.c b/src/window/building_info.c index 9d40a8851d..25406b9f45 100644 --- a/src/window/building_info.c +++ b/src/window/building_info.c @@ -248,6 +248,7 @@ static int get_height_id(void) case BUILDING_GRAND_TEMPLE_CERES_REWORKED: case BUILDING_GRAND_TEMPLE_NEPTUNE_REWORKED: case BUILDING_GRAND_TEMPLE_MERCURY_REWORKED: + case BUILDING_GRAND_TEMPLE_MARS_REWORKED: case BUILDING_PANTHEON: case BUILDING_PANTHEON_REWORKED: case BUILDING_HIPPODROME: @@ -256,7 +257,6 @@ static int get_height_id(void) //736px case BUILDING_GRAND_TEMPLE_MARS: - case BUILDING_GRAND_TEMPLE_MARS_REWORKED: return HEIGHT_10_46_BLOCKS; //448px