From 596428fa49b09ea1a0e0f17670ee127472576f37 Mon Sep 17 00:00:00 2001 From: Haru Date: Mon, 25 Jun 2018 23:27:54 +0200 Subject: HPM Hooks Update --- src/plugins/HPMHooking/HPMHooking.Defs.inc | 188 +- .../HPMHooking/HPMHooking_char.HPMHooksCore.inc | 312 ++- .../HPMHooking/HPMHooking_char.HookingPoints.inc | 78 +- src/plugins/HPMHooking/HPMHooking_char.Hooks.inc | 2710 +++++++++++++------- 4 files changed, 2151 insertions(+), 1137 deletions(-) (limited to 'src/plugins/HPMHooking') diff --git a/src/plugins/HPMHooking/HPMHooking.Defs.inc b/src/plugins/HPMHooking/HPMHooking.Defs.inc index 8aa1c6512..e1d9af73a 100644 --- a/src/plugins/HPMHooking/HPMHooking.Defs.inc +++ b/src/plugins/HPMHooking/HPMHooking.Defs.inc @@ -436,8 +436,10 @@ typedef bool (*HPMHOOK_pre_chr_char_slotchange) (struct char_session_data **sd, typedef bool (*HPMHOOK_post_chr_char_slotchange) (bool retVal___, struct char_session_data *sd, int fd, unsigned short from, unsigned short to); typedef int (*HPMHOOK_pre_chr_rename_char_sql) (struct char_session_data **sd, int *char_id); typedef int (*HPMHOOK_post_chr_rename_char_sql) (int retVal___, struct char_session_data *sd, int char_id); -typedef int (*HPMHOOK_pre_chr_check_char_name) (char **name, char **esc_name); -typedef int (*HPMHOOK_post_chr_check_char_name) (int retVal___, char *name, char *esc_name); +typedef bool (*HPMHOOK_pre_chr_name_exists) (const char **name, const char **esc_name); +typedef bool (*HPMHOOK_post_chr_name_exists) (bool retVal___, const char *name, const char *esc_name); +typedef int (*HPMHOOK_pre_chr_check_char_name) (const char **name, const char **esc_name); +typedef int (*HPMHOOK_post_chr_check_char_name) (int retVal___, const char *name, const char *esc_name); typedef int (*HPMHOOK_pre_chr_make_new_char_sql) (struct char_session_data **sd, const char **name_, int *str, int *agi, int *vit, int *int_, int *dex, int *luk, int *slot, int *hair_color, int *hair_style, short *starting_job, uint8 *sex); typedef int (*HPMHOOK_post_chr_make_new_char_sql) (int retVal___, struct char_session_data *sd, const char *name_, int str, int agi, int vit, int int_, int dex, int luk, int slot, int hair_color, int hair_style, short starting_job, uint8 sex); typedef int (*HPMHOOK_pre_chr_divorce_char_sql) (int *partner_id1, int *partner_id2); @@ -3022,6 +3024,14 @@ typedef void (*HPMHOOK_pre_inter_elemental_sql_final) (void); typedef void (*HPMHOOK_post_inter_elemental_sql_final) (void); typedef int (*HPMHOOK_pre_inter_elemental_parse_frommap) (int *fd); typedef int (*HPMHOOK_post_inter_elemental_parse_frommap) (int retVal___, int fd); +typedef bool (*HPMHOOK_pre_inter_elemental_create) (struct s_elemental **ele); +typedef bool (*HPMHOOK_post_inter_elemental_create) (bool retVal___, struct s_elemental *ele); +typedef bool (*HPMHOOK_pre_inter_elemental_save) (const struct s_elemental **ele); +typedef bool (*HPMHOOK_post_inter_elemental_save) (bool retVal___, const struct s_elemental *ele); +typedef bool (*HPMHOOK_pre_inter_elemental_load) (int *ele_id, int *char_id, struct s_elemental **ele); +typedef bool (*HPMHOOK_post_inter_elemental_load) (bool retVal___, int ele_id, int char_id, struct s_elemental *ele); +typedef bool (*HPMHOOK_pre_inter_elemental_delete) (int *ele_id); +typedef bool (*HPMHOOK_post_inter_elemental_delete) (bool retVal___, int ele_id); #endif // CHAR_INT_ELEMENTAL_H #ifdef CHAR_INT_GUILD_H /* inter_guild */ typedef int (*HPMHOOK_pre_inter_guild_save_timer) (int *tid, int64 *tick, int *id, intptr_t *data); @@ -3064,10 +3074,38 @@ typedef int (*HPMHOOK_pre_inter_guild_charname_changed) (int *guild_id, int *acc typedef int (*HPMHOOK_post_inter_guild_charname_changed) (int retVal___, int guild_id, int account_id, int char_id, char *name); typedef int (*HPMHOOK_pre_inter_guild_parse_frommap) (int *fd); typedef int (*HPMHOOK_post_inter_guild_parse_frommap) (int retVal___, int fd); -typedef int (*HPMHOOK_pre_inter_guild_leave) (int *guild_id, int *account_id, int *char_id); -typedef int (*HPMHOOK_post_inter_guild_leave) (int retVal___, int guild_id, int account_id, int char_id); typedef int (*HPMHOOK_pre_inter_guild_broken) (int *guild_id); typedef int (*HPMHOOK_post_inter_guild_broken) (int retVal___, int guild_id); +typedef struct guild* (*HPMHOOK_pre_inter_guild_create) (const char **name, const struct guild_member **master); +typedef struct guild* (*HPMHOOK_post_inter_guild_create) (struct guild* retVal___, const char *name, const struct guild_member *master); +typedef bool (*HPMHOOK_pre_inter_guild_add_member) (int *guild_id, const struct guild_member **member); +typedef bool (*HPMHOOK_post_inter_guild_add_member) (bool retVal___, int guild_id, const struct guild_member *member); +typedef bool (*HPMHOOK_pre_inter_guild_leave) (int *guild_id, int *account_id, int *char_id, int *flag, const char **mes, int *map_fd); +typedef bool (*HPMHOOK_post_inter_guild_leave) (bool retVal___, int guild_id, int account_id, int char_id, int flag, const char *mes, int map_fd); +typedef bool (*HPMHOOK_pre_inter_guild_update_member_info_short) (int *guild_id, int *account_id, int *char_id, int *online, int *lv, int16 *class); +typedef bool (*HPMHOOK_post_inter_guild_update_member_info_short) (bool retVal___, int guild_id, int account_id, int char_id, int online, int lv, int16 class); +typedef bool (*HPMHOOK_pre_inter_guild_update_member_info) (int *guild_id, int *account_id, int *char_id, int *type, const char **data, int *len); +typedef bool (*HPMHOOK_post_inter_guild_update_member_info) (bool retVal___, int guild_id, int account_id, int char_id, int type, const char *data, int len); +typedef bool (*HPMHOOK_pre_inter_guild_disband) (int *guild_id); +typedef bool (*HPMHOOK_post_inter_guild_disband) (bool retVal___, int guild_id); +typedef bool (*HPMHOOK_pre_inter_guild_update_basic_info) (int *guild_id, int *type, const void **data, int *len); +typedef bool (*HPMHOOK_post_inter_guild_update_basic_info) (bool retVal___, int guild_id, int type, const void *data, int len); +typedef bool (*HPMHOOK_pre_inter_guild_update_position) (int *guild_id, int *idx, const struct guild_position **p); +typedef bool (*HPMHOOK_post_inter_guild_update_position) (bool retVal___, int guild_id, int idx, const struct guild_position *p); +typedef bool (*HPMHOOK_pre_inter_guild_use_skill_point) (int *guild_id, uint16 *skill_id, int *account_id, int *max); +typedef bool (*HPMHOOK_post_inter_guild_use_skill_point) (bool retVal___, int guild_id, uint16 skill_id, int account_id, int max); +typedef bool (*HPMHOOK_pre_inter_guild_remove_alliance) (struct guild **g, int *guild_id, int *account_id1, int *account_id2, int *flag); +typedef bool (*HPMHOOK_post_inter_guild_remove_alliance) (bool retVal___, struct guild *g, int guild_id, int account_id1, int account_id2, int flag); +typedef bool (*HPMHOOK_pre_inter_guild_change_alliance) (int *guild_id1, int *guild_id2, int *account_id1, int *account_id2, int *flag); +typedef bool (*HPMHOOK_post_inter_guild_change_alliance) (bool retVal___, int guild_id1, int guild_id2, int account_id1, int account_id2, int flag); +typedef bool (*HPMHOOK_pre_inter_guild_update_notice) (int *guild_id, const char **mes1, const char **mes2); +typedef bool (*HPMHOOK_post_inter_guild_update_notice) (bool retVal___, int guild_id, const char *mes1, const char *mes2); +typedef bool (*HPMHOOK_pre_inter_guild_update_emblem) (int *len, int *guild_id, const char **data); +typedef bool (*HPMHOOK_post_inter_guild_update_emblem) (bool retVal___, int len, int guild_id, const char *data); +typedef bool (*HPMHOOK_pre_inter_guild_update_castle_data) (int *castle_id, int *index, int *value); +typedef bool (*HPMHOOK_post_inter_guild_update_castle_data) (bool retVal___, int castle_id, int index, int value); +typedef bool (*HPMHOOK_pre_inter_guild_change_leader) (int *guild_id, const char **name, int *len); +typedef bool (*HPMHOOK_post_inter_guild_change_leader) (bool retVal___, int guild_id, const char *name, int len); #endif // CHAR_INT_GUILD_H #ifdef CHAR_INT_HOMUN_H /* inter_homunculus */ typedef int (*HPMHOOK_pre_inter_homunculus_sql_init) (void); @@ -3076,6 +3114,16 @@ typedef void (*HPMHOOK_pre_inter_homunculus_sql_final) (void); typedef void (*HPMHOOK_post_inter_homunculus_sql_final) (void); typedef int (*HPMHOOK_pre_inter_homunculus_parse_frommap) (int *fd); typedef int (*HPMHOOK_post_inter_homunculus_parse_frommap) (int retVal___, int fd); +typedef bool (*HPMHOOK_pre_inter_homunculus_create) (struct s_homunculus **hd); +typedef bool (*HPMHOOK_post_inter_homunculus_create) (bool retVal___, struct s_homunculus *hd); +typedef bool (*HPMHOOK_pre_inter_homunculus_save) (const struct s_homunculus **hd); +typedef bool (*HPMHOOK_post_inter_homunculus_save) (bool retVal___, const struct s_homunculus *hd); +typedef bool (*HPMHOOK_pre_inter_homunculus_load) (int *homun_id, struct s_homunculus **hd); +typedef bool (*HPMHOOK_post_inter_homunculus_load) (bool retVal___, int homun_id, struct s_homunculus *hd); +typedef bool (*HPMHOOK_pre_inter_homunculus_delete) (int *homun_id); +typedef bool (*HPMHOOK_post_inter_homunculus_delete) (bool retVal___, int homun_id); +typedef bool (*HPMHOOK_pre_inter_homunculus_rename) (const char **name); +typedef bool (*HPMHOOK_post_inter_homunculus_rename) (bool retVal___, const char *name); #endif // CHAR_INT_HOMUN_H #ifdef CHAR_INTER_H /* inter */ typedef const char* (*HPMHOOK_pre_inter_msg_txt) (int *msg_number); @@ -3114,6 +3162,16 @@ typedef bool (*HPMHOOK_pre_inter_config_read_log) (const char **filename, const typedef bool (*HPMHOOK_post_inter_config_read_log) (bool retVal___, const char *filename, const struct config_t *config, bool imported); typedef bool (*HPMHOOK_pre_inter_config_read_connection) (const char **filename, const struct config_t **config, bool *imported); typedef bool (*HPMHOOK_post_inter_config_read_connection) (bool retVal___, const char *filename, const struct config_t *config, bool imported); +typedef void (*HPMHOOK_pre_inter_accinfo) (int *u_fd, int *aid, int *castergroup, const char **query, int *map_fd); +typedef void (*HPMHOOK_post_inter_accinfo) (int u_fd, int aid, int castergroup, const char *query, int map_fd); +typedef void (*HPMHOOK_pre_inter_accinfo2) (bool *success, int *map_fd, int *u_fd, int *u_aid, int *account_id, const char **userid, const char **user_pass, const char **email, const char **last_ip, const char **lastlogin, const char **pin_code, const char **birthdate, int *group_id, int *logincount, int *state); +typedef void (*HPMHOOK_post_inter_accinfo2) (bool success, int map_fd, int u_fd, int u_aid, int account_id, const char *userid, const char *user_pass, const char *email, const char *last_ip, const char *lastlogin, const char *pin_code, const char *birthdate, int group_id, int logincount, int state); +typedef struct WisData* (*HPMHOOK_pre_inter_add_wisdata) (int *fd, const unsigned char **src, const unsigned char **dst, const unsigned char **msg, int *msg_len); +typedef struct WisData* (*HPMHOOK_post_inter_add_wisdata) (struct WisData* retVal___, int fd, const unsigned char *src, const unsigned char *dst, const unsigned char *msg, int msg_len); +typedef struct WisData* (*HPMHOOK_pre_inter_get_wisdata) (int *id); +typedef struct WisData* (*HPMHOOK_post_inter_get_wisdata) (struct WisData* retVal___, int id); +typedef void (*HPMHOOK_pre_inter_remove_wisdata) (int *id); +typedef void (*HPMHOOK_post_inter_remove_wisdata) (int id); #endif // CHAR_INTER_H #ifdef CHAR_INT_MAIL_H /* inter_mail */ typedef int (*HPMHOOK_pre_inter_mail_sql_init) (void); @@ -3132,6 +3190,16 @@ typedef bool (*HPMHOOK_pre_inter_mail_DeleteAttach) (int *mail_id); typedef bool (*HPMHOOK_post_inter_mail_DeleteAttach) (bool retVal___, int mail_id); typedef void (*HPMHOOK_pre_inter_mail_sendmail) (int *send_id, const char **send_name, int *dest_id, const char **dest_name, const char **title, const char **body, int *zeny, struct item **item); typedef void (*HPMHOOK_post_inter_mail_sendmail) (int send_id, const char *send_name, int dest_id, const char *dest_name, const char *title, const char *body, int zeny, struct item *item); +typedef bool (*HPMHOOK_pre_inter_mail_mark_read) (int *mail_id); +typedef bool (*HPMHOOK_post_inter_mail_mark_read) (bool retVal___, int mail_id); +typedef bool (*HPMHOOK_pre_inter_mail_get_attachment) (int *char_id, int *mail_id, struct mail_message **msg); +typedef bool (*HPMHOOK_post_inter_mail_get_attachment) (bool retVal___, int char_id, int mail_id, struct mail_message *msg); +typedef bool (*HPMHOOK_pre_inter_mail_delete) (int *char_id, int *mail_id); +typedef bool (*HPMHOOK_post_inter_mail_delete) (bool retVal___, int char_id, int mail_id); +typedef bool (*HPMHOOK_pre_inter_mail_return_message) (int *char_id, int *mail_id, int **new_mail); +typedef bool (*HPMHOOK_post_inter_mail_return_message) (bool retVal___, int char_id, int mail_id, int *new_mail); +typedef bool (*HPMHOOK_pre_inter_mail_send) (int *account_id, struct mail_message **msg); +typedef bool (*HPMHOOK_post_inter_mail_send) (bool retVal___, int account_id, struct mail_message *msg); #endif // CHAR_INT_MAIL_H #ifdef CHAR_INT_MERCENARY_H /* inter_mercenary */ typedef bool (*HPMHOOK_pre_inter_mercenary_owner_fromsql) (int *char_id, struct mmo_charstatus **status); @@ -3146,6 +3214,14 @@ typedef void (*HPMHOOK_pre_inter_mercenary_sql_final) (void); typedef void (*HPMHOOK_post_inter_mercenary_sql_final) (void); typedef int (*HPMHOOK_pre_inter_mercenary_parse_frommap) (int *fd); typedef int (*HPMHOOK_post_inter_mercenary_parse_frommap) (int retVal___, int fd); +typedef bool (*HPMHOOK_pre_inter_mercenary_create) (struct s_mercenary **merc); +typedef bool (*HPMHOOK_post_inter_mercenary_create) (bool retVal___, struct s_mercenary *merc); +typedef bool (*HPMHOOK_pre_inter_mercenary_save) (const struct s_mercenary **merc); +typedef bool (*HPMHOOK_post_inter_mercenary_save) (bool retVal___, const struct s_mercenary *merc); +typedef bool (*HPMHOOK_pre_inter_mercenary_load) (int *merc_id, int *char_id, struct s_mercenary **merc); +typedef bool (*HPMHOOK_post_inter_mercenary_load) (bool retVal___, int merc_id, int char_id, struct s_mercenary *merc); +typedef bool (*HPMHOOK_pre_inter_mercenary_delete) (int *merc_id); +typedef bool (*HPMHOOK_post_inter_mercenary_delete) (bool retVal___, int merc_id); #endif // CHAR_INT_MERCENARY_H #ifdef CHAR_INT_PARTY_H /* inter_party */ typedef int (*HPMHOOK_pre_inter_party_check_lv) (struct party_data **p); @@ -3168,12 +3244,24 @@ typedef int (*HPMHOOK_pre_inter_party_check_empty) (struct party_data **p); typedef int (*HPMHOOK_post_inter_party_check_empty) (int retVal___, struct party_data *p); typedef int (*HPMHOOK_pre_inter_party_parse_frommap) (int *fd); typedef int (*HPMHOOK_post_inter_party_parse_frommap) (int retVal___, int fd); -typedef int (*HPMHOOK_pre_inter_party_leave) (int *party_id, int *account_id, int *char_id); -typedef int (*HPMHOOK_post_inter_party_leave) (int retVal___, int party_id, int account_id, int char_id); +typedef bool (*HPMHOOK_pre_inter_party_leave) (int *party_id, int *account_id, int *char_id); +typedef bool (*HPMHOOK_post_inter_party_leave) (bool retVal___, int party_id, int account_id, int char_id); typedef int (*HPMHOOK_pre_inter_party_CharOnline) (int *char_id, int *party_id); typedef int (*HPMHOOK_post_inter_party_CharOnline) (int retVal___, int char_id, int party_id); typedef int (*HPMHOOK_pre_inter_party_CharOffline) (int *char_id, int *party_id); typedef int (*HPMHOOK_post_inter_party_CharOffline) (int retVal___, int char_id, int party_id); +typedef struct party_data* (*HPMHOOK_pre_inter_party_create) (const char **name, int *item, int *item2, const struct party_member **leader); +typedef struct party_data* (*HPMHOOK_post_inter_party_create) (struct party_data* retVal___, const char *name, int item, int item2, const struct party_member *leader); +typedef bool (*HPMHOOK_pre_inter_party_add_member) (int *party_id, const struct party_member **member); +typedef bool (*HPMHOOK_post_inter_party_add_member) (bool retVal___, int party_id, const struct party_member *member); +typedef bool (*HPMHOOK_pre_inter_party_change_option) (int *party_id, int *account_id, int *exp, int *item, int *map_fd); +typedef bool (*HPMHOOK_post_inter_party_change_option) (bool retVal___, int party_id, int account_id, int exp, int item, int map_fd); +typedef bool (*HPMHOOK_pre_inter_party_change_map) (int *party_id, int *account_id, int *char_id, unsigned short *map, int *online, unsigned int *lv); +typedef bool (*HPMHOOK_post_inter_party_change_map) (bool retVal___, int party_id, int account_id, int char_id, unsigned short map, int online, unsigned int lv); +typedef bool (*HPMHOOK_pre_inter_party_disband) (int *party_id); +typedef bool (*HPMHOOK_post_inter_party_disband) (bool retVal___, int party_id); +typedef bool (*HPMHOOK_pre_inter_party_change_leader) (int *party_id, int *account_id, int *char_id); +typedef bool (*HPMHOOK_post_inter_party_change_leader) (bool retVal___, int party_id, int account_id, int char_id); #endif // CHAR_INT_PARTY_H #ifdef CHAR_INT_PET_H /* inter_pet */ typedef int (*HPMHOOK_pre_inter_pet_tosql) (const struct s_pet **p); @@ -3188,10 +3276,24 @@ typedef int (*HPMHOOK_pre_inter_pet_delete_) (int *pet_id); typedef int (*HPMHOOK_post_inter_pet_delete_) (int retVal___, int pet_id); typedef int (*HPMHOOK_pre_inter_pet_parse_frommap) (int *fd); typedef int (*HPMHOOK_post_inter_pet_parse_frommap) (int retVal___, int fd); +typedef struct s_pet* (*HPMHOOK_pre_inter_pet_create) (int *account_id, int *char_id, short *pet_class, short *pet_lv, short *pet_egg_id, short *pet_equip, short *intimate, short *hungry, char *rename_flag, char *incubate, const char **pet_name); +typedef struct s_pet* (*HPMHOOK_post_inter_pet_create) (struct s_pet* retVal___, int account_id, int char_id, short pet_class, short pet_lv, short pet_egg_id, short pet_equip, short intimate, short hungry, char rename_flag, char incubate, const char *pet_name); +typedef struct s_pet* (*HPMHOOK_pre_inter_pet_load) (int *account_id, int *char_id, int *pet_id); +typedef struct s_pet* (*HPMHOOK_post_inter_pet_load) (struct s_pet* retVal___, int account_id, int char_id, int pet_id); #endif // CHAR_INT_PET_H #ifdef CHAR_INT_QUEST_H /* inter_quest */ typedef int (*HPMHOOK_pre_inter_quest_parse_frommap) (int *fd); typedef int (*HPMHOOK_post_inter_quest_parse_frommap) (int retVal___, int fd); +typedef struct quest* (*HPMHOOK_pre_inter_quest_fromsql) (int *char_id, int **count); +typedef struct quest* (*HPMHOOK_post_inter_quest_fromsql) (struct quest* retVal___, int char_id, int *count); +typedef bool (*HPMHOOK_pre_inter_quest_delete) (int *char_id, int *quest_id); +typedef bool (*HPMHOOK_post_inter_quest_delete) (bool retVal___, int char_id, int quest_id); +typedef bool (*HPMHOOK_pre_inter_quest_add) (int *char_id, struct quest *qd); +typedef bool (*HPMHOOK_post_inter_quest_add) (bool retVal___, int char_id, struct quest qd); +typedef bool (*HPMHOOK_pre_inter_quest_update) (int *char_id, struct quest *qd); +typedef bool (*HPMHOOK_post_inter_quest_update) (bool retVal___, int char_id, struct quest qd); +typedef bool (*HPMHOOK_pre_inter_quest_save) (int *char_id, const struct quest **new_qd, int *new_n); +typedef bool (*HPMHOOK_post_inter_quest_save) (bool retVal___, int char_id, const struct quest *new_qd, int new_n); #endif // CHAR_INT_QUEST_H #ifdef CHAR_INT_RODEX_H /* inter_rodex */ typedef int (*HPMHOOK_pre_inter_rodex_sql_init) (void); @@ -3208,14 +3310,16 @@ typedef bool (*HPMHOOK_pre_inter_rodex_checkname) (const char **name, int **targ typedef bool (*HPMHOOK_post_inter_rodex_checkname) (bool retVal___, const char *name, int *target_char_id, short *target_class, int *target_level); typedef int64 (*HPMHOOK_pre_inter_rodex_savemessage) (struct rodex_message **msg); typedef int64 (*HPMHOOK_post_inter_rodex_savemessage) (int64 retVal___, struct rodex_message *msg); +typedef bool (*HPMHOOK_pre_inter_rodex_updatemail) (int64 *mail_id, int8 *flag); +typedef bool (*HPMHOOK_post_inter_rodex_updatemail) (bool retVal___, int64 mail_id, int8 flag); #endif // CHAR_INT_RODEX_H #ifdef CHAR_INT_STORAGE_H /* inter_storage */ typedef int (*HPMHOOK_pre_inter_storage_tosql) (int *account_id, const struct storage_data **p); typedef int (*HPMHOOK_post_inter_storage_tosql) (int retVal___, int account_id, const struct storage_data *p); typedef int (*HPMHOOK_pre_inter_storage_fromsql) (int *account_id, struct storage_data **p); typedef int (*HPMHOOK_post_inter_storage_fromsql) (int retVal___, int account_id, struct storage_data *p); -typedef int (*HPMHOOK_pre_inter_storage_guild_storage_tosql) (int *guild_id, const struct guild_storage **p); -typedef int (*HPMHOOK_post_inter_storage_guild_storage_tosql) (int retVal___, int guild_id, const struct guild_storage *p); +typedef bool (*HPMHOOK_pre_inter_storage_guild_storage_tosql) (int *guild_id, const struct guild_storage **p); +typedef bool (*HPMHOOK_post_inter_storage_guild_storage_tosql) (bool retVal___, int guild_id, const struct guild_storage *p); typedef int (*HPMHOOK_pre_inter_storage_guild_storage_fromsql) (int *guild_id, struct guild_storage **p); typedef int (*HPMHOOK_post_inter_storage_guild_storage_fromsql) (int retVal___, int guild_id, struct guild_storage *p); typedef int (*HPMHOOK_pre_inter_storage_sql_init) (void); @@ -3228,6 +3332,8 @@ typedef int (*HPMHOOK_pre_inter_storage_guild_storage_delete) (int *guild_id); typedef int (*HPMHOOK_post_inter_storage_guild_storage_delete) (int retVal___, int guild_id); typedef int (*HPMHOOK_pre_inter_storage_parse_frommap) (int *fd); typedef int (*HPMHOOK_post_inter_storage_parse_frommap) (int retVal___, int fd); +typedef bool (*HPMHOOK_pre_inter_storage_retrieve_bound_items) (int *char_id, int *account_id, int *guild_id); +typedef bool (*HPMHOOK_post_inter_storage_retrieve_bound_items) (bool retVal___, int char_id, int account_id, int guild_id); #endif // CHAR_INT_STORAGE_H #ifdef MAP_INTIF_H /* intif */ typedef int (*HPMHOOK_pre_intif_parse) (int *fd); @@ -4468,14 +4574,6 @@ typedef void (*HPMHOOK_pre_mapif_auction_bid) (int *fd, int *char_id, int *bid, typedef void (*HPMHOOK_post_mapif_auction_bid) (int fd, int char_id, int bid, unsigned char result); typedef void (*HPMHOOK_pre_mapif_parse_auction_bid) (int *fd); typedef void (*HPMHOOK_post_mapif_parse_auction_bid) (int fd); -typedef bool (*HPMHOOK_pre_mapif_elemental_create) (struct s_elemental **ele); -typedef bool (*HPMHOOK_post_mapif_elemental_create) (bool retVal___, struct s_elemental *ele); -typedef bool (*HPMHOOK_pre_mapif_elemental_save) (const struct s_elemental **ele); -typedef bool (*HPMHOOK_post_mapif_elemental_save) (bool retVal___, const struct s_elemental *ele); -typedef bool (*HPMHOOK_pre_mapif_elemental_load) (int *ele_id, int *char_id, struct s_elemental **ele); -typedef bool (*HPMHOOK_post_mapif_elemental_load) (bool retVal___, int ele_id, int char_id, struct s_elemental *ele); -typedef bool (*HPMHOOK_pre_mapif_elemental_delete) (int *ele_id); -typedef bool (*HPMHOOK_post_mapif_elemental_delete) (bool retVal___, int ele_id); typedef void (*HPMHOOK_pre_mapif_elemental_send) (int *fd, struct s_elemental **ele, unsigned char *flag); typedef void (*HPMHOOK_post_mapif_elemental_send) (int fd, struct s_elemental *ele, unsigned char flag); typedef void (*HPMHOOK_pre_mapif_parse_elemental_create) (int *fd, const struct s_elemental **ele); @@ -4546,8 +4644,6 @@ typedef int (*HPMHOOK_pre_mapif_parse_GuildPosition) (int *fd, int *guild_id, in typedef int (*HPMHOOK_post_mapif_parse_GuildPosition) (int retVal___, int fd, int guild_id, int idx, const struct guild_position *p); typedef int (*HPMHOOK_pre_mapif_parse_GuildSkillUp) (int *fd, int *guild_id, uint16 *skill_id, int *account_id, int *max); typedef int (*HPMHOOK_post_mapif_parse_GuildSkillUp) (int retVal___, int fd, int guild_id, uint16 skill_id, int account_id, int max); -typedef int (*HPMHOOK_pre_mapif_parse_GuildDeleteAlliance) (struct guild **g, int *guild_id, int *account_id1, int *account_id2, int *flag); -typedef int (*HPMHOOK_post_mapif_parse_GuildDeleteAlliance) (int retVal___, struct guild *g, int guild_id, int account_id1, int account_id2, int flag); typedef int (*HPMHOOK_pre_mapif_parse_GuildAlliance) (int *fd, int *guild_id1, int *guild_id2, int *account_id1, int *account_id2, int *flag); typedef int (*HPMHOOK_post_mapif_parse_GuildAlliance) (int retVal___, int fd, int guild_id1, int guild_id2, int account_id1, int account_id2, int flag); typedef int (*HPMHOOK_pre_mapif_parse_GuildNotice) (int *fd, int *guild_id, const char **mes1, const char **mes2); @@ -4570,16 +4666,6 @@ typedef void (*HPMHOOK_pre_mapif_homunculus_saved) (int *fd, int *account_id, bo typedef void (*HPMHOOK_post_mapif_homunculus_saved) (int fd, int account_id, bool flag); typedef void (*HPMHOOK_pre_mapif_homunculus_renamed) (int *fd, int *account_id, int *char_id, unsigned char *flag, const char **name); typedef void (*HPMHOOK_post_mapif_homunculus_renamed) (int fd, int account_id, int char_id, unsigned char flag, const char *name); -typedef bool (*HPMHOOK_pre_mapif_homunculus_create) (struct s_homunculus **hd); -typedef bool (*HPMHOOK_post_mapif_homunculus_create) (bool retVal___, struct s_homunculus *hd); -typedef bool (*HPMHOOK_pre_mapif_homunculus_save) (const struct s_homunculus **hd); -typedef bool (*HPMHOOK_post_mapif_homunculus_save) (bool retVal___, const struct s_homunculus *hd); -typedef bool (*HPMHOOK_pre_mapif_homunculus_load) (int *homun_id, struct s_homunculus **hd); -typedef bool (*HPMHOOK_post_mapif_homunculus_load) (bool retVal___, int homun_id, struct s_homunculus *hd); -typedef bool (*HPMHOOK_pre_mapif_homunculus_delete) (int *homun_id); -typedef bool (*HPMHOOK_post_mapif_homunculus_delete) (bool retVal___, int homun_id); -typedef bool (*HPMHOOK_pre_mapif_homunculus_rename) (const char **name); -typedef bool (*HPMHOOK_post_mapif_homunculus_rename) (bool retVal___, const char *name); typedef void (*HPMHOOK_pre_mapif_parse_homunculus_create) (int *fd, int *len, int *account_id, const struct s_homunculus **phd); typedef void (*HPMHOOK_post_mapif_parse_homunculus_create) (int fd, int len, int account_id, const struct s_homunculus *phd); typedef void (*HPMHOOK_pre_mapif_parse_homunculus_delete) (int *fd, int *homun_id); @@ -4598,8 +4684,6 @@ typedef void (*HPMHOOK_pre_mapif_parse_mail_read) (int *fd); typedef void (*HPMHOOK_post_mapif_parse_mail_read) (int fd); typedef void (*HPMHOOK_pre_mapif_mail_sendattach) (int *fd, int *char_id, struct mail_message **msg); typedef void (*HPMHOOK_post_mapif_mail_sendattach) (int fd, int char_id, struct mail_message *msg); -typedef void (*HPMHOOK_pre_mapif_mail_getattach) (int *fd, int *char_id, int *mail_id); -typedef void (*HPMHOOK_post_mapif_mail_getattach) (int fd, int char_id, int mail_id); typedef void (*HPMHOOK_pre_mapif_parse_mail_getattach) (int *fd); typedef void (*HPMHOOK_post_mapif_parse_mail_getattach) (int fd); typedef void (*HPMHOOK_pre_mapif_mail_delete) (int *fd, int *char_id, int *mail_id, bool *failed); @@ -4616,14 +4700,6 @@ typedef void (*HPMHOOK_pre_mapif_mail_send) (int *fd, struct mail_message **msg) typedef void (*HPMHOOK_post_mapif_mail_send) (int fd, struct mail_message *msg); typedef void (*HPMHOOK_pre_mapif_parse_mail_send) (int *fd); typedef void (*HPMHOOK_post_mapif_parse_mail_send) (int fd); -typedef bool (*HPMHOOK_pre_mapif_mercenary_create) (struct s_mercenary **merc); -typedef bool (*HPMHOOK_post_mapif_mercenary_create) (bool retVal___, struct s_mercenary *merc); -typedef bool (*HPMHOOK_pre_mapif_mercenary_save) (const struct s_mercenary **merc); -typedef bool (*HPMHOOK_post_mapif_mercenary_save) (bool retVal___, const struct s_mercenary *merc); -typedef bool (*HPMHOOK_pre_mapif_mercenary_load) (int *merc_id, int *char_id, struct s_mercenary **merc); -typedef bool (*HPMHOOK_post_mapif_mercenary_load) (bool retVal___, int merc_id, int char_id, struct s_mercenary *merc); -typedef bool (*HPMHOOK_pre_mapif_mercenary_delete) (int *merc_id); -typedef bool (*HPMHOOK_post_mapif_mercenary_delete) (bool retVal___, int merc_id); typedef void (*HPMHOOK_pre_mapif_mercenary_send) (int *fd, struct s_mercenary **merc, unsigned char *flag); typedef void (*HPMHOOK_post_mapif_mercenary_send) (int fd, struct s_mercenary *merc, unsigned char flag); typedef void (*HPMHOOK_pre_mapif_parse_mercenary_create) (int *fd, const struct s_mercenary **merc); @@ -4684,10 +4760,6 @@ typedef int (*HPMHOOK_pre_mapif_save_pet_ack) (int *fd, int *account_id, int *fl typedef int (*HPMHOOK_post_mapif_save_pet_ack) (int retVal___, int fd, int account_id, int flag); typedef int (*HPMHOOK_pre_mapif_delete_pet_ack) (int *fd, int *flag); typedef int (*HPMHOOK_post_mapif_delete_pet_ack) (int retVal___, int fd, int flag); -typedef int (*HPMHOOK_pre_mapif_create_pet) (int *fd, int *account_id, int *char_id, short *pet_class, short *pet_lv, short *pet_egg_id, short *pet_equip, short *intimate, short *hungry, char *rename_flag, char *incubate, const char **pet_name); -typedef int (*HPMHOOK_post_mapif_create_pet) (int retVal___, int fd, int account_id, int char_id, short pet_class, short pet_lv, short pet_egg_id, short pet_equip, short intimate, short hungry, char rename_flag, char incubate, const char *pet_name); -typedef int (*HPMHOOK_pre_mapif_load_pet) (int *fd, int *account_id, int *char_id, int *pet_id); -typedef int (*HPMHOOK_post_mapif_load_pet) (int retVal___, int fd, int account_id, int char_id, int pet_id); typedef int (*HPMHOOK_pre_mapif_save_pet) (int *fd, int *account_id, const struct s_pet **data); typedef int (*HPMHOOK_post_mapif_save_pet) (int retVal___, int fd, int account_id, const struct s_pet *data); typedef int (*HPMHOOK_pre_mapif_delete_pet) (int *fd, int *pet_id); @@ -4700,14 +4772,6 @@ typedef int (*HPMHOOK_pre_mapif_parse_SavePet) (int *fd); typedef int (*HPMHOOK_post_mapif_parse_SavePet) (int retVal___, int fd); typedef int (*HPMHOOK_pre_mapif_parse_DeletePet) (int *fd); typedef int (*HPMHOOK_post_mapif_parse_DeletePet) (int retVal___, int fd); -typedef struct quest* (*HPMHOOK_pre_mapif_quests_fromsql) (int *char_id, int **count); -typedef struct quest* (*HPMHOOK_post_mapif_quests_fromsql) (struct quest* retVal___, int char_id, int *count); -typedef bool (*HPMHOOK_pre_mapif_quest_delete) (int *char_id, int *quest_id); -typedef bool (*HPMHOOK_post_mapif_quest_delete) (bool retVal___, int char_id, int quest_id); -typedef bool (*HPMHOOK_pre_mapif_quest_add) (int *char_id, struct quest *qd); -typedef bool (*HPMHOOK_post_mapif_quest_add) (bool retVal___, int char_id, struct quest qd); -typedef bool (*HPMHOOK_pre_mapif_quest_update) (int *char_id, struct quest *qd); -typedef bool (*HPMHOOK_post_mapif_quest_update) (bool retVal___, int char_id, struct quest qd); typedef void (*HPMHOOK_pre_mapif_quest_save_ack) (int *fd, int *char_id, bool *success); typedef void (*HPMHOOK_post_mapif_quest_save_ack) (int fd, int char_id, bool success); typedef int (*HPMHOOK_pre_mapif_parse_quest_save) (int *fd); @@ -4716,22 +4780,22 @@ typedef void (*HPMHOOK_pre_mapif_send_quests) (int *fd, int *char_id, struct que typedef void (*HPMHOOK_post_mapif_send_quests) (int fd, int char_id, struct quest *tmp_questlog, int num_quests); typedef int (*HPMHOOK_pre_mapif_parse_quest_load) (int *fd); typedef int (*HPMHOOK_post_mapif_parse_quest_load) (int retVal___, int fd); -typedef int (*HPMHOOK_pre_mapif_parse_rodex_requestinbox) (int *fd); -typedef int (*HPMHOOK_post_mapif_parse_rodex_requestinbox) (int retVal___, int fd); +typedef void (*HPMHOOK_pre_mapif_parse_rodex_requestinbox) (int *fd); +typedef void (*HPMHOOK_post_mapif_parse_rodex_requestinbox) (int fd); typedef void (*HPMHOOK_pre_mapif_rodex_sendinbox) (int *fd, int *char_id, int8 *opentype, int8 *flag, int *count, int64 *mail_id, struct rodex_maillist **mails); typedef void (*HPMHOOK_post_mapif_rodex_sendinbox) (int fd, int char_id, int8 opentype, int8 flag, int count, int64 mail_id, struct rodex_maillist *mails); -typedef int (*HPMHOOK_pre_mapif_parse_rodex_checkhasnew) (int *fd); -typedef int (*HPMHOOK_post_mapif_parse_rodex_checkhasnew) (int retVal___, int fd); +typedef void (*HPMHOOK_pre_mapif_parse_rodex_checkhasnew) (int *fd); +typedef void (*HPMHOOK_post_mapif_parse_rodex_checkhasnew) (int fd); typedef void (*HPMHOOK_pre_mapif_rodex_sendhasnew) (int *fd, int *char_id, bool *has_new); typedef void (*HPMHOOK_post_mapif_rodex_sendhasnew) (int fd, int char_id, bool has_new); -typedef int (*HPMHOOK_pre_mapif_parse_rodex_updatemail) (int *fd); -typedef int (*HPMHOOK_post_mapif_parse_rodex_updatemail) (int retVal___, int fd); -typedef int (*HPMHOOK_pre_mapif_parse_rodex_send) (int *fd); -typedef int (*HPMHOOK_post_mapif_parse_rodex_send) (int retVal___, int fd); +typedef void (*HPMHOOK_pre_mapif_parse_rodex_updatemail) (int *fd); +typedef void (*HPMHOOK_post_mapif_parse_rodex_updatemail) (int fd); +typedef void (*HPMHOOK_pre_mapif_parse_rodex_send) (int *fd); +typedef void (*HPMHOOK_post_mapif_parse_rodex_send) (int fd); typedef void (*HPMHOOK_pre_mapif_rodex_send) (int *fd, int *sender_id, int *receiver_id, int *receiver_accountid, bool *result); typedef void (*HPMHOOK_post_mapif_rodex_send) (int fd, int sender_id, int receiver_id, int receiver_accountid, bool result); -typedef int (*HPMHOOK_pre_mapif_parse_rodex_checkname) (int *fd); -typedef int (*HPMHOOK_post_mapif_parse_rodex_checkname) (int retVal___, int fd); +typedef void (*HPMHOOK_pre_mapif_parse_rodex_checkname) (int *fd); +typedef void (*HPMHOOK_post_mapif_parse_rodex_checkname) (int fd); typedef void (*HPMHOOK_pre_mapif_rodex_checkname) (int *fd, int *reqchar_id, int *target_char_id, short *target_class, int *target_level, char **name); typedef void (*HPMHOOK_post_mapif_rodex_checkname) (int fd, int reqchar_id, int target_char_id, short target_class, int target_level, char *name); typedef int (*HPMHOOK_pre_mapif_load_guild_storage) (int *fd, int *account_id, int *guild_id, char *flag); @@ -4752,14 +4816,10 @@ typedef void (*HPMHOOK_pre_mapif_sAccountStorageSaveAck) (int *fd, int *account_ typedef void (*HPMHOOK_post_mapif_sAccountStorageSaveAck) (int fd, int account_id, bool save); typedef int (*HPMHOOK_pre_mapif_itembound_ack) (int *fd, int *aid, int *guild_id); typedef int (*HPMHOOK_post_mapif_itembound_ack) (int retVal___, int fd, int aid, int guild_id); -typedef int (*HPMHOOK_pre_mapif_parse_ItemBoundRetrieve_sub) (int *fd); -typedef int (*HPMHOOK_post_mapif_parse_ItemBoundRetrieve_sub) (int retVal___, int fd); typedef void (*HPMHOOK_pre_mapif_parse_ItemBoundRetrieve) (int *fd); typedef void (*HPMHOOK_post_mapif_parse_ItemBoundRetrieve) (int fd); typedef void (*HPMHOOK_pre_mapif_parse_accinfo) (int *fd); typedef void (*HPMHOOK_post_mapif_parse_accinfo) (int fd); -typedef void (*HPMHOOK_pre_mapif_parse_accinfo2) (bool *success, int *map_fd, int *u_fd, int *u_aid, int *account_id, const char **userid, const char **user_pass, const char **email, const char **last_ip, const char **lastlogin, const char **pin_code, const char **birthdate, int *group_id, int *logincount, int *state); -typedef void (*HPMHOOK_post_mapif_parse_accinfo2) (bool success, int map_fd, int u_fd, int u_aid, int account_id, const char *userid, const char *user_pass, const char *email, const char *last_ip, const char *lastlogin, const char *pin_code, const char *birthdate, int group_id, int logincount, int state); typedef int (*HPMHOOK_pre_mapif_broadcast) (const unsigned char **mes, int *len, unsigned int *fontColor, short *fontType, short *fontSize, short *fontAlign, short *fontY, int *sfd); typedef int (*HPMHOOK_post_mapif_broadcast) (int retVal___, const unsigned char *mes, int len, unsigned int fontColor, short fontType, short fontSize, short fontAlign, short fontY, int sfd); typedef int (*HPMHOOK_pre_mapif_wis_message) (struct WisData **wd); diff --git a/src/plugins/HPMHooking/HPMHooking_char.HPMHooksCore.inc b/src/plugins/HPMHooking/HPMHooking_char.HPMHooksCore.inc index 0f9e48287..d77174ef5 100644 --- a/src/plugins/HPMHooking/HPMHooking_char.HPMHooksCore.inc +++ b/src/plugins/HPMHooking/HPMHooking_char.HPMHooksCore.inc @@ -78,6 +78,8 @@ struct { struct HPMHookPoint *HP_chr_char_slotchange_post; struct HPMHookPoint *HP_chr_rename_char_sql_pre; struct HPMHookPoint *HP_chr_rename_char_sql_post; + struct HPMHookPoint *HP_chr_name_exists_pre; + struct HPMHookPoint *HP_chr_name_exists_post; struct HPMHookPoint *HP_chr_check_char_name_pre; struct HPMHookPoint *HP_chr_check_char_name_post; struct HPMHookPoint *HP_chr_make_new_char_sql_pre; @@ -476,6 +478,14 @@ struct { struct HPMHookPoint *HP_inter_elemental_sql_final_post; struct HPMHookPoint *HP_inter_elemental_parse_frommap_pre; struct HPMHookPoint *HP_inter_elemental_parse_frommap_post; + struct HPMHookPoint *HP_inter_elemental_create_pre; + struct HPMHookPoint *HP_inter_elemental_create_post; + struct HPMHookPoint *HP_inter_elemental_save_pre; + struct HPMHookPoint *HP_inter_elemental_save_post; + struct HPMHookPoint *HP_inter_elemental_load_pre; + struct HPMHookPoint *HP_inter_elemental_load_post; + struct HPMHookPoint *HP_inter_elemental_delete_pre; + struct HPMHookPoint *HP_inter_elemental_delete_post; struct HPMHookPoint *HP_inter_guild_save_timer_pre; struct HPMHookPoint *HP_inter_guild_save_timer_post; struct HPMHookPoint *HP_inter_guild_removemember_tosql_pre; @@ -516,16 +526,54 @@ struct { struct HPMHookPoint *HP_inter_guild_charname_changed_post; struct HPMHookPoint *HP_inter_guild_parse_frommap_pre; struct HPMHookPoint *HP_inter_guild_parse_frommap_post; - struct HPMHookPoint *HP_inter_guild_leave_pre; - struct HPMHookPoint *HP_inter_guild_leave_post; struct HPMHookPoint *HP_inter_guild_broken_pre; struct HPMHookPoint *HP_inter_guild_broken_post; + struct HPMHookPoint *HP_inter_guild_create_pre; + struct HPMHookPoint *HP_inter_guild_create_post; + struct HPMHookPoint *HP_inter_guild_add_member_pre; + struct HPMHookPoint *HP_inter_guild_add_member_post; + struct HPMHookPoint *HP_inter_guild_leave_pre; + struct HPMHookPoint *HP_inter_guild_leave_post; + struct HPMHookPoint *HP_inter_guild_update_member_info_short_pre; + struct HPMHookPoint *HP_inter_guild_update_member_info_short_post; + struct HPMHookPoint *HP_inter_guild_update_member_info_pre; + struct HPMHookPoint *HP_inter_guild_update_member_info_post; + struct HPMHookPoint *HP_inter_guild_disband_pre; + struct HPMHookPoint *HP_inter_guild_disband_post; + struct HPMHookPoint *HP_inter_guild_update_basic_info_pre; + struct HPMHookPoint *HP_inter_guild_update_basic_info_post; + struct HPMHookPoint *HP_inter_guild_update_position_pre; + struct HPMHookPoint *HP_inter_guild_update_position_post; + struct HPMHookPoint *HP_inter_guild_use_skill_point_pre; + struct HPMHookPoint *HP_inter_guild_use_skill_point_post; + struct HPMHookPoint *HP_inter_guild_remove_alliance_pre; + struct HPMHookPoint *HP_inter_guild_remove_alliance_post; + struct HPMHookPoint *HP_inter_guild_change_alliance_pre; + struct HPMHookPoint *HP_inter_guild_change_alliance_post; + struct HPMHookPoint *HP_inter_guild_update_notice_pre; + struct HPMHookPoint *HP_inter_guild_update_notice_post; + struct HPMHookPoint *HP_inter_guild_update_emblem_pre; + struct HPMHookPoint *HP_inter_guild_update_emblem_post; + struct HPMHookPoint *HP_inter_guild_update_castle_data_pre; + struct HPMHookPoint *HP_inter_guild_update_castle_data_post; + struct HPMHookPoint *HP_inter_guild_change_leader_pre; + struct HPMHookPoint *HP_inter_guild_change_leader_post; struct HPMHookPoint *HP_inter_homunculus_sql_init_pre; struct HPMHookPoint *HP_inter_homunculus_sql_init_post; struct HPMHookPoint *HP_inter_homunculus_sql_final_pre; struct HPMHookPoint *HP_inter_homunculus_sql_final_post; struct HPMHookPoint *HP_inter_homunculus_parse_frommap_pre; struct HPMHookPoint *HP_inter_homunculus_parse_frommap_post; + struct HPMHookPoint *HP_inter_homunculus_create_pre; + struct HPMHookPoint *HP_inter_homunculus_create_post; + struct HPMHookPoint *HP_inter_homunculus_save_pre; + struct HPMHookPoint *HP_inter_homunculus_save_post; + struct HPMHookPoint *HP_inter_homunculus_load_pre; + struct HPMHookPoint *HP_inter_homunculus_load_post; + struct HPMHookPoint *HP_inter_homunculus_delete_pre; + struct HPMHookPoint *HP_inter_homunculus_delete_post; + struct HPMHookPoint *HP_inter_homunculus_rename_pre; + struct HPMHookPoint *HP_inter_homunculus_rename_post; struct HPMHookPoint *HP_inter_msg_txt_pre; struct HPMHookPoint *HP_inter_msg_txt_post; struct HPMHookPoint *HP_inter_msg_config_read_pre; @@ -562,6 +610,16 @@ struct { struct HPMHookPoint *HP_inter_config_read_log_post; struct HPMHookPoint *HP_inter_config_read_connection_pre; struct HPMHookPoint *HP_inter_config_read_connection_post; + struct HPMHookPoint *HP_inter_accinfo_pre; + struct HPMHookPoint *HP_inter_accinfo_post; + struct HPMHookPoint *HP_inter_accinfo2_pre; + struct HPMHookPoint *HP_inter_accinfo2_post; + struct HPMHookPoint *HP_inter_add_wisdata_pre; + struct HPMHookPoint *HP_inter_add_wisdata_post; + struct HPMHookPoint *HP_inter_get_wisdata_pre; + struct HPMHookPoint *HP_inter_get_wisdata_post; + struct HPMHookPoint *HP_inter_remove_wisdata_pre; + struct HPMHookPoint *HP_inter_remove_wisdata_post; struct HPMHookPoint *HP_inter_mail_sql_init_pre; struct HPMHookPoint *HP_inter_mail_sql_init_post; struct HPMHookPoint *HP_inter_mail_sql_final_pre; @@ -578,6 +636,16 @@ struct { struct HPMHookPoint *HP_inter_mail_DeleteAttach_post; struct HPMHookPoint *HP_inter_mail_sendmail_pre; struct HPMHookPoint *HP_inter_mail_sendmail_post; + struct HPMHookPoint *HP_inter_mail_mark_read_pre; + struct HPMHookPoint *HP_inter_mail_mark_read_post; + struct HPMHookPoint *HP_inter_mail_get_attachment_pre; + struct HPMHookPoint *HP_inter_mail_get_attachment_post; + struct HPMHookPoint *HP_inter_mail_delete_pre; + struct HPMHookPoint *HP_inter_mail_delete_post; + struct HPMHookPoint *HP_inter_mail_return_message_pre; + struct HPMHookPoint *HP_inter_mail_return_message_post; + struct HPMHookPoint *HP_inter_mail_send_pre; + struct HPMHookPoint *HP_inter_mail_send_post; struct HPMHookPoint *HP_inter_mercenary_owner_fromsql_pre; struct HPMHookPoint *HP_inter_mercenary_owner_fromsql_post; struct HPMHookPoint *HP_inter_mercenary_owner_tosql_pre; @@ -590,6 +658,14 @@ struct { struct HPMHookPoint *HP_inter_mercenary_sql_final_post; struct HPMHookPoint *HP_inter_mercenary_parse_frommap_pre; struct HPMHookPoint *HP_inter_mercenary_parse_frommap_post; + struct HPMHookPoint *HP_inter_mercenary_create_pre; + struct HPMHookPoint *HP_inter_mercenary_create_post; + struct HPMHookPoint *HP_inter_mercenary_save_pre; + struct HPMHookPoint *HP_inter_mercenary_save_post; + struct HPMHookPoint *HP_inter_mercenary_load_pre; + struct HPMHookPoint *HP_inter_mercenary_load_post; + struct HPMHookPoint *HP_inter_mercenary_delete_pre; + struct HPMHookPoint *HP_inter_mercenary_delete_post; struct HPMHookPoint *HP_inter_party_check_lv_pre; struct HPMHookPoint *HP_inter_party_check_lv_post; struct HPMHookPoint *HP_inter_party_calc_state_pre; @@ -616,6 +692,18 @@ struct { struct HPMHookPoint *HP_inter_party_CharOnline_post; struct HPMHookPoint *HP_inter_party_CharOffline_pre; struct HPMHookPoint *HP_inter_party_CharOffline_post; + struct HPMHookPoint *HP_inter_party_create_pre; + struct HPMHookPoint *HP_inter_party_create_post; + struct HPMHookPoint *HP_inter_party_add_member_pre; + struct HPMHookPoint *HP_inter_party_add_member_post; + struct HPMHookPoint *HP_inter_party_change_option_pre; + struct HPMHookPoint *HP_inter_party_change_option_post; + struct HPMHookPoint *HP_inter_party_change_map_pre; + struct HPMHookPoint *HP_inter_party_change_map_post; + struct HPMHookPoint *HP_inter_party_disband_pre; + struct HPMHookPoint *HP_inter_party_disband_post; + struct HPMHookPoint *HP_inter_party_change_leader_pre; + struct HPMHookPoint *HP_inter_party_change_leader_post; struct HPMHookPoint *HP_inter_pet_tosql_pre; struct HPMHookPoint *HP_inter_pet_tosql_post; struct HPMHookPoint *HP_inter_pet_fromsql_pre; @@ -628,8 +716,22 @@ struct { struct HPMHookPoint *HP_inter_pet_delete__post; struct HPMHookPoint *HP_inter_pet_parse_frommap_pre; struct HPMHookPoint *HP_inter_pet_parse_frommap_post; + struct HPMHookPoint *HP_inter_pet_create_pre; + struct HPMHookPoint *HP_inter_pet_create_post; + struct HPMHookPoint *HP_inter_pet_load_pre; + struct HPMHookPoint *HP_inter_pet_load_post; struct HPMHookPoint *HP_inter_quest_parse_frommap_pre; struct HPMHookPoint *HP_inter_quest_parse_frommap_post; + struct HPMHookPoint *HP_inter_quest_fromsql_pre; + struct HPMHookPoint *HP_inter_quest_fromsql_post; + struct HPMHookPoint *HP_inter_quest_delete_pre; + struct HPMHookPoint *HP_inter_quest_delete_post; + struct HPMHookPoint *HP_inter_quest_add_pre; + struct HPMHookPoint *HP_inter_quest_add_post; + struct HPMHookPoint *HP_inter_quest_update_pre; + struct HPMHookPoint *HP_inter_quest_update_post; + struct HPMHookPoint *HP_inter_quest_save_pre; + struct HPMHookPoint *HP_inter_quest_save_post; struct HPMHookPoint *HP_inter_rodex_sql_init_pre; struct HPMHookPoint *HP_inter_rodex_sql_init_post; struct HPMHookPoint *HP_inter_rodex_sql_final_pre; @@ -644,6 +746,8 @@ struct { struct HPMHookPoint *HP_inter_rodex_checkname_post; struct HPMHookPoint *HP_inter_rodex_savemessage_pre; struct HPMHookPoint *HP_inter_rodex_savemessage_post; + struct HPMHookPoint *HP_inter_rodex_updatemail_pre; + struct HPMHookPoint *HP_inter_rodex_updatemail_post; struct HPMHookPoint *HP_inter_storage_tosql_pre; struct HPMHookPoint *HP_inter_storage_tosql_post; struct HPMHookPoint *HP_inter_storage_fromsql_pre; @@ -662,6 +766,8 @@ struct { struct HPMHookPoint *HP_inter_storage_guild_storage_delete_post; struct HPMHookPoint *HP_inter_storage_parse_frommap_pre; struct HPMHookPoint *HP_inter_storage_parse_frommap_post; + struct HPMHookPoint *HP_inter_storage_retrieve_bound_items_pre; + struct HPMHookPoint *HP_inter_storage_retrieve_bound_items_post; struct HPMHookPoint *HP_libconfig_read_pre; struct HPMHookPoint *HP_libconfig_read_post; struct HPMHookPoint *HP_libconfig_write_pre; @@ -868,14 +974,6 @@ struct { struct HPMHookPoint *HP_mapif_auction_bid_post; struct HPMHookPoint *HP_mapif_parse_auction_bid_pre; struct HPMHookPoint *HP_mapif_parse_auction_bid_post; - struct HPMHookPoint *HP_mapif_elemental_create_pre; - struct HPMHookPoint *HP_mapif_elemental_create_post; - struct HPMHookPoint *HP_mapif_elemental_save_pre; - struct HPMHookPoint *HP_mapif_elemental_save_post; - struct HPMHookPoint *HP_mapif_elemental_load_pre; - struct HPMHookPoint *HP_mapif_elemental_load_post; - struct HPMHookPoint *HP_mapif_elemental_delete_pre; - struct HPMHookPoint *HP_mapif_elemental_delete_post; struct HPMHookPoint *HP_mapif_elemental_send_pre; struct HPMHookPoint *HP_mapif_elemental_send_post; struct HPMHookPoint *HP_mapif_parse_elemental_create_pre; @@ -946,8 +1044,6 @@ struct { struct HPMHookPoint *HP_mapif_parse_GuildPosition_post; struct HPMHookPoint *HP_mapif_parse_GuildSkillUp_pre; struct HPMHookPoint *HP_mapif_parse_GuildSkillUp_post; - struct HPMHookPoint *HP_mapif_parse_GuildDeleteAlliance_pre; - struct HPMHookPoint *HP_mapif_parse_GuildDeleteAlliance_post; struct HPMHookPoint *HP_mapif_parse_GuildAlliance_pre; struct HPMHookPoint *HP_mapif_parse_GuildAlliance_post; struct HPMHookPoint *HP_mapif_parse_GuildNotice_pre; @@ -970,16 +1066,6 @@ struct { struct HPMHookPoint *HP_mapif_homunculus_saved_post; struct HPMHookPoint *HP_mapif_homunculus_renamed_pre; struct HPMHookPoint *HP_mapif_homunculus_renamed_post; - struct HPMHookPoint *HP_mapif_homunculus_create_pre; - struct HPMHookPoint *HP_mapif_homunculus_create_post; - struct HPMHookPoint *HP_mapif_homunculus_save_pre; - struct HPMHookPoint *HP_mapif_homunculus_save_post; - struct HPMHookPoint *HP_mapif_homunculus_load_pre; - struct HPMHookPoint *HP_mapif_homunculus_load_post; - struct HPMHookPoint *HP_mapif_homunculus_delete_pre; - struct HPMHookPoint *HP_mapif_homunculus_delete_post; - struct HPMHookPoint *HP_mapif_homunculus_rename_pre; - struct HPMHookPoint *HP_mapif_homunculus_rename_post; struct HPMHookPoint *HP_mapif_parse_homunculus_create_pre; struct HPMHookPoint *HP_mapif_parse_homunculus_create_post; struct HPMHookPoint *HP_mapif_parse_homunculus_delete_pre; @@ -998,8 +1084,6 @@ struct { struct HPMHookPoint *HP_mapif_parse_mail_read_post; struct HPMHookPoint *HP_mapif_mail_sendattach_pre; struct HPMHookPoint *HP_mapif_mail_sendattach_post; - struct HPMHookPoint *HP_mapif_mail_getattach_pre; - struct HPMHookPoint *HP_mapif_mail_getattach_post; struct HPMHookPoint *HP_mapif_parse_mail_getattach_pre; struct HPMHookPoint *HP_mapif_parse_mail_getattach_post; struct HPMHookPoint *HP_mapif_mail_delete_pre; @@ -1016,14 +1100,6 @@ struct { struct HPMHookPoint *HP_mapif_mail_send_post; struct HPMHookPoint *HP_mapif_parse_mail_send_pre; struct HPMHookPoint *HP_mapif_parse_mail_send_post; - struct HPMHookPoint *HP_mapif_mercenary_create_pre; - struct HPMHookPoint *HP_mapif_mercenary_create_post; - struct HPMHookPoint *HP_mapif_mercenary_save_pre; - struct HPMHookPoint *HP_mapif_mercenary_save_post; - struct HPMHookPoint *HP_mapif_mercenary_load_pre; - struct HPMHookPoint *HP_mapif_mercenary_load_post; - struct HPMHookPoint *HP_mapif_mercenary_delete_pre; - struct HPMHookPoint *HP_mapif_mercenary_delete_post; struct HPMHookPoint *HP_mapif_mercenary_send_pre; struct HPMHookPoint *HP_mapif_mercenary_send_post; struct HPMHookPoint *HP_mapif_parse_mercenary_create_pre; @@ -1084,10 +1160,6 @@ struct { struct HPMHookPoint *HP_mapif_save_pet_ack_post; struct HPMHookPoint *HP_mapif_delete_pet_ack_pre; struct HPMHookPoint *HP_mapif_delete_pet_ack_post; - struct HPMHookPoint *HP_mapif_create_pet_pre; - struct HPMHookPoint *HP_mapif_create_pet_post; - struct HPMHookPoint *HP_mapif_load_pet_pre; - struct HPMHookPoint *HP_mapif_load_pet_post; struct HPMHookPoint *HP_mapif_save_pet_pre; struct HPMHookPoint *HP_mapif_save_pet_post; struct HPMHookPoint *HP_mapif_delete_pet_pre; @@ -1100,14 +1172,6 @@ struct { struct HPMHookPoint *HP_mapif_parse_SavePet_post; struct HPMHookPoint *HP_mapif_parse_DeletePet_pre; struct HPMHookPoint *HP_mapif_parse_DeletePet_post; - struct HPMHookPoint *HP_mapif_quests_fromsql_pre; - struct HPMHookPoint *HP_mapif_quests_fromsql_post; - struct HPMHookPoint *HP_mapif_quest_delete_pre; - struct HPMHookPoint *HP_mapif_quest_delete_post; - struct HPMHookPoint *HP_mapif_quest_add_pre; - struct HPMHookPoint *HP_mapif_quest_add_post; - struct HPMHookPoint *HP_mapif_quest_update_pre; - struct HPMHookPoint *HP_mapif_quest_update_post; struct HPMHookPoint *HP_mapif_quest_save_ack_pre; struct HPMHookPoint *HP_mapif_quest_save_ack_post; struct HPMHookPoint *HP_mapif_parse_quest_save_pre; @@ -1152,14 +1216,10 @@ struct { struct HPMHookPoint *HP_mapif_sAccountStorageSaveAck_post; struct HPMHookPoint *HP_mapif_itembound_ack_pre; struct HPMHookPoint *HP_mapif_itembound_ack_post; - struct HPMHookPoint *HP_mapif_parse_ItemBoundRetrieve_sub_pre; - struct HPMHookPoint *HP_mapif_parse_ItemBoundRetrieve_sub_post; struct HPMHookPoint *HP_mapif_parse_ItemBoundRetrieve_pre; struct HPMHookPoint *HP_mapif_parse_ItemBoundRetrieve_post; struct HPMHookPoint *HP_mapif_parse_accinfo_pre; struct HPMHookPoint *HP_mapif_parse_accinfo_post; - struct HPMHookPoint *HP_mapif_parse_accinfo2_pre; - struct HPMHookPoint *HP_mapif_parse_accinfo2_post; struct HPMHookPoint *HP_mapif_broadcast_pre; struct HPMHookPoint *HP_mapif_broadcast_post; struct HPMHookPoint *HP_mapif_wis_message_pre; @@ -1617,6 +1677,8 @@ struct { int HP_chr_char_slotchange_post; int HP_chr_rename_char_sql_pre; int HP_chr_rename_char_sql_post; + int HP_chr_name_exists_pre; + int HP_chr_name_exists_post; int HP_chr_check_char_name_pre; int HP_chr_check_char_name_post; int HP_chr_make_new_char_sql_pre; @@ -2015,6 +2077,14 @@ struct { int HP_inter_elemental_sql_final_post; int HP_inter_elemental_parse_frommap_pre; int HP_inter_elemental_parse_frommap_post; + int HP_inter_elemental_create_pre; + int HP_inter_elemental_create_post; + int HP_inter_elemental_save_pre; + int HP_inter_elemental_save_post; + int HP_inter_elemental_load_pre; + int HP_inter_elemental_load_post; + int HP_inter_elemental_delete_pre; + int HP_inter_elemental_delete_post; int HP_inter_guild_save_timer_pre; int HP_inter_guild_save_timer_post; int HP_inter_guild_removemember_tosql_pre; @@ -2055,16 +2125,54 @@ struct { int HP_inter_guild_charname_changed_post; int HP_inter_guild_parse_frommap_pre; int HP_inter_guild_parse_frommap_post; - int HP_inter_guild_leave_pre; - int HP_inter_guild_leave_post; int HP_inter_guild_broken_pre; int HP_inter_guild_broken_post; + int HP_inter_guild_create_pre; + int HP_inter_guild_create_post; + int HP_inter_guild_add_member_pre; + int HP_inter_guild_add_member_post; + int HP_inter_guild_leave_pre; + int HP_inter_guild_leave_post; + int HP_inter_guild_update_member_info_short_pre; + int HP_inter_guild_update_member_info_short_post; + int HP_inter_guild_update_member_info_pre; + int HP_inter_guild_update_member_info_post; + int HP_inter_guild_disband_pre; + int HP_inter_guild_disband_post; + int HP_inter_guild_update_basic_info_pre; + int HP_inter_guild_update_basic_info_post; + int HP_inter_guild_update_position_pre; + int HP_inter_guild_update_position_post; + int HP_inter_guild_use_skill_point_pre; + int HP_inter_guild_use_skill_point_post; + int HP_inter_guild_remove_alliance_pre; + int HP_inter_guild_remove_alliance_post; + int HP_inter_guild_change_alliance_pre; + int HP_inter_guild_change_alliance_post; + int HP_inter_guild_update_notice_pre; + int HP_inter_guild_update_notice_post; + int HP_inter_guild_update_emblem_pre; + int HP_inter_guild_update_emblem_post; + int HP_inter_guild_update_castle_data_pre; + int HP_inter_guild_update_castle_data_post; + int HP_inter_guild_change_leader_pre; + int HP_inter_guild_change_leader_post; int HP_inter_homunculus_sql_init_pre; int HP_inter_homunculus_sql_init_post; int HP_inter_homunculus_sql_final_pre; int HP_inter_homunculus_sql_final_post; int HP_inter_homunculus_parse_frommap_pre; int HP_inter_homunculus_parse_frommap_post; + int HP_inter_homunculus_create_pre; + int HP_inter_homunculus_create_post; + int HP_inter_homunculus_save_pre; + int HP_inter_homunculus_save_post; + int HP_inter_homunculus_load_pre; + int HP_inter_homunculus_load_post; + int HP_inter_homunculus_delete_pre; + int HP_inter_homunculus_delete_post; + int HP_inter_homunculus_rename_pre; + int HP_inter_homunculus_rename_post; int HP_inter_msg_txt_pre; int HP_inter_msg_txt_post; int HP_inter_msg_config_read_pre; @@ -2101,6 +2209,16 @@ struct { int HP_inter_config_read_log_post; int HP_inter_config_read_connection_pre; int HP_inter_config_read_connection_post; + int HP_inter_accinfo_pre; + int HP_inter_accinfo_post; + int HP_inter_accinfo2_pre; + int HP_inter_accinfo2_post; + int HP_inter_add_wisdata_pre; + int HP_inter_add_wisdata_post; + int HP_inter_get_wisdata_pre; + int HP_inter_get_wisdata_post; + int HP_inter_remove_wisdata_pre; + int HP_inter_remove_wisdata_post; int HP_inter_mail_sql_init_pre; int HP_inter_mail_sql_init_post; int HP_inter_mail_sql_final_pre; @@ -2117,6 +2235,16 @@ struct { int HP_inter_mail_DeleteAttach_post; int HP_inter_mail_sendmail_pre; int HP_inter_mail_sendmail_post; + int HP_inter_mail_mark_read_pre; + int HP_inter_mail_mark_read_post; + int HP_inter_mail_get_attachment_pre; + int HP_inter_mail_get_attachment_post; + int HP_inter_mail_delete_pre; + int HP_inter_mail_delete_post; + int HP_inter_mail_return_message_pre; + int HP_inter_mail_return_message_post; + int HP_inter_mail_send_pre; + int HP_inter_mail_send_post; int HP_inter_mercenary_owner_fromsql_pre; int HP_inter_mercenary_owner_fromsql_post; int HP_inter_mercenary_owner_tosql_pre; @@ -2129,6 +2257,14 @@ struct { int HP_inter_mercenary_sql_final_post; int HP_inter_mercenary_parse_frommap_pre; int HP_inter_mercenary_parse_frommap_post; + int HP_inter_mercenary_create_pre; + int HP_inter_mercenary_create_post; + int HP_inter_mercenary_save_pre; + int HP_inter_mercenary_save_post; + int HP_inter_mercenary_load_pre; + int HP_inter_mercenary_load_post; + int HP_inter_mercenary_delete_pre; + int HP_inter_mercenary_delete_post; int HP_inter_party_check_lv_pre; int HP_inter_party_check_lv_post; int HP_inter_party_calc_state_pre; @@ -2155,6 +2291,18 @@ struct { int HP_inter_party_CharOnline_post; int HP_inter_party_CharOffline_pre; int HP_inter_party_CharOffline_post; + int HP_inter_party_create_pre; + int HP_inter_party_create_post; + int HP_inter_party_add_member_pre; + int HP_inter_party_add_member_post; + int HP_inter_party_change_option_pre; + int HP_inter_party_change_option_post; + int HP_inter_party_change_map_pre; + int HP_inter_party_change_map_post; + int HP_inter_party_disband_pre; + int HP_inter_party_disband_post; + int HP_inter_party_change_leader_pre; + int HP_inter_party_change_leader_post; int HP_inter_pet_tosql_pre; int HP_inter_pet_tosql_post; int HP_inter_pet_fromsql_pre; @@ -2167,8 +2315,22 @@ struct { int HP_inter_pet_delete__post; int HP_inter_pet_parse_frommap_pre; int HP_inter_pet_parse_frommap_post; + int HP_inter_pet_create_pre; + int HP_inter_pet_create_post; + int HP_inter_pet_load_pre; + int HP_inter_pet_load_post; int HP_inter_quest_parse_frommap_pre; int HP_inter_quest_parse_frommap_post; + int HP_inter_quest_fromsql_pre; + int HP_inter_quest_fromsql_post; + int HP_inter_quest_delete_pre; + int HP_inter_quest_delete_post; + int HP_inter_quest_add_pre; + int HP_inter_quest_add_post; + int HP_inter_quest_update_pre; + int HP_inter_quest_update_post; + int HP_inter_quest_save_pre; + int HP_inter_quest_save_post; int HP_inter_rodex_sql_init_pre; int HP_inter_rodex_sql_init_post; int HP_inter_rodex_sql_final_pre; @@ -2183,6 +2345,8 @@ struct { int HP_inter_rodex_checkname_post; int HP_inter_rodex_savemessage_pre; int HP_inter_rodex_savemessage_post; + int HP_inter_rodex_updatemail_pre; + int HP_inter_rodex_updatemail_post; int HP_inter_storage_tosql_pre; int HP_inter_storage_tosql_post; int HP_inter_storage_fromsql_pre; @@ -2201,6 +2365,8 @@ struct { int HP_inter_storage_guild_storage_delete_post; int HP_inter_storage_parse_frommap_pre; int HP_inter_storage_parse_frommap_post; + int HP_inter_storage_retrieve_bound_items_pre; + int HP_inter_storage_retrieve_bound_items_post; int HP_libconfig_read_pre; int HP_libconfig_read_post; int HP_libconfig_write_pre; @@ -2407,14 +2573,6 @@ struct { int HP_mapif_auction_bid_post; int HP_mapif_parse_auction_bid_pre; int HP_mapif_parse_auction_bid_post; - int HP_mapif_elemental_create_pre; - int HP_mapif_elemental_create_post; - int HP_mapif_elemental_save_pre; - int HP_mapif_elemental_save_post; - int HP_mapif_elemental_load_pre; - int HP_mapif_elemental_load_post; - int HP_mapif_elemental_delete_pre; - int HP_mapif_elemental_delete_post; int HP_mapif_elemental_send_pre; int HP_mapif_elemental_send_post; int HP_mapif_parse_elemental_create_pre; @@ -2485,8 +2643,6 @@ struct { int HP_mapif_parse_GuildPosition_post; int HP_mapif_parse_GuildSkillUp_pre; int HP_mapif_parse_GuildSkillUp_post; - int HP_mapif_parse_GuildDeleteAlliance_pre; - int HP_mapif_parse_GuildDeleteAlliance_post; int HP_mapif_parse_GuildAlliance_pre; int HP_mapif_parse_GuildAlliance_post; int HP_mapif_parse_GuildNotice_pre; @@ -2509,16 +2665,6 @@ struct { int HP_mapif_homunculus_saved_post; int HP_mapif_homunculus_renamed_pre; int HP_mapif_homunculus_renamed_post; - int HP_mapif_homunculus_create_pre; - int HP_mapif_homunculus_create_post; - int HP_mapif_homunculus_save_pre; - int HP_mapif_homunculus_save_post; - int HP_mapif_homunculus_load_pre; - int HP_mapif_homunculus_load_post; - int HP_mapif_homunculus_delete_pre; - int HP_mapif_homunculus_delete_post; - int HP_mapif_homunculus_rename_pre; - int HP_mapif_homunculus_rename_post; int HP_mapif_parse_homunculus_create_pre; int HP_mapif_parse_homunculus_create_post; int HP_mapif_parse_homunculus_delete_pre; @@ -2537,8 +2683,6 @@ struct { int HP_mapif_parse_mail_read_post; int HP_mapif_mail_sendattach_pre; int HP_mapif_mail_sendattach_post; - int HP_mapif_mail_getattach_pre; - int HP_mapif_mail_getattach_post; int HP_mapif_parse_mail_getattach_pre; int HP_mapif_parse_mail_getattach_post; int HP_mapif_mail_delete_pre; @@ -2555,14 +2699,6 @@ struct { int HP_mapif_mail_send_post; int HP_mapif_parse_mail_send_pre; int HP_mapif_parse_mail_send_post; - int HP_mapif_mercenary_create_pre; - int HP_mapif_mercenary_create_post; - int HP_mapif_mercenary_save_pre; - int HP_mapif_mercenary_save_post; - int HP_mapif_mercenary_load_pre; - int HP_mapif_mercenary_load_post; - int HP_mapif_mercenary_delete_pre; - int HP_mapif_mercenary_delete_post; int HP_mapif_mercenary_send_pre; int HP_mapif_mercenary_send_post; int HP_mapif_parse_mercenary_create_pre; @@ -2623,10 +2759,6 @@ struct { int HP_mapif_save_pet_ack_post; int HP_mapif_delete_pet_ack_pre; int HP_mapif_delete_pet_ack_post; - int HP_mapif_create_pet_pre; - int HP_mapif_create_pet_post; - int HP_mapif_load_pet_pre; - int HP_mapif_load_pet_post; int HP_mapif_save_pet_pre; int HP_mapif_save_pet_post; int HP_mapif_delete_pet_pre; @@ -2639,14 +2771,6 @@ struct { int HP_mapif_parse_SavePet_post; int HP_mapif_parse_DeletePet_pre; int HP_mapif_parse_DeletePet_post; - int HP_mapif_quests_fromsql_pre; - int HP_mapif_quests_fromsql_post; - int HP_mapif_quest_delete_pre; - int HP_mapif_quest_delete_post; - int HP_mapif_quest_add_pre; - int HP_mapif_quest_add_post; - int HP_mapif_quest_update_pre; - int HP_mapif_quest_update_post; int HP_mapif_quest_save_ack_pre; int HP_mapif_quest_save_ack_post; int HP_mapif_parse_quest_save_pre; @@ -2691,14 +2815,10 @@ struct { int HP_mapif_sAccountStorageSaveAck_post; int HP_mapif_itembound_ack_pre; int HP_mapif_itembound_ack_post; - int HP_mapif_parse_ItemBoundRetrieve_sub_pre; - int HP_mapif_parse_ItemBoundRetrieve_sub_post; int HP_mapif_parse_ItemBoundRetrieve_pre; int HP_mapif_parse_ItemBoundRetrieve_post; int HP_mapif_parse_accinfo_pre; int HP_mapif_parse_accinfo_post; - int HP_mapif_parse_accinfo2_pre; - int HP_mapif_parse_accinfo2_post; int HP_mapif_broadcast_pre; int HP_mapif_broadcast_post; int HP_mapif_wis_message_pre; diff --git a/src/plugins/HPMHooking/HPMHooking_char.HookingPoints.inc b/src/plugins/HPMHooking/HPMHooking_char.HookingPoints.inc index 099bd1e81..d91cc43c8 100644 --- a/src/plugins/HPMHooking/HPMHooking_char.HookingPoints.inc +++ b/src/plugins/HPMHooking/HPMHooking_char.HookingPoints.inc @@ -54,6 +54,7 @@ struct HookingPointData HookingPoints[] = { { HP_POP(chr->mmo_char_sql_init, HP_chr_mmo_char_sql_init) }, { HP_POP(chr->char_slotchange, HP_chr_char_slotchange) }, { HP_POP(chr->rename_char_sql, HP_chr_rename_char_sql) }, + { HP_POP(chr->name_exists, HP_chr_name_exists) }, { HP_POP(chr->check_char_name, HP_chr_check_char_name) }, { HP_POP(chr->make_new_char_sql, HP_chr_make_new_char_sql) }, { HP_POP(chr->divorce_char_sql, HP_chr_divorce_char_sql) }, @@ -262,6 +263,10 @@ struct HookingPointData HookingPoints[] = { { HP_POP(inter_elemental->sql_init, HP_inter_elemental_sql_init) }, { HP_POP(inter_elemental->sql_final, HP_inter_elemental_sql_final) }, { HP_POP(inter_elemental->parse_frommap, HP_inter_elemental_parse_frommap) }, + { HP_POP(inter_elemental->create, HP_inter_elemental_create) }, + { HP_POP(inter_elemental->save, HP_inter_elemental_save) }, + { HP_POP(inter_elemental->load, HP_inter_elemental_load) }, + { HP_POP(inter_elemental->delete, HP_inter_elemental_delete) }, /* inter_guild_interface */ { HP_POP(inter_guild->save_timer, HP_inter_guild_save_timer) }, { HP_POP(inter_guild->removemember_tosql, HP_inter_guild_removemember_tosql) }, @@ -283,12 +288,31 @@ struct HookingPointData HookingPoints[] = { { HP_POP(inter_guild->sex_changed, HP_inter_guild_sex_changed) }, { HP_POP(inter_guild->charname_changed, HP_inter_guild_charname_changed) }, { HP_POP(inter_guild->parse_frommap, HP_inter_guild_parse_frommap) }, - { HP_POP(inter_guild->leave, HP_inter_guild_leave) }, { HP_POP(inter_guild->broken, HP_inter_guild_broken) }, + { HP_POP(inter_guild->create, HP_inter_guild_create) }, + { HP_POP(inter_guild->add_member, HP_inter_guild_add_member) }, + { HP_POP(inter_guild->leave, HP_inter_guild_leave) }, + { HP_POP(inter_guild->update_member_info_short, HP_inter_guild_update_member_info_short) }, + { HP_POP(inter_guild->update_member_info, HP_inter_guild_update_member_info) }, + { HP_POP(inter_guild->disband, HP_inter_guild_disband) }, + { HP_POP(inter_guild->update_basic_info, HP_inter_guild_update_basic_info) }, + { HP_POP(inter_guild->update_position, HP_inter_guild_update_position) }, + { HP_POP(inter_guild->use_skill_point, HP_inter_guild_use_skill_point) }, + { HP_POP(inter_guild->remove_alliance, HP_inter_guild_remove_alliance) }, + { HP_POP(inter_guild->change_alliance, HP_inter_guild_change_alliance) }, + { HP_POP(inter_guild->update_notice, HP_inter_guild_update_notice) }, + { HP_POP(inter_guild->update_emblem, HP_inter_guild_update_emblem) }, + { HP_POP(inter_guild->update_castle_data, HP_inter_guild_update_castle_data) }, + { HP_POP(inter_guild->change_leader, HP_inter_guild_change_leader) }, /* inter_homunculus_interface */ { HP_POP(inter_homunculus->sql_init, HP_inter_homunculus_sql_init) }, { HP_POP(inter_homunculus->sql_final, HP_inter_homunculus_sql_final) }, { HP_POP(inter_homunculus->parse_frommap, HP_inter_homunculus_parse_frommap) }, + { HP_POP(inter_homunculus->create, HP_inter_homunculus_create) }, + { HP_POP(inter_homunculus->save, HP_inter_homunculus_save) }, + { HP_POP(inter_homunculus->load, HP_inter_homunculus_load) }, + { HP_POP(inter_homunculus->delete, HP_inter_homunculus_delete) }, + { HP_POP(inter_homunculus->rename, HP_inter_homunculus_rename) }, /* inter_interface */ { HP_POP(inter->msg_txt, HP_inter_msg_txt) }, { HP_POP(inter->msg_config_read, HP_inter_msg_config_read) }, @@ -308,6 +332,11 @@ struct HookingPointData HookingPoints[] = { { HP_POP(inter->config_read, HP_inter_config_read) }, { HP_POP(inter->config_read_log, HP_inter_config_read_log) }, { HP_POP(inter->config_read_connection, HP_inter_config_read_connection) }, + { HP_POP(inter->accinfo, HP_inter_accinfo) }, + { HP_POP(inter->accinfo2, HP_inter_accinfo2) }, + { HP_POP(inter->add_wisdata, HP_inter_add_wisdata) }, + { HP_POP(inter->get_wisdata, HP_inter_get_wisdata) }, + { HP_POP(inter->remove_wisdata, HP_inter_remove_wisdata) }, /* inter_mail_interface */ { HP_POP(inter_mail->sql_init, HP_inter_mail_sql_init) }, { HP_POP(inter_mail->sql_final, HP_inter_mail_sql_final) }, @@ -317,6 +346,11 @@ struct HookingPointData HookingPoints[] = { { HP_POP(inter_mail->loadmessage, HP_inter_mail_loadmessage) }, { HP_POP(inter_mail->DeleteAttach, HP_inter_mail_DeleteAttach) }, { HP_POP(inter_mail->sendmail, HP_inter_mail_sendmail) }, + { HP_POP(inter_mail->mark_read, HP_inter_mail_mark_read) }, + { HP_POP(inter_mail->get_attachment, HP_inter_mail_get_attachment) }, + { HP_POP(inter_mail->delete, HP_inter_mail_delete) }, + { HP_POP(inter_mail->return_message, HP_inter_mail_return_message) }, + { HP_POP(inter_mail->send, HP_inter_mail_send) }, /* inter_mercenary_interface */ { HP_POP(inter_mercenary->owner_fromsql, HP_inter_mercenary_owner_fromsql) }, { HP_POP(inter_mercenary->owner_tosql, HP_inter_mercenary_owner_tosql) }, @@ -324,6 +358,10 @@ struct HookingPointData HookingPoints[] = { { HP_POP(inter_mercenary->sql_init, HP_inter_mercenary_sql_init) }, { HP_POP(inter_mercenary->sql_final, HP_inter_mercenary_sql_final) }, { HP_POP(inter_mercenary->parse_frommap, HP_inter_mercenary_parse_frommap) }, + { HP_POP(inter_mercenary->create, HP_inter_mercenary_create) }, + { HP_POP(inter_mercenary->save, HP_inter_mercenary_save) }, + { HP_POP(inter_mercenary->load, HP_inter_mercenary_load) }, + { HP_POP(inter_mercenary->delete, HP_inter_mercenary_delete) }, /* inter_party_interface */ { HP_POP(inter_party->check_lv, HP_inter_party_check_lv) }, { HP_POP(inter_party->calc_state, HP_inter_party_calc_state) }, @@ -338,6 +376,12 @@ struct HookingPointData HookingPoints[] = { { HP_POP(inter_party->leave, HP_inter_party_leave) }, { HP_POP(inter_party->CharOnline, HP_inter_party_CharOnline) }, { HP_POP(inter_party->CharOffline, HP_inter_party_CharOffline) }, + { HP_POP(inter_party->create, HP_inter_party_create) }, + { HP_POP(inter_party->add_member, HP_inter_party_add_member) }, + { HP_POP(inter_party->change_option, HP_inter_party_change_option) }, + { HP_POP(inter_party->change_map, HP_inter_party_change_map) }, + { HP_POP(inter_party->disband, HP_inter_party_disband) }, + { HP_POP(inter_party->change_leader, HP_inter_party_change_leader) }, /* inter_pet_interface */ { HP_POP(inter_pet->tosql, HP_inter_pet_tosql) }, { HP_POP(inter_pet->fromsql, HP_inter_pet_fromsql) }, @@ -345,8 +389,15 @@ struct HookingPointData HookingPoints[] = { { HP_POP(inter_pet->sql_final, HP_inter_pet_sql_final) }, { HP_POP(inter_pet->delete_, HP_inter_pet_delete_) }, { HP_POP(inter_pet->parse_frommap, HP_inter_pet_parse_frommap) }, + { HP_POP(inter_pet->create, HP_inter_pet_create) }, + { HP_POP(inter_pet->load, HP_inter_pet_load) }, /* inter_quest_interface */ { HP_POP(inter_quest->parse_frommap, HP_inter_quest_parse_frommap) }, + { HP_POP(inter_quest->fromsql, HP_inter_quest_fromsql) }, + { HP_POP(inter_quest->delete, HP_inter_quest_delete) }, + { HP_POP(inter_quest->add, HP_inter_quest_add) }, + { HP_POP(inter_quest->update, HP_inter_quest_update) }, + { HP_POP(inter_quest->save, HP_inter_quest_save) }, /* inter_rodex_interface */ { HP_POP(inter_rodex->sql_init, HP_inter_rodex_sql_init) }, { HP_POP(inter_rodex->sql_final, HP_inter_rodex_sql_final) }, @@ -355,6 +406,7 @@ struct HookingPointData HookingPoints[] = { { HP_POP(inter_rodex->hasnew, HP_inter_rodex_hasnew) }, { HP_POP(inter_rodex->checkname, HP_inter_rodex_checkname) }, { HP_POP(inter_rodex->savemessage, HP_inter_rodex_savemessage) }, + { HP_POP(inter_rodex->updatemail, HP_inter_rodex_updatemail) }, /* inter_storage_interface */ { HP_POP(inter_storage->tosql, HP_inter_storage_tosql) }, { HP_POP(inter_storage->fromsql, HP_inter_storage_fromsql) }, @@ -365,6 +417,7 @@ struct HookingPointData HookingPoints[] = { { HP_POP(inter_storage->delete_, HP_inter_storage_delete_) }, { HP_POP(inter_storage->guild_storage_delete, HP_inter_storage_guild_storage_delete) }, { HP_POP(inter_storage->parse_frommap, HP_inter_storage_parse_frommap) }, + { HP_POP(inter_storage->retrieve_bound_items, HP_inter_storage_retrieve_bound_items) }, /* libconfig_interface */ { HP_POP(libconfig->read, HP_libconfig_read) }, { HP_POP(libconfig->write, HP_libconfig_write) }, @@ -471,10 +524,6 @@ struct HookingPointData HookingPoints[] = { { HP_POP(mapif->parse_auction_close, HP_mapif_parse_auction_close) }, { HP_POP(mapif->auction_bid, HP_mapif_auction_bid) }, { HP_POP(mapif->parse_auction_bid, HP_mapif_parse_auction_bid) }, - { HP_POP(mapif->elemental_create, HP_mapif_elemental_create) }, - { HP_POP(mapif->elemental_save, HP_mapif_elemental_save) }, - { HP_POP(mapif->elemental_load, HP_mapif_elemental_load) }, - { HP_POP(mapif->elemental_delete, HP_mapif_elemental_delete) }, { HP_POP(mapif->elemental_send, HP_mapif_elemental_send) }, { HP_POP(mapif->parse_elemental_create, HP_mapif_parse_elemental_create) }, { HP_POP(mapif->parse_elemental_load, HP_mapif_parse_elemental_load) }, @@ -510,7 +559,6 @@ struct HookingPointData HookingPoints[] = { { HP_POP(mapif->parse_GuildMemberInfoChange, HP_mapif_parse_GuildMemberInfoChange) }, { HP_POP(mapif->parse_GuildPosition, HP_mapif_parse_GuildPosition) }, { HP_POP(mapif->parse_GuildSkillUp, HP_mapif_parse_GuildSkillUp) }, - { HP_POP(mapif->parse_GuildDeleteAlliance, HP_mapif_parse_GuildDeleteAlliance) }, { HP_POP(mapif->parse_GuildAlliance, HP_mapif_parse_GuildAlliance) }, { HP_POP(mapif->parse_GuildNotice, HP_mapif_parse_GuildNotice) }, { HP_POP(mapif->parse_GuildEmblem, HP_mapif_parse_GuildEmblem) }, @@ -522,11 +570,6 @@ struct HookingPointData HookingPoints[] = { { HP_POP(mapif->homunculus_loaded, HP_mapif_homunculus_loaded) }, { HP_POP(mapif->homunculus_saved, HP_mapif_homunculus_saved) }, { HP_POP(mapif->homunculus_renamed, HP_mapif_homunculus_renamed) }, - { HP_POP(mapif->homunculus_create, HP_mapif_homunculus_create) }, - { HP_POP(mapif->homunculus_save, HP_mapif_homunculus_save) }, - { HP_POP(mapif->homunculus_load, HP_mapif_homunculus_load) }, - { HP_POP(mapif->homunculus_delete, HP_mapif_homunculus_delete) }, - { HP_POP(mapif->homunculus_rename, HP_mapif_homunculus_rename) }, { HP_POP(mapif->parse_homunculus_create, HP_mapif_parse_homunculus_create) }, { HP_POP(mapif->parse_homunculus_delete, HP_mapif_parse_homunculus_delete) }, { HP_POP(mapif->parse_homunculus_load, HP_mapif_parse_homunculus_load) }, @@ -536,7 +579,6 @@ struct HookingPointData HookingPoints[] = { { HP_POP(mapif->parse_mail_requestinbox, HP_mapif_parse_mail_requestinbox) }, { HP_POP(mapif->parse_mail_read, HP_mapif_parse_mail_read) }, { HP_POP(mapif->mail_sendattach, HP_mapif_mail_sendattach) }, - { HP_POP(mapif->mail_getattach, HP_mapif_mail_getattach) }, { HP_POP(mapif->parse_mail_getattach, HP_mapif_parse_mail_getattach) }, { HP_POP(mapif->mail_delete, HP_mapif_mail_delete) }, { HP_POP(mapif->parse_mail_delete, HP_mapif_parse_mail_delete) }, @@ -545,10 +587,6 @@ struct HookingPointData HookingPoints[] = { { HP_POP(mapif->parse_mail_return, HP_mapif_parse_mail_return) }, { HP_POP(mapif->mail_send, HP_mapif_mail_send) }, { HP_POP(mapif->parse_mail_send, HP_mapif_parse_mail_send) }, - { HP_POP(mapif->mercenary_create, HP_mapif_mercenary_create) }, - { HP_POP(mapif->mercenary_save, HP_mapif_mercenary_save) }, - { HP_POP(mapif->mercenary_load, HP_mapif_mercenary_load) }, - { HP_POP(mapif->mercenary_delete, HP_mapif_mercenary_delete) }, { HP_POP(mapif->mercenary_send, HP_mapif_mercenary_send) }, { HP_POP(mapif->parse_mercenary_create, HP_mapif_parse_mercenary_create) }, { HP_POP(mapif->parse_mercenary_load, HP_mapif_parse_mercenary_load) }, @@ -579,18 +617,12 @@ struct HookingPointData HookingPoints[] = { { HP_POP(mapif->pet_noinfo, HP_mapif_pet_noinfo) }, { HP_POP(mapif->save_pet_ack, HP_mapif_save_pet_ack) }, { HP_POP(mapif->delete_pet_ack, HP_mapif_delete_pet_ack) }, - { HP_POP(mapif->create_pet, HP_mapif_create_pet) }, - { HP_POP(mapif->load_pet, HP_mapif_load_pet) }, { HP_POP(mapif->save_pet, HP_mapif_save_pet) }, { HP_POP(mapif->delete_pet, HP_mapif_delete_pet) }, { HP_POP(mapif->parse_CreatePet, HP_mapif_parse_CreatePet) }, { HP_POP(mapif->parse_LoadPet, HP_mapif_parse_LoadPet) }, { HP_POP(mapif->parse_SavePet, HP_mapif_parse_SavePet) }, { HP_POP(mapif->parse_DeletePet, HP_mapif_parse_DeletePet) }, - { HP_POP(mapif->quests_fromsql, HP_mapif_quests_fromsql) }, - { HP_POP(mapif->quest_delete, HP_mapif_quest_delete) }, - { HP_POP(mapif->quest_add, HP_mapif_quest_add) }, - { HP_POP(mapif->quest_update, HP_mapif_quest_update) }, { HP_POP(mapif->quest_save_ack, HP_mapif_quest_save_ack) }, { HP_POP(mapif->parse_quest_save, HP_mapif_parse_quest_save) }, { HP_POP(mapif->send_quests, HP_mapif_send_quests) }, @@ -613,10 +645,8 @@ struct HookingPointData HookingPoints[] = { { HP_POP(mapif->pAccountStorageSave, HP_mapif_pAccountStorageSave) }, { HP_POP(mapif->sAccountStorageSaveAck, HP_mapif_sAccountStorageSaveAck) }, { HP_POP(mapif->itembound_ack, HP_mapif_itembound_ack) }, - { HP_POP(mapif->parse_ItemBoundRetrieve_sub, HP_mapif_parse_ItemBoundRetrieve_sub) }, { HP_POP(mapif->parse_ItemBoundRetrieve, HP_mapif_parse_ItemBoundRetrieve) }, { HP_POP(mapif->parse_accinfo, HP_mapif_parse_accinfo) }, - { HP_POP(mapif->parse_accinfo2, HP_mapif_parse_accinfo2) }, { HP_POP(mapif->broadcast, HP_mapif_broadcast) }, { HP_POP(mapif->wis_message, HP_mapif_wis_message) }, { HP_POP(mapif->wis_response, HP_mapif_wis_response) }, diff --git a/src/plugins/HPMHooking/HPMHooking_char.Hooks.inc b/src/plugins/HPMHooking/HPMHooking_char.Hooks.inc index 6ce1c5015..765044b5b 100644 --- a/src/plugins/HPMHooking/HPMHooking_char.Hooks.inc +++ b/src/plugins/HPMHooking/HPMHooking_char.Hooks.inc @@ -744,11 +744,38 @@ int HP_chr_rename_char_sql(struct char_session_data *sd, int char_id) { } return retVal___; } -int HP_chr_check_char_name(char *name, char *esc_name) { +bool HP_chr_name_exists(const char *name, const char *esc_name) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_chr_name_exists_pre > 0) { + bool (*preHookFunc) (const char **name, const char **esc_name); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_chr_name_exists_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_chr_name_exists_pre[hIndex].func; + retVal___ = preHookFunc(&name, &esc_name); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.chr.name_exists(name, esc_name); + } + if (HPMHooks.count.HP_chr_name_exists_post > 0) { + bool (*postHookFunc) (bool retVal___, const char *name, const char *esc_name); + for (hIndex = 0; hIndex < HPMHooks.count.HP_chr_name_exists_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_chr_name_exists_post[hIndex].func; + retVal___ = postHookFunc(retVal___, name, esc_name); + } + } + return retVal___; +} +int HP_chr_check_char_name(const char *name, const char *esc_name) { int hIndex = 0; int retVal___ = 0; if (HPMHooks.count.HP_chr_check_char_name_pre > 0) { - int (*preHookFunc) (char **name, char **esc_name); + int (*preHookFunc) (const char **name, const char **esc_name); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_chr_check_char_name_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_chr_check_char_name_pre[hIndex].func; @@ -763,7 +790,7 @@ int HP_chr_check_char_name(char *name, char *esc_name) { retVal___ = HPMHooks.source.chr.check_char_name(name, esc_name); } if (HPMHooks.count.HP_chr_check_char_name_post > 0) { - int (*postHookFunc) (int retVal___, char *name, char *esc_name); + int (*postHookFunc) (int retVal___, const char *name, const char *esc_name); for (hIndex = 0; hIndex < HPMHooks.count.HP_chr_check_char_name_post; hIndex++) { postHookFunc = HPMHooks.list.HP_chr_check_char_name_post[hIndex].func; retVal___ = postHookFunc(retVal___, name, esc_name); @@ -6015,6 +6042,114 @@ int HP_inter_elemental_parse_frommap(int fd) { } return retVal___; } +bool HP_inter_elemental_create(struct s_elemental *ele) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_elemental_create_pre > 0) { + bool (*preHookFunc) (struct s_elemental **ele); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_elemental_create_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_elemental_create_pre[hIndex].func; + retVal___ = preHookFunc(&ele); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_elemental.create(ele); + } + if (HPMHooks.count.HP_inter_elemental_create_post > 0) { + bool (*postHookFunc) (bool retVal___, struct s_elemental *ele); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_elemental_create_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_elemental_create_post[hIndex].func; + retVal___ = postHookFunc(retVal___, ele); + } + } + return retVal___; +} +bool HP_inter_elemental_save(const struct s_elemental *ele) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_elemental_save_pre > 0) { + bool (*preHookFunc) (const struct s_elemental **ele); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_elemental_save_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_elemental_save_pre[hIndex].func; + retVal___ = preHookFunc(&ele); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_elemental.save(ele); + } + if (HPMHooks.count.HP_inter_elemental_save_post > 0) { + bool (*postHookFunc) (bool retVal___, const struct s_elemental *ele); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_elemental_save_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_elemental_save_post[hIndex].func; + retVal___ = postHookFunc(retVal___, ele); + } + } + return retVal___; +} +bool HP_inter_elemental_load(int ele_id, int char_id, struct s_elemental *ele) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_elemental_load_pre > 0) { + bool (*preHookFunc) (int *ele_id, int *char_id, struct s_elemental **ele); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_elemental_load_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_elemental_load_pre[hIndex].func; + retVal___ = preHookFunc(&ele_id, &char_id, &ele); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_elemental.load(ele_id, char_id, ele); + } + if (HPMHooks.count.HP_inter_elemental_load_post > 0) { + bool (*postHookFunc) (bool retVal___, int ele_id, int char_id, struct s_elemental *ele); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_elemental_load_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_elemental_load_post[hIndex].func; + retVal___ = postHookFunc(retVal___, ele_id, char_id, ele); + } + } + return retVal___; +} +bool HP_inter_elemental_delete(int ele_id) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_elemental_delete_pre > 0) { + bool (*preHookFunc) (int *ele_id); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_elemental_delete_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_elemental_delete_pre[hIndex].func; + retVal___ = preHookFunc(&ele_id); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_elemental.delete(ele_id); + } + if (HPMHooks.count.HP_inter_elemental_delete_post > 0) { + bool (*postHookFunc) (bool retVal___, int ele_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_elemental_delete_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_elemental_delete_post[hIndex].func; + retVal___ = postHookFunc(retVal___, ele_id); + } + } + return retVal___; +} /* inter_guild_interface */ int HP_inter_guild_save_timer(int tid, int64 tick, int id, intptr_t data) { int hIndex = 0; @@ -6561,33 +6696,6 @@ int HP_inter_guild_parse_frommap(int fd) { } return retVal___; } -int HP_inter_guild_leave(int guild_id, int account_id, int char_id) { - int hIndex = 0; - int retVal___ = 0; - if (HPMHooks.count.HP_inter_guild_leave_pre > 0) { - int (*preHookFunc) (int *guild_id, int *account_id, int *char_id); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_leave_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_inter_guild_leave_pre[hIndex].func; - retVal___ = preHookFunc(&guild_id, &account_id, &char_id); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.inter_guild.leave(guild_id, account_id, char_id); - } - if (HPMHooks.count.HP_inter_guild_leave_post > 0) { - int (*postHookFunc) (int retVal___, int guild_id, int account_id, int char_id); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_leave_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_inter_guild_leave_post[hIndex].func; - retVal___ = postHookFunc(retVal___, guild_id, account_id, char_id); - } - } - return retVal___; -} int HP_inter_guild_broken(int guild_id) { int hIndex = 0; int retVal___ = 0; @@ -6615,16 +6723,15 @@ int HP_inter_guild_broken(int guild_id) { } return retVal___; } -/* inter_homunculus_interface */ -int HP_inter_homunculus_sql_init(void) { +struct guild* HP_inter_guild_create(const char *name, const struct guild_member *master) { int hIndex = 0; - int retVal___ = 0; - if (HPMHooks.count.HP_inter_homunculus_sql_init_pre > 0) { - int (*preHookFunc) (void); + struct guild* retVal___ = NULL; + if (HPMHooks.count.HP_inter_guild_create_pre > 0) { + struct guild* (*preHookFunc) (const char **name, const struct guild_member **master); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_sql_init_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_inter_homunculus_sql_init_pre[hIndex].func; - retVal___ = preHookFunc(); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_create_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_create_pre[hIndex].func; + retVal___ = preHookFunc(&name, &master); } if (*HPMforce_return) { *HPMforce_return = false; @@ -6632,52 +6739,53 @@ int HP_inter_homunculus_sql_init(void) { } } { - retVal___ = HPMHooks.source.inter_homunculus.sql_init(); + retVal___ = HPMHooks.source.inter_guild.create(name, master); } - if (HPMHooks.count.HP_inter_homunculus_sql_init_post > 0) { - int (*postHookFunc) (int retVal___); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_sql_init_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_inter_homunculus_sql_init_post[hIndex].func; - retVal___ = postHookFunc(retVal___); + if (HPMHooks.count.HP_inter_guild_create_post > 0) { + struct guild* (*postHookFunc) (struct guild* retVal___, const char *name, const struct guild_member *master); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_create_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_create_post[hIndex].func; + retVal___ = postHookFunc(retVal___, name, master); } } return retVal___; } -void HP_inter_homunculus_sql_final(void) { +bool HP_inter_guild_add_member(int guild_id, const struct guild_member *member) { int hIndex = 0; - if (HPMHooks.count.HP_inter_homunculus_sql_final_pre > 0) { - void (*preHookFunc) (void); + bool retVal___ = false; + if (HPMHooks.count.HP_inter_guild_add_member_pre > 0) { + bool (*preHookFunc) (int *guild_id, const struct guild_member **member); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_sql_final_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_inter_homunculus_sql_final_pre[hIndex].func; - preHookFunc(); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_add_member_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_add_member_pre[hIndex].func; + retVal___ = preHookFunc(&guild_id, &member); } if (*HPMforce_return) { *HPMforce_return = false; - return; + return retVal___; } } { - HPMHooks.source.inter_homunculus.sql_final(); + retVal___ = HPMHooks.source.inter_guild.add_member(guild_id, member); } - if (HPMHooks.count.HP_inter_homunculus_sql_final_post > 0) { - void (*postHookFunc) (void); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_sql_final_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_inter_homunculus_sql_final_post[hIndex].func; - postHookFunc(); + if (HPMHooks.count.HP_inter_guild_add_member_post > 0) { + bool (*postHookFunc) (bool retVal___, int guild_id, const struct guild_member *member); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_add_member_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_add_member_post[hIndex].func; + retVal___ = postHookFunc(retVal___, guild_id, member); } } - return; + return retVal___; } -int HP_inter_homunculus_parse_frommap(int fd) { +bool HP_inter_guild_leave(int guild_id, int account_id, int char_id, int flag, const char *mes, int map_fd) { int hIndex = 0; - int retVal___ = 0; - if (HPMHooks.count.HP_inter_homunculus_parse_frommap_pre > 0) { - int (*preHookFunc) (int *fd); + bool retVal___ = false; + if (HPMHooks.count.HP_inter_guild_leave_pre > 0) { + bool (*preHookFunc) (int *guild_id, int *account_id, int *char_id, int *flag, const char **mes, int *map_fd); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_parse_frommap_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_inter_homunculus_parse_frommap_pre[hIndex].func; - retVal___ = preHookFunc(&fd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_leave_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_leave_pre[hIndex].func; + retVal___ = preHookFunc(&guild_id, &account_id, &char_id, &flag, &mes, &map_fd); } if (*HPMforce_return) { *HPMforce_return = false; @@ -6685,27 +6793,26 @@ int HP_inter_homunculus_parse_frommap(int fd) { } } { - retVal___ = HPMHooks.source.inter_homunculus.parse_frommap(fd); + retVal___ = HPMHooks.source.inter_guild.leave(guild_id, account_id, char_id, flag, mes, map_fd); } - if (HPMHooks.count.HP_inter_homunculus_parse_frommap_post > 0) { - int (*postHookFunc) (int retVal___, int fd); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_parse_frommap_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_inter_homunculus_parse_frommap_post[hIndex].func; - retVal___ = postHookFunc(retVal___, fd); + if (HPMHooks.count.HP_inter_guild_leave_post > 0) { + bool (*postHookFunc) (bool retVal___, int guild_id, int account_id, int char_id, int flag, const char *mes, int map_fd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_leave_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_leave_post[hIndex].func; + retVal___ = postHookFunc(retVal___, guild_id, account_id, char_id, flag, mes, map_fd); } } return retVal___; } -/* inter_interface */ -const char* HP_inter_msg_txt(int msg_number) { +bool HP_inter_guild_update_member_info_short(int guild_id, int account_id, int char_id, int online, int lv, int16 class) { int hIndex = 0; - const char* retVal___ = NULL; - if (HPMHooks.count.HP_inter_msg_txt_pre > 0) { - const char* (*preHookFunc) (int *msg_number); + bool retVal___ = false; + if (HPMHooks.count.HP_inter_guild_update_member_info_short_pre > 0) { + bool (*preHookFunc) (int *guild_id, int *account_id, int *char_id, int *online, int *lv, int16 *class); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_msg_txt_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_inter_msg_txt_pre[hIndex].func; - retVal___ = preHookFunc(&msg_number); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_update_member_info_short_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_update_member_info_short_pre[hIndex].func; + retVal___ = preHookFunc(&guild_id, &account_id, &char_id, &online, &lv, &class); } if (*HPMforce_return) { *HPMforce_return = false; @@ -6713,26 +6820,26 @@ const char* HP_inter_msg_txt(int msg_number) { } } { - retVal___ = HPMHooks.source.inter.msg_txt(msg_number); + retVal___ = HPMHooks.source.inter_guild.update_member_info_short(guild_id, account_id, char_id, online, lv, class); } - if (HPMHooks.count.HP_inter_msg_txt_post > 0) { - const char* (*postHookFunc) (const char* retVal___, int msg_number); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_msg_txt_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_inter_msg_txt_post[hIndex].func; - retVal___ = postHookFunc(retVal___, msg_number); + if (HPMHooks.count.HP_inter_guild_update_member_info_short_post > 0) { + bool (*postHookFunc) (bool retVal___, int guild_id, int account_id, int char_id, int online, int lv, int16 class); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_update_member_info_short_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_update_member_info_short_post[hIndex].func; + retVal___ = postHookFunc(retVal___, guild_id, account_id, char_id, online, lv, class); } } return retVal___; } -bool HP_inter_msg_config_read(const char *cfg_name, bool allow_override) { +bool HP_inter_guild_update_member_info(int guild_id, int account_id, int char_id, int type, const char *data, int len) { int hIndex = 0; bool retVal___ = false; - if (HPMHooks.count.HP_inter_msg_config_read_pre > 0) { - bool (*preHookFunc) (const char **cfg_name, bool *allow_override); + if (HPMHooks.count.HP_inter_guild_update_member_info_pre > 0) { + bool (*preHookFunc) (int *guild_id, int *account_id, int *char_id, int *type, const char **data, int *len); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_msg_config_read_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_inter_msg_config_read_pre[hIndex].func; - retVal___ = preHookFunc(&cfg_name, &allow_override); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_update_member_info_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_update_member_info_pre[hIndex].func; + retVal___ = preHookFunc(&guild_id, &account_id, &char_id, &type, &data, &len); } if (*HPMforce_return) { *HPMforce_return = false; @@ -6740,52 +6847,53 @@ bool HP_inter_msg_config_read(const char *cfg_name, bool allow_override) { } } { - retVal___ = HPMHooks.source.inter.msg_config_read(cfg_name, allow_override); + retVal___ = HPMHooks.source.inter_guild.update_member_info(guild_id, account_id, char_id, type, data, len); } - if (HPMHooks.count.HP_inter_msg_config_read_post > 0) { - bool (*postHookFunc) (bool retVal___, const char *cfg_name, bool allow_override); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_msg_config_read_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_inter_msg_config_read_post[hIndex].func; - retVal___ = postHookFunc(retVal___, cfg_name, allow_override); + if (HPMHooks.count.HP_inter_guild_update_member_info_post > 0) { + bool (*postHookFunc) (bool retVal___, int guild_id, int account_id, int char_id, int type, const char *data, int len); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_update_member_info_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_update_member_info_post[hIndex].func; + retVal___ = postHookFunc(retVal___, guild_id, account_id, char_id, type, data, len); } } return retVal___; } -void HP_inter_do_final_msg(void) { +bool HP_inter_guild_disband(int guild_id) { int hIndex = 0; - if (HPMHooks.count.HP_inter_do_final_msg_pre > 0) { - void (*preHookFunc) (void); + bool retVal___ = false; + if (HPMHooks.count.HP_inter_guild_disband_pre > 0) { + bool (*preHookFunc) (int *guild_id); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_do_final_msg_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_inter_do_final_msg_pre[hIndex].func; - preHookFunc(); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_disband_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_disband_pre[hIndex].func; + retVal___ = preHookFunc(&guild_id); } if (*HPMforce_return) { *HPMforce_return = false; - return; + return retVal___; } } { - HPMHooks.source.inter.do_final_msg(); + retVal___ = HPMHooks.source.inter_guild.disband(guild_id); } - if (HPMHooks.count.HP_inter_do_final_msg_post > 0) { - void (*postHookFunc) (void); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_do_final_msg_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_inter_do_final_msg_post[hIndex].func; - postHookFunc(); + if (HPMHooks.count.HP_inter_guild_disband_post > 0) { + bool (*postHookFunc) (bool retVal___, int guild_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_disband_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_disband_post[hIndex].func; + retVal___ = postHookFunc(retVal___, guild_id); } } - return; + return retVal___; } -const char* HP_inter_job_name(int class) { +bool HP_inter_guild_update_basic_info(int guild_id, int type, const void *data, int len) { int hIndex = 0; - const char* retVal___ = NULL; - if (HPMHooks.count.HP_inter_job_name_pre > 0) { - const char* (*preHookFunc) (int *class); + bool retVal___ = false; + if (HPMHooks.count.HP_inter_guild_update_basic_info_pre > 0) { + bool (*preHookFunc) (int *guild_id, int *type, const void **data, int *len); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_job_name_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_inter_job_name_pre[hIndex].func; - retVal___ = preHookFunc(&class); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_update_basic_info_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_update_basic_info_pre[hIndex].func; + retVal___ = preHookFunc(&guild_id, &type, &data, &len); } if (*HPMforce_return) { *HPMforce_return = false; @@ -6793,53 +6901,593 @@ const char* HP_inter_job_name(int class) { } } { - retVal___ = HPMHooks.source.inter.job_name(class); + retVal___ = HPMHooks.source.inter_guild.update_basic_info(guild_id, type, data, len); } - if (HPMHooks.count.HP_inter_job_name_post > 0) { - const char* (*postHookFunc) (const char* retVal___, int class); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_job_name_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_inter_job_name_post[hIndex].func; - retVal___ = postHookFunc(retVal___, class); + if (HPMHooks.count.HP_inter_guild_update_basic_info_post > 0) { + bool (*postHookFunc) (bool retVal___, int guild_id, int type, const void *data, int len); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_update_basic_info_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_update_basic_info_post[hIndex].func; + retVal___ = postHookFunc(retVal___, guild_id, type, data, len); } } return retVal___; } -void HP_inter_vmsg_to_fd(int fd, int u_fd, int aid, char *msg, va_list ap) { +bool HP_inter_guild_update_position(int guild_id, int idx, const struct guild_position *p) { int hIndex = 0; - if (HPMHooks.count.HP_inter_vmsg_to_fd_pre > 0) { - void (*preHookFunc) (int *fd, int *u_fd, int *aid, char **msg, va_list ap); + bool retVal___ = false; + if (HPMHooks.count.HP_inter_guild_update_position_pre > 0) { + bool (*preHookFunc) (int *guild_id, int *idx, const struct guild_position **p); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_vmsg_to_fd_pre; hIndex++) { - va_list ap___copy; va_copy(ap___copy, ap); - preHookFunc = HPMHooks.list.HP_inter_vmsg_to_fd_pre[hIndex].func; - preHookFunc(&fd, &u_fd, &aid, &msg, ap___copy); - va_end(ap___copy); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_update_position_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_update_position_pre[hIndex].func; + retVal___ = preHookFunc(&guild_id, &idx, &p); } if (*HPMforce_return) { *HPMforce_return = false; - return; + return retVal___; } } { - va_list ap___copy; va_copy(ap___copy, ap); - HPMHooks.source.inter.vmsg_to_fd(fd, u_fd, aid, msg, ap___copy); - va_end(ap___copy); + retVal___ = HPMHooks.source.inter_guild.update_position(guild_id, idx, p); } - if (HPMHooks.count.HP_inter_vmsg_to_fd_post > 0) { - void (*postHookFunc) (int fd, int u_fd, int aid, char *msg, va_list ap); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_vmsg_to_fd_post; hIndex++) { - va_list ap___copy; va_copy(ap___copy, ap); - postHookFunc = HPMHooks.list.HP_inter_vmsg_to_fd_post[hIndex].func; - postHookFunc(fd, u_fd, aid, msg, ap___copy); - va_end(ap___copy); + if (HPMHooks.count.HP_inter_guild_update_position_post > 0) { + bool (*postHookFunc) (bool retVal___, int guild_id, int idx, const struct guild_position *p); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_update_position_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_update_position_post[hIndex].func; + retVal___ = postHookFunc(retVal___, guild_id, idx, p); } } - return; + return retVal___; } -void HP_inter_savereg(int account_id, int char_id, const char *key, unsigned int index, intptr_t val, bool is_string) { +bool HP_inter_guild_use_skill_point(int guild_id, uint16 skill_id, int account_id, int max) { int hIndex = 0; - if (HPMHooks.count.HP_inter_savereg_pre > 0) { - void (*preHookFunc) (int *account_id, int *char_id, const char **key, unsigned int *index, intptr_t *val, bool *is_string); + bool retVal___ = false; + if (HPMHooks.count.HP_inter_guild_use_skill_point_pre > 0) { + bool (*preHookFunc) (int *guild_id, uint16 *skill_id, int *account_id, int *max); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_use_skill_point_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_use_skill_point_pre[hIndex].func; + retVal___ = preHookFunc(&guild_id, &skill_id, &account_id, &max); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_guild.use_skill_point(guild_id, skill_id, account_id, max); + } + if (HPMHooks.count.HP_inter_guild_use_skill_point_post > 0) { + bool (*postHookFunc) (bool retVal___, int guild_id, uint16 skill_id, int account_id, int max); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_use_skill_point_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_use_skill_point_post[hIndex].func; + retVal___ = postHookFunc(retVal___, guild_id, skill_id, account_id, max); + } + } + return retVal___; +} +bool HP_inter_guild_remove_alliance(struct guild *g, int guild_id, int account_id1, int account_id2, int flag) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_guild_remove_alliance_pre > 0) { + bool (*preHookFunc) (struct guild **g, int *guild_id, int *account_id1, int *account_id2, int *flag); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_remove_alliance_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_remove_alliance_pre[hIndex].func; + retVal___ = preHookFunc(&g, &guild_id, &account_id1, &account_id2, &flag); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_guild.remove_alliance(g, guild_id, account_id1, account_id2, flag); + } + if (HPMHooks.count.HP_inter_guild_remove_alliance_post > 0) { + bool (*postHookFunc) (bool retVal___, struct guild *g, int guild_id, int account_id1, int account_id2, int flag); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_remove_alliance_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_remove_alliance_post[hIndex].func; + retVal___ = postHookFunc(retVal___, g, guild_id, account_id1, account_id2, flag); + } + } + return retVal___; +} +bool HP_inter_guild_change_alliance(int guild_id1, int guild_id2, int account_id1, int account_id2, int flag) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_guild_change_alliance_pre > 0) { + bool (*preHookFunc) (int *guild_id1, int *guild_id2, int *account_id1, int *account_id2, int *flag); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_change_alliance_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_change_alliance_pre[hIndex].func; + retVal___ = preHookFunc(&guild_id1, &guild_id2, &account_id1, &account_id2, &flag); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_guild.change_alliance(guild_id1, guild_id2, account_id1, account_id2, flag); + } + if (HPMHooks.count.HP_inter_guild_change_alliance_post > 0) { + bool (*postHookFunc) (bool retVal___, int guild_id1, int guild_id2, int account_id1, int account_id2, int flag); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_change_alliance_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_change_alliance_post[hIndex].func; + retVal___ = postHookFunc(retVal___, guild_id1, guild_id2, account_id1, account_id2, flag); + } + } + return retVal___; +} +bool HP_inter_guild_update_notice(int guild_id, const char *mes1, const char *mes2) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_guild_update_notice_pre > 0) { + bool (*preHookFunc) (int *guild_id, const char **mes1, const char **mes2); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_update_notice_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_update_notice_pre[hIndex].func; + retVal___ = preHookFunc(&guild_id, &mes1, &mes2); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_guild.update_notice(guild_id, mes1, mes2); + } + if (HPMHooks.count.HP_inter_guild_update_notice_post > 0) { + bool (*postHookFunc) (bool retVal___, int guild_id, const char *mes1, const char *mes2); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_update_notice_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_update_notice_post[hIndex].func; + retVal___ = postHookFunc(retVal___, guild_id, mes1, mes2); + } + } + return retVal___; +} +bool HP_inter_guild_update_emblem(int len, int guild_id, const char *data) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_guild_update_emblem_pre > 0) { + bool (*preHookFunc) (int *len, int *guild_id, const char **data); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_update_emblem_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_update_emblem_pre[hIndex].func; + retVal___ = preHookFunc(&len, &guild_id, &data); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_guild.update_emblem(len, guild_id, data); + } + if (HPMHooks.count.HP_inter_guild_update_emblem_post > 0) { + bool (*postHookFunc) (bool retVal___, int len, int guild_id, const char *data); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_update_emblem_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_update_emblem_post[hIndex].func; + retVal___ = postHookFunc(retVal___, len, guild_id, data); + } + } + return retVal___; +} +bool HP_inter_guild_update_castle_data(int castle_id, int index, int value) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_guild_update_castle_data_pre > 0) { + bool (*preHookFunc) (int *castle_id, int *index, int *value); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_update_castle_data_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_update_castle_data_pre[hIndex].func; + retVal___ = preHookFunc(&castle_id, &index, &value); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_guild.update_castle_data(castle_id, index, value); + } + if (HPMHooks.count.HP_inter_guild_update_castle_data_post > 0) { + bool (*postHookFunc) (bool retVal___, int castle_id, int index, int value); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_update_castle_data_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_update_castle_data_post[hIndex].func; + retVal___ = postHookFunc(retVal___, castle_id, index, value); + } + } + return retVal___; +} +bool HP_inter_guild_change_leader(int guild_id, const char *name, int len) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_guild_change_leader_pre > 0) { + bool (*preHookFunc) (int *guild_id, const char **name, int *len); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_change_leader_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_change_leader_pre[hIndex].func; + retVal___ = preHookFunc(&guild_id, &name, &len); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_guild.change_leader(guild_id, name, len); + } + if (HPMHooks.count.HP_inter_guild_change_leader_post > 0) { + bool (*postHookFunc) (bool retVal___, int guild_id, const char *name, int len); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_change_leader_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_change_leader_post[hIndex].func; + retVal___ = postHookFunc(retVal___, guild_id, name, len); + } + } + return retVal___; +} +/* inter_homunculus_interface */ +int HP_inter_homunculus_sql_init(void) { + int hIndex = 0; + int retVal___ = 0; + if (HPMHooks.count.HP_inter_homunculus_sql_init_pre > 0) { + int (*preHookFunc) (void); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_sql_init_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_homunculus_sql_init_pre[hIndex].func; + retVal___ = preHookFunc(); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_homunculus.sql_init(); + } + if (HPMHooks.count.HP_inter_homunculus_sql_init_post > 0) { + int (*postHookFunc) (int retVal___); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_sql_init_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_homunculus_sql_init_post[hIndex].func; + retVal___ = postHookFunc(retVal___); + } + } + return retVal___; +} +void HP_inter_homunculus_sql_final(void) { + int hIndex = 0; + if (HPMHooks.count.HP_inter_homunculus_sql_final_pre > 0) { + void (*preHookFunc) (void); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_sql_final_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_homunculus_sql_final_pre[hIndex].func; + preHookFunc(); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.inter_homunculus.sql_final(); + } + if (HPMHooks.count.HP_inter_homunculus_sql_final_post > 0) { + void (*postHookFunc) (void); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_sql_final_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_homunculus_sql_final_post[hIndex].func; + postHookFunc(); + } + } + return; +} +int HP_inter_homunculus_parse_frommap(int fd) { + int hIndex = 0; + int retVal___ = 0; + if (HPMHooks.count.HP_inter_homunculus_parse_frommap_pre > 0) { + int (*preHookFunc) (int *fd); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_parse_frommap_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_homunculus_parse_frommap_pre[hIndex].func; + retVal___ = preHookFunc(&fd); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_homunculus.parse_frommap(fd); + } + if (HPMHooks.count.HP_inter_homunculus_parse_frommap_post > 0) { + int (*postHookFunc) (int retVal___, int fd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_parse_frommap_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_homunculus_parse_frommap_post[hIndex].func; + retVal___ = postHookFunc(retVal___, fd); + } + } + return retVal___; +} +bool HP_inter_homunculus_create(struct s_homunculus *hd) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_homunculus_create_pre > 0) { + bool (*preHookFunc) (struct s_homunculus **hd); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_create_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_homunculus_create_pre[hIndex].func; + retVal___ = preHookFunc(&hd); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_homunculus.create(hd); + } + if (HPMHooks.count.HP_inter_homunculus_create_post > 0) { + bool (*postHookFunc) (bool retVal___, struct s_homunculus *hd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_create_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_homunculus_create_post[hIndex].func; + retVal___ = postHookFunc(retVal___, hd); + } + } + return retVal___; +} +bool HP_inter_homunculus_save(const struct s_homunculus *hd) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_homunculus_save_pre > 0) { + bool (*preHookFunc) (const struct s_homunculus **hd); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_save_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_homunculus_save_pre[hIndex].func; + retVal___ = preHookFunc(&hd); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_homunculus.save(hd); + } + if (HPMHooks.count.HP_inter_homunculus_save_post > 0) { + bool (*postHookFunc) (bool retVal___, const struct s_homunculus *hd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_save_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_homunculus_save_post[hIndex].func; + retVal___ = postHookFunc(retVal___, hd); + } + } + return retVal___; +} +bool HP_inter_homunculus_load(int homun_id, struct s_homunculus *hd) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_homunculus_load_pre > 0) { + bool (*preHookFunc) (int *homun_id, struct s_homunculus **hd); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_load_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_homunculus_load_pre[hIndex].func; + retVal___ = preHookFunc(&homun_id, &hd); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_homunculus.load(homun_id, hd); + } + if (HPMHooks.count.HP_inter_homunculus_load_post > 0) { + bool (*postHookFunc) (bool retVal___, int homun_id, struct s_homunculus *hd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_load_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_homunculus_load_post[hIndex].func; + retVal___ = postHookFunc(retVal___, homun_id, hd); + } + } + return retVal___; +} +bool HP_inter_homunculus_delete(int homun_id) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_homunculus_delete_pre > 0) { + bool (*preHookFunc) (int *homun_id); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_delete_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_homunculus_delete_pre[hIndex].func; + retVal___ = preHookFunc(&homun_id); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_homunculus.delete(homun_id); + } + if (HPMHooks.count.HP_inter_homunculus_delete_post > 0) { + bool (*postHookFunc) (bool retVal___, int homun_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_delete_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_homunculus_delete_post[hIndex].func; + retVal___ = postHookFunc(retVal___, homun_id); + } + } + return retVal___; +} +bool HP_inter_homunculus_rename(const char *name) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_homunculus_rename_pre > 0) { + bool (*preHookFunc) (const char **name); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_rename_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_homunculus_rename_pre[hIndex].func; + retVal___ = preHookFunc(&name); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_homunculus.rename(name); + } + if (HPMHooks.count.HP_inter_homunculus_rename_post > 0) { + bool (*postHookFunc) (bool retVal___, const char *name); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_homunculus_rename_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_homunculus_rename_post[hIndex].func; + retVal___ = postHookFunc(retVal___, name); + } + } + return retVal___; +} +/* inter_interface */ +const char* HP_inter_msg_txt(int msg_number) { + int hIndex = 0; + const char* retVal___ = NULL; + if (HPMHooks.count.HP_inter_msg_txt_pre > 0) { + const char* (*preHookFunc) (int *msg_number); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_msg_txt_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_msg_txt_pre[hIndex].func; + retVal___ = preHookFunc(&msg_number); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter.msg_txt(msg_number); + } + if (HPMHooks.count.HP_inter_msg_txt_post > 0) { + const char* (*postHookFunc) (const char* retVal___, int msg_number); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_msg_txt_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_msg_txt_post[hIndex].func; + retVal___ = postHookFunc(retVal___, msg_number); + } + } + return retVal___; +} +bool HP_inter_msg_config_read(const char *cfg_name, bool allow_override) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_msg_config_read_pre > 0) { + bool (*preHookFunc) (const char **cfg_name, bool *allow_override); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_msg_config_read_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_msg_config_read_pre[hIndex].func; + retVal___ = preHookFunc(&cfg_name, &allow_override); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter.msg_config_read(cfg_name, allow_override); + } + if (HPMHooks.count.HP_inter_msg_config_read_post > 0) { + bool (*postHookFunc) (bool retVal___, const char *cfg_name, bool allow_override); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_msg_config_read_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_msg_config_read_post[hIndex].func; + retVal___ = postHookFunc(retVal___, cfg_name, allow_override); + } + } + return retVal___; +} +void HP_inter_do_final_msg(void) { + int hIndex = 0; + if (HPMHooks.count.HP_inter_do_final_msg_pre > 0) { + void (*preHookFunc) (void); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_do_final_msg_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_do_final_msg_pre[hIndex].func; + preHookFunc(); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.inter.do_final_msg(); + } + if (HPMHooks.count.HP_inter_do_final_msg_post > 0) { + void (*postHookFunc) (void); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_do_final_msg_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_do_final_msg_post[hIndex].func; + postHookFunc(); + } + } + return; +} +const char* HP_inter_job_name(int class) { + int hIndex = 0; + const char* retVal___ = NULL; + if (HPMHooks.count.HP_inter_job_name_pre > 0) { + const char* (*preHookFunc) (int *class); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_job_name_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_job_name_pre[hIndex].func; + retVal___ = preHookFunc(&class); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter.job_name(class); + } + if (HPMHooks.count.HP_inter_job_name_post > 0) { + const char* (*postHookFunc) (const char* retVal___, int class); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_job_name_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_job_name_post[hIndex].func; + retVal___ = postHookFunc(retVal___, class); + } + } + return retVal___; +} +void HP_inter_vmsg_to_fd(int fd, int u_fd, int aid, char *msg, va_list ap) { + int hIndex = 0; + if (HPMHooks.count.HP_inter_vmsg_to_fd_pre > 0) { + void (*preHookFunc) (int *fd, int *u_fd, int *aid, char **msg, va_list ap); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_vmsg_to_fd_pre; hIndex++) { + va_list ap___copy; va_copy(ap___copy, ap); + preHookFunc = HPMHooks.list.HP_inter_vmsg_to_fd_pre[hIndex].func; + preHookFunc(&fd, &u_fd, &aid, &msg, ap___copy); + va_end(ap___copy); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + va_list ap___copy; va_copy(ap___copy, ap); + HPMHooks.source.inter.vmsg_to_fd(fd, u_fd, aid, msg, ap___copy); + va_end(ap___copy); + } + if (HPMHooks.count.HP_inter_vmsg_to_fd_post > 0) { + void (*postHookFunc) (int fd, int u_fd, int aid, char *msg, va_list ap); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_vmsg_to_fd_post; hIndex++) { + va_list ap___copy; va_copy(ap___copy, ap); + postHookFunc = HPMHooks.list.HP_inter_vmsg_to_fd_post[hIndex].func; + postHookFunc(fd, u_fd, aid, msg, ap___copy); + va_end(ap___copy); + } + } + return; +} +void HP_inter_savereg(int account_id, int char_id, const char *key, unsigned int index, intptr_t val, bool is_string) { + int hIndex = 0; + if (HPMHooks.count.HP_inter_savereg_pre > 0) { + void (*preHookFunc) (int *account_id, int *char_id, const char **key, unsigned int *index, intptr_t *val, bool *is_string); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_savereg_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_inter_savereg_pre[hIndex].func; @@ -7197,6 +7845,138 @@ bool HP_inter_config_read_connection(const char *filename, const struct config_t } return retVal___; } +void HP_inter_accinfo(int u_fd, int aid, int castergroup, const char *query, int map_fd) { + int hIndex = 0; + if (HPMHooks.count.HP_inter_accinfo_pre > 0) { + void (*preHookFunc) (int *u_fd, int *aid, int *castergroup, const char **query, int *map_fd); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_accinfo_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_accinfo_pre[hIndex].func; + preHookFunc(&u_fd, &aid, &castergroup, &query, &map_fd); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.inter.accinfo(u_fd, aid, castergroup, query, map_fd); + } + if (HPMHooks.count.HP_inter_accinfo_post > 0) { + void (*postHookFunc) (int u_fd, int aid, int castergroup, const char *query, int map_fd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_accinfo_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_accinfo_post[hIndex].func; + postHookFunc(u_fd, aid, castergroup, query, map_fd); + } + } + return; +} +void HP_inter_accinfo2(bool success, int map_fd, int u_fd, int u_aid, int account_id, const char *userid, const char *user_pass, const char *email, const char *last_ip, const char *lastlogin, const char *pin_code, const char *birthdate, int group_id, int logincount, int state) { + int hIndex = 0; + if (HPMHooks.count.HP_inter_accinfo2_pre > 0) { + void (*preHookFunc) (bool *success, int *map_fd, int *u_fd, int *u_aid, int *account_id, const char **userid, const char **user_pass, const char **email, const char **last_ip, const char **lastlogin, const char **pin_code, const char **birthdate, int *group_id, int *logincount, int *state); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_accinfo2_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_accinfo2_pre[hIndex].func; + preHookFunc(&success, &map_fd, &u_fd, &u_aid, &account_id, &userid, &user_pass, &email, &last_ip, &lastlogin, &pin_code, &birthdate, &group_id, &logincount, &state); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.inter.accinfo2(success, map_fd, u_fd, u_aid, account_id, userid, user_pass, email, last_ip, lastlogin, pin_code, birthdate, group_id, logincount, state); + } + if (HPMHooks.count.HP_inter_accinfo2_post > 0) { + void (*postHookFunc) (bool success, int map_fd, int u_fd, int u_aid, int account_id, const char *userid, const char *user_pass, const char *email, const char *last_ip, const char *lastlogin, const char *pin_code, const char *birthdate, int group_id, int logincount, int state); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_accinfo2_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_accinfo2_post[hIndex].func; + postHookFunc(success, map_fd, u_fd, u_aid, account_id, userid, user_pass, email, last_ip, lastlogin, pin_code, birthdate, group_id, logincount, state); + } + } + return; +} +struct WisData* HP_inter_add_wisdata(int fd, const unsigned char *src, const unsigned char *dst, const unsigned char *msg, int msg_len) { + int hIndex = 0; + struct WisData* retVal___ = NULL; + if (HPMHooks.count.HP_inter_add_wisdata_pre > 0) { + struct WisData* (*preHookFunc) (int *fd, const unsigned char **src, const unsigned char **dst, const unsigned char **msg, int *msg_len); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_add_wisdata_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_add_wisdata_pre[hIndex].func; + retVal___ = preHookFunc(&fd, &src, &dst, &msg, &msg_len); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter.add_wisdata(fd, src, dst, msg, msg_len); + } + if (HPMHooks.count.HP_inter_add_wisdata_post > 0) { + struct WisData* (*postHookFunc) (struct WisData* retVal___, int fd, const unsigned char *src, const unsigned char *dst, const unsigned char *msg, int msg_len); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_add_wisdata_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_add_wisdata_post[hIndex].func; + retVal___ = postHookFunc(retVal___, fd, src, dst, msg, msg_len); + } + } + return retVal___; +} +struct WisData* HP_inter_get_wisdata(int id) { + int hIndex = 0; + struct WisData* retVal___ = NULL; + if (HPMHooks.count.HP_inter_get_wisdata_pre > 0) { + struct WisData* (*preHookFunc) (int *id); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_get_wisdata_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_get_wisdata_pre[hIndex].func; + retVal___ = preHookFunc(&id); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter.get_wisdata(id); + } + if (HPMHooks.count.HP_inter_get_wisdata_post > 0) { + struct WisData* (*postHookFunc) (struct WisData* retVal___, int id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_get_wisdata_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_get_wisdata_post[hIndex].func; + retVal___ = postHookFunc(retVal___, id); + } + } + return retVal___; +} +void HP_inter_remove_wisdata(int id) { + int hIndex = 0; + if (HPMHooks.count.HP_inter_remove_wisdata_pre > 0) { + void (*preHookFunc) (int *id); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_remove_wisdata_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_remove_wisdata_pre[hIndex].func; + preHookFunc(&id); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.inter.remove_wisdata(id); + } + if (HPMHooks.count.HP_inter_remove_wisdata_post > 0) { + void (*postHookFunc) (int id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_remove_wisdata_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_remove_wisdata_post[hIndex].func; + postHookFunc(id); + } + } + return; +} /* inter_mail_interface */ int HP_inter_mail_sql_init(void) { int hIndex = 0; @@ -7278,15 +8058,149 @@ int HP_inter_mail_parse_frommap(int fd) { } return retVal___; } -int HP_inter_mail_fromsql(int char_id, struct mail_data *md) { +int HP_inter_mail_fromsql(int char_id, struct mail_data *md) { + int hIndex = 0; + int retVal___ = 0; + if (HPMHooks.count.HP_inter_mail_fromsql_pre > 0) { + int (*preHookFunc) (int *char_id, struct mail_data **md); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_fromsql_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_mail_fromsql_pre[hIndex].func; + retVal___ = preHookFunc(&char_id, &md); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_mail.fromsql(char_id, md); + } + if (HPMHooks.count.HP_inter_mail_fromsql_post > 0) { + int (*postHookFunc) (int retVal___, int char_id, struct mail_data *md); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_fromsql_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_mail_fromsql_post[hIndex].func; + retVal___ = postHookFunc(retVal___, char_id, md); + } + } + return retVal___; +} +int HP_inter_mail_savemessage(struct mail_message *msg) { + int hIndex = 0; + int retVal___ = 0; + if (HPMHooks.count.HP_inter_mail_savemessage_pre > 0) { + int (*preHookFunc) (struct mail_message **msg); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_savemessage_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_mail_savemessage_pre[hIndex].func; + retVal___ = preHookFunc(&msg); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_mail.savemessage(msg); + } + if (HPMHooks.count.HP_inter_mail_savemessage_post > 0) { + int (*postHookFunc) (int retVal___, struct mail_message *msg); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_savemessage_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_mail_savemessage_post[hIndex].func; + retVal___ = postHookFunc(retVal___, msg); + } + } + return retVal___; +} +bool HP_inter_mail_loadmessage(int mail_id, struct mail_message *msg) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_mail_loadmessage_pre > 0) { + bool (*preHookFunc) (int *mail_id, struct mail_message **msg); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_loadmessage_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_mail_loadmessage_pre[hIndex].func; + retVal___ = preHookFunc(&mail_id, &msg); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_mail.loadmessage(mail_id, msg); + } + if (HPMHooks.count.HP_inter_mail_loadmessage_post > 0) { + bool (*postHookFunc) (bool retVal___, int mail_id, struct mail_message *msg); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_loadmessage_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_mail_loadmessage_post[hIndex].func; + retVal___ = postHookFunc(retVal___, mail_id, msg); + } + } + return retVal___; +} +bool HP_inter_mail_DeleteAttach(int mail_id) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_mail_DeleteAttach_pre > 0) { + bool (*preHookFunc) (int *mail_id); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_DeleteAttach_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_mail_DeleteAttach_pre[hIndex].func; + retVal___ = preHookFunc(&mail_id); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_mail.DeleteAttach(mail_id); + } + if (HPMHooks.count.HP_inter_mail_DeleteAttach_post > 0) { + bool (*postHookFunc) (bool retVal___, int mail_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_DeleteAttach_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_mail_DeleteAttach_post[hIndex].func; + retVal___ = postHookFunc(retVal___, mail_id); + } + } + return retVal___; +} +void HP_inter_mail_sendmail(int send_id, const char *send_name, int dest_id, const char *dest_name, const char *title, const char *body, int zeny, struct item *item) { + int hIndex = 0; + if (HPMHooks.count.HP_inter_mail_sendmail_pre > 0) { + void (*preHookFunc) (int *send_id, const char **send_name, int *dest_id, const char **dest_name, const char **title, const char **body, int *zeny, struct item **item); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_sendmail_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_mail_sendmail_pre[hIndex].func; + preHookFunc(&send_id, &send_name, &dest_id, &dest_name, &title, &body, &zeny, &item); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.inter_mail.sendmail(send_id, send_name, dest_id, dest_name, title, body, zeny, item); + } + if (HPMHooks.count.HP_inter_mail_sendmail_post > 0) { + void (*postHookFunc) (int send_id, const char *send_name, int dest_id, const char *dest_name, const char *title, const char *body, int zeny, struct item *item); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_sendmail_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_mail_sendmail_post[hIndex].func; + postHookFunc(send_id, send_name, dest_id, dest_name, title, body, zeny, item); + } + } + return; +} +bool HP_inter_mail_mark_read(int mail_id) { int hIndex = 0; - int retVal___ = 0; - if (HPMHooks.count.HP_inter_mail_fromsql_pre > 0) { - int (*preHookFunc) (int *char_id, struct mail_data **md); + bool retVal___ = false; + if (HPMHooks.count.HP_inter_mail_mark_read_pre > 0) { + bool (*preHookFunc) (int *mail_id); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_fromsql_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_inter_mail_fromsql_pre[hIndex].func; - retVal___ = preHookFunc(&char_id, &md); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_mark_read_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_mail_mark_read_pre[hIndex].func; + retVal___ = preHookFunc(&mail_id); } if (*HPMforce_return) { *HPMforce_return = false; @@ -7294,26 +8208,26 @@ int HP_inter_mail_fromsql(int char_id, struct mail_data *md) { } } { - retVal___ = HPMHooks.source.inter_mail.fromsql(char_id, md); + retVal___ = HPMHooks.source.inter_mail.mark_read(mail_id); } - if (HPMHooks.count.HP_inter_mail_fromsql_post > 0) { - int (*postHookFunc) (int retVal___, int char_id, struct mail_data *md); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_fromsql_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_inter_mail_fromsql_post[hIndex].func; - retVal___ = postHookFunc(retVal___, char_id, md); + if (HPMHooks.count.HP_inter_mail_mark_read_post > 0) { + bool (*postHookFunc) (bool retVal___, int mail_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_mark_read_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_mail_mark_read_post[hIndex].func; + retVal___ = postHookFunc(retVal___, mail_id); } } return retVal___; } -int HP_inter_mail_savemessage(struct mail_message *msg) { +bool HP_inter_mail_get_attachment(int char_id, int mail_id, struct mail_message *msg) { int hIndex = 0; - int retVal___ = 0; - if (HPMHooks.count.HP_inter_mail_savemessage_pre > 0) { - int (*preHookFunc) (struct mail_message **msg); + bool retVal___ = false; + if (HPMHooks.count.HP_inter_mail_get_attachment_pre > 0) { + bool (*preHookFunc) (int *char_id, int *mail_id, struct mail_message **msg); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_savemessage_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_inter_mail_savemessage_pre[hIndex].func; - retVal___ = preHookFunc(&msg); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_get_attachment_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_mail_get_attachment_pre[hIndex].func; + retVal___ = preHookFunc(&char_id, &mail_id, &msg); } if (*HPMforce_return) { *HPMforce_return = false; @@ -7321,26 +8235,26 @@ int HP_inter_mail_savemessage(struct mail_message *msg) { } } { - retVal___ = HPMHooks.source.inter_mail.savemessage(msg); + retVal___ = HPMHooks.source.inter_mail.get_attachment(char_id, mail_id, msg); } - if (HPMHooks.count.HP_inter_mail_savemessage_post > 0) { - int (*postHookFunc) (int retVal___, struct mail_message *msg); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_savemessage_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_inter_mail_savemessage_post[hIndex].func; - retVal___ = postHookFunc(retVal___, msg); + if (HPMHooks.count.HP_inter_mail_get_attachment_post > 0) { + bool (*postHookFunc) (bool retVal___, int char_id, int mail_id, struct mail_message *msg); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_get_attachment_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_mail_get_attachment_post[hIndex].func; + retVal___ = postHookFunc(retVal___, char_id, mail_id, msg); } } return retVal___; } -bool HP_inter_mail_loadmessage(int mail_id, struct mail_message *msg) { +bool HP_inter_mail_delete(int char_id, int mail_id) { int hIndex = 0; bool retVal___ = false; - if (HPMHooks.count.HP_inter_mail_loadmessage_pre > 0) { - bool (*preHookFunc) (int *mail_id, struct mail_message **msg); + if (HPMHooks.count.HP_inter_mail_delete_pre > 0) { + bool (*preHookFunc) (int *char_id, int *mail_id); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_loadmessage_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_inter_mail_loadmessage_pre[hIndex].func; - retVal___ = preHookFunc(&mail_id, &msg); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_delete_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_mail_delete_pre[hIndex].func; + retVal___ = preHookFunc(&char_id, &mail_id); } if (*HPMforce_return) { *HPMforce_return = false; @@ -7348,26 +8262,26 @@ bool HP_inter_mail_loadmessage(int mail_id, struct mail_message *msg) { } } { - retVal___ = HPMHooks.source.inter_mail.loadmessage(mail_id, msg); + retVal___ = HPMHooks.source.inter_mail.delete(char_id, mail_id); } - if (HPMHooks.count.HP_inter_mail_loadmessage_post > 0) { - bool (*postHookFunc) (bool retVal___, int mail_id, struct mail_message *msg); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_loadmessage_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_inter_mail_loadmessage_post[hIndex].func; - retVal___ = postHookFunc(retVal___, mail_id, msg); + if (HPMHooks.count.HP_inter_mail_delete_post > 0) { + bool (*postHookFunc) (bool retVal___, int char_id, int mail_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_delete_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_mail_delete_post[hIndex].func; + retVal___ = postHookFunc(retVal___, char_id, mail_id); } } return retVal___; } -bool HP_inter_mail_DeleteAttach(int mail_id) { +bool HP_inter_mail_return_message(int char_id, int mail_id, int *new_mail) { int hIndex = 0; bool retVal___ = false; - if (HPMHooks.count.HP_inter_mail_DeleteAttach_pre > 0) { - bool (*preHookFunc) (int *mail_id); + if (HPMHooks.count.HP_inter_mail_return_message_pre > 0) { + bool (*preHookFunc) (int *char_id, int *mail_id, int **new_mail); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_DeleteAttach_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_inter_mail_DeleteAttach_pre[hIndex].func; - retVal___ = preHookFunc(&mail_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_return_message_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_mail_return_message_pre[hIndex].func; + retVal___ = preHookFunc(&char_id, &mail_id, &new_mail); } if (*HPMforce_return) { *HPMforce_return = false; @@ -7375,42 +8289,43 @@ bool HP_inter_mail_DeleteAttach(int mail_id) { } } { - retVal___ = HPMHooks.source.inter_mail.DeleteAttach(mail_id); + retVal___ = HPMHooks.source.inter_mail.return_message(char_id, mail_id, new_mail); } - if (HPMHooks.count.HP_inter_mail_DeleteAttach_post > 0) { - bool (*postHookFunc) (bool retVal___, int mail_id); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_DeleteAttach_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_inter_mail_DeleteAttach_post[hIndex].func; - retVal___ = postHookFunc(retVal___, mail_id); + if (HPMHooks.count.HP_inter_mail_return_message_post > 0) { + bool (*postHookFunc) (bool retVal___, int char_id, int mail_id, int *new_mail); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_return_message_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_mail_return_message_post[hIndex].func; + retVal___ = postHookFunc(retVal___, char_id, mail_id, new_mail); } } return retVal___; } -void HP_inter_mail_sendmail(int send_id, const char *send_name, int dest_id, const char *dest_name, const char *title, const char *body, int zeny, struct item *item) { +bool HP_inter_mail_send(int account_id, struct mail_message *msg) { int hIndex = 0; - if (HPMHooks.count.HP_inter_mail_sendmail_pre > 0) { - void (*preHookFunc) (int *send_id, const char **send_name, int *dest_id, const char **dest_name, const char **title, const char **body, int *zeny, struct item **item); + bool retVal___ = false; + if (HPMHooks.count.HP_inter_mail_send_pre > 0) { + bool (*preHookFunc) (int *account_id, struct mail_message **msg); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_sendmail_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_inter_mail_sendmail_pre[hIndex].func; - preHookFunc(&send_id, &send_name, &dest_id, &dest_name, &title, &body, &zeny, &item); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_send_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_mail_send_pre[hIndex].func; + retVal___ = preHookFunc(&account_id, &msg); } if (*HPMforce_return) { *HPMforce_return = false; - return; + return retVal___; } } { - HPMHooks.source.inter_mail.sendmail(send_id, send_name, dest_id, dest_name, title, body, zeny, item); + retVal___ = HPMHooks.source.inter_mail.send(account_id, msg); } - if (HPMHooks.count.HP_inter_mail_sendmail_post > 0) { - void (*postHookFunc) (int send_id, const char *send_name, int dest_id, const char *dest_name, const char *title, const char *body, int zeny, struct item *item); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_sendmail_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_inter_mail_sendmail_post[hIndex].func; - postHookFunc(send_id, send_name, dest_id, dest_name, title, body, zeny, item); + if (HPMHooks.count.HP_inter_mail_send_post > 0) { + bool (*postHookFunc) (bool retVal___, int account_id, struct mail_message *msg); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mail_send_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_mail_send_post[hIndex].func; + retVal___ = postHookFunc(retVal___, account_id, msg); } } - return; + return retVal___; } /* inter_mercenary_interface */ bool HP_inter_mercenary_owner_fromsql(int char_id, struct mmo_charstatus *status) { @@ -7574,6 +8489,114 @@ int HP_inter_mercenary_parse_frommap(int fd) { } return retVal___; } +bool HP_inter_mercenary_create(struct s_mercenary *merc) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_mercenary_create_pre > 0) { + bool (*preHookFunc) (struct s_mercenary **merc); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mercenary_create_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_mercenary_create_pre[hIndex].func; + retVal___ = preHookFunc(&merc); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_mercenary.create(merc); + } + if (HPMHooks.count.HP_inter_mercenary_create_post > 0) { + bool (*postHookFunc) (bool retVal___, struct s_mercenary *merc); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mercenary_create_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_mercenary_create_post[hIndex].func; + retVal___ = postHookFunc(retVal___, merc); + } + } + return retVal___; +} +bool HP_inter_mercenary_save(const struct s_mercenary *merc) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_mercenary_save_pre > 0) { + bool (*preHookFunc) (const struct s_mercenary **merc); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mercenary_save_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_mercenary_save_pre[hIndex].func; + retVal___ = preHookFunc(&merc); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_mercenary.save(merc); + } + if (HPMHooks.count.HP_inter_mercenary_save_post > 0) { + bool (*postHookFunc) (bool retVal___, const struct s_mercenary *merc); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mercenary_save_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_mercenary_save_post[hIndex].func; + retVal___ = postHookFunc(retVal___, merc); + } + } + return retVal___; +} +bool HP_inter_mercenary_load(int merc_id, int char_id, struct s_mercenary *merc) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_mercenary_load_pre > 0) { + bool (*preHookFunc) (int *merc_id, int *char_id, struct s_mercenary **merc); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mercenary_load_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_mercenary_load_pre[hIndex].func; + retVal___ = preHookFunc(&merc_id, &char_id, &merc); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_mercenary.load(merc_id, char_id, merc); + } + if (HPMHooks.count.HP_inter_mercenary_load_post > 0) { + bool (*postHookFunc) (bool retVal___, int merc_id, int char_id, struct s_mercenary *merc); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mercenary_load_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_mercenary_load_post[hIndex].func; + retVal___ = postHookFunc(retVal___, merc_id, char_id, merc); + } + } + return retVal___; +} +bool HP_inter_mercenary_delete(int merc_id) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_mercenary_delete_pre > 0) { + bool (*preHookFunc) (int *merc_id); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mercenary_delete_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_mercenary_delete_pre[hIndex].func; + retVal___ = preHookFunc(&merc_id); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_mercenary.delete(merc_id); + } + if (HPMHooks.count.HP_inter_mercenary_delete_post > 0) { + bool (*postHookFunc) (bool retVal___, int merc_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_mercenary_delete_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_mercenary_delete_post[hIndex].func; + retVal___ = postHookFunc(retVal___, merc_id); + } + } + return retVal___; +} /* inter_party_interface */ int HP_inter_party_check_lv(struct party_data *p) { int hIndex = 0; @@ -7843,11 +8866,11 @@ int HP_inter_party_parse_frommap(int fd) { } return retVal___; } -int HP_inter_party_leave(int party_id, int account_id, int char_id) { +bool HP_inter_party_leave(int party_id, int account_id, int char_id) { int hIndex = 0; - int retVal___ = 0; + bool retVal___ = false; if (HPMHooks.count.HP_inter_party_leave_pre > 0) { - int (*preHookFunc) (int *party_id, int *account_id, int *char_id); + bool (*preHookFunc) (int *party_id, int *account_id, int *char_id); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_leave_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_inter_party_leave_pre[hIndex].func; @@ -7862,7 +8885,7 @@ int HP_inter_party_leave(int party_id, int account_id, int char_id) { retVal___ = HPMHooks.source.inter_party.leave(party_id, account_id, char_id); } if (HPMHooks.count.HP_inter_party_leave_post > 0) { - int (*postHookFunc) (int retVal___, int party_id, int account_id, int char_id); + bool (*postHookFunc) (bool retVal___, int party_id, int account_id, int char_id); for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_leave_post; hIndex++) { postHookFunc = HPMHooks.list.HP_inter_party_leave_post[hIndex].func; retVal___ = postHookFunc(retVal___, party_id, account_id, char_id); @@ -7899,13 +8922,175 @@ int HP_inter_party_CharOnline(int char_id, int party_id) { } int HP_inter_party_CharOffline(int char_id, int party_id) { int hIndex = 0; - int retVal___ = 0; - if (HPMHooks.count.HP_inter_party_CharOffline_pre > 0) { - int (*preHookFunc) (int *char_id, int *party_id); + int retVal___ = 0; + if (HPMHooks.count.HP_inter_party_CharOffline_pre > 0) { + int (*preHookFunc) (int *char_id, int *party_id); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_CharOffline_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_party_CharOffline_pre[hIndex].func; + retVal___ = preHookFunc(&char_id, &party_id); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_party.CharOffline(char_id, party_id); + } + if (HPMHooks.count.HP_inter_party_CharOffline_post > 0) { + int (*postHookFunc) (int retVal___, int char_id, int party_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_CharOffline_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_party_CharOffline_post[hIndex].func; + retVal___ = postHookFunc(retVal___, char_id, party_id); + } + } + return retVal___; +} +struct party_data* HP_inter_party_create(const char *name, int item, int item2, const struct party_member *leader) { + int hIndex = 0; + struct party_data* retVal___ = NULL; + if (HPMHooks.count.HP_inter_party_create_pre > 0) { + struct party_data* (*preHookFunc) (const char **name, int *item, int *item2, const struct party_member **leader); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_create_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_party_create_pre[hIndex].func; + retVal___ = preHookFunc(&name, &item, &item2, &leader); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_party.create(name, item, item2, leader); + } + if (HPMHooks.count.HP_inter_party_create_post > 0) { + struct party_data* (*postHookFunc) (struct party_data* retVal___, const char *name, int item, int item2, const struct party_member *leader); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_create_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_party_create_post[hIndex].func; + retVal___ = postHookFunc(retVal___, name, item, item2, leader); + } + } + return retVal___; +} +bool HP_inter_party_add_member(int party_id, const struct party_member *member) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_party_add_member_pre > 0) { + bool (*preHookFunc) (int *party_id, const struct party_member **member); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_add_member_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_party_add_member_pre[hIndex].func; + retVal___ = preHookFunc(&party_id, &member); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_party.add_member(party_id, member); + } + if (HPMHooks.count.HP_inter_party_add_member_post > 0) { + bool (*postHookFunc) (bool retVal___, int party_id, const struct party_member *member); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_add_member_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_party_add_member_post[hIndex].func; + retVal___ = postHookFunc(retVal___, party_id, member); + } + } + return retVal___; +} +bool HP_inter_party_change_option(int party_id, int account_id, int exp, int item, int map_fd) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_party_change_option_pre > 0) { + bool (*preHookFunc) (int *party_id, int *account_id, int *exp, int *item, int *map_fd); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_change_option_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_party_change_option_pre[hIndex].func; + retVal___ = preHookFunc(&party_id, &account_id, &exp, &item, &map_fd); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_party.change_option(party_id, account_id, exp, item, map_fd); + } + if (HPMHooks.count.HP_inter_party_change_option_post > 0) { + bool (*postHookFunc) (bool retVal___, int party_id, int account_id, int exp, int item, int map_fd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_change_option_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_party_change_option_post[hIndex].func; + retVal___ = postHookFunc(retVal___, party_id, account_id, exp, item, map_fd); + } + } + return retVal___; +} +bool HP_inter_party_change_map(int party_id, int account_id, int char_id, unsigned short map, int online, unsigned int lv) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_party_change_map_pre > 0) { + bool (*preHookFunc) (int *party_id, int *account_id, int *char_id, unsigned short *map, int *online, unsigned int *lv); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_change_map_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_party_change_map_pre[hIndex].func; + retVal___ = preHookFunc(&party_id, &account_id, &char_id, &map, &online, &lv); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_party.change_map(party_id, account_id, char_id, map, online, lv); + } + if (HPMHooks.count.HP_inter_party_change_map_post > 0) { + bool (*postHookFunc) (bool retVal___, int party_id, int account_id, int char_id, unsigned short map, int online, unsigned int lv); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_change_map_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_party_change_map_post[hIndex].func; + retVal___ = postHookFunc(retVal___, party_id, account_id, char_id, map, online, lv); + } + } + return retVal___; +} +bool HP_inter_party_disband(int party_id) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_party_disband_pre > 0) { + bool (*preHookFunc) (int *party_id); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_disband_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_party_disband_pre[hIndex].func; + retVal___ = preHookFunc(&party_id); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_party.disband(party_id); + } + if (HPMHooks.count.HP_inter_party_disband_post > 0) { + bool (*postHookFunc) (bool retVal___, int party_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_disband_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_party_disband_post[hIndex].func; + retVal___ = postHookFunc(retVal___, party_id); + } + } + return retVal___; +} +bool HP_inter_party_change_leader(int party_id, int account_id, int char_id) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_party_change_leader_pre > 0) { + bool (*preHookFunc) (int *party_id, int *account_id, int *char_id); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_CharOffline_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_inter_party_CharOffline_pre[hIndex].func; - retVal___ = preHookFunc(&char_id, &party_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_change_leader_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_party_change_leader_pre[hIndex].func; + retVal___ = preHookFunc(&party_id, &account_id, &char_id); } if (*HPMforce_return) { *HPMforce_return = false; @@ -7913,13 +9098,13 @@ int HP_inter_party_CharOffline(int char_id, int party_id) { } } { - retVal___ = HPMHooks.source.inter_party.CharOffline(char_id, party_id); + retVal___ = HPMHooks.source.inter_party.change_leader(party_id, account_id, char_id); } - if (HPMHooks.count.HP_inter_party_CharOffline_post > 0) { - int (*postHookFunc) (int retVal___, int char_id, int party_id); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_CharOffline_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_inter_party_CharOffline_post[hIndex].func; - retVal___ = postHookFunc(retVal___, char_id, party_id); + if (HPMHooks.count.HP_inter_party_change_leader_post > 0) { + bool (*postHookFunc) (bool retVal___, int party_id, int account_id, int char_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_party_change_leader_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_party_change_leader_post[hIndex].func; + retVal___ = postHookFunc(retVal___, party_id, account_id, char_id); } } return retVal___; @@ -8086,6 +9271,60 @@ int HP_inter_pet_parse_frommap(int fd) { } return retVal___; } +struct s_pet* HP_inter_pet_create(int account_id, int char_id, short pet_class, short pet_lv, short pet_egg_id, short pet_equip, short intimate, short hungry, char rename_flag, char incubate, const char *pet_name) { + int hIndex = 0; + struct s_pet* retVal___ = NULL; + if (HPMHooks.count.HP_inter_pet_create_pre > 0) { + struct s_pet* (*preHookFunc) (int *account_id, int *char_id, short *pet_class, short *pet_lv, short *pet_egg_id, short *pet_equip, short *intimate, short *hungry, char *rename_flag, char *incubate, const char **pet_name); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_pet_create_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_pet_create_pre[hIndex].func; + retVal___ = preHookFunc(&account_id, &char_id, &pet_class, &pet_lv, &pet_egg_id, &pet_equip, &intimate, &hungry, &rename_flag, &incubate, &pet_name); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_pet.create(account_id, char_id, pet_class, pet_lv, pet_egg_id, pet_equip, intimate, hungry, rename_flag, incubate, pet_name); + } + if (HPMHooks.count.HP_inter_pet_create_post > 0) { + struct s_pet* (*postHookFunc) (struct s_pet* retVal___, int account_id, int char_id, short pet_class, short pet_lv, short pet_egg_id, short pet_equip, short intimate, short hungry, char rename_flag, char incubate, const char *pet_name); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_pet_create_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_pet_create_post[hIndex].func; + retVal___ = postHookFunc(retVal___, account_id, char_id, pet_class, pet_lv, pet_egg_id, pet_equip, intimate, hungry, rename_flag, incubate, pet_name); + } + } + return retVal___; +} +struct s_pet* HP_inter_pet_load(int account_id, int char_id, int pet_id) { + int hIndex = 0; + struct s_pet* retVal___ = NULL; + if (HPMHooks.count.HP_inter_pet_load_pre > 0) { + struct s_pet* (*preHookFunc) (int *account_id, int *char_id, int *pet_id); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_pet_load_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_pet_load_pre[hIndex].func; + retVal___ = preHookFunc(&account_id, &char_id, &pet_id); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_pet.load(account_id, char_id, pet_id); + } + if (HPMHooks.count.HP_inter_pet_load_post > 0) { + struct s_pet* (*postHookFunc) (struct s_pet* retVal___, int account_id, int char_id, int pet_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_pet_load_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_pet_load_post[hIndex].func; + retVal___ = postHookFunc(retVal___, account_id, char_id, pet_id); + } + } + return retVal___; +} /* inter_quest_interface */ int HP_inter_quest_parse_frommap(int fd) { int hIndex = 0; @@ -8114,6 +9353,141 @@ int HP_inter_quest_parse_frommap(int fd) { } return retVal___; } +struct quest* HP_inter_quest_fromsql(int char_id, int *count) { + int hIndex = 0; + struct quest* retVal___ = NULL; + if (HPMHooks.count.HP_inter_quest_fromsql_pre > 0) { + struct quest* (*preHookFunc) (int *char_id, int **count); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_quest_fromsql_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_quest_fromsql_pre[hIndex].func; + retVal___ = preHookFunc(&char_id, &count); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_quest.fromsql(char_id, count); + } + if (HPMHooks.count.HP_inter_quest_fromsql_post > 0) { + struct quest* (*postHookFunc) (struct quest* retVal___, int char_id, int *count); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_quest_fromsql_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_quest_fromsql_post[hIndex].func; + retVal___ = postHookFunc(retVal___, char_id, count); + } + } + return retVal___; +} +bool HP_inter_quest_delete(int char_id, int quest_id) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_quest_delete_pre > 0) { + bool (*preHookFunc) (int *char_id, int *quest_id); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_quest_delete_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_quest_delete_pre[hIndex].func; + retVal___ = preHookFunc(&char_id, &quest_id); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_quest.delete(char_id, quest_id); + } + if (HPMHooks.count.HP_inter_quest_delete_post > 0) { + bool (*postHookFunc) (bool retVal___, int char_id, int quest_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_quest_delete_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_quest_delete_post[hIndex].func; + retVal___ = postHookFunc(retVal___, char_id, quest_id); + } + } + return retVal___; +} +bool HP_inter_quest_add(int char_id, struct quest qd) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_quest_add_pre > 0) { + bool (*preHookFunc) (int *char_id, struct quest *qd); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_quest_add_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_quest_add_pre[hIndex].func; + retVal___ = preHookFunc(&char_id, &qd); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_quest.add(char_id, qd); + } + if (HPMHooks.count.HP_inter_quest_add_post > 0) { + bool (*postHookFunc) (bool retVal___, int char_id, struct quest qd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_quest_add_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_quest_add_post[hIndex].func; + retVal___ = postHookFunc(retVal___, char_id, qd); + } + } + return retVal___; +} +bool HP_inter_quest_update(int char_id, struct quest qd) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_quest_update_pre > 0) { + bool (*preHookFunc) (int *char_id, struct quest *qd); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_quest_update_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_quest_update_pre[hIndex].func; + retVal___ = preHookFunc(&char_id, &qd); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_quest.update(char_id, qd); + } + if (HPMHooks.count.HP_inter_quest_update_post > 0) { + bool (*postHookFunc) (bool retVal___, int char_id, struct quest qd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_quest_update_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_quest_update_post[hIndex].func; + retVal___ = postHookFunc(retVal___, char_id, qd); + } + } + return retVal___; +} +bool HP_inter_quest_save(int char_id, const struct quest *new_qd, int new_n) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_quest_save_pre > 0) { + bool (*preHookFunc) (int *char_id, const struct quest **new_qd, int *new_n); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_quest_save_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_quest_save_pre[hIndex].func; + retVal___ = preHookFunc(&char_id, &new_qd, &new_n); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_quest.save(char_id, new_qd, new_n); + } + if (HPMHooks.count.HP_inter_quest_save_post > 0) { + bool (*postHookFunc) (bool retVal___, int char_id, const struct quest *new_qd, int new_n); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_quest_save_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_quest_save_post[hIndex].func; + retVal___ = postHookFunc(retVal___, char_id, new_qd, new_n); + } + } + return retVal___; +} /* inter_rodex_interface */ int HP_inter_rodex_sql_init(void) { int hIndex = 0; @@ -8303,6 +9677,33 @@ int64 HP_inter_rodex_savemessage(struct rodex_message *msg) { } return retVal___; } +bool HP_inter_rodex_updatemail(int64 mail_id, int8 flag) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_rodex_updatemail_pre > 0) { + bool (*preHookFunc) (int64 *mail_id, int8 *flag); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_rodex_updatemail_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_rodex_updatemail_pre[hIndex].func; + retVal___ = preHookFunc(&mail_id, &flag); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_rodex.updatemail(mail_id, flag); + } + if (HPMHooks.count.HP_inter_rodex_updatemail_post > 0) { + bool (*postHookFunc) (bool retVal___, int64 mail_id, int8 flag); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_rodex_updatemail_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_rodex_updatemail_post[hIndex].func; + retVal___ = postHookFunc(retVal___, mail_id, flag); + } + } + return retVal___; +} /* inter_storage_interface */ int HP_inter_storage_tosql(int account_id, const struct storage_data *p) { int hIndex = 0; @@ -8358,11 +9759,11 @@ int HP_inter_storage_fromsql(int account_id, struct storage_data *p) { } return retVal___; } -int HP_inter_storage_guild_storage_tosql(int guild_id, const struct guild_storage *p) { +bool HP_inter_storage_guild_storage_tosql(int guild_id, const struct guild_storage *p) { int hIndex = 0; - int retVal___ = 0; + bool retVal___ = false; if (HPMHooks.count.HP_inter_storage_guild_storage_tosql_pre > 0) { - int (*preHookFunc) (int *guild_id, const struct guild_storage **p); + bool (*preHookFunc) (int *guild_id, const struct guild_storage **p); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_storage_guild_storage_tosql_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_inter_storage_guild_storage_tosql_pre[hIndex].func; @@ -8377,7 +9778,7 @@ int HP_inter_storage_guild_storage_tosql(int guild_id, const struct guild_storag retVal___ = HPMHooks.source.inter_storage.guild_storage_tosql(guild_id, p); } if (HPMHooks.count.HP_inter_storage_guild_storage_tosql_post > 0) { - int (*postHookFunc) (int retVal___, int guild_id, const struct guild_storage *p); + bool (*postHookFunc) (bool retVal___, int guild_id, const struct guild_storage *p); for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_storage_guild_storage_tosql_post; hIndex++) { postHookFunc = HPMHooks.list.HP_inter_storage_guild_storage_tosql_post[hIndex].func; retVal___ = postHookFunc(retVal___, guild_id, p); @@ -8546,6 +9947,33 @@ int HP_inter_storage_parse_frommap(int fd) { } return retVal___; } +bool HP_inter_storage_retrieve_bound_items(int char_id, int account_id, int guild_id) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_storage_retrieve_bound_items_pre > 0) { + bool (*preHookFunc) (int *char_id, int *account_id, int *guild_id); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_storage_retrieve_bound_items_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_storage_retrieve_bound_items_pre[hIndex].func; + retVal___ = preHookFunc(&char_id, &account_id, &guild_id); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_storage.retrieve_bound_items(char_id, account_id, guild_id); + } + if (HPMHooks.count.HP_inter_storage_retrieve_bound_items_post > 0) { + bool (*postHookFunc) (bool retVal___, int char_id, int account_id, int guild_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_storage_retrieve_bound_items_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_storage_retrieve_bound_items_post[hIndex].func; + retVal___ = postHookFunc(retVal___, char_id, account_id, guild_id); + } + } + return retVal___; +} /* libconfig_interface */ int HP_libconfig_read(struct config_t *config, FILE *stream) { int hIndex = 0; @@ -11241,160 +12669,52 @@ void HP_mapif_auction_bid(int fd, int char_id, int bid, unsigned char result) { if (HPMHooks.count.HP_mapif_auction_bid_pre > 0) { void (*preHookFunc) (int *fd, int *char_id, int *bid, unsigned char *result); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_auction_bid_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_auction_bid_pre[hIndex].func; - preHookFunc(&fd, &char_id, &bid, &result); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return; - } - } - { - HPMHooks.source.mapif.auction_bid(fd, char_id, bid, result); - } - if (HPMHooks.count.HP_mapif_auction_bid_post > 0) { - void (*postHookFunc) (int fd, int char_id, int bid, unsigned char result); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_auction_bid_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_auction_bid_post[hIndex].func; - postHookFunc(fd, char_id, bid, result); - } - } - return; -} -void HP_mapif_parse_auction_bid(int fd) { - int hIndex = 0; - if (HPMHooks.count.HP_mapif_parse_auction_bid_pre > 0) { - void (*preHookFunc) (int *fd); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_auction_bid_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_parse_auction_bid_pre[hIndex].func; - preHookFunc(&fd); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return; - } - } - { - HPMHooks.source.mapif.parse_auction_bid(fd); - } - if (HPMHooks.count.HP_mapif_parse_auction_bid_post > 0) { - void (*postHookFunc) (int fd); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_auction_bid_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_parse_auction_bid_post[hIndex].func; - postHookFunc(fd); - } - } - return; -} -bool HP_mapif_elemental_create(struct s_elemental *ele) { - int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_elemental_create_pre > 0) { - bool (*preHookFunc) (struct s_elemental **ele); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_elemental_create_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_elemental_create_pre[hIndex].func; - retVal___ = preHookFunc(&ele); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.elemental_create(ele); - } - if (HPMHooks.count.HP_mapif_elemental_create_post > 0) { - bool (*postHookFunc) (bool retVal___, struct s_elemental *ele); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_elemental_create_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_elemental_create_post[hIndex].func; - retVal___ = postHookFunc(retVal___, ele); - } - } - return retVal___; -} -bool HP_mapif_elemental_save(const struct s_elemental *ele) { - int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_elemental_save_pre > 0) { - bool (*preHookFunc) (const struct s_elemental **ele); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_elemental_save_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_elemental_save_pre[hIndex].func; - retVal___ = preHookFunc(&ele); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.elemental_save(ele); - } - if (HPMHooks.count.HP_mapif_elemental_save_post > 0) { - bool (*postHookFunc) (bool retVal___, const struct s_elemental *ele); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_elemental_save_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_elemental_save_post[hIndex].func; - retVal___ = postHookFunc(retVal___, ele); - } - } - return retVal___; -} -bool HP_mapif_elemental_load(int ele_id, int char_id, struct s_elemental *ele) { - int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_elemental_load_pre > 0) { - bool (*preHookFunc) (int *ele_id, int *char_id, struct s_elemental **ele); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_elemental_load_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_elemental_load_pre[hIndex].func; - retVal___ = preHookFunc(&ele_id, &char_id, &ele); + for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_auction_bid_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_mapif_auction_bid_pre[hIndex].func; + preHookFunc(&fd, &char_id, &bid, &result); } if (*HPMforce_return) { *HPMforce_return = false; - return retVal___; + return; } } { - retVal___ = HPMHooks.source.mapif.elemental_load(ele_id, char_id, ele); + HPMHooks.source.mapif.auction_bid(fd, char_id, bid, result); } - if (HPMHooks.count.HP_mapif_elemental_load_post > 0) { - bool (*postHookFunc) (bool retVal___, int ele_id, int char_id, struct s_elemental *ele); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_elemental_load_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_elemental_load_post[hIndex].func; - retVal___ = postHookFunc(retVal___, ele_id, char_id, ele); + if (HPMHooks.count.HP_mapif_auction_bid_post > 0) { + void (*postHookFunc) (int fd, int char_id, int bid, unsigned char result); + for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_auction_bid_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_mapif_auction_bid_post[hIndex].func; + postHookFunc(fd, char_id, bid, result); } } - return retVal___; + return; } -bool HP_mapif_elemental_delete(int ele_id) { +void HP_mapif_parse_auction_bid(int fd) { int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_elemental_delete_pre > 0) { - bool (*preHookFunc) (int *ele_id); + if (HPMHooks.count.HP_mapif_parse_auction_bid_pre > 0) { + void (*preHookFunc) (int *fd); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_elemental_delete_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_elemental_delete_pre[hIndex].func; - retVal___ = preHookFunc(&ele_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_auction_bid_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_mapif_parse_auction_bid_pre[hIndex].func; + preHookFunc(&fd); } if (*HPMforce_return) { *HPMforce_return = false; - return retVal___; + return; } } { - retVal___ = HPMHooks.source.mapif.elemental_delete(ele_id); + HPMHooks.source.mapif.parse_auction_bid(fd); } - if (HPMHooks.count.HP_mapif_elemental_delete_post > 0) { - bool (*postHookFunc) (bool retVal___, int ele_id); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_elemental_delete_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_elemental_delete_post[hIndex].func; - retVal___ = postHookFunc(retVal___, ele_id); + if (HPMHooks.count.HP_mapif_parse_auction_bid_post > 0) { + void (*postHookFunc) (int fd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_auction_bid_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_mapif_parse_auction_bid_post[hIndex].func; + postHookFunc(fd); } } - return retVal___; + return; } void HP_mapif_elemental_send(int fd, struct s_elemental *ele, unsigned char flag) { int hIndex = 0; @@ -12334,33 +13654,6 @@ int HP_mapif_parse_GuildSkillUp(int fd, int guild_id, uint16 skill_id, int accou } return retVal___; } -int HP_mapif_parse_GuildDeleteAlliance(struct guild *g, int guild_id, int account_id1, int account_id2, int flag) { - int hIndex = 0; - int retVal___ = 0; - if (HPMHooks.count.HP_mapif_parse_GuildDeleteAlliance_pre > 0) { - int (*preHookFunc) (struct guild **g, int *guild_id, int *account_id1, int *account_id2, int *flag); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_GuildDeleteAlliance_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_parse_GuildDeleteAlliance_pre[hIndex].func; - retVal___ = preHookFunc(&g, &guild_id, &account_id1, &account_id2, &flag); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.parse_GuildDeleteAlliance(g, guild_id, account_id1, account_id2, flag); - } - if (HPMHooks.count.HP_mapif_parse_GuildDeleteAlliance_post > 0) { - int (*postHookFunc) (int retVal___, struct guild *g, int guild_id, int account_id1, int account_id2, int flag); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_GuildDeleteAlliance_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_parse_GuildDeleteAlliance_post[hIndex].func; - retVal___ = postHookFunc(retVal___, g, guild_id, account_id1, account_id2, flag); - } - } - return retVal___; -} int HP_mapif_parse_GuildAlliance(int fd, int guild_id1, int guild_id2, int account_id1, int account_id2, int flag) { int hIndex = 0; int retVal___ = 0; @@ -12653,141 +13946,6 @@ void HP_mapif_homunculus_renamed(int fd, int account_id, int char_id, unsigned c } return; } -bool HP_mapif_homunculus_create(struct s_homunculus *hd) { - int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_homunculus_create_pre > 0) { - bool (*preHookFunc) (struct s_homunculus **hd); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_homunculus_create_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_homunculus_create_pre[hIndex].func; - retVal___ = preHookFunc(&hd); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.homunculus_create(hd); - } - if (HPMHooks.count.HP_mapif_homunculus_create_post > 0) { - bool (*postHookFunc) (bool retVal___, struct s_homunculus *hd); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_homunculus_create_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_homunculus_create_post[hIndex].func; - retVal___ = postHookFunc(retVal___, hd); - } - } - return retVal___; -} -bool HP_mapif_homunculus_save(const struct s_homunculus *hd) { - int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_homunculus_save_pre > 0) { - bool (*preHookFunc) (const struct s_homunculus **hd); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_homunculus_save_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_homunculus_save_pre[hIndex].func; - retVal___ = preHookFunc(&hd); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.homunculus_save(hd); - } - if (HPMHooks.count.HP_mapif_homunculus_save_post > 0) { - bool (*postHookFunc) (bool retVal___, const struct s_homunculus *hd); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_homunculus_save_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_homunculus_save_post[hIndex].func; - retVal___ = postHookFunc(retVal___, hd); - } - } - return retVal___; -} -bool HP_mapif_homunculus_load(int homun_id, struct s_homunculus *hd) { - int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_homunculus_load_pre > 0) { - bool (*preHookFunc) (int *homun_id, struct s_homunculus **hd); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_homunculus_load_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_homunculus_load_pre[hIndex].func; - retVal___ = preHookFunc(&homun_id, &hd); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.homunculus_load(homun_id, hd); - } - if (HPMHooks.count.HP_mapif_homunculus_load_post > 0) { - bool (*postHookFunc) (bool retVal___, int homun_id, struct s_homunculus *hd); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_homunculus_load_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_homunculus_load_post[hIndex].func; - retVal___ = postHookFunc(retVal___, homun_id, hd); - } - } - return retVal___; -} -bool HP_mapif_homunculus_delete(int homun_id) { - int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_homunculus_delete_pre > 0) { - bool (*preHookFunc) (int *homun_id); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_homunculus_delete_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_homunculus_delete_pre[hIndex].func; - retVal___ = preHookFunc(&homun_id); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.homunculus_delete(homun_id); - } - if (HPMHooks.count.HP_mapif_homunculus_delete_post > 0) { - bool (*postHookFunc) (bool retVal___, int homun_id); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_homunculus_delete_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_homunculus_delete_post[hIndex].func; - retVal___ = postHookFunc(retVal___, homun_id); - } - } - return retVal___; -} -bool HP_mapif_homunculus_rename(const char *name) { - int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_homunculus_rename_pre > 0) { - bool (*preHookFunc) (const char **name); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_homunculus_rename_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_homunculus_rename_pre[hIndex].func; - retVal___ = preHookFunc(&name); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.homunculus_rename(name); - } - if (HPMHooks.count.HP_mapif_homunculus_rename_post > 0) { - bool (*postHookFunc) (bool retVal___, const char *name); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_homunculus_rename_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_homunculus_rename_post[hIndex].func; - retVal___ = postHookFunc(retVal___, name); - } - } - return retVal___; -} void HP_mapif_parse_homunculus_create(int fd, int len, int account_id, const struct s_homunculus *phd) { int hIndex = 0; if (HPMHooks.count.HP_mapif_parse_homunculus_create_pre > 0) { @@ -13022,32 +14180,6 @@ void HP_mapif_mail_sendattach(int fd, int char_id, struct mail_message *msg) { } return; } -void HP_mapif_mail_getattach(int fd, int char_id, int mail_id) { - int hIndex = 0; - if (HPMHooks.count.HP_mapif_mail_getattach_pre > 0) { - void (*preHookFunc) (int *fd, int *char_id, int *mail_id); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_mail_getattach_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_mail_getattach_pre[hIndex].func; - preHookFunc(&fd, &char_id, &mail_id); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return; - } - } - { - HPMHooks.source.mapif.mail_getattach(fd, char_id, mail_id); - } - if (HPMHooks.count.HP_mapif_mail_getattach_post > 0) { - void (*postHookFunc) (int fd, int char_id, int mail_id); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_mail_getattach_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_mail_getattach_post[hIndex].func; - postHookFunc(fd, char_id, mail_id); - } - } - return; -} void HP_mapif_parse_mail_getattach(int fd) { int hIndex = 0; if (HPMHooks.count.HP_mapif_parse_mail_getattach_pre > 0) { @@ -13196,173 +14328,65 @@ void HP_mapif_parse_mail_return(int fd) { HPMHooks.source.mapif.parse_mail_return(fd); } if (HPMHooks.count.HP_mapif_parse_mail_return_post > 0) { - void (*postHookFunc) (int fd); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_mail_return_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_parse_mail_return_post[hIndex].func; - postHookFunc(fd); - } - } - return; -} -void HP_mapif_mail_send(int fd, struct mail_message *msg) { - int hIndex = 0; - if (HPMHooks.count.HP_mapif_mail_send_pre > 0) { - void (*preHookFunc) (int *fd, struct mail_message **msg); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_mail_send_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_mail_send_pre[hIndex].func; - preHookFunc(&fd, &msg); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return; - } - } - { - HPMHooks.source.mapif.mail_send(fd, msg); - } - if (HPMHooks.count.HP_mapif_mail_send_post > 0) { - void (*postHookFunc) (int fd, struct mail_message *msg); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_mail_send_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_mail_send_post[hIndex].func; - postHookFunc(fd, msg); - } - } - return; -} -void HP_mapif_parse_mail_send(int fd) { - int hIndex = 0; - if (HPMHooks.count.HP_mapif_parse_mail_send_pre > 0) { - void (*preHookFunc) (int *fd); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_mail_send_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_parse_mail_send_pre[hIndex].func; - preHookFunc(&fd); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return; - } - } - { - HPMHooks.source.mapif.parse_mail_send(fd); - } - if (HPMHooks.count.HP_mapif_parse_mail_send_post > 0) { - void (*postHookFunc) (int fd); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_mail_send_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_parse_mail_send_post[hIndex].func; - postHookFunc(fd); - } - } - return; -} -bool HP_mapif_mercenary_create(struct s_mercenary *merc) { - int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_mercenary_create_pre > 0) { - bool (*preHookFunc) (struct s_mercenary **merc); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_mercenary_create_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_mercenary_create_pre[hIndex].func; - retVal___ = preHookFunc(&merc); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.mercenary_create(merc); - } - if (HPMHooks.count.HP_mapif_mercenary_create_post > 0) { - bool (*postHookFunc) (bool retVal___, struct s_mercenary *merc); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_mercenary_create_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_mercenary_create_post[hIndex].func; - retVal___ = postHookFunc(retVal___, merc); - } - } - return retVal___; -} -bool HP_mapif_mercenary_save(const struct s_mercenary *merc) { - int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_mercenary_save_pre > 0) { - bool (*preHookFunc) (const struct s_mercenary **merc); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_mercenary_save_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_mercenary_save_pre[hIndex].func; - retVal___ = preHookFunc(&merc); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.mercenary_save(merc); - } - if (HPMHooks.count.HP_mapif_mercenary_save_post > 0) { - bool (*postHookFunc) (bool retVal___, const struct s_mercenary *merc); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_mercenary_save_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_mercenary_save_post[hIndex].func; - retVal___ = postHookFunc(retVal___, merc); + void (*postHookFunc) (int fd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_mail_return_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_mapif_parse_mail_return_post[hIndex].func; + postHookFunc(fd); } } - return retVal___; + return; } -bool HP_mapif_mercenary_load(int merc_id, int char_id, struct s_mercenary *merc) { +void HP_mapif_mail_send(int fd, struct mail_message *msg) { int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_mercenary_load_pre > 0) { - bool (*preHookFunc) (int *merc_id, int *char_id, struct s_mercenary **merc); + if (HPMHooks.count.HP_mapif_mail_send_pre > 0) { + void (*preHookFunc) (int *fd, struct mail_message **msg); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_mercenary_load_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_mercenary_load_pre[hIndex].func; - retVal___ = preHookFunc(&merc_id, &char_id, &merc); + for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_mail_send_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_mapif_mail_send_pre[hIndex].func; + preHookFunc(&fd, &msg); } if (*HPMforce_return) { *HPMforce_return = false; - return retVal___; + return; } } { - retVal___ = HPMHooks.source.mapif.mercenary_load(merc_id, char_id, merc); + HPMHooks.source.mapif.mail_send(fd, msg); } - if (HPMHooks.count.HP_mapif_mercenary_load_post > 0) { - bool (*postHookFunc) (bool retVal___, int merc_id, int char_id, struct s_mercenary *merc); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_mercenary_load_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_mercenary_load_post[hIndex].func; - retVal___ = postHookFunc(retVal___, merc_id, char_id, merc); + if (HPMHooks.count.HP_mapif_mail_send_post > 0) { + void (*postHookFunc) (int fd, struct mail_message *msg); + for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_mail_send_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_mapif_mail_send_post[hIndex].func; + postHookFunc(fd, msg); } } - return retVal___; + return; } -bool HP_mapif_mercenary_delete(int merc_id) { +void HP_mapif_parse_mail_send(int fd) { int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_mercenary_delete_pre > 0) { - bool (*preHookFunc) (int *merc_id); + if (HPMHooks.count.HP_mapif_parse_mail_send_pre > 0) { + void (*preHookFunc) (int *fd); *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_mercenary_delete_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_mercenary_delete_pre[hIndex].func; - retVal___ = preHookFunc(&merc_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_mail_send_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_mapif_parse_mail_send_pre[hIndex].func; + preHookFunc(&fd); } if (*HPMforce_return) { *HPMforce_return = false; - return retVal___; + return; } } { - retVal___ = HPMHooks.source.mapif.mercenary_delete(merc_id); + HPMHooks.source.mapif.parse_mail_send(fd); } - if (HPMHooks.count.HP_mapif_mercenary_delete_post > 0) { - bool (*postHookFunc) (bool retVal___, int merc_id); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_mercenary_delete_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_mercenary_delete_post[hIndex].func; - retVal___ = postHookFunc(retVal___, merc_id); + if (HPMHooks.count.HP_mapif_parse_mail_send_post > 0) { + void (*postHookFunc) (int fd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_mail_send_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_mapif_parse_mail_send_post[hIndex].func; + postHookFunc(fd); } } - return retVal___; + return; } void HP_mapif_mercenary_send(int fd, struct s_mercenary *merc, unsigned char flag) { int hIndex = 0; @@ -14164,60 +15188,6 @@ int HP_mapif_delete_pet_ack(int fd, int flag) { } return retVal___; } -int HP_mapif_create_pet(int fd, int account_id, int char_id, short pet_class, short pet_lv, short pet_egg_id, short pet_equip, short intimate, short hungry, char rename_flag, char incubate, const char *pet_name) { - int hIndex = 0; - int retVal___ = 0; - if (HPMHooks.count.HP_mapif_create_pet_pre > 0) { - int (*preHookFunc) (int *fd, int *account_id, int *char_id, short *pet_class, short *pet_lv, short *pet_egg_id, short *pet_equip, short *intimate, short *hungry, char *rename_flag, char *incubate, const char **pet_name); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_create_pet_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_create_pet_pre[hIndex].func; - retVal___ = preHookFunc(&fd, &account_id, &char_id, &pet_class, &pet_lv, &pet_egg_id, &pet_equip, &intimate, &hungry, &rename_flag, &incubate, &pet_name); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.create_pet(fd, account_id, char_id, pet_class, pet_lv, pet_egg_id, pet_equip, intimate, hungry, rename_flag, incubate, pet_name); - } - if (HPMHooks.count.HP_mapif_create_pet_post > 0) { - int (*postHookFunc) (int retVal___, int fd, int account_id, int char_id, short pet_class, short pet_lv, short pet_egg_id, short pet_equip, short intimate, short hungry, char rename_flag, char incubate, const char *pet_name); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_create_pet_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_create_pet_post[hIndex].func; - retVal___ = postHookFunc(retVal___, fd, account_id, char_id, pet_class, pet_lv, pet_egg_id, pet_equip, intimate, hungry, rename_flag, incubate, pet_name); - } - } - return retVal___; -} -int HP_mapif_load_pet(int fd, int account_id, int char_id, int pet_id) { - int hIndex = 0; - int retVal___ = 0; - if (HPMHooks.count.HP_mapif_load_pet_pre > 0) { - int (*preHookFunc) (int *fd, int *account_id, int *char_id, int *pet_id); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_load_pet_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_load_pet_pre[hIndex].func; - retVal___ = preHookFunc(&fd, &account_id, &char_id, &pet_id); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.load_pet(fd, account_id, char_id, pet_id); - } - if (HPMHooks.count.HP_mapif_load_pet_post > 0) { - int (*postHookFunc) (int retVal___, int fd, int account_id, int char_id, int pet_id); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_load_pet_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_load_pet_post[hIndex].func; - retVal___ = postHookFunc(retVal___, fd, account_id, char_id, pet_id); - } - } - return retVal___; -} int HP_mapif_save_pet(int fd, int account_id, const struct s_pet *data) { int hIndex = 0; int retVal___ = 0; @@ -14380,114 +15350,6 @@ int HP_mapif_parse_DeletePet(int fd) { } return retVal___; } -struct quest* HP_mapif_quests_fromsql(int char_id, int *count) { - int hIndex = 0; - struct quest* retVal___ = NULL; - if (HPMHooks.count.HP_mapif_quests_fromsql_pre > 0) { - struct quest* (*preHookFunc) (int *char_id, int **count); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_quests_fromsql_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_quests_fromsql_pre[hIndex].func; - retVal___ = preHookFunc(&char_id, &count); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.quests_fromsql(char_id, count); - } - if (HPMHooks.count.HP_mapif_quests_fromsql_post > 0) { - struct quest* (*postHookFunc) (struct quest* retVal___, int char_id, int *count); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_quests_fromsql_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_quests_fromsql_post[hIndex].func; - retVal___ = postHookFunc(retVal___, char_id, count); - } - } - return retVal___; -} -bool HP_mapif_quest_delete(int char_id, int quest_id) { - int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_quest_delete_pre > 0) { - bool (*preHookFunc) (int *char_id, int *quest_id); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_quest_delete_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_quest_delete_pre[hIndex].func; - retVal___ = preHookFunc(&char_id, &quest_id); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.quest_delete(char_id, quest_id); - } - if (HPMHooks.count.HP_mapif_quest_delete_post > 0) { - bool (*postHookFunc) (bool retVal___, int char_id, int quest_id); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_quest_delete_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_quest_delete_post[hIndex].func; - retVal___ = postHookFunc(retVal___, char_id, quest_id); - } - } - return retVal___; -} -bool HP_mapif_quest_add(int char_id, struct quest qd) { - int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_quest_add_pre > 0) { - bool (*preHookFunc) (int *char_id, struct quest *qd); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_quest_add_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_quest_add_pre[hIndex].func; - retVal___ = preHookFunc(&char_id, &qd); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.quest_add(char_id, qd); - } - if (HPMHooks.count.HP_mapif_quest_add_post > 0) { - bool (*postHookFunc) (bool retVal___, int char_id, struct quest qd); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_quest_add_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_quest_add_post[hIndex].func; - retVal___ = postHookFunc(retVal___, char_id, qd); - } - } - return retVal___; -} -bool HP_mapif_quest_update(int char_id, struct quest qd) { - int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_quest_update_pre > 0) { - bool (*preHookFunc) (int *char_id, struct quest *qd); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_quest_update_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_quest_update_pre[hIndex].func; - retVal___ = preHookFunc(&char_id, &qd); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.quest_update(char_id, qd); - } - if (HPMHooks.count.HP_mapif_quest_update_post > 0) { - bool (*postHookFunc) (bool retVal___, int char_id, struct quest qd); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_quest_update_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_quest_update_post[hIndex].func; - retVal___ = postHookFunc(retVal___, char_id, qd); - } - } - return retVal___; -} void HP_mapif_quest_save_ack(int fd, int char_id, bool success) { int hIndex = 0; if (HPMHooks.count.HP_mapif_quest_save_ack_pre > 0) { @@ -14594,32 +15456,31 @@ int HP_mapif_parse_quest_load(int fd) { } return retVal___; } -int HP_mapif_parse_rodex_requestinbox(int fd) { +void HP_mapif_parse_rodex_requestinbox(int fd) { int hIndex = 0; - int retVal___ = 0; if (HPMHooks.count.HP_mapif_parse_rodex_requestinbox_pre > 0) { - int (*preHookFunc) (int *fd); + void (*preHookFunc) (int *fd); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_rodex_requestinbox_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_mapif_parse_rodex_requestinbox_pre[hIndex].func; - retVal___ = preHookFunc(&fd); + preHookFunc(&fd); } if (*HPMforce_return) { *HPMforce_return = false; - return retVal___; + return; } } { - retVal___ = HPMHooks.source.mapif.parse_rodex_requestinbox(fd); + HPMHooks.source.mapif.parse_rodex_requestinbox(fd); } if (HPMHooks.count.HP_mapif_parse_rodex_requestinbox_post > 0) { - int (*postHookFunc) (int retVal___, int fd); + void (*postHookFunc) (int fd); for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_rodex_requestinbox_post; hIndex++) { postHookFunc = HPMHooks.list.HP_mapif_parse_rodex_requestinbox_post[hIndex].func; - retVal___ = postHookFunc(retVal___, fd); + postHookFunc(fd); } } - return retVal___; + return; } void HP_mapif_rodex_sendinbox(int fd, int char_id, int8 opentype, int8 flag, int count, int64 mail_id, struct rodex_maillist *mails) { int hIndex = 0; @@ -14647,32 +15508,31 @@ void HP_mapif_rodex_sendinbox(int fd, int char_id, int8 opentype, int8 flag, int } return; } -int HP_mapif_parse_rodex_checkhasnew(int fd) { +void HP_mapif_parse_rodex_checkhasnew(int fd) { int hIndex = 0; - int retVal___ = 0; if (HPMHooks.count.HP_mapif_parse_rodex_checkhasnew_pre > 0) { - int (*preHookFunc) (int *fd); + void (*preHookFunc) (int *fd); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_rodex_checkhasnew_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_mapif_parse_rodex_checkhasnew_pre[hIndex].func; - retVal___ = preHookFunc(&fd); + preHookFunc(&fd); } if (*HPMforce_return) { *HPMforce_return = false; - return retVal___; + return; } } { - retVal___ = HPMHooks.source.mapif.parse_rodex_checkhasnew(fd); + HPMHooks.source.mapif.parse_rodex_checkhasnew(fd); } if (HPMHooks.count.HP_mapif_parse_rodex_checkhasnew_post > 0) { - int (*postHookFunc) (int retVal___, int fd); + void (*postHookFunc) (int fd); for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_rodex_checkhasnew_post; hIndex++) { postHookFunc = HPMHooks.list.HP_mapif_parse_rodex_checkhasnew_post[hIndex].func; - retVal___ = postHookFunc(retVal___, fd); + postHookFunc(fd); } } - return retVal___; + return; } void HP_mapif_rodex_sendhasnew(int fd, int char_id, bool has_new) { int hIndex = 0; @@ -14700,59 +15560,57 @@ void HP_mapif_rodex_sendhasnew(int fd, int char_id, bool has_new) { } return; } -int HP_mapif_parse_rodex_updatemail(int fd) { +void HP_mapif_parse_rodex_updatemail(int fd) { int hIndex = 0; - int retVal___ = 0; if (HPMHooks.count.HP_mapif_parse_rodex_updatemail_pre > 0) { - int (*preHookFunc) (int *fd); + void (*preHookFunc) (int *fd); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_rodex_updatemail_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_mapif_parse_rodex_updatemail_pre[hIndex].func; - retVal___ = preHookFunc(&fd); + preHookFunc(&fd); } if (*HPMforce_return) { *HPMforce_return = false; - return retVal___; + return; } } { - retVal___ = HPMHooks.source.mapif.parse_rodex_updatemail(fd); + HPMHooks.source.mapif.parse_rodex_updatemail(fd); } if (HPMHooks.count.HP_mapif_parse_rodex_updatemail_post > 0) { - int (*postHookFunc) (int retVal___, int fd); + void (*postHookFunc) (int fd); for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_rodex_updatemail_post; hIndex++) { postHookFunc = HPMHooks.list.HP_mapif_parse_rodex_updatemail_post[hIndex].func; - retVal___ = postHookFunc(retVal___, fd); + postHookFunc(fd); } } - return retVal___; + return; } -int HP_mapif_parse_rodex_send(int fd) { +void HP_mapif_parse_rodex_send(int fd) { int hIndex = 0; - int retVal___ = 0; if (HPMHooks.count.HP_mapif_parse_rodex_send_pre > 0) { - int (*preHookFunc) (int *fd); + void (*preHookFunc) (int *fd); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_rodex_send_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_mapif_parse_rodex_send_pre[hIndex].func; - retVal___ = preHookFunc(&fd); + preHookFunc(&fd); } if (*HPMforce_return) { *HPMforce_return = false; - return retVal___; + return; } } { - retVal___ = HPMHooks.source.mapif.parse_rodex_send(fd); + HPMHooks.source.mapif.parse_rodex_send(fd); } if (HPMHooks.count.HP_mapif_parse_rodex_send_post > 0) { - int (*postHookFunc) (int retVal___, int fd); + void (*postHookFunc) (int fd); for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_rodex_send_post; hIndex++) { postHookFunc = HPMHooks.list.HP_mapif_parse_rodex_send_post[hIndex].func; - retVal___ = postHookFunc(retVal___, fd); + postHookFunc(fd); } } - return retVal___; + return; } void HP_mapif_rodex_send(int fd, int sender_id, int receiver_id, int receiver_accountid, bool result) { int hIndex = 0; @@ -14780,32 +15638,31 @@ void HP_mapif_rodex_send(int fd, int sender_id, int receiver_id, int receiver_ac } return; } -int HP_mapif_parse_rodex_checkname(int fd) { +void HP_mapif_parse_rodex_checkname(int fd) { int hIndex = 0; - int retVal___ = 0; if (HPMHooks.count.HP_mapif_parse_rodex_checkname_pre > 0) { - int (*preHookFunc) (int *fd); + void (*preHookFunc) (int *fd); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_rodex_checkname_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_mapif_parse_rodex_checkname_pre[hIndex].func; - retVal___ = preHookFunc(&fd); + preHookFunc(&fd); } if (*HPMforce_return) { *HPMforce_return = false; - return retVal___; + return; } } { - retVal___ = HPMHooks.source.mapif.parse_rodex_checkname(fd); + HPMHooks.source.mapif.parse_rodex_checkname(fd); } if (HPMHooks.count.HP_mapif_parse_rodex_checkname_post > 0) { - int (*postHookFunc) (int retVal___, int fd); + void (*postHookFunc) (int fd); for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_rodex_checkname_post; hIndex++) { postHookFunc = HPMHooks.list.HP_mapif_parse_rodex_checkname_post[hIndex].func; - retVal___ = postHookFunc(retVal___, fd); + postHookFunc(fd); } } - return retVal___; + return; } void HP_mapif_rodex_checkname(int fd, int reqchar_id, int target_char_id, short target_class, int target_level, char *name) { int hIndex = 0; @@ -15075,33 +15932,6 @@ int HP_mapif_itembound_ack(int fd, int aid, int guild_id) { } return retVal___; } -int HP_mapif_parse_ItemBoundRetrieve_sub(int fd) { - int hIndex = 0; - int retVal___ = 0; - if (HPMHooks.count.HP_mapif_parse_ItemBoundRetrieve_sub_pre > 0) { - int (*preHookFunc) (int *fd); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_ItemBoundRetrieve_sub_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_parse_ItemBoundRetrieve_sub_pre[hIndex].func; - retVal___ = preHookFunc(&fd); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.parse_ItemBoundRetrieve_sub(fd); - } - if (HPMHooks.count.HP_mapif_parse_ItemBoundRetrieve_sub_post > 0) { - int (*postHookFunc) (int retVal___, int fd); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_ItemBoundRetrieve_sub_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_parse_ItemBoundRetrieve_sub_post[hIndex].func; - retVal___ = postHookFunc(retVal___, fd); - } - } - return retVal___; -} void HP_mapif_parse_ItemBoundRetrieve(int fd) { int hIndex = 0; if (HPMHooks.count.HP_mapif_parse_ItemBoundRetrieve_pre > 0) { @@ -15154,32 +15984,6 @@ void HP_mapif_parse_accinfo(int fd) { } return; } -void HP_mapif_parse_accinfo2(bool success, int map_fd, int u_fd, int u_aid, int account_id, const char *userid, const char *user_pass, const char *email, const char *last_ip, const char *lastlogin, const char *pin_code, const char *birthdate, int group_id, int logincount, int state) { - int hIndex = 0; - if (HPMHooks.count.HP_mapif_parse_accinfo2_pre > 0) { - void (*preHookFunc) (bool *success, int *map_fd, int *u_fd, int *u_aid, int *account_id, const char **userid, const char **user_pass, const char **email, const char **last_ip, const char **lastlogin, const char **pin_code, const char **birthdate, int *group_id, int *logincount, int *state); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_accinfo2_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_mapif_parse_accinfo2_pre[hIndex].func; - preHookFunc(&success, &map_fd, &u_fd, &u_aid, &account_id, &userid, &user_pass, &email, &last_ip, &lastlogin, &pin_code, &birthdate, &group_id, &logincount, &state); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return; - } - } - { - HPMHooks.source.mapif.parse_accinfo2(success, map_fd, u_fd, u_aid, account_id, userid, user_pass, email, last_ip, lastlogin, pin_code, birthdate, group_id, logincount, state); - } - if (HPMHooks.count.HP_mapif_parse_accinfo2_post > 0) { - void (*postHookFunc) (bool success, int map_fd, int u_fd, int u_aid, int account_id, const char *userid, const char *user_pass, const char *email, const char *last_ip, const char *lastlogin, const char *pin_code, const char *birthdate, int group_id, int logincount, int state); - for (hIndex = 0; hIndex < HPMHooks.count.HP_mapif_parse_accinfo2_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_mapif_parse_accinfo2_post[hIndex].func; - postHookFunc(success, map_fd, u_fd, u_aid, account_id, userid, user_pass, email, last_ip, lastlogin, pin_code, birthdate, group_id, logincount, state); - } - } - return; -} int HP_mapif_broadcast(const unsigned char *mes, int len, unsigned int fontColor, short fontType, short fontSize, short fontAlign, short fontY, int sfd) { int hIndex = 0; int retVal___ = 0; -- cgit v1.2.3-70-g09d2