//---------- Begin of function FirmWork::next_day --------// // void FirmWork::next_day() { Firm::next_day(); //------ recruit workers ---------// if( info.game_date%5 == firm_recno%5 ) // recruit workers once 5 days recruit_worker(); //--- reduce independent town resistance if their people work here ---// if( info.game_date%15 == firm_recno%15 ) process_independent_town_worker(); //----- calculate productivity -----// calc_productivity(); }
//--------- Begin of function FirmResearch::next_day ---------// // void FirmResearch::next_day() { //----- call next_day() of the base class -----// Firm::next_day(); //----------- update population -------------// recruit_worker(); //-------- train up the skill ------------// update_worker(); //--------- calculate productivity ----------// calc_productivity(); //--------- process research ----------// process_research(); }
//--------- Begin of function FirmMine::next_day ---------// // void FirmMine::next_day() { //----- call next_day() of the base class -----// Firm::next_day(); //----------- update population -------------// recruit_worker(); //-------- train up the skill ------------// update_worker(); //---------------------------------------// if( info.game_date%PROCESS_GOODS_INTERVAL == firm_recno%PROCESS_GOODS_INTERVAL ) // produce raw materials once every 3 days { produce_raw(); set_next_output_firm(); // set next output firm } }
//--------- Begin of function FirmFactory::next_day ---------// // void FirmFactory::next_day() { //----- call next_day() of the base class -----// Firm::next_day(); //----------- update population -------------// recruit_worker(); //-------- train up the skill ------------// update_worker(); //--------- daily manufacturing activities ---------// if( info.game_date%PROCESS_GOODS_INTERVAL == firm_recno%PROCESS_GOODS_INTERVAL ) { input_raw(); production(); set_next_output_firm(); // set next output firm } }