/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_city_load(const struct section_file *file, struct city *pcity, const char *citystr) { struct ai_type *deftype = classic_ai_get_self(); dai_city_load(deftype, "ai", file, pcity, citystr); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_unit_load(const struct section_file *file, struct unit *punit, const char *unitstr) { struct ai_type *deftype = classic_ai_get_self(); dai_unit_load(deftype, "", file, punit, unitstr); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_player_save(struct player *pplayer, struct section_file *file, int plrno) { struct ai_type *deftype = classic_ai_get_self(); dai_player_save(deftype, "ai", pplayer, file, plrno); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_unit_new_adv_task(struct unit *punit, enum adv_unit_task task, struct tile *ptile) { struct ai_type *deftype = classic_ai_get_self(); dai_unit_new_adv_task(deftype, punit, task, ptile); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_consider_plr_dangerous(struct player *plr1, struct player *plr2, enum danger_consideration *result) { struct ai_type *deftype = classic_ai_get_self(); dai_consider_plr_dangerous(deftype, plr1, plr2, result); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_auto_settler_cont(struct player *pplayer, struct unit *punit, struct settlermap *state) { struct ai_type *deftype = classic_ai_get_self(); dai_auto_settler_cont(deftype, pplayer, punit, state); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_treaty_accepted(struct player *pplayer, struct player *aplayer, struct Treaty *ptreaty) { struct ai_type *deftype = classic_ai_get_self(); dai_treaty_accepted(deftype, pplayer, aplayer, ptreaty); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_diplomacy_first_contact(struct player *pplayer, struct player *aplayer) { struct ai_type *deftype = classic_ai_get_self(); dai_diplomacy_first_contact(deftype, pplayer, aplayer); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_incident(enum incident_type type, struct player *violator, struct player *victim) { struct ai_type *deftype = classic_ai_get_self(); dai_incident(deftype, type, violator, victim); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_unit_move_or_attack(struct unit *punit, struct tile *ptile, struct pf_path *path, int step) { struct ai_type *deftype = classic_ai_get_self(); dai_unit_move_or_attack(deftype, punit, ptile, path, step); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_consider_tile_dangerous(struct tile *ptile, struct unit *punit, enum danger_consideration *result) { struct ai_type *deftype = classic_ai_get_self(); dai_consider_tile_dangerous(deftype, ptile, punit, result); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_do_first_activities(struct player *pplayer) { struct ai_type *deftype = classic_ai_get_self(); dai_do_first_activities(deftype, pplayer); pplayer->ai_phase_done = TRUE; }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_city_log(char *buffer, int buflength, const struct city *pcity) { struct ai_type *deftype = classic_ai_get_self(); dai_city_log(deftype, buffer, buflength, pcity); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_unit_close(struct unit *punit) { struct ai_type *deftype = classic_ai_get_self(); dai_unit_close(deftype, punit); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_units_ruleset_close(void) { struct ai_type *deftype = classic_ai_get_self(); dai_units_ruleset_close(deftype); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_do_last_activities(struct player *pplayer) { struct ai_type *deftype = classic_ai_get_self(); dai_do_last_activities(deftype, pplayer); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_ferry_init_ferry(struct unit *ferry) { struct ai_type *deftype = classic_ai_get_self(); dai_ferry_init_ferry(deftype, ferry); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_ferry_transformed(struct unit *ferry, struct unit_type *old) { struct ai_type *deftype = classic_ai_get_self(); dai_ferry_transformed(deftype, ferry, old); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_diplomacy_actions(struct player *pplayer) { struct ai_type *deftype = classic_ai_get_self(); dai_diplomacy_actions(deftype, pplayer); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_wonder_city_distance(struct player *pplayer, struct adv_data *adv) { struct ai_type *deftype = classic_ai_get_self(); dai_wonder_city_distance(deftype, pplayer, adv); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_build_adv_adjust(struct player *pplayer, struct city *wonder_city) { struct ai_type *deftype = classic_ai_get_self(); dai_build_adv_adjust(deftype, pplayer, wonder_city); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_unit_log(char *buffer, int buflength, const struct unit *punit) { struct ai_type *deftype = classic_ai_get_self(); dai_unit_log(deftype, buffer, buflength, punit); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_ferry_lost(struct unit *punit) { struct ai_type *deftype = classic_ai_get_self(); dai_ferry_lost(deftype, punit); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_unit_turn_end(struct unit *punit) { struct ai_type *deftype = classic_ai_get_self(); dai_unit_turn_end(deftype, punit); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_player_free(struct player *pplayer) { struct ai_type *deftype = classic_ai_get_self(); dai_player_free(deftype, pplayer); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_build_adv_init(struct player *pplayer) { struct ai_type *deftype = classic_ai_get_self(); dai_build_adv_init(deftype, pplayer); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_consider_wonder_city(struct city *pcity, bool *result) { struct ai_type *deftype = classic_ai_get_self(); dai_consider_wonder_city(deftype, pcity, result); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_city_free(struct city *pcity) { struct ai_type *deftype = classic_ai_get_self(); dai_city_free(deftype, pcity); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_auto_settler_reset(struct player *pplayer) { struct ai_type *deftype = classic_ai_get_self(); dai_auto_settler_reset(deftype, pplayer); }
/************************************************************************** Call default ai with classic ai type as parameter. **************************************************************************/ static void cai_build_adv_override(struct city *pcity, struct adv_choice *choice) { struct ai_type *deftype = classic_ai_get_self(); dai_build_adv_override(deftype, pcity, choice); }