1 #ifndef CITY_DATA_PRIVATE_H 2 #define CITY_DATA_PRIVATE_H 3 4 #include <stdint.h> 5 6 #include "city/emperor.h" 7 #include "city/finance.h" 8 #include "city/houses.h" 9 #include "city/labor.h" 10 #include "city/resource.h" 11 #include "map/point.h" 12 13 typedef struct { 14 int8_t happiness; 15 int8_t target_happiness; 16 int8_t wrath_bolts; 17 int8_t blessing_done; 18 int8_t small_curse_done; 19 int32_t months_since_festival; 20 int8_t unused1; 21 int8_t unused2; 22 int8_t unused3; 23 } god_status; 24 25 extern struct city_data_t { 26 struct { 27 int16_t senate_placed; 28 uint8_t senate_x; 29 uint8_t senate_y; 30 int16_t senate_grid_offset; 31 int32_t senate_building_id; 32 int32_t hippodrome_placed; 33 int8_t barracks_x; 34 int8_t barracks_y; 35 int16_t barracks_grid_offset; 36 int32_t barracks_building_id; 37 int32_t barracks_placed; 38 int8_t distribution_center_x; 39 int8_t distribution_center_y; 40 int16_t distribution_center_grid_offset; 41 int32_t distribution_center_building_id; 42 int32_t distribution_center_placed; 43 int32_t trade_center_building_id; 44 int8_t triumphal_arches_available; 45 int8_t triumphal_arches_placed; 46 int16_t working_wharfs; 47 int32_t shipyard_boats_requested; 48 int16_t working_docks; 49 int16_t working_dock_ids[10]; 50 int32_t mission_post_operational; 51 map_point main_native_meeting; 52 int8_t unknown_value; 53 } building; 54 struct { 55 int16_t animals; 56 int32_t attacking_natives; 57 int32_t enemies; 58 int32_t imperial_soldiers; 59 int32_t rioters; 60 int32_t soldiers; 61 int32_t security_breach_duration; 62 } figure; 63 house_demands houses; 64 struct { 65 emperor_gift gifts[3]; 66 int32_t selected_gift_size; 67 int32_t months_since_gift; 68 int32_t gift_overdose_penalty; 69 70 int32_t debt_state; 71 int32_t months_in_debt; 72 73 int32_t player_rank; 74 int32_t salary_rank; 75 int32_t salary_amount; 76 int32_t donate_amount; 77 int32_t personal_savings; 78 struct { 79 int32_t count; 80 int32_t size; 81 int32_t soldiers_killed; 82 int32_t warnings_given; 83 int32_t days_until_invasion; 84 int32_t duration_day_countdown; 85 int32_t retreat_message_shown; 86 } invasion; 87 } emperor; 88 struct { 89 uint8_t total_legions; 90 uint8_t total_soldiers; 91 uint8_t empire_service_legions; 92 int32_t legionary_legions; 93 int32_t native_attack_duration; 94 } military; 95 struct { 96 uint8_t city; 97 int8_t city_foreign_months_left; 98 int8_t total_count; 99 int8_t won_count; 100 uint8_t enemy_strength; 101 uint8_t roman_strength; 102 int8_t months_until_battle; 103 int8_t roman_months_to_travel_forth; 104 int8_t roman_months_to_travel_back; 105 int8_t enemy_months_traveled; 106 int8_t roman_months_traveled; 107 } distant_battle; 108 struct { 109 int32_t treasury; 110 int32_t tax_percentage; 111 int32_t estimated_tax_income; 112 int32_t estimated_wages; 113 finance_overview last_year; 114 finance_overview this_year; 115 int32_t interest_so_far; 116 int32_t salary_so_far; 117 int32_t wages_so_far; 118 int16_t stolen_this_year; 119 int16_t stolen_last_year; 120 int32_t cheated_money; 121 int32_t tribute_not_paid_last_year; 122 int32_t tribute_not_paid_total_years; 123 int32_t wage_rate_paid_this_year; 124 int32_t wage_rate_paid_last_year; 125 } finance; 126 struct { 127 int32_t taxed_plebs; 128 int32_t taxed_patricians; 129 int32_t untaxed_plebs; 130 int32_t untaxed_patricians; 131 int32_t percentage_taxed_plebs; 132 int32_t percentage_taxed_patricians; 133 int32_t percentage_taxed_people; 134 struct { 135 int32_t collected_plebs; 136 int32_t collected_patricians; 137 int32_t uncollected_plebs; 138 int32_t uncollected_patricians; 139 } yearly; 140 struct { 141 int32_t collected_plebs; 142 int32_t collected_patricians; 143 int32_t uncollected_plebs; 144 int32_t uncollected_patricians; 145 } monthly; 146 } taxes; 147 struct { 148 int32_t population; 149 int32_t population_last_year; 150 int32_t school_age; 151 int32_t academy_age; 152 int32_t working_age; 153 struct { 154 int32_t values[2400]; 155 int32_t next_index; 156 int32_t count; 157 } monthly; 158 int16_t at_age[100]; 159 int32_t at_level[20]; 160 161 int32_t yearly_update_requested; 162 int32_t yearly_births; 163 int32_t yearly_deaths; 164 int32_t lost_removal; 165 int32_t lost_homeless; 166 int32_t lost_troop_request; 167 int32_t last_change; 168 int32_t total_all_years; 169 int32_t total_years; 170 int32_t average_per_year; 171 int32_t highest_ever; 172 int32_t total_capacity; 173 int32_t room_in_houses; 174 175 int32_t people_in_tents; 176 int32_t people_in_tents_shacks; 177 int32_t people_in_large_insula_and_above; 178 int32_t people_in_villas_palaces; 179 int32_t percentage_plebs; 180 181 int32_t last_used_house_add; 182 int32_t last_used_house_remove; 183 int32_t graph_order; 184 } population; 185 struct { 186 int32_t wages; 187 int32_t wages_rome; 188 int32_t workers_available; 189 int32_t workers_employed; 190 int32_t workers_unemployed; 191 int32_t workers_needed; 192 int32_t unemployment_percentage; 193 int32_t unemployment_percentage_for_senate; 194 labor_category_data categories[10]; 195 } labor; 196 struct { 197 int32_t immigration_duration; 198 int32_t emigration_duration; 199 int32_t immigration_amount_per_batch; 200 int32_t emigration_amount_per_batch; 201 int32_t immigration_queue_size; 202 int32_t emigration_queue_size; 203 int32_t immigrated_today; 204 int32_t emigrated_today; 205 int32_t refused_immigrants_today; 206 int32_t no_immigration_cause; 207 int32_t percentage; 208 int32_t newcomers; 209 int32_t emigration_message_shown; 210 } migration; 211 struct { 212 int32_t value; 213 int32_t previous_value; 214 int32_t message_delay; 215 216 int8_t include_tents; 217 int32_t unemployment; 218 int32_t wages; 219 int32_t low_mood_cause; 220 221 int32_t protesters; 222 int32_t criminals; // muggers+rioters 223 } sentiment; 224 struct { 225 int32_t num_hospital_workers; 226 int32_t target_value; 227 int32_t value; 228 } health; 229 struct { 230 int32_t culture; 231 int32_t prosperity; 232 int32_t peace; 233 int32_t favor; 234 struct { 235 int32_t theater; 236 int32_t religion; 237 int32_t school; 238 int32_t library; 239 int32_t academy; 240 } culture_points; 241 int32_t prosperity_treasury_last_year; 242 int32_t prosperity_max; 243 int32_t peace_destroyed_buildings; 244 int32_t peace_years_of_peace; 245 int32_t peace_num_criminals; 246 int32_t peace_num_rioters; 247 int32_t peace_riot_cause; 248 int32_t favor_salary_penalty; 249 int32_t favor_milestone_penalty; 250 int32_t favor_ignored_request_penalty; 251 int32_t favor_last_year; 252 int32_t favor_change; // 0 = dropping, 1 = stalling, 2 = rising 253 254 int32_t selected; 255 int32_t culture_explanation; 256 int32_t prosperity_explanation; 257 int32_t peace_explanation; 258 int32_t favor_explanation; 259 } ratings; 260 struct { 261 int32_t average_entertainment; 262 int32_t average_religion; 263 int32_t average_education; 264 int32_t average_health; 265 int32_t religion_coverage; 266 } culture; 267 struct { 268 god_status gods[5]; 269 int32_t least_happy_god; 270 int32_t angry_message_delay; 271 int32_t venus_curse_active; 272 int32_t neptune_double_trade_active; 273 int32_t neptune_sank_ships; 274 int32_t mars_spirit_power; 275 } religion; 276 struct { 277 int32_t theater_shows; 278 int32_t theater_no_shows_weighted; 279 int32_t amphitheater_shows; 280 int32_t amphitheater_no_shows_weighted; 281 int32_t colosseum_shows; 282 int32_t colosseum_no_shows_weighted; 283 int32_t hippodrome_shows; 284 int32_t hippodrome_no_shows_weighted; 285 int32_t venue_needing_shows; 286 int32_t hippodrome_has_race; 287 int32_t hippodrome_message_shown; 288 int32_t colosseum_message_shown; 289 } entertainment; 290 struct { 291 struct { 292 int32_t months_to_go; 293 int32_t god; 294 int32_t size; 295 } planned; 296 struct { 297 int32_t god; 298 int32_t size; 299 } selected; 300 int32_t small_cost; 301 int32_t large_cost; 302 int32_t grand_cost; 303 int32_t grand_wine; 304 int32_t not_enough_wine; 305 306 int32_t months_since_festival; 307 int32_t first_festival_effect_months; 308 int32_t second_festival_effect_months; 309 } festival; 310 struct { 311 int16_t space_in_warehouses[RESOURCE_MAX]; 312 int16_t stored_in_warehouses[RESOURCE_MAX]; 313 int32_t space_in_workshops[6]; 314 int32_t stored_in_workshops[6]; 315 int16_t trade_status[RESOURCE_MAX]; 316 int16_t export_over[RESOURCE_MAX]; 317 int32_t stockpiled[RESOURCE_MAX]; 318 int16_t mothballed[RESOURCE_MAX]; 319 int32_t wine_types_available; 320 int32_t food_types_available; 321 int32_t food_types_eaten; 322 int32_t granary_food_stored[RESOURCE_MAX_FOOD]; 323 int32_t granary_total_stored; 324 int32_t food_supply_months; 325 int32_t food_needed_per_month; 326 int32_t food_consumed_last_month; 327 int32_t food_produced_last_month; 328 int32_t food_produced_this_month; 329 struct { 330 int operating; 331 int not_operating; 332 int not_operating_with_food; 333 int understaffed; 334 } granaries; 335 int16_t last_used_warehouse; 336 } resource; 337 struct { 338 int8_t march_enemy; 339 int8_t march_horse; 340 int8_t march_wolf; 341 int8_t shoot_arrow; 342 int8_t hit_soldier; 343 int8_t hit_spear; 344 int8_t hit_club; 345 int8_t hit_elephant; 346 int8_t hit_axe; 347 int8_t hit_wolf; 348 int8_t die_citizen; 349 int8_t die_soldier; 350 } sound; 351 struct { 352 int16_t num_land_routes; 353 int16_t num_sea_routes; 354 int16_t land_trade_problem_duration; 355 int16_t sea_trade_problem_duration; 356 int32_t caravan_import_resource; 357 int32_t caravan_backup_import_resource; 358 int32_t docker_import_resource; 359 int32_t docker_export_resource; 360 } trade; 361 struct { 362 map_tile entry_point; 363 map_tile exit_point; 364 map_tile entry_flag; 365 map_tile exit_flag; 366 struct { 367 int32_t id; 368 int32_t size; 369 } largest_road_networks[10]; 370 } map; 371 struct { 372 int32_t has_won; 373 int32_t continue_months_left; 374 int32_t continue_months_chosen; 375 int32_t fired_message_shown; 376 int32_t victory_message_shown; 377 int32_t start_saved_game_written; 378 int32_t tutorial_fire_message_shown; 379 int32_t tutorial_disease_message_shown; 380 int32_t tutorial_senate_built; 381 } mission; 382 struct { 383 int8_t other_player[18068]; 384 int8_t unknown_00a0; 385 int8_t unknown_00a1; 386 int8_t unknown_00a2; 387 int8_t unknown_00a3; 388 int8_t unknown_00a4; 389 int8_t unknown_00a6; 390 int8_t unknown_00a7; 391 int32_t unknown_00c0; 392 int32_t unused_27d0; 393 int32_t unknown_27e0[4]; 394 int16_t unknown_27f0; 395 int16_t unknown_27f4[18]; 396 int16_t unknown_2828; 397 int16_t unused_28ca; 398 int8_t unknown_2924[272]; 399 int32_t unknown_2b6c; 400 int32_t unknown_2c20[1400]; 401 int32_t houses_requiring_unknown_to_evolve[8]; 402 int32_t unknown_4238[4]; 403 int32_t unknown_4284; 404 int32_t unknown_4294[2]; 405 int32_t unknown_4334; 406 int32_t unknown_4374[2]; 407 int16_t unknown_439c[3]; 408 int8_t padding_43b2[2]; 409 int32_t unknown_43d8[5]; 410 int32_t unknown_43f0; 411 int32_t unused_4454; 412 int32_t unknown_446c[4]; 413 int32_t unused_4488; 414 int32_t unused_native_force_attack; 415 int32_t unused_44e0[2]; 416 int32_t unused_44ec; 417 int32_t unused_44f8; 418 int32_t unused_4524[11]; 419 uint8_t unknown_458e; 420 int8_t unused_45a5[6]; 421 int8_t unknown_464c[232]; 422 int32_t unknown_order; 423 int32_t faction_id; 424 uint8_t faction_bytes[2]; 425 } unused; 426 } city_data; 427 428 #endif // CITY_DATA_PRIVATE_H 429