1 #include "building/building.h" 2 3 #ifndef BUILDING_HOUSE_POPULATION_H 4 #define BUILDING_HOUSE_POPULATION_H 5 6 /** 7 * Add people to the houses in the city, use for births 8 * @param num_people Number of people to add 9 * @return Number of people added 10 */ 11 int house_population_add_to_city(int num_people); 12 13 /** 14 * Removes people from the houses in the city, use for births and troop requests 15 * @param num_people Number of people to remove 16 * @return Number of people removed 17 */ 18 int house_population_remove_from_city(int num_people); 19 20 /** 21 * Update room available in houses 22 */ 23 void house_population_update_room(void); 24 25 /** 26 * Update migration statistics and create immigrants/emigrants 27 */ 28 void house_population_update_migration(void); 29 30 /** 31 * Evict people from overcrowded houses 32 */ 33 void house_population_evict_overcrowded(void); 34 35 /** 36 * Create immigrants 37 * @param num_people Number of people to immigrate 38 * @return Number of people actually immigrated 39 */ 40 int house_population_create_immigrants(int num_people); 41 42 /** 43 * Create emigrants 44 * @param num_people Number of people to emigrate 45 * @return Number of people actually emigrated 46 */ 47 int house_population_create_emigrants(int num_people); 48 49 int house_population_get_capacity(building *house); 50 51 #endif // BUILDING_HOUSE_POPULATION_H 52