diff options
Diffstat (limited to 'src/plugins')
-rw-r--r-- | src/plugins/HPMHooking.c | 2 | ||||
-rw-r--r-- | src/plugins/HPMHooking/HPMHooking.Defs.inc | 370 | ||||
-rw-r--r-- | src/plugins/HPMHooking/HPMHooking_char.HPMHooksCore.inc | 316 | ||||
-rw-r--r-- | src/plugins/HPMHooking/HPMHooking_char.HookingPoints.inc | 79 | ||||
-rw-r--r-- | src/plugins/HPMHooking/HPMHooking_char.Hooks.inc | 2226 | ||||
-rw-r--r-- | src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc | 104 | ||||
-rw-r--r-- | src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc | 26 | ||||
-rw-r--r-- | src/plugins/HPMHooking/HPMHooking_map.Hooks.inc | 918 | ||||
-rw-r--r-- | src/plugins/Makefile.in | 2 | ||||
-rw-r--r-- | src/plugins/constdb2doc.c | 2 | ||||
-rw-r--r-- | src/plugins/db2sql.c | 4 | ||||
-rw-r--r-- | src/plugins/script_mapquit.c | 2 |
12 files changed, 2955 insertions, 1096 deletions
diff --git a/src/plugins/HPMHooking.c b/src/plugins/HPMHooking.c index e3b694c2b..ca64aca6a 100644 --- a/src/plugins/HPMHooking.c +++ b/src/plugins/HPMHooking.c @@ -2,7 +2,7 @@ * This file is part of Hercules. * http://herc.ws - http://github.com/HerculesWS/Hercules * - * Copyright (C) 2013-2016 Hercules Dev Team + * Copyright (C) 2013-2018 Hercules Dev Team * * Hercules is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/src/plugins/HPMHooking/HPMHooking.Defs.inc b/src/plugins/HPMHooking/HPMHooking.Defs.inc index 7c609f0bf..c5519001b 100644 --- a/src/plugins/HPMHooking/HPMHooking.Defs.inc +++ b/src/plugins/HPMHooking/HPMHooking.Defs.inc @@ -330,16 +330,16 @@ typedef void (*HPMHOOK_post_bg_config_read) (void); #ifdef MAP_BUYINGSTORE_H /* buyingstore */ typedef bool (*HPMHOOK_pre_buyingstore_setup) (struct map_session_data **sd, unsigned char *slots); typedef bool (*HPMHOOK_post_buyingstore_setup) (bool retVal___, struct map_session_data *sd, unsigned char slots); -typedef void (*HPMHOOK_pre_buyingstore_create) (struct map_session_data **sd, int *zenylimit, unsigned char *result, const char **storename, const uint8 **itemlist, unsigned int *count); -typedef void (*HPMHOOK_post_buyingstore_create) (struct map_session_data *sd, int zenylimit, unsigned char result, const char *storename, const uint8 *itemlist, unsigned int count); +typedef void (*HPMHOOK_pre_buyingstore_create) (struct map_session_data **sd, int *zenylimit, unsigned char *result, const char **storename, const struct PACKET_CZ_REQ_OPEN_BUYING_STORE_sub **itemlist, unsigned int *count); +typedef void (*HPMHOOK_post_buyingstore_create) (struct map_session_data *sd, int zenylimit, unsigned char result, const char *storename, const struct PACKET_CZ_REQ_OPEN_BUYING_STORE_sub *itemlist, unsigned int count); typedef void (*HPMHOOK_pre_buyingstore_close) (struct map_session_data **sd); typedef void (*HPMHOOK_post_buyingstore_close) (struct map_session_data *sd); typedef void (*HPMHOOK_pre_buyingstore_open) (struct map_session_data **sd, int *account_id); typedef void (*HPMHOOK_post_buyingstore_open) (struct map_session_data *sd, int account_id); -typedef void (*HPMHOOK_pre_buyingstore_trade) (struct map_session_data **sd, int *account_id, unsigned int *buyer_id, const uint8 **itemlist, unsigned int *count); -typedef void (*HPMHOOK_post_buyingstore_trade) (struct map_session_data *sd, int account_id, unsigned int buyer_id, const uint8 *itemlist, unsigned int count); -typedef bool (*HPMHOOK_pre_buyingstore_search) (struct map_session_data **sd, unsigned short *nameid); -typedef bool (*HPMHOOK_post_buyingstore_search) (bool retVal___, struct map_session_data *sd, unsigned short nameid); +typedef void (*HPMHOOK_pre_buyingstore_trade) (struct map_session_data **sd, int *account_id, unsigned int *buyer_id, const struct PACKET_CZ_REQ_TRADE_BUYING_STORE_sub **itemlist, unsigned int *count); +typedef void (*HPMHOOK_post_buyingstore_trade) (struct map_session_data *sd, int account_id, unsigned int buyer_id, const struct PACKET_CZ_REQ_TRADE_BUYING_STORE_sub *itemlist, unsigned int count); +typedef bool (*HPMHOOK_pre_buyingstore_search) (struct map_session_data **sd, int *nameid); +typedef bool (*HPMHOOK_post_buyingstore_search) (bool retVal___, struct map_session_data *sd, int nameid); typedef bool (*HPMHOOK_pre_buyingstore_searchall) (struct map_session_data **sd, const struct s_search_store_search **s); typedef bool (*HPMHOOK_post_buyingstore_searchall) (bool retVal___, struct map_session_data *sd, const struct s_search_store_search *s); typedef unsigned int (*HPMHOOK_pre_buyingstore_getuid) (void); @@ -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); @@ -622,8 +624,8 @@ typedef void (*HPMHOOK_pre_chr_send_account_id) (int *fd, int *account_id); typedef void (*HPMHOOK_post_chr_send_account_id) (int fd, int account_id); typedef void (*HPMHOOK_pre_chr_parse_char_connect) (int *fd, struct char_session_data **sd, uint32 *ipl); typedef void (*HPMHOOK_post_chr_parse_char_connect) (int fd, struct char_session_data *sd, uint32 ipl); -typedef void (*HPMHOOK_pre_chr_send_map_info) (int *fd, int *i, uint32 *subnet_map_ip, struct mmo_charstatus **cd); -typedef void (*HPMHOOK_post_chr_send_map_info) (int fd, int i, uint32 subnet_map_ip, struct mmo_charstatus *cd); +typedef void (*HPMHOOK_pre_chr_send_map_info) (int *fd, int *i, uint32 *subnet_map_ip, struct mmo_charstatus **cd, char **dnsHost); +typedef void (*HPMHOOK_post_chr_send_map_info) (int fd, int i, uint32 subnet_map_ip, struct mmo_charstatus *cd, char *dnsHost); typedef void (*HPMHOOK_pre_chr_send_wait_char_server) (int *fd); typedef void (*HPMHOOK_post_chr_send_wait_char_server) (int fd); typedef int (*HPMHOOK_pre_chr_search_default_maps_mapserver) (struct mmo_charstatus **cd); @@ -988,6 +990,8 @@ typedef unsigned short (*HPMHOOK_pre_clif_decrypt_cmd) (int *cmd, struct map_ses typedef unsigned short (*HPMHOOK_post_clif_decrypt_cmd) (unsigned short retVal___, int cmd, struct map_session_data *sd); typedef void (*HPMHOOK_pre_clif_authok) (struct map_session_data **sd); typedef void (*HPMHOOK_post_clif_authok) (struct map_session_data *sd); +typedef void (*HPMHOOK_pre_clif_auth_error) (int *fd, int *errorCode); +typedef void (*HPMHOOK_post_clif_auth_error) (int fd, int errorCode); typedef void (*HPMHOOK_pre_clif_authrefuse) (int *fd, uint8 *error_code); typedef void (*HPMHOOK_post_clif_authrefuse) (int fd, uint8 error_code); typedef void (*HPMHOOK_pre_clif_authfail_fd) (int *fd, int *type); @@ -1026,10 +1030,8 @@ typedef void (*HPMHOOK_pre_clif_unequipitemack) (struct map_session_data **sd, i typedef void (*HPMHOOK_post_clif_unequipitemack) (struct map_session_data *sd, int n, int pos, enum e_UNEQUIP_ITEM_ACK result); typedef void (*HPMHOOK_pre_clif_useitemack) (struct map_session_data **sd, int *index, int *amount, bool *ok); typedef void (*HPMHOOK_post_clif_useitemack) (struct map_session_data *sd, int index, int amount, bool ok); -typedef void (*HPMHOOK_pre_clif_addcards) (unsigned char **buf, struct item **item); -typedef void (*HPMHOOK_post_clif_addcards) (unsigned char *buf, struct item *item); -typedef void (*HPMHOOK_pre_clif_addcards2) (unsigned short **cards, struct item **item); -typedef void (*HPMHOOK_post_clif_addcards2) (unsigned short *cards, struct item *item); +typedef void (*HPMHOOK_pre_clif_addcards) (struct EQUIPSLOTINFO **buf, struct item **item); +typedef void (*HPMHOOK_post_clif_addcards) (struct EQUIPSLOTINFO *buf, struct item *item); typedef void (*HPMHOOK_pre_clif_item_sub) (unsigned char **buf, int *n, struct item **i, struct item_data **id, int *equip); typedef void (*HPMHOOK_post_clif_item_sub) (unsigned char *buf, int n, struct item *i, struct item_data *id, int equip); typedef void (*HPMHOOK_pre_clif_getareachar_item) (struct map_session_data **sd, struct flooritem_data **fitem); @@ -1038,10 +1040,12 @@ typedef void (*HPMHOOK_pre_clif_cart_additem_ack) (struct map_session_data **sd, typedef void (*HPMHOOK_post_clif_cart_additem_ack) (struct map_session_data *sd, int flag); typedef void (*HPMHOOK_pre_clif_cashshop_load) (void); typedef void (*HPMHOOK_post_clif_cashshop_load) (void); -typedef void (*HPMHOOK_pre_clif_package_announce) (struct map_session_data **sd, unsigned short *nameid, unsigned short *containerid); -typedef void (*HPMHOOK_post_clif_package_announce) (struct map_session_data *sd, unsigned short nameid, unsigned short containerid); -typedef void (*HPMHOOK_pre_clif_item_drop_announce) (struct map_session_data **sd, unsigned short *nameid, char **monsterName); -typedef void (*HPMHOOK_post_clif_item_drop_announce) (struct map_session_data *sd, unsigned short nameid, char *monsterName); +typedef void (*HPMHOOK_pre_clif_cashShopSchedule) (int *fd, struct map_session_data **sd); +typedef void (*HPMHOOK_post_clif_cashShopSchedule) (int fd, struct map_session_data *sd); +typedef void (*HPMHOOK_pre_clif_package_announce) (struct map_session_data **sd, int *nameid, int *containerid); +typedef void (*HPMHOOK_post_clif_package_announce) (struct map_session_data *sd, int nameid, int containerid); +typedef void (*HPMHOOK_pre_clif_item_drop_announce) (struct map_session_data **sd, int *nameid, char **monsterName); +typedef void (*HPMHOOK_post_clif_item_drop_announce) (struct map_session_data *sd, int nameid, char *monsterName); typedef void (*HPMHOOK_pre_clif_clearunit_single) (int *id, clr_type *type, int *fd); typedef void (*HPMHOOK_post_clif_clearunit_single) (int id, clr_type type, int fd); typedef void (*HPMHOOK_pre_clif_clearunit_area) (struct block_list **bl, clr_type *type); @@ -1102,6 +1106,8 @@ typedef bool (*HPMHOOK_pre_clif_spawn) (struct block_list **bl); typedef bool (*HPMHOOK_post_clif_spawn) (bool retVal___, struct block_list *bl); typedef void (*HPMHOOK_pre_clif_changemap) (struct map_session_data **sd, short *m, int *x, int *y); typedef void (*HPMHOOK_post_clif_changemap) (struct map_session_data *sd, short m, int x, int y); +typedef void (*HPMHOOK_pre_clif_changemap_airship) (struct map_session_data **sd, short *m, int *x, int *y); +typedef void (*HPMHOOK_post_clif_changemap_airship) (struct map_session_data *sd, short m, int x, int y); typedef void (*HPMHOOK_pre_clif_changemapcell) (int *fd, int16 *m, int *x, int *y, int *type, enum send_target *target); typedef void (*HPMHOOK_post_clif_changemapcell) (int fd, int16 m, int x, int y, int type, enum send_target target); typedef void (*HPMHOOK_pre_clif_map_property) (struct map_session_data **sd, enum map_property *property); @@ -1118,6 +1124,8 @@ typedef void (*HPMHOOK_pre_clif_maptypeproperty2) (struct block_list **bl, enum typedef void (*HPMHOOK_post_clif_maptypeproperty2) (struct block_list *bl, enum send_target t); typedef void (*HPMHOOK_pre_clif_changemapserver) (struct map_session_data **sd, unsigned short *map_index, int *x, int *y, uint32 *ip, uint16 *port); typedef void (*HPMHOOK_post_clif_changemapserver) (struct map_session_data *sd, unsigned short map_index, int x, int y, uint32 ip, uint16 port); +typedef void (*HPMHOOK_pre_clif_changemapserver_airship) (struct map_session_data **sd, unsigned short *map_index, int *x, int *y, uint32 *ip, uint16 *port); +typedef void (*HPMHOOK_post_clif_changemapserver_airship) (struct map_session_data *sd, unsigned short map_index, int x, int y, uint32 ip, uint16 port); typedef void (*HPMHOOK_pre_clif_npcbuysell) (struct map_session_data **sd, int *id); typedef void (*HPMHOOK_post_clif_npcbuysell) (struct map_session_data *sd, int id); typedef void (*HPMHOOK_pre_clif_buylist) (struct map_session_data **sd, struct npc_data **nd); @@ -1184,8 +1192,8 @@ typedef int (*HPMHOOK_pre_clif_outsight) (struct block_list **bl, va_list ap); typedef int (*HPMHOOK_post_clif_outsight) (int retVal___, struct block_list *bl, va_list ap); typedef void (*HPMHOOK_pre_clif_skillcastcancel) (struct block_list **bl); typedef void (*HPMHOOK_post_clif_skillcastcancel) (struct block_list *bl); -typedef void (*HPMHOOK_pre_clif_skill_fail) (struct map_session_data **sd, uint16 *skill_id, enum useskill_fail_cause *cause, int *btype); -typedef void (*HPMHOOK_post_clif_skill_fail) (struct map_session_data *sd, uint16 skill_id, enum useskill_fail_cause cause, int btype); +typedef void (*HPMHOOK_pre_clif_skill_fail) (struct map_session_data **sd, uint16 *skill_id, enum useskill_fail_cause *cause, int *btype, int32 *item_id); +typedef void (*HPMHOOK_post_clif_skill_fail) (struct map_session_data *sd, uint16 skill_id, enum useskill_fail_cause cause, int btype, int32 item_id); typedef void (*HPMHOOK_pre_clif_skill_cooldown) (struct map_session_data **sd, uint16 *skill_id, unsigned int *duration); typedef void (*HPMHOOK_post_clif_skill_cooldown) (struct map_session_data *sd, uint16 skill_id, unsigned int duration); typedef void (*HPMHOOK_pre_clif_skill_memomessage) (struct map_session_data **sd, int *type); @@ -1248,8 +1256,8 @@ typedef int (*HPMHOOK_pre_clif_hpmeter_sub) (struct block_list **bl, va_list ap) typedef int (*HPMHOOK_post_clif_hpmeter_sub) (int retVal___, struct block_list *bl, va_list ap); typedef void (*HPMHOOK_pre_clif_upgrademessage) (int *fd, int *result, int *item_id); typedef void (*HPMHOOK_post_clif_upgrademessage) (int fd, int result, int item_id); -typedef void (*HPMHOOK_pre_clif_get_weapon_view) (struct map_session_data **sd, unsigned short **rhand, unsigned short **lhand); -typedef void (*HPMHOOK_post_clif_get_weapon_view) (struct map_session_data *sd, unsigned short *rhand, unsigned short *lhand); +typedef void (*HPMHOOK_pre_clif_get_weapon_view) (struct map_session_data **sd, int **rhand, int **lhand); +typedef void (*HPMHOOK_post_clif_get_weapon_view) (struct map_session_data *sd, int *rhand, int *lhand); typedef void (*HPMHOOK_pre_clif_gospel_info) (struct map_session_data **sd, int *type); typedef void (*HPMHOOK_post_clif_gospel_info) (struct map_session_data *sd, int type); typedef void (*HPMHOOK_pre_clif_feel_req) (int *fd, struct map_session_data **sd, uint16 *skill_lv); @@ -1266,8 +1274,8 @@ typedef void (*HPMHOOK_pre_clif_feel_hate_reset) (struct map_session_data **sd); typedef void (*HPMHOOK_post_clif_feel_hate_reset) (struct map_session_data *sd); typedef void (*HPMHOOK_pre_clif_partytickack) (struct map_session_data **sd, bool *flag); typedef void (*HPMHOOK_post_clif_partytickack) (struct map_session_data *sd, bool flag); -typedef void (*HPMHOOK_pre_clif_zc_config) (struct map_session_data **sd, int *type, int *flag); -typedef void (*HPMHOOK_post_clif_zc_config) (struct map_session_data *sd, int type, int flag); +typedef void (*HPMHOOK_pre_clif_zc_config) (struct map_session_data **sd, enum CZ_CONFIG *type, int *flag); +typedef void (*HPMHOOK_post_clif_zc_config) (struct map_session_data *sd, enum CZ_CONFIG type, int flag); typedef void (*HPMHOOK_pre_clif_viewequip_ack) (struct map_session_data **sd, struct map_session_data **tsd); typedef void (*HPMHOOK_post_clif_viewequip_ack) (struct map_session_data *sd, struct map_session_data *tsd); typedef void (*HPMHOOK_pre_clif_equpcheckbox) (struct map_session_data **sd); @@ -1440,8 +1448,10 @@ typedef void (*HPMHOOK_pre_clif_messagecolor_self) (int *fd, uint32 *color, cons typedef void (*HPMHOOK_post_clif_messagecolor_self) (int fd, uint32 color, const char *msg); typedef void (*HPMHOOK_pre_clif_messagecolor) (struct block_list **bl, uint32 *color, const char **msg); typedef void (*HPMHOOK_post_clif_messagecolor) (struct block_list *bl, uint32 color, const char *msg); -typedef void (*HPMHOOK_pre_clif_disp_overhead) (struct block_list **bl, const char **mes); -typedef void (*HPMHOOK_post_clif_disp_overhead) (struct block_list *bl, const char *mes); +typedef void (*HPMHOOK_pre_clif_disp_overhead) (struct block_list **bl, const char **mes, enum send_target *target, struct block_list **target_bl); +typedef void (*HPMHOOK_post_clif_disp_overhead) (struct block_list *bl, const char *mes, enum send_target target, struct block_list *target_bl); +typedef void (*HPMHOOK_pre_clif_notify_playerchat) (struct block_list **bl, const char **mes); +typedef void (*HPMHOOK_post_clif_notify_playerchat) (struct block_list *bl, const char *mes); typedef void (*HPMHOOK_pre_clif_msgtable) (struct map_session_data **sd, enum clif_messages *msg_id); typedef void (*HPMHOOK_post_clif_msgtable) (struct map_session_data *sd, enum clif_messages msg_id); typedef void (*HPMHOOK_pre_clif_msgtable_num) (struct map_session_data **sd, enum clif_messages *msg_id, int *value); @@ -1496,6 +1506,8 @@ typedef void (*HPMHOOK_pre_clif_buyvending) (struct map_session_data **sd, int * typedef void (*HPMHOOK_post_clif_buyvending) (struct map_session_data *sd, int index, int amount, int fail); typedef void (*HPMHOOK_pre_clif_openvending) (struct map_session_data **sd, int *id, struct s_vending **vending_list); typedef void (*HPMHOOK_post_clif_openvending) (struct map_session_data *sd, int id, struct s_vending *vending_list); +typedef void (*HPMHOOK_pre_clif_openvendingAck) (int *fd, int *result); +typedef void (*HPMHOOK_post_clif_openvendingAck) (int fd, int result); typedef void (*HPMHOOK_pre_clif_vendingreport) (struct map_session_data **sd, int *index, int *amount, uint32 *char_id, int *zeny); typedef void (*HPMHOOK_post_clif_vendingreport) (struct map_session_data *sd, int index, int amount, uint32 char_id, int zeny); typedef void (*HPMHOOK_pre_clif_storagelist) (struct map_session_data **sd, struct item **items, int *items_length); @@ -1788,12 +1800,12 @@ typedef void (*HPMHOOK_pre_clif_buyingstore_itemlist) (struct map_session_data * typedef void (*HPMHOOK_post_clif_buyingstore_itemlist) (struct map_session_data *sd, struct map_session_data *pl_sd); typedef void (*HPMHOOK_pre_clif_buyingstore_trade_failed_buyer) (struct map_session_data **sd, short *result); typedef void (*HPMHOOK_post_clif_buyingstore_trade_failed_buyer) (struct map_session_data *sd, short result); -typedef void (*HPMHOOK_pre_clif_buyingstore_update_item) (struct map_session_data **sd, unsigned short *nameid, unsigned short *amount, uint32 *char_id, int *zeny); -typedef void (*HPMHOOK_post_clif_buyingstore_update_item) (struct map_session_data *sd, unsigned short nameid, unsigned short amount, uint32 char_id, int zeny); +typedef void (*HPMHOOK_pre_clif_buyingstore_update_item) (struct map_session_data **sd, int *nameid, unsigned short *amount, uint32 *char_id, int *zeny); +typedef void (*HPMHOOK_post_clif_buyingstore_update_item) (struct map_session_data *sd, int nameid, unsigned short amount, uint32 char_id, int zeny); typedef void (*HPMHOOK_pre_clif_buyingstore_delete_item) (struct map_session_data **sd, short *index, unsigned short *amount, int *price); typedef void (*HPMHOOK_post_clif_buyingstore_delete_item) (struct map_session_data *sd, short index, unsigned short amount, int price); -typedef void (*HPMHOOK_pre_clif_buyingstore_trade_failed_seller) (struct map_session_data **sd, short *result, unsigned short *nameid); -typedef void (*HPMHOOK_post_clif_buyingstore_trade_failed_seller) (struct map_session_data *sd, short result, unsigned short nameid); +typedef void (*HPMHOOK_pre_clif_buyingstore_trade_failed_seller) (struct map_session_data **sd, short *result, int *nameid); +typedef void (*HPMHOOK_post_clif_buyingstore_trade_failed_seller) (struct map_session_data *sd, short result, int nameid); typedef void (*HPMHOOK_pre_clif_search_store_info_ack) (struct map_session_data **sd); typedef void (*HPMHOOK_post_clif_search_store_info_ack) (struct map_session_data *sd); typedef void (*HPMHOOK_pre_clif_search_store_info_failed) (struct map_session_data **sd, unsigned char *reason); @@ -1856,8 +1868,8 @@ typedef void (*HPMHOOK_pre_clif_npc_market_purchase_ack) (struct map_session_dat typedef void (*HPMHOOK_post_clif_npc_market_purchase_ack) (struct map_session_data *sd, const struct itemlist *item_list, unsigned char response); typedef bool (*HPMHOOK_pre_clif_parse_roulette_db) (void); typedef bool (*HPMHOOK_post_clif_parse_roulette_db) (bool retVal___); -typedef void (*HPMHOOK_pre_clif_roulette_generate_ack) (struct map_session_data **sd, unsigned char *result, short *stage, short *prizeIdx, short *bonusItemID); -typedef void (*HPMHOOK_post_clif_roulette_generate_ack) (struct map_session_data *sd, unsigned char result, short stage, short prizeIdx, short bonusItemID); +typedef void (*HPMHOOK_pre_clif_roulette_generate_ack) (struct map_session_data **sd, unsigned char *result, short *stage, short *prizeIdx, int *bonusItemID); +typedef void (*HPMHOOK_post_clif_roulette_generate_ack) (struct map_session_data *sd, unsigned char result, short stage, short prizeIdx, int bonusItemID); typedef void (*HPMHOOK_pre_clif_openmergeitem) (int *fd, struct map_session_data **sd); typedef void (*HPMHOOK_post_clif_openmergeitem) (int fd, struct map_session_data *sd); typedef void (*HPMHOOK_pre_clif_cancelmergeitem) (int *fd, struct map_session_data **sd); @@ -2348,8 +2360,8 @@ typedef void (*HPMHOOK_pre_clif_rodex_open_write_mail) (int *fd, const char **re typedef void (*HPMHOOK_post_clif_rodex_open_write_mail) (int fd, const char *receiver_name, int8 result); typedef void (*HPMHOOK_pre_clif_pRodexAddItem) (int *fd, struct map_session_data **sd); typedef void (*HPMHOOK_post_clif_pRodexAddItem) (int fd, struct map_session_data *sd); -typedef void (*HPMHOOK_pre_clif_rodex_add_item_result) (struct map_session_data **sd, int16 *idx, int16 *amount, int8 *result); -typedef void (*HPMHOOK_post_clif_rodex_add_item_result) (struct map_session_data *sd, int16 idx, int16 amount, int8 result); +typedef void (*HPMHOOK_pre_clif_rodex_add_item_result) (struct map_session_data **sd, int16 *idx, int16 *amount, enum rodex_add_item *result); +typedef void (*HPMHOOK_post_clif_rodex_add_item_result) (struct map_session_data *sd, int16 idx, int16 amount, enum rodex_add_item result); typedef void (*HPMHOOK_pre_clif_pRodexRemoveItem) (int *fd, struct map_session_data **sd); typedef void (*HPMHOOK_post_clif_pRodexRemoveItem) (int fd, struct map_session_data *sd); typedef void (*HPMHOOK_pre_clif_rodex_remove_item_result) (struct map_session_data **sd, int16 *idx, int16 *amount); @@ -2388,12 +2400,12 @@ typedef void (*HPMHOOK_pre_clif_pRodexRefreshMaillist) (int *fd, struct map_sess typedef void (*HPMHOOK_post_clif_pRodexRefreshMaillist) (int fd, struct map_session_data *sd); typedef void (*HPMHOOK_pre_clif_pRodexRequestZeny) (int *fd, struct map_session_data **sd); typedef void (*HPMHOOK_post_clif_pRodexRequestZeny) (int fd, struct map_session_data *sd); -typedef void (*HPMHOOK_pre_clif_rodex_request_zeny) (struct map_session_data **sd, int8 *opentype, int64 *mail_id, int8 *result); -typedef void (*HPMHOOK_post_clif_rodex_request_zeny) (struct map_session_data *sd, int8 opentype, int64 mail_id, int8 result); +typedef void (*HPMHOOK_pre_clif_rodex_request_zeny) (struct map_session_data **sd, int8 *opentype, int64 *mail_id, enum rodex_get_zeny *result); +typedef void (*HPMHOOK_post_clif_rodex_request_zeny) (struct map_session_data *sd, int8 opentype, int64 mail_id, enum rodex_get_zeny result); typedef void (*HPMHOOK_pre_clif_pRodexRequestItems) (int *fd, struct map_session_data **sd); typedef void (*HPMHOOK_post_clif_pRodexRequestItems) (int fd, struct map_session_data *sd); -typedef void (*HPMHOOK_pre_clif_rodex_request_items) (struct map_session_data **sd, int8 *opentype, int64 *mail_id, int8 *result); -typedef void (*HPMHOOK_post_clif_rodex_request_items) (struct map_session_data *sd, int8 opentype, int64 mail_id, int8 result); +typedef void (*HPMHOOK_pre_clif_rodex_request_items) (struct map_session_data **sd, int8 *opentype, int64 *mail_id, enum rodex_get_items *result); +typedef void (*HPMHOOK_post_clif_rodex_request_items) (struct map_session_data *sd, int8 opentype, int64 mail_id, enum rodex_get_items result); typedef void (*HPMHOOK_pre_clif_rodex_icon) (int *fd, bool *show); typedef void (*HPMHOOK_post_clif_rodex_icon) (int fd, bool show); typedef void (*HPMHOOK_pre_clif_skill_scale) (struct block_list **bl, int *src_id, int *x, int *y, uint16 *skill_id, uint16 *skill_lv, int *casttime); @@ -2442,14 +2454,18 @@ typedef bool (*HPMHOOK_pre_clif_stylist_read_db_libconfig_sub) (struct config_se typedef bool (*HPMHOOK_post_clif_stylist_read_db_libconfig_sub) (bool retVal___, struct config_setting_t *it, int idx, const char *source); typedef bool (*HPMHOOK_pre_clif_style_change_validate_requirements) (struct map_session_data **sd, int *type, int16 *idx); typedef bool (*HPMHOOK_post_clif_style_change_validate_requirements) (bool retVal___, struct map_session_data *sd, int type, int16 idx); -typedef void (*HPMHOOK_pre_clif_stylist_send_rodexitem) (struct map_session_data **sd, int16 *itemid); -typedef void (*HPMHOOK_post_clif_stylist_send_rodexitem) (struct map_session_data *sd, int16 itemid); +typedef void (*HPMHOOK_pre_clif_stylist_send_rodexitem) (struct map_session_data **sd, int *itemid); +typedef void (*HPMHOOK_post_clif_stylist_send_rodexitem) (struct map_session_data *sd, int itemid); typedef void (*HPMHOOK_pre_clif_pReqStyleChange) (int *fd, struct map_session_data **sd); typedef void (*HPMHOOK_post_clif_pReqStyleChange) (int fd, struct map_session_data *sd); typedef void (*HPMHOOK_pre_clif_cz_req_style_change_sub) (struct map_session_data **sd, int *type, int16 *idx, bool *isitem); typedef void (*HPMHOOK_post_clif_cz_req_style_change_sub) (struct map_session_data *sd, int type, int16 idx, bool isitem); typedef void (*HPMHOOK_pre_clif_style_change_response) (struct map_session_data **sd, enum stylist_shop *flag); typedef void (*HPMHOOK_post_clif_style_change_response) (struct map_session_data *sd, enum stylist_shop flag); +typedef void (*HPMHOOK_pre_clif_pPetEvolution) (int *fd, struct map_session_data **sd); +typedef void (*HPMHOOK_post_clif_pPetEvolution) (int fd, struct map_session_data *sd); +typedef void (*HPMHOOK_pre_clif_petEvolutionResult) (int *fd, enum pet_evolution_result *result); +typedef void (*HPMHOOK_post_clif_petEvolutionResult) (int fd, enum pet_evolution_result result); #endif // MAP_CLIF_H #ifdef COMMON_CORE_H /* cmdline */ typedef void (*HPMHOOK_pre_cmdline_init) (void); @@ -3012,6 +3028,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); @@ -3054,10 +3078,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, int *map_fd); +typedef bool (*HPMHOOK_post_inter_guild_add_member) (bool retVal___, int guild_id, const struct guild_member *member, int map_fd); +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); @@ -3066,6 +3118,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); @@ -3104,6 +3166,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); @@ -3122,6 +3194,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); @@ -3136,6 +3218,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); @@ -3158,12 +3248,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); @@ -3178,10 +3280,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, int *pet_egg_id, int *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, int pet_egg_id, int 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); @@ -3198,14 +3314,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); @@ -3218,12 +3336,14 @@ 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); typedef int (*HPMHOOK_post_intif_parse) (int retVal___, int fd); -typedef int (*HPMHOOK_pre_intif_create_pet) (int *account_id, int *char_id, short *pet_type, short *pet_lv, short *pet_egg_id, short *pet_equip, short *intimate, short *hungry, char *rename_flag, char *incubate, char **pet_name); -typedef int (*HPMHOOK_post_intif_create_pet) (int retVal___, int account_id, int char_id, short pet_type, short pet_lv, short pet_egg_id, short pet_equip, short intimate, short hungry, char rename_flag, char incubate, char *pet_name); +typedef int (*HPMHOOK_pre_intif_create_pet) (int *account_id, int *char_id, short *pet_type, short *pet_lv, int *pet_egg_id, int *pet_equip, short *intimate, short *hungry, char *rename_flag, char *incubate, char **pet_name); +typedef int (*HPMHOOK_post_intif_create_pet) (int retVal___, int account_id, int char_id, short pet_type, short pet_lv, int pet_egg_id, int pet_equip, short intimate, short hungry, char rename_flag, char incubate, char *pet_name); typedef int (*HPMHOOK_pre_intif_broadcast) (const char **mes, int *len, int *type); typedef int (*HPMHOOK_post_intif_broadcast) (int retVal___, const char *mes, int len, int type); typedef int (*HPMHOOK_pre_intif_broadcast2) (const char **mes, int *len, unsigned int *fontColor, short *fontType, short *fontSize, short *fontAlign, short *fontY); @@ -3608,8 +3728,8 @@ typedef struct item_data* (*HPMHOOK_pre_itemdb_search) (int *nameid); typedef struct item_data* (*HPMHOOK_post_itemdb_search) (struct item_data* retVal___, int nameid); typedef struct item_data* (*HPMHOOK_pre_itemdb_exists) (int *nameid); typedef struct item_data* (*HPMHOOK_post_itemdb_exists) (struct item_data* retVal___, int nameid); -typedef struct item_option* (*HPMHOOK_pre_itemdb_option_exists) (int *idx); -typedef struct item_option* (*HPMHOOK_post_itemdb_option_exists) (struct item_option* retVal___, int idx); +typedef struct itemdb_option* (*HPMHOOK_pre_itemdb_option_exists) (int *idx); +typedef struct itemdb_option* (*HPMHOOK_post_itemdb_option_exists) (struct itemdb_option* retVal___, int idx); typedef bool (*HPMHOOK_pre_itemdb_in_group) (struct item_group **group, int *nameid); typedef bool (*HPMHOOK_post_itemdb_in_group) (bool retVal___, struct item_group *group, int nameid); typedef int (*HPMHOOK_pre_itemdb_group_item) (struct item_group **group); @@ -3674,8 +3794,8 @@ typedef int (*HPMHOOK_pre_itemdb_gendercheck) (struct item_data **id); typedef int (*HPMHOOK_post_itemdb_gendercheck) (int retVal___, struct item_data *id); typedef int (*HPMHOOK_pre_itemdb_validate_entry) (struct item_data **entry, int *n, const char **source); typedef int (*HPMHOOK_post_itemdb_validate_entry) (int retVal___, struct item_data *entry, int n, const char *source); -typedef void (*HPMHOOK_pre_itemdb_readdb_options_additional_fields) (struct item_option **ito, struct config_setting_t **t, const char **source); -typedef void (*HPMHOOK_post_itemdb_readdb_options_additional_fields) (struct item_option *ito, struct config_setting_t *t, const char *source); +typedef void (*HPMHOOK_pre_itemdb_readdb_options_additional_fields) (struct itemdb_option **ito, struct config_setting_t **t, const char **source); +typedef void (*HPMHOOK_post_itemdb_readdb_options_additional_fields) (struct itemdb_option *ito, struct config_setting_t *t, const char *source); typedef void (*HPMHOOK_pre_itemdb_readdb_additional_fields) (int *itemid, struct config_setting_t **it, int *n, const char **source); typedef void (*HPMHOOK_post_itemdb_readdb_additional_fields) (int itemid, struct config_setting_t *it, int n, const char *source); typedef void (*HPMHOOK_pre_itemdb_readdb_job_sub) (struct item_data **id, struct config_setting_t **t); @@ -3696,8 +3816,8 @@ typedef int (*HPMHOOK_pre_itemdb_options_final_sub) (union DBKey *key, struct DB typedef int (*HPMHOOK_post_itemdb_options_final_sub) (int retVal___, union DBKey key, struct DBData *data, va_list ap); typedef void (*HPMHOOK_pre_itemdb_clear) (bool *total); typedef void (*HPMHOOK_post_itemdb_clear) (bool total); -typedef struct item_combo* (*HPMHOOK_pre_itemdb_id2combo) (unsigned short *id); -typedef struct item_combo* (*HPMHOOK_post_itemdb_id2combo) (struct item_combo* retVal___, unsigned short id); +typedef struct item_combo* (*HPMHOOK_pre_itemdb_id2combo) (int *id); +typedef struct item_combo* (*HPMHOOK_post_itemdb_id2combo) (struct item_combo* retVal___, int id); typedef bool (*HPMHOOK_pre_itemdb_is_item_usable) (struct item_data **item); typedef bool (*HPMHOOK_post_itemdb_is_item_usable) (bool retVal___, struct item_data *item); typedef bool (*HPMHOOK_pre_itemdb_lookup_const) (const struct config_setting_t **it, const char **name, int **value); @@ -4384,8 +4504,8 @@ typedef int (*HPMHOOK_pre_map_sql_close) (void); typedef int (*HPMHOOK_post_map_sql_close) (int retVal___); typedef bool (*HPMHOOK_pre_map_zone_mf_cache) (int *m, char **flag, char **params); typedef bool (*HPMHOOK_post_map_zone_mf_cache) (bool retVal___, int m, char *flag, char *params); -typedef unsigned short (*HPMHOOK_pre_map_zone_str2itemid) (const char **name); -typedef unsigned short (*HPMHOOK_post_map_zone_str2itemid) (unsigned short retVal___, const char *name); +typedef int (*HPMHOOK_pre_map_zone_str2itemid) (const char **name); +typedef int (*HPMHOOK_post_map_zone_str2itemid) (int retVal___, const char *name); typedef unsigned short (*HPMHOOK_pre_map_zone_str2skillid) (const char **name); typedef unsigned short (*HPMHOOK_post_map_zone_str2skillid) (unsigned short retVal___, const char *name); typedef enum bl_type (*HPMHOOK_pre_map_zone_bl_type) (const char **entry, enum map_zone_skill_subtype **subtype); @@ -4458,14 +4578,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); @@ -4536,8 +4648,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); @@ -4560,16 +4670,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); @@ -4588,8 +4688,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); @@ -4606,14 +4704,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); @@ -4674,10 +4764,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); @@ -4690,14 +4776,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); @@ -4706,22 +4784,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); @@ -4742,14 +4820,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); @@ -5112,6 +5186,12 @@ typedef void (*HPMHOOK_pre_mob_load) (bool *minimal); typedef void (*HPMHOOK_post_mob_load) (bool minimal); typedef void (*HPMHOOK_pre_mob_clear_spawninfo) (void); typedef void (*HPMHOOK_post_mob_clear_spawninfo) (void); +typedef struct item_drop_ratio* (*HPMHOOK_pre_mob_get_item_drop_ratio) (int *nameid); +typedef struct item_drop_ratio* (*HPMHOOK_post_mob_get_item_drop_ratio) (struct item_drop_ratio* retVal___, int nameid); +typedef void (*HPMHOOK_pre_mob_set_item_drop_ratio) (int *nameid, struct item_drop_ratio **ratio); +typedef void (*HPMHOOK_post_mob_set_item_drop_ratio) (int nameid, struct item_drop_ratio *ratio); +typedef int (*HPMHOOK_pre_mob_final_ratio_sub) (union DBKey *key, struct DBData **data, va_list ap); +typedef int (*HPMHOOK_post_mob_final_ratio_sub) (int retVal___, union DBKey key, struct DBData *data, va_list ap); typedef void (*HPMHOOK_pre_mob_destroy_mob_db) (int *index); typedef void (*HPMHOOK_post_mob_destroy_mob_db) (int index); typedef bool (*HPMHOOK_pre_mob_skill_db_libconfig) (const char **filename, bool *ignore_missing); @@ -5904,10 +5984,10 @@ typedef int (*HPMHOOK_pre_pc_inventory_rental_end) (int *tid, int64 *tick, int * typedef int (*HPMHOOK_post_pc_inventory_rental_end) (int retVal___, int tid, int64 tick, int id, intptr_t data); typedef void (*HPMHOOK_pre_pc_check_skilltree) (struct map_session_data **sd, int *skill_id); typedef void (*HPMHOOK_post_pc_check_skilltree) (struct map_session_data *sd, int skill_id); -typedef int (*HPMHOOK_pre_pc_bonus_autospell) (struct s_autospell **spell, int *max, short *id, short *lv, short *rate, short *flag, short *card_id); -typedef int (*HPMHOOK_post_pc_bonus_autospell) (int retVal___, struct s_autospell *spell, int max, short id, short lv, short rate, short flag, short card_id); -typedef int (*HPMHOOK_pre_pc_bonus_autospell_onskill) (struct s_autospell **spell, int *max, short *src_skill, short *id, short *lv, short *rate, short *card_id); -typedef int (*HPMHOOK_post_pc_bonus_autospell_onskill) (int retVal___, struct s_autospell *spell, int max, short src_skill, short id, short lv, short rate, short card_id); +typedef int (*HPMHOOK_pre_pc_bonus_autospell) (struct s_autospell **spell, int *max, short *id, short *lv, short *rate, short *flag, int *card_id); +typedef int (*HPMHOOK_post_pc_bonus_autospell) (int retVal___, struct s_autospell *spell, int max, short id, short lv, short rate, short flag, int card_id); +typedef int (*HPMHOOK_pre_pc_bonus_autospell_onskill) (struct s_autospell **spell, int *max, short *src_skill, short *id, short *lv, short *rate, int *card_id); +typedef int (*HPMHOOK_post_pc_bonus_autospell_onskill) (int retVal___, struct s_autospell *spell, int max, short src_skill, short id, short lv, short rate, int card_id); typedef int (*HPMHOOK_pre_pc_bonus_addeff) (struct s_addeffect **effect, int *max, enum sc_type *id, int16 *rate, int16 *arrow_rate, uint8 *flag, uint16 *duration); typedef int (*HPMHOOK_post_pc_bonus_addeff) (int retVal___, struct s_addeffect *effect, int max, enum sc_type id, int16 rate, int16 arrow_rate, uint8 flag, uint16 duration); typedef int (*HPMHOOK_pre_pc_bonus_addeff_onskill) (struct s_addeffectonskill **effect, int *max, enum sc_type *id, short *rate, short *skill_id, unsigned char *target); @@ -6006,6 +6086,8 @@ typedef bool (*HPMHOOK_pre_pc_check_basicskill) (struct map_session_data **sd, i typedef bool (*HPMHOOK_post_pc_check_basicskill) (bool retVal___, struct map_session_data *sd, int level); typedef bool (*HPMHOOK_pre_pc_isDeathPenaltyJob) (uint16 *job); typedef bool (*HPMHOOK_post_pc_isDeathPenaltyJob) (bool retVal___, uint16 job); +typedef bool (*HPMHOOK_pre_pc_has_second_costume) (struct map_session_data **sd); +typedef bool (*HPMHOOK_post_pc_has_second_costume) (bool retVal___, struct map_session_data *sd); #endif // MAP_PC_H #ifdef MAP_NPC_H /* libpcre */ typedef pcre* (*HPMHOOK_pre_libpcre_compile) (const char **pattern, int *options, const char ***errptr, int **erroffset, const unsigned char **tableptr); @@ -6060,8 +6142,8 @@ typedef int (*HPMHOOK_pre_pet_birth_process) (struct map_session_data **sd, stru typedef int (*HPMHOOK_post_pet_birth_process) (int retVal___, struct map_session_data *sd, struct s_pet *petinfo); typedef int (*HPMHOOK_pre_pet_recv_petdata) (int *account_id, struct s_pet **p, int *flag); typedef int (*HPMHOOK_post_pet_recv_petdata) (int retVal___, int account_id, struct s_pet *p, int flag); -typedef int (*HPMHOOK_pre_pet_select_egg) (struct map_session_data **sd, short *egg_index); -typedef int (*HPMHOOK_post_pet_select_egg) (int retVal___, struct map_session_data *sd, short egg_index); +typedef int (*HPMHOOK_pre_pet_select_egg) (struct map_session_data **sd, int *egg_index); +typedef int (*HPMHOOK_post_pet_select_egg) (int retVal___, struct map_session_data *sd, int egg_index); typedef int (*HPMHOOK_pre_pet_catch_process1) (struct map_session_data **sd, int *target_class); typedef int (*HPMHOOK_post_pet_catch_process1) (int retVal___, struct map_session_data *sd, int target_class); typedef int (*HPMHOOK_pre_pet_catch_process2) (struct map_session_data **sd, int *target_id); @@ -6110,6 +6192,8 @@ typedef bool (*HPMHOOK_pre_pet_read_db_sub_intimacy) (int *idx, struct config_se typedef bool (*HPMHOOK_post_pet_read_db_sub_intimacy) (bool retVal___, int idx, struct config_setting_t *t); typedef void (*HPMHOOK_pre_pet_read_db_clear) (void); typedef void (*HPMHOOK_post_pet_read_db_clear) (void); +typedef void (*HPMHOOK_pre_pet_read_db_sub_evolution) (struct config_setting_t **t, int *n); +typedef void (*HPMHOOK_post_pet_read_db_sub_evolution) (struct config_setting_t *t, int n); #endif // MAP_PET_H #ifdef CHAR_PINCODE_H /* pincode */ typedef void (*HPMHOOK_pre_pincode_handle) (int *fd, struct char_session_data **sd); @@ -6126,6 +6210,8 @@ typedef void (*HPMHOOK_pre_pincode_editstate) (int *fd, struct char_session_data typedef void (*HPMHOOK_post_pincode_editstate) (int fd, struct char_session_data *sd, enum pincode_edit_response state); typedef void (*HPMHOOK_pre_pincode_loginstate) (int *fd, struct char_session_data **sd, enum pincode_login_response *state); typedef void (*HPMHOOK_post_pincode_loginstate) (int fd, struct char_session_data *sd, enum pincode_login_response state); +typedef void (*HPMHOOK_pre_pincode_loginstate2) (int *fd, struct char_session_data **sd, enum pincode_login_response *state, enum pincode_login_response2 *flag); +typedef void (*HPMHOOK_post_pincode_loginstate2) (int fd, struct char_session_data *sd, enum pincode_login_response state, enum pincode_login_response2 flag); typedef void (*HPMHOOK_pre_pincode_setnew) (int *fd, struct char_session_data **sd); typedef void (*HPMHOOK_post_pincode_setnew) (int fd, struct char_session_data *sd); typedef void (*HPMHOOK_pre_pincode_change) (int *fd, struct char_session_data **sd); @@ -6174,6 +6260,30 @@ typedef int (*HPMHOOK_pre_quest_read_db) (void); typedef int (*HPMHOOK_post_quest_read_db) (int retVal___); typedef struct quest_db* (*HPMHOOK_pre_quest_read_db_sub) (struct config_setting_t **cs, int *n, const char **source); typedef struct quest_db* (*HPMHOOK_post_quest_read_db_sub) (struct quest_db* retVal___, struct config_setting_t *cs, int n, const char *source); +typedef int (*HPMHOOK_pre_quest_questinfo_validate_icon) (int *icon); +typedef int (*HPMHOOK_post_quest_questinfo_validate_icon) (int retVal___, int icon); +typedef void (*HPMHOOK_pre_quest_questinfo_refresh) (struct map_session_data **sd); +typedef void (*HPMHOOK_post_quest_questinfo_refresh) (struct map_session_data *sd); +typedef bool (*HPMHOOK_pre_quest_questinfo_validate) (struct map_session_data **sd, struct questinfo **qi); +typedef bool (*HPMHOOK_post_quest_questinfo_validate) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); +typedef bool (*HPMHOOK_pre_quest_questinfo_validate_job) (struct map_session_data **sd, struct questinfo **qi); +typedef bool (*HPMHOOK_post_quest_questinfo_validate_job) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); +typedef bool (*HPMHOOK_pre_quest_questinfo_validate_sex) (struct map_session_data **sd, struct questinfo **qi); +typedef bool (*HPMHOOK_post_quest_questinfo_validate_sex) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); +typedef bool (*HPMHOOK_pre_quest_questinfo_validate_baselevel) (struct map_session_data **sd, struct questinfo **qi); +typedef bool (*HPMHOOK_post_quest_questinfo_validate_baselevel) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); +typedef bool (*HPMHOOK_pre_quest_questinfo_validate_joblevel) (struct map_session_data **sd, struct questinfo **qi); +typedef bool (*HPMHOOK_post_quest_questinfo_validate_joblevel) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); +typedef bool (*HPMHOOK_pre_quest_questinfo_validate_items) (struct map_session_data **sd, struct questinfo **qi); +typedef bool (*HPMHOOK_post_quest_questinfo_validate_items) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); +typedef bool (*HPMHOOK_pre_quest_questinfo_validate_homunculus_level) (struct map_session_data **sd, struct questinfo **qi); +typedef bool (*HPMHOOK_post_quest_questinfo_validate_homunculus_level) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); +typedef bool (*HPMHOOK_pre_quest_questinfo_validate_homunculus_type) (struct map_session_data **sd, struct questinfo **qi); +typedef bool (*HPMHOOK_post_quest_questinfo_validate_homunculus_type) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); +typedef bool (*HPMHOOK_pre_quest_questinfo_validate_quests) (struct map_session_data **sd, struct questinfo **qi); +typedef bool (*HPMHOOK_post_quest_questinfo_validate_quests) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); +typedef void (*HPMHOOK_pre_quest_questinfo_vector_clear) (int *m); +typedef void (*HPMHOOK_post_quest_questinfo_vector_clear) (int m); #endif // MAP_QUEST_H #ifdef COMMON_RANDOM_H /* rnd */ typedef void (*HPMHOOK_pre_rnd_init) (void); @@ -6424,8 +6534,8 @@ typedef const char* (*HPMHOOK_pre_script_parse_expr) (const char **p); typedef const char* (*HPMHOOK_post_script_parse_expr) (const char* retVal___, const char *p); typedef const char* (*HPMHOOK_pre_script_parse_line) (const char **p); typedef const char* (*HPMHOOK_post_script_parse_line) (const char* retVal___, const char *p); -typedef void (*HPMHOOK_pre_script_read_constdb) (void); -typedef void (*HPMHOOK_post_script_read_constdb) (void); +typedef void (*HPMHOOK_pre_script_read_constdb) (bool *reload); +typedef void (*HPMHOOK_post_script_read_constdb) (bool reload); typedef void (*HPMHOOK_pre_script_constdb_comment) (const char **comment); typedef void (*HPMHOOK_post_script_constdb_comment) (const char *comment); typedef void (*HPMHOOK_pre_script_load_parameters) (void); @@ -6600,8 +6710,8 @@ typedef void (*HPMHOOK_post_script_run_item_unequip_script) (struct map_session_ #ifdef MAP_SEARCHSTORE_H /* searchstore */ typedef bool (*HPMHOOK_pre_searchstore_open) (struct map_session_data **sd, unsigned int *uses, unsigned short *effect); typedef bool (*HPMHOOK_post_searchstore_open) (bool retVal___, struct map_session_data *sd, unsigned int uses, unsigned short effect); -typedef void (*HPMHOOK_pre_searchstore_query) (struct map_session_data **sd, unsigned char *type, unsigned int *min_price, unsigned int *max_price, const unsigned short **itemlist, unsigned int *item_count, const unsigned short **cardlist, unsigned int *card_count); -typedef void (*HPMHOOK_post_searchstore_query) (struct map_session_data *sd, unsigned char type, unsigned int min_price, unsigned int max_price, const unsigned short *itemlist, unsigned int item_count, const unsigned short *cardlist, unsigned int card_count); +typedef void (*HPMHOOK_pre_searchstore_query) (struct map_session_data **sd, unsigned char *type, unsigned int *min_price, unsigned int *max_price, const uint32 **itemlist, unsigned int *item_count, const uint32 **cardlist, unsigned int *card_count); +typedef void (*HPMHOOK_post_searchstore_query) (struct map_session_data *sd, unsigned char type, unsigned int min_price, unsigned int max_price, const uint32 *itemlist, unsigned int item_count, const uint32 *cardlist, unsigned int card_count); typedef bool (*HPMHOOK_pre_searchstore_querynext) (struct map_session_data **sd); typedef bool (*HPMHOOK_post_searchstore_querynext) (bool retVal___, struct map_session_data *sd); typedef void (*HPMHOOK_pre_searchstore_next) (struct map_session_data **sd); @@ -6610,14 +6720,14 @@ typedef void (*HPMHOOK_pre_searchstore_clear) (struct map_session_data **sd); typedef void (*HPMHOOK_post_searchstore_clear) (struct map_session_data *sd); typedef void (*HPMHOOK_pre_searchstore_close) (struct map_session_data **sd); typedef void (*HPMHOOK_post_searchstore_close) (struct map_session_data *sd); -typedef void (*HPMHOOK_pre_searchstore_click) (struct map_session_data **sd, int *account_id, int *store_id, unsigned short *nameid); -typedef void (*HPMHOOK_post_searchstore_click) (struct map_session_data *sd, int account_id, int store_id, unsigned short nameid); +typedef void (*HPMHOOK_pre_searchstore_click) (struct map_session_data **sd, int *account_id, int *store_id, int *nameid); +typedef void (*HPMHOOK_post_searchstore_click) (struct map_session_data *sd, int account_id, int store_id, int nameid); typedef bool (*HPMHOOK_pre_searchstore_queryremote) (struct map_session_data **sd, int *account_id); typedef bool (*HPMHOOK_post_searchstore_queryremote) (bool retVal___, struct map_session_data *sd, int account_id); typedef void (*HPMHOOK_pre_searchstore_clearremote) (struct map_session_data **sd); typedef void (*HPMHOOK_post_searchstore_clearremote) (struct map_session_data *sd); -typedef bool (*HPMHOOK_pre_searchstore_result) (struct map_session_data **sd, unsigned int *store_id, int *account_id, const char **store_name, unsigned short *nameid, unsigned short *amount, unsigned int *price, const short **card, unsigned char *refine); -typedef bool (*HPMHOOK_post_searchstore_result) (bool retVal___, struct map_session_data *sd, unsigned int store_id, int account_id, const char *store_name, unsigned short nameid, unsigned short amount, unsigned int price, const short *card, unsigned char refine); +typedef bool (*HPMHOOK_pre_searchstore_result) (struct map_session_data **sd, unsigned int *store_id, int *account_id, const char **store_name, int *nameid, unsigned short *amount, unsigned int *price, const int **card, unsigned char *refine, const struct item_option **option); +typedef bool (*HPMHOOK_post_searchstore_result) (bool retVal___, struct map_session_data *sd, unsigned int store_id, int account_id, const char *store_name, int nameid, unsigned short amount, unsigned int price, const int *card, unsigned char refine, const struct item_option *option); #endif // MAP_SEARCHSTORE_H #ifdef COMMON_SHOWMSG_H /* showmsg */ typedef void (*HPMHOOK_pre_showmsg_init) (void); @@ -7102,8 +7212,8 @@ typedef int (*HPMHOOK_pre_skill_check_condition_castbegin_madogear_unknown) (str typedef int (*HPMHOOK_post_skill_check_condition_castbegin_madogear_unknown) (int retVal___, struct status_change *sc, uint16 *skill_id); typedef int (*HPMHOOK_pre_skill_check_condition_castbegin_unknown) (struct status_change **sc, uint16 **skill_id); typedef int (*HPMHOOK_post_skill_check_condition_castbegin_unknown) (int retVal___, struct status_change *sc, uint16 *skill_id); -typedef void (*HPMHOOK_pre_skill_check_condition_castend_unknown) (struct map_session_data **sd, uint16 **skill_id, uint16 **skill_lv); -typedef void (*HPMHOOK_post_skill_check_condition_castend_unknown) (struct map_session_data *sd, uint16 *skill_id, uint16 *skill_lv); +typedef bool (*HPMHOOK_pre_skill_check_condition_castend_unknown) (struct map_session_data **sd, uint16 **skill_id, uint16 **skill_lv); +typedef bool (*HPMHOOK_post_skill_check_condition_castend_unknown) (bool retVal___, struct map_session_data *sd, uint16 *skill_id, uint16 *skill_lv); typedef bool (*HPMHOOK_pre_skill_get_requirement_off_unknown) (struct status_change **sc, uint16 **skill_id); typedef bool (*HPMHOOK_post_skill_get_requirement_off_unknown) (bool retVal___, struct status_change *sc, uint16 *skill_id); typedef bool (*HPMHOOK_pre_skill_get_requirement_item_unknown) (struct status_change **sc, struct map_session_data **sd, uint16 **skill_id, uint16 **skill_lv, uint16 **idx, int **i); @@ -7814,8 +7924,8 @@ typedef void (*HPMHOOK_pre_vending_list) (struct map_session_data **sd, unsigned typedef void (*HPMHOOK_post_vending_list) (struct map_session_data *sd, unsigned int id); typedef void (*HPMHOOK_pre_vending_purchase) (struct map_session_data **sd, int *aid, unsigned int *uid, const uint8 **data, int *count); typedef void (*HPMHOOK_post_vending_purchase) (struct map_session_data *sd, int aid, unsigned int uid, const uint8 *data, int count); -typedef bool (*HPMHOOK_pre_vending_search) (struct map_session_data **sd, unsigned short *nameid); -typedef bool (*HPMHOOK_post_vending_search) (bool retVal___, struct map_session_data *sd, unsigned short nameid); +typedef bool (*HPMHOOK_pre_vending_search) (struct map_session_data **sd, int *nameid); +typedef bool (*HPMHOOK_post_vending_search) (bool retVal___, struct map_session_data *sd, int nameid); typedef bool (*HPMHOOK_pre_vending_searchall) (struct map_session_data **sd, const struct s_search_store_search **s); typedef bool (*HPMHOOK_post_vending_searchall) (bool retVal___, struct map_session_data *sd, const struct s_search_store_search *s); #endif // MAP_VENDING_H diff --git a/src/plugins/HPMHooking/HPMHooking_char.HPMHooksCore.inc b/src/plugins/HPMHooking/HPMHooking_char.HPMHooksCore.inc index be39bf2ea..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; @@ -1252,6 +1312,8 @@ struct { struct HPMHookPoint *HP_pincode_editstate_post; struct HPMHookPoint *HP_pincode_loginstate_pre; struct HPMHookPoint *HP_pincode_loginstate_post; + struct HPMHookPoint *HP_pincode_loginstate2_pre; + struct HPMHookPoint *HP_pincode_loginstate2_post; struct HPMHookPoint *HP_pincode_setnew_pre; struct HPMHookPoint *HP_pincode_setnew_post; struct HPMHookPoint *HP_pincode_change_pre; @@ -1615,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; @@ -2013,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; @@ -2053,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; @@ -2099,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; @@ -2115,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; @@ -2127,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; @@ -2153,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; @@ -2165,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; @@ -2181,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; @@ -2199,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; @@ -2405,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; @@ -2483,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; @@ -2507,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; @@ -2535,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; @@ -2553,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; @@ -2621,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; @@ -2637,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; @@ -2689,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; @@ -2789,6 +2911,8 @@ struct { int HP_pincode_editstate_post; int HP_pincode_loginstate_pre; int HP_pincode_loginstate_post; + int HP_pincode_loginstate2_pre; + int HP_pincode_loginstate2_post; int HP_pincode_setnew_pre; int HP_pincode_setnew_post; int HP_pincode_change_pre; diff --git a/src/plugins/HPMHooking/HPMHooking_char.HookingPoints.inc b/src/plugins/HPMHooking/HPMHooking_char.HookingPoints.inc index 3ba47102c..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) }, @@ -668,6 +698,7 @@ struct HookingPointData HookingPoints[] = { { HP_POP(pincode->makestate, HP_pincode_makestate) }, { HP_POP(pincode->editstate, HP_pincode_editstate) }, { HP_POP(pincode->loginstate, HP_pincode_loginstate) }, + { HP_POP(pincode->loginstate2, HP_pincode_loginstate2) }, { HP_POP(pincode->setnew, HP_pincode_setnew) }, { HP_POP(pincode->change, HP_pincode_change) }, { HP_POP(pincode->isBlacklisted, HP_pincode_isBlacklisted) }, diff --git a/src/plugins/HPMHooking/HPMHooking_char.Hooks.inc b/src/plugins/HPMHooking/HPMHooking_char.Hooks.inc index a15eccc0c..831c9da63 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); @@ -3182,14 +3209,14 @@ void HP_chr_parse_char_connect(int fd, struct char_session_data *sd, uint32 ipl) } return; } -void HP_chr_send_map_info(int fd, int i, uint32 subnet_map_ip, struct mmo_charstatus *cd) { +void HP_chr_send_map_info(int fd, int i, uint32 subnet_map_ip, struct mmo_charstatus *cd, char *dnsHost) { int hIndex = 0; if (HPMHooks.count.HP_chr_send_map_info_pre > 0) { - void (*preHookFunc) (int *fd, int *i, uint32 *subnet_map_ip, struct mmo_charstatus **cd); + void (*preHookFunc) (int *fd, int *i, uint32 *subnet_map_ip, struct mmo_charstatus **cd, char **dnsHost); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_chr_send_map_info_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_chr_send_map_info_pre[hIndex].func; - preHookFunc(&fd, &i, &subnet_map_ip, &cd); + preHookFunc(&fd, &i, &subnet_map_ip, &cd, &dnsHost); } if (*HPMforce_return) { *HPMforce_return = false; @@ -3197,13 +3224,13 @@ void HP_chr_send_map_info(int fd, int i, uint32 subnet_map_ip, struct mmo_charst } } { - HPMHooks.source.chr.send_map_info(fd, i, subnet_map_ip, cd); + HPMHooks.source.chr.send_map_info(fd, i, subnet_map_ip, cd, dnsHost); } if (HPMHooks.count.HP_chr_send_map_info_post > 0) { - void (*postHookFunc) (int fd, int i, uint32 subnet_map_ip, struct mmo_charstatus *cd); + void (*postHookFunc) (int fd, int i, uint32 subnet_map_ip, struct mmo_charstatus *cd, char *dnsHost); for (hIndex = 0; hIndex < HPMHooks.count.HP_chr_send_map_info_post; hIndex++) { postHookFunc = HPMHooks.list.HP_chr_send_map_info_post[hIndex].func; - postHookFunc(fd, i, subnet_map_ip, cd); + postHookFunc(fd, i, subnet_map_ip, cd, dnsHost); } } return; @@ -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,15 +6696,96 @@ 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 HP_inter_guild_broken(int guild_id) { int hIndex = 0; int retVal___ = 0; + if (HPMHooks.count.HP_inter_guild_broken_pre > 0) { + int (*preHookFunc) (int *guild_id); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_broken_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_broken_pre[hIndex].func; + retVal___ = preHookFunc(&guild_id); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_guild.broken(guild_id); + } + if (HPMHooks.count.HP_inter_guild_broken_post > 0) { + int (*postHookFunc) (int retVal___, int guild_id); + for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_broken_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_inter_guild_broken_post[hIndex].func; + retVal___ = postHookFunc(retVal___, guild_id); + } + } + return retVal___; +} +struct guild* HP_inter_guild_create(const char *name, const struct guild_member *master) { + int hIndex = 0; + 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_guild_create_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_create_pre[hIndex].func; + retVal___ = preHookFunc(&name, &master); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_guild.create(name, master); + } + 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___; +} +bool HP_inter_guild_add_member(int guild_id, const struct guild_member *member, int map_fd) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_inter_guild_add_member_pre > 0) { + bool (*preHookFunc) (int *guild_id, const struct guild_member **member, int *map_fd); + *HPMforce_return = false; + 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, &map_fd); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_guild.add_member(guild_id, member, map_fd); + } + if (HPMHooks.count.HP_inter_guild_add_member_post > 0) { + bool (*postHookFunc) (bool retVal___, int guild_id, const struct guild_member *member, int map_fd); + 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, map_fd); + } + } + return retVal___; +} +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; + bool retVal___ = false; if (HPMHooks.count.HP_inter_guild_leave_pre > 0) { - int (*preHookFunc) (int *guild_id, int *account_id, int *char_id); + 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_guild_leave_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_inter_guild_leave_pre[hIndex].func; - retVal___ = preHookFunc(&guild_id, &account_id, &char_id); + retVal___ = preHookFunc(&guild_id, &account_id, &char_id, &flag, &mes, &map_fd); } if (*HPMforce_return) { *HPMforce_return = false; @@ -6577,25 +6793,79 @@ int HP_inter_guild_leave(int guild_id, int account_id, int char_id) { } } { - retVal___ = HPMHooks.source.inter_guild.leave(guild_id, account_id, char_id); + retVal___ = HPMHooks.source.inter_guild.leave(guild_id, account_id, char_id, flag, mes, map_fd); } if (HPMHooks.count.HP_inter_guild_leave_post > 0) { - int (*postHookFunc) (int retVal___, int guild_id, int account_id, int char_id); + 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); + retVal___ = postHookFunc(retVal___, guild_id, account_id, char_id, flag, mes, map_fd); } } return retVal___; } -int HP_inter_guild_broken(int guild_id) { +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; - int retVal___ = 0; - if (HPMHooks.count.HP_inter_guild_broken_pre > 0) { - int (*preHookFunc) (int *guild_id); + 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_guild_broken_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_inter_guild_broken_pre[hIndex].func; + 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; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_guild.update_member_info_short(guild_id, account_id, char_id, online, lv, class); + } + 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_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_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_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; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_guild.update_member_info(guild_id, account_id, char_id, type, data, len); + } + 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___; +} +bool HP_inter_guild_disband(int guild_id) { + int hIndex = 0; + 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_guild_disband_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_inter_guild_disband_pre[hIndex].func; retVal___ = preHookFunc(&guild_id); } if (*HPMforce_return) { @@ -6604,17 +6874,260 @@ int HP_inter_guild_broken(int guild_id) { } } { - retVal___ = HPMHooks.source.inter_guild.broken(guild_id); + retVal___ = HPMHooks.source.inter_guild.disband(guild_id); } - if (HPMHooks.count.HP_inter_guild_broken_post > 0) { - int (*postHookFunc) (int retVal___, int guild_id); - for (hIndex = 0; hIndex < HPMHooks.count.HP_inter_guild_broken_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_inter_guild_broken_post[hIndex].func; + 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 retVal___; } +bool HP_inter_guild_update_basic_info(int guild_id, int type, const void *data, int len) { + int hIndex = 0; + 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_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; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_guild.update_basic_info(guild_id, type, data, len); + } + 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___; +} +bool HP_inter_guild_update_position(int guild_id, int idx, const struct guild_position *p) { + int hIndex = 0; + 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_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 retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_guild.update_position(guild_id, idx, p); + } + 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 retVal___; +} +bool HP_inter_guild_use_skill_point(int guild_id, uint16 skill_id, int account_id, int max) { + int hIndex = 0; + 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; @@ -6696,6 +7209,141 @@ int HP_inter_homunculus_parse_frommap(int 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; @@ -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; @@ -7412,6 +8192,141 @@ void HP_inter_mail_sendmail(int send_id, const char *send_name, int dest_id, con } return; } +bool HP_inter_mail_mark_read(int mail_id) { + int hIndex = 0; + 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_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; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_mail.mark_read(mail_id); + } + 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___; +} +bool HP_inter_mail_get_attachment(int char_id, int mail_id, struct mail_message *msg) { + int hIndex = 0; + 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_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; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_mail.get_attachment(char_id, mail_id, 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_delete(int char_id, int mail_id) { + int hIndex = 0; + bool retVal___ = false; + 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_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; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_mail.delete(char_id, mail_id); + } + 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_return_message(int char_id, int mail_id, int *new_mail) { + int hIndex = 0; + bool retVal___ = false; + 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_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; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_mail.return_message(char_id, mail_id, new_mail); + } + 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___; +} +bool HP_inter_mail_send(int account_id, struct mail_message *msg) { + int hIndex = 0; + 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_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 retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_mail.send(account_id, msg); + } + 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 retVal___; +} /* inter_mercenary_interface */ bool HP_inter_mercenary_owner_fromsql(int char_id, struct mmo_charstatus *status) { int hIndex = 0; @@ -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); @@ -7924,6 +8947,168 @@ int HP_inter_party_CharOffline(int char_id, int 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_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; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.inter_party.change_leader(party_id, account_id, char_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___; +} /* inter_pet_interface */ int HP_inter_pet_tosql(const struct s_pet *p) { int hIndex = 0; @@ -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, int pet_egg_id, int 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, int *pet_egg_id, int *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, int pet_egg_id, int 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; @@ -11288,114 +12716,6 @@ void HP_mapif_parse_auction_bid(int 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); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.elemental_load(ele_id, char_id, ele); - } - 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); - } - } - return retVal___; -} -bool HP_mapif_elemental_delete(int ele_id) { - int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_elemental_delete_pre > 0) { - bool (*preHookFunc) (int *ele_id); - *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); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.elemental_delete(ele_id); - } - 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); - } - } - return retVal___; -} void HP_mapif_elemental_send(int fd, struct s_elemental *ele, unsigned char flag) { int hIndex = 0; if (HPMHooks.count.HP_mapif_elemental_send_pre > 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) { @@ -13256,114 +14388,6 @@ void HP_mapif_parse_mail_send(int 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); - } - } - return retVal___; -} -bool HP_mapif_mercenary_load(int merc_id, int char_id, struct s_mercenary *merc) { - 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); - *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); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.mercenary_load(merc_id, char_id, merc); - } - 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); - } - } - return retVal___; -} -bool HP_mapif_mercenary_delete(int merc_id) { - int hIndex = 0; - bool retVal___ = false; - if (HPMHooks.count.HP_mapif_mercenary_delete_pre > 0) { - bool (*preHookFunc) (int *merc_id); - *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); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return retVal___; - } - } - { - retVal___ = HPMHooks.source.mapif.mercenary_delete(merc_id); - } - 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); - } - } - return retVal___; -} void HP_mapif_mercenary_send(int fd, struct s_mercenary *merc, unsigned char flag) { int hIndex = 0; if (HPMHooks.count.HP_mapif_mercenary_send_pre > 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; @@ -16405,6 +17209,32 @@ void HP_pincode_loginstate(int fd, struct char_session_data *sd, enum pincode_lo } return; } +void HP_pincode_loginstate2(int fd, struct char_session_data *sd, enum pincode_login_response state, enum pincode_login_response2 flag) { + int hIndex = 0; + if (HPMHooks.count.HP_pincode_loginstate2_pre > 0) { + void (*preHookFunc) (int *fd, struct char_session_data **sd, enum pincode_login_response *state, enum pincode_login_response2 *flag); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_pincode_loginstate2_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_pincode_loginstate2_pre[hIndex].func; + preHookFunc(&fd, &sd, &state, &flag); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.pincode.loginstate2(fd, sd, state, flag); + } + if (HPMHooks.count.HP_pincode_loginstate2_post > 0) { + void (*postHookFunc) (int fd, struct char_session_data *sd, enum pincode_login_response state, enum pincode_login_response2 flag); + for (hIndex = 0; hIndex < HPMHooks.count.HP_pincode_loginstate2_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_pincode_loginstate2_post[hIndex].func; + postHookFunc(fd, sd, state, flag); + } + } + return; +} void HP_pincode_setnew(int fd, struct char_session_data *sd) { int hIndex = 0; if (HPMHooks.count.HP_pincode_setnew_pre > 0) { diff --git a/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc b/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc index d17955db7..6ab215bfc 100644 --- a/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc +++ b/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc @@ -584,6 +584,8 @@ struct { struct HPMHookPoint *HP_clif_decrypt_cmd_post; struct HPMHookPoint *HP_clif_authok_pre; struct HPMHookPoint *HP_clif_authok_post; + struct HPMHookPoint *HP_clif_auth_error_pre; + struct HPMHookPoint *HP_clif_auth_error_post; struct HPMHookPoint *HP_clif_authrefuse_pre; struct HPMHookPoint *HP_clif_authrefuse_post; struct HPMHookPoint *HP_clif_authfail_fd_pre; @@ -624,8 +626,6 @@ struct { struct HPMHookPoint *HP_clif_useitemack_post; struct HPMHookPoint *HP_clif_addcards_pre; struct HPMHookPoint *HP_clif_addcards_post; - struct HPMHookPoint *HP_clif_addcards2_pre; - struct HPMHookPoint *HP_clif_addcards2_post; struct HPMHookPoint *HP_clif_item_sub_pre; struct HPMHookPoint *HP_clif_item_sub_post; struct HPMHookPoint *HP_clif_getareachar_item_pre; @@ -634,6 +634,8 @@ struct { struct HPMHookPoint *HP_clif_cart_additem_ack_post; struct HPMHookPoint *HP_clif_cashshop_load_pre; struct HPMHookPoint *HP_clif_cashshop_load_post; + struct HPMHookPoint *HP_clif_cashShopSchedule_pre; + struct HPMHookPoint *HP_clif_cashShopSchedule_post; struct HPMHookPoint *HP_clif_package_announce_pre; struct HPMHookPoint *HP_clif_package_announce_post; struct HPMHookPoint *HP_clif_item_drop_announce_pre; @@ -698,6 +700,8 @@ struct { struct HPMHookPoint *HP_clif_spawn_post; struct HPMHookPoint *HP_clif_changemap_pre; struct HPMHookPoint *HP_clif_changemap_post; + struct HPMHookPoint *HP_clif_changemap_airship_pre; + struct HPMHookPoint *HP_clif_changemap_airship_post; struct HPMHookPoint *HP_clif_changemapcell_pre; struct HPMHookPoint *HP_clif_changemapcell_post; struct HPMHookPoint *HP_clif_map_property_pre; @@ -714,6 +718,8 @@ struct { struct HPMHookPoint *HP_clif_maptypeproperty2_post; struct HPMHookPoint *HP_clif_changemapserver_pre; struct HPMHookPoint *HP_clif_changemapserver_post; + struct HPMHookPoint *HP_clif_changemapserver_airship_pre; + struct HPMHookPoint *HP_clif_changemapserver_airship_post; struct HPMHookPoint *HP_clif_npcbuysell_pre; struct HPMHookPoint *HP_clif_npcbuysell_post; struct HPMHookPoint *HP_clif_buylist_pre; @@ -1038,6 +1044,8 @@ struct { struct HPMHookPoint *HP_clif_messagecolor_post; struct HPMHookPoint *HP_clif_disp_overhead_pre; struct HPMHookPoint *HP_clif_disp_overhead_post; + struct HPMHookPoint *HP_clif_notify_playerchat_pre; + struct HPMHookPoint *HP_clif_notify_playerchat_post; struct HPMHookPoint *HP_clif_msgtable_pre; struct HPMHookPoint *HP_clif_msgtable_post; struct HPMHookPoint *HP_clif_msgtable_num_pre; @@ -1092,6 +1100,8 @@ struct { struct HPMHookPoint *HP_clif_buyvending_post; struct HPMHookPoint *HP_clif_openvending_pre; struct HPMHookPoint *HP_clif_openvending_post; + struct HPMHookPoint *HP_clif_openvendingAck_pre; + struct HPMHookPoint *HP_clif_openvendingAck_post; struct HPMHookPoint *HP_clif_vendingreport_pre; struct HPMHookPoint *HP_clif_vendingreport_post; struct HPMHookPoint *HP_clif_storagelist_pre; @@ -2046,6 +2056,10 @@ struct { struct HPMHookPoint *HP_clif_cz_req_style_change_sub_post; struct HPMHookPoint *HP_clif_style_change_response_pre; struct HPMHookPoint *HP_clif_style_change_response_post; + struct HPMHookPoint *HP_clif_pPetEvolution_pre; + struct HPMHookPoint *HP_clif_pPetEvolution_post; + struct HPMHookPoint *HP_clif_petEvolutionResult_pre; + struct HPMHookPoint *HP_clif_petEvolutionResult_post; struct HPMHookPoint *HP_cmdline_init_pre; struct HPMHookPoint *HP_cmdline_init_post; struct HPMHookPoint *HP_cmdline_final_pre; @@ -3784,6 +3798,12 @@ struct { struct HPMHookPoint *HP_mob_load_post; struct HPMHookPoint *HP_mob_clear_spawninfo_pre; struct HPMHookPoint *HP_mob_clear_spawninfo_post; + struct HPMHookPoint *HP_mob_get_item_drop_ratio_pre; + struct HPMHookPoint *HP_mob_get_item_drop_ratio_post; + struct HPMHookPoint *HP_mob_set_item_drop_ratio_pre; + struct HPMHookPoint *HP_mob_set_item_drop_ratio_post; + struct HPMHookPoint *HP_mob_final_ratio_sub_pre; + struct HPMHookPoint *HP_mob_final_ratio_sub_post; struct HPMHookPoint *HP_mob_destroy_mob_db_pre; struct HPMHookPoint *HP_mob_destroy_mob_db_post; struct HPMHookPoint *HP_mob_skill_db_libconfig_pre; @@ -4662,6 +4682,8 @@ struct { struct HPMHookPoint *HP_pc_check_basicskill_post; struct HPMHookPoint *HP_pc_isDeathPenaltyJob_pre; struct HPMHookPoint *HP_pc_isDeathPenaltyJob_post; + struct HPMHookPoint *HP_pc_has_second_costume_pre; + struct HPMHookPoint *HP_pc_has_second_costume_post; struct HPMHookPoint *HP_libpcre_compile_pre; struct HPMHookPoint *HP_libpcre_compile_post; struct HPMHookPoint *HP_libpcre_study_pre; @@ -4762,6 +4784,8 @@ struct { struct HPMHookPoint *HP_pet_read_db_sub_intimacy_post; struct HPMHookPoint *HP_pet_read_db_clear_pre; struct HPMHookPoint *HP_pet_read_db_clear_post; + struct HPMHookPoint *HP_pet_read_db_sub_evolution_pre; + struct HPMHookPoint *HP_pet_read_db_sub_evolution_post; struct HPMHookPoint *HP_quest_init_pre; struct HPMHookPoint *HP_quest_init_post; struct HPMHookPoint *HP_quest_final_pre; @@ -4792,6 +4816,30 @@ struct { struct HPMHookPoint *HP_quest_read_db_post; struct HPMHookPoint *HP_quest_read_db_sub_pre; struct HPMHookPoint *HP_quest_read_db_sub_post; + struct HPMHookPoint *HP_quest_questinfo_validate_icon_pre; + struct HPMHookPoint *HP_quest_questinfo_validate_icon_post; + struct HPMHookPoint *HP_quest_questinfo_refresh_pre; + struct HPMHookPoint *HP_quest_questinfo_refresh_post; + struct HPMHookPoint *HP_quest_questinfo_validate_pre; + struct HPMHookPoint *HP_quest_questinfo_validate_post; + struct HPMHookPoint *HP_quest_questinfo_validate_job_pre; + struct HPMHookPoint *HP_quest_questinfo_validate_job_post; + struct HPMHookPoint *HP_quest_questinfo_validate_sex_pre; + struct HPMHookPoint *HP_quest_questinfo_validate_sex_post; + struct HPMHookPoint *HP_quest_questinfo_validate_baselevel_pre; + struct HPMHookPoint *HP_quest_questinfo_validate_baselevel_post; + struct HPMHookPoint *HP_quest_questinfo_validate_joblevel_pre; + struct HPMHookPoint *HP_quest_questinfo_validate_joblevel_post; + struct HPMHookPoint *HP_quest_questinfo_validate_items_pre; + struct HPMHookPoint *HP_quest_questinfo_validate_items_post; + struct HPMHookPoint *HP_quest_questinfo_validate_homunculus_level_pre; + struct HPMHookPoint *HP_quest_questinfo_validate_homunculus_level_post; + struct HPMHookPoint *HP_quest_questinfo_validate_homunculus_type_pre; + struct HPMHookPoint *HP_quest_questinfo_validate_homunculus_type_post; + struct HPMHookPoint *HP_quest_questinfo_validate_quests_pre; + struct HPMHookPoint *HP_quest_questinfo_validate_quests_post; + struct HPMHookPoint *HP_quest_questinfo_vector_clear_pre; + struct HPMHookPoint *HP_quest_questinfo_vector_clear_post; struct HPMHookPoint *HP_rnd_init_pre; struct HPMHookPoint *HP_rnd_init_post; struct HPMHookPoint *HP_rnd_final_pre; @@ -6959,6 +7007,8 @@ struct { int HP_clif_decrypt_cmd_post; int HP_clif_authok_pre; int HP_clif_authok_post; + int HP_clif_auth_error_pre; + int HP_clif_auth_error_post; int HP_clif_authrefuse_pre; int HP_clif_authrefuse_post; int HP_clif_authfail_fd_pre; @@ -6999,8 +7049,6 @@ struct { int HP_clif_useitemack_post; int HP_clif_addcards_pre; int HP_clif_addcards_post; - int HP_clif_addcards2_pre; - int HP_clif_addcards2_post; int HP_clif_item_sub_pre; int HP_clif_item_sub_post; int HP_clif_getareachar_item_pre; @@ -7009,6 +7057,8 @@ struct { int HP_clif_cart_additem_ack_post; int HP_clif_cashshop_load_pre; int HP_clif_cashshop_load_post; + int HP_clif_cashShopSchedule_pre; + int HP_clif_cashShopSchedule_post; int HP_clif_package_announce_pre; int HP_clif_package_announce_post; int HP_clif_item_drop_announce_pre; @@ -7073,6 +7123,8 @@ struct { int HP_clif_spawn_post; int HP_clif_changemap_pre; int HP_clif_changemap_post; + int HP_clif_changemap_airship_pre; + int HP_clif_changemap_airship_post; int HP_clif_changemapcell_pre; int HP_clif_changemapcell_post; int HP_clif_map_property_pre; @@ -7089,6 +7141,8 @@ struct { int HP_clif_maptypeproperty2_post; int HP_clif_changemapserver_pre; int HP_clif_changemapserver_post; + int HP_clif_changemapserver_airship_pre; + int HP_clif_changemapserver_airship_post; int HP_clif_npcbuysell_pre; int HP_clif_npcbuysell_post; int HP_clif_buylist_pre; @@ -7413,6 +7467,8 @@ struct { int HP_clif_messagecolor_post; int HP_clif_disp_overhead_pre; int HP_clif_disp_overhead_post; + int HP_clif_notify_playerchat_pre; + int HP_clif_notify_playerchat_post; int HP_clif_msgtable_pre; int HP_clif_msgtable_post; int HP_clif_msgtable_num_pre; @@ -7467,6 +7523,8 @@ struct { int HP_clif_buyvending_post; int HP_clif_openvending_pre; int HP_clif_openvending_post; + int HP_clif_openvendingAck_pre; + int HP_clif_openvendingAck_post; int HP_clif_vendingreport_pre; int HP_clif_vendingreport_post; int HP_clif_storagelist_pre; @@ -8421,6 +8479,10 @@ struct { int HP_clif_cz_req_style_change_sub_post; int HP_clif_style_change_response_pre; int HP_clif_style_change_response_post; + int HP_clif_pPetEvolution_pre; + int HP_clif_pPetEvolution_post; + int HP_clif_petEvolutionResult_pre; + int HP_clif_petEvolutionResult_post; int HP_cmdline_init_pre; int HP_cmdline_init_post; int HP_cmdline_final_pre; @@ -10159,6 +10221,12 @@ struct { int HP_mob_load_post; int HP_mob_clear_spawninfo_pre; int HP_mob_clear_spawninfo_post; + int HP_mob_get_item_drop_ratio_pre; + int HP_mob_get_item_drop_ratio_post; + int HP_mob_set_item_drop_ratio_pre; + int HP_mob_set_item_drop_ratio_post; + int HP_mob_final_ratio_sub_pre; + int HP_mob_final_ratio_sub_post; int HP_mob_destroy_mob_db_pre; int HP_mob_destroy_mob_db_post; int HP_mob_skill_db_libconfig_pre; @@ -11037,6 +11105,8 @@ struct { int HP_pc_check_basicskill_post; int HP_pc_isDeathPenaltyJob_pre; int HP_pc_isDeathPenaltyJob_post; + int HP_pc_has_second_costume_pre; + int HP_pc_has_second_costume_post; int HP_libpcre_compile_pre; int HP_libpcre_compile_post; int HP_libpcre_study_pre; @@ -11137,6 +11207,8 @@ struct { int HP_pet_read_db_sub_intimacy_post; int HP_pet_read_db_clear_pre; int HP_pet_read_db_clear_post; + int HP_pet_read_db_sub_evolution_pre; + int HP_pet_read_db_sub_evolution_post; int HP_quest_init_pre; int HP_quest_init_post; int HP_quest_final_pre; @@ -11167,6 +11239,30 @@ struct { int HP_quest_read_db_post; int HP_quest_read_db_sub_pre; int HP_quest_read_db_sub_post; + int HP_quest_questinfo_validate_icon_pre; + int HP_quest_questinfo_validate_icon_post; + int HP_quest_questinfo_refresh_pre; + int HP_quest_questinfo_refresh_post; + int HP_quest_questinfo_validate_pre; + int HP_quest_questinfo_validate_post; + int HP_quest_questinfo_validate_job_pre; + int HP_quest_questinfo_validate_job_post; + int HP_quest_questinfo_validate_sex_pre; + int HP_quest_questinfo_validate_sex_post; + int HP_quest_questinfo_validate_baselevel_pre; + int HP_quest_questinfo_validate_baselevel_post; + int HP_quest_questinfo_validate_joblevel_pre; + int HP_quest_questinfo_validate_joblevel_post; + int HP_quest_questinfo_validate_items_pre; + int HP_quest_questinfo_validate_items_post; + int HP_quest_questinfo_validate_homunculus_level_pre; + int HP_quest_questinfo_validate_homunculus_level_post; + int HP_quest_questinfo_validate_homunculus_type_pre; + int HP_quest_questinfo_validate_homunculus_type_post; + int HP_quest_questinfo_validate_quests_pre; + int HP_quest_questinfo_validate_quests_post; + int HP_quest_questinfo_vector_clear_pre; + int HP_quest_questinfo_vector_clear_post; int HP_rnd_init_pre; int HP_rnd_init_post; int HP_rnd_final_pre; diff --git a/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc b/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc index c9463b1b8..43c9c8e6d 100644 --- a/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc +++ b/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc @@ -315,6 +315,7 @@ struct HookingPointData HookingPoints[] = { { HP_POP(clif->parse_cmd, HP_clif_parse_cmd) }, { HP_POP(clif->decrypt_cmd, HP_clif_decrypt_cmd) }, { HP_POP(clif->authok, HP_clif_authok) }, + { HP_POP(clif->auth_error, HP_clif_auth_error) }, { HP_POP(clif->authrefuse, HP_clif_authrefuse) }, { HP_POP(clif->authfail_fd, HP_clif_authfail_fd) }, { HP_POP(clif->charselectok, HP_clif_charselectok) }, @@ -335,11 +336,11 @@ struct HookingPointData HookingPoints[] = { { HP_POP(clif->unequipitemack, HP_clif_unequipitemack) }, { HP_POP(clif->useitemack, HP_clif_useitemack) }, { HP_POP(clif->addcards, HP_clif_addcards) }, - { HP_POP(clif->addcards2, HP_clif_addcards2) }, { HP_POP(clif->item_sub, HP_clif_item_sub) }, { HP_POP(clif->getareachar_item, HP_clif_getareachar_item) }, { HP_POP(clif->cart_additem_ack, HP_clif_cart_additem_ack) }, { HP_POP(clif->cashshop_load, HP_clif_cashshop_load) }, + { HP_POP(clif->cashShopSchedule, HP_clif_cashShopSchedule) }, { HP_POP(clif->package_announce, HP_clif_package_announce) }, { HP_POP(clif->item_drop_announce, HP_clif_item_drop_announce) }, { HP_POP(clif->clearunit_single, HP_clif_clearunit_single) }, @@ -372,6 +373,7 @@ struct HookingPointData HookingPoints[] = { { HP_POP(clif->graffiti_entry, HP_clif_graffiti_entry) }, { HP_POP(clif->spawn, HP_clif_spawn) }, { HP_POP(clif->changemap, HP_clif_changemap) }, + { HP_POP(clif->changemap_airship, HP_clif_changemap_airship) }, { HP_POP(clif->changemapcell, HP_clif_changemapcell) }, { HP_POP(clif->map_property, HP_clif_map_property) }, { HP_POP(clif->pvpset, HP_clif_pvpset) }, @@ -380,6 +382,7 @@ struct HookingPointData HookingPoints[] = { { HP_POP(clif->map_type, HP_clif_map_type) }, { HP_POP(clif->maptypeproperty2, HP_clif_maptypeproperty2) }, { HP_POP(clif->changemapserver, HP_clif_changemapserver) }, + { HP_POP(clif->changemapserver_airship, HP_clif_changemapserver_airship) }, { HP_POP(clif->npcbuysell, HP_clif_npcbuysell) }, { HP_POP(clif->buylist, HP_clif_buylist) }, { HP_POP(clif->selllist, HP_clif_selllist) }, @@ -542,6 +545,7 @@ struct HookingPointData HookingPoints[] = { { HP_POP(clif->messagecolor_self, HP_clif_messagecolor_self) }, { HP_POP(clif->messagecolor, HP_clif_messagecolor) }, { HP_POP(clif->disp_overhead, HP_clif_disp_overhead) }, + { HP_POP(clif->notify_playerchat, HP_clif_notify_playerchat) }, { HP_POP(clif->msgtable, HP_clif_msgtable) }, { HP_POP(clif->msgtable_num, HP_clif_msgtable_num) }, { HP_POP(clif->msgtable_skill, HP_clif_msgtable_skill) }, @@ -569,6 +573,7 @@ struct HookingPointData HookingPoints[] = { { HP_POP(clif->vendinglist, HP_clif_vendinglist) }, { HP_POP(clif->buyvending, HP_clif_buyvending) }, { HP_POP(clif->openvending, HP_clif_openvending) }, + { HP_POP(clif->openvendingAck, HP_clif_openvendingAck) }, { HP_POP(clif->vendingreport, HP_clif_vendingreport) }, { HP_POP(clif->storagelist, HP_clif_storagelist) }, { HP_POP(clif->updatestorageamount, HP_clif_updatestorageamount) }, @@ -1046,6 +1051,8 @@ struct HookingPointData HookingPoints[] = { { HP_POP(clif->pReqStyleChange, HP_clif_pReqStyleChange) }, { HP_POP(clif->cz_req_style_change_sub, HP_clif_cz_req_style_change_sub) }, { HP_POP(clif->style_change_response, HP_clif_style_change_response) }, + { HP_POP(clif->pPetEvolution, HP_clif_pPetEvolution) }, + { HP_POP(clif->petEvolutionResult, HP_clif_petEvolutionResult) }, /* cmdline_interface */ { HP_POP(cmdline->init, HP_cmdline_init) }, { HP_POP(cmdline->final, HP_cmdline_final) }, @@ -1940,6 +1947,9 @@ struct HookingPointData HookingPoints[] = { { HP_POP(mob->readdb_itemratio, HP_mob_readdb_itemratio) }, { HP_POP(mob->load, HP_mob_load) }, { HP_POP(mob->clear_spawninfo, HP_mob_clear_spawninfo) }, + { HP_POP(mob->get_item_drop_ratio, HP_mob_get_item_drop_ratio) }, + { HP_POP(mob->set_item_drop_ratio, HP_mob_set_item_drop_ratio) }, + { HP_POP(mob->final_ratio_sub, HP_mob_final_ratio_sub) }, { HP_POP(mob->destroy_mob_db, HP_mob_destroy_mob_db) }, { HP_POP(mob->skill_db_libconfig, HP_mob_skill_db_libconfig) }, { HP_POP(mob->skill_db_libconfig_sub, HP_mob_skill_db_libconfig_sub) }, @@ -2387,6 +2397,7 @@ struct HookingPointData HookingPoints[] = { { HP_POP(pc->check_supernovice_call, HP_pc_check_supernovice_call) }, { HP_POP(pc->check_basicskill, HP_pc_check_basicskill) }, { HP_POP(pc->isDeathPenaltyJob, HP_pc_isDeathPenaltyJob) }, + { HP_POP(pc->has_second_costume, HP_pc_has_second_costume) }, /* pcre_interface */ { HP_POP(libpcre->compile, HP_libpcre_compile) }, { HP_POP(libpcre->study, HP_libpcre_study) }, @@ -2439,6 +2450,7 @@ struct HookingPointData HookingPoints[] = { { HP_POP(pet->read_db_sub, HP_pet_read_db_sub) }, { HP_POP(pet->read_db_sub_intimacy, HP_pet_read_db_sub_intimacy) }, { HP_POP(pet->read_db_clear, HP_pet_read_db_clear) }, + { HP_POP(pet->read_db_sub_evolution, HP_pet_read_db_sub_evolution) }, /* quest_interface */ { HP_POP(quest->init, HP_quest_init) }, { HP_POP(quest->final, HP_quest_final) }, @@ -2455,6 +2467,18 @@ struct HookingPointData HookingPoints[] = { { HP_POP(quest->clear, HP_quest_clear) }, { HP_POP(quest->read_db, HP_quest_read_db) }, { HP_POP(quest->read_db_sub, HP_quest_read_db_sub) }, + { HP_POP(quest->questinfo_validate_icon, HP_quest_questinfo_validate_icon) }, + { HP_POP(quest->questinfo_refresh, HP_quest_questinfo_refresh) }, + { HP_POP(quest->questinfo_validate, HP_quest_questinfo_validate) }, + { HP_POP(quest->questinfo_validate_job, HP_quest_questinfo_validate_job) }, + { HP_POP(quest->questinfo_validate_sex, HP_quest_questinfo_validate_sex) }, + { HP_POP(quest->questinfo_validate_baselevel, HP_quest_questinfo_validate_baselevel) }, + { HP_POP(quest->questinfo_validate_joblevel, HP_quest_questinfo_validate_joblevel) }, + { HP_POP(quest->questinfo_validate_items, HP_quest_questinfo_validate_items) }, + { HP_POP(quest->questinfo_validate_homunculus_level, HP_quest_questinfo_validate_homunculus_level) }, + { HP_POP(quest->questinfo_validate_homunculus_type, HP_quest_questinfo_validate_homunculus_type) }, + { HP_POP(quest->questinfo_validate_quests, HP_quest_questinfo_validate_quests) }, + { HP_POP(quest->questinfo_vector_clear, HP_quest_questinfo_vector_clear) }, /* rnd_interface */ { HP_POP(rnd->init, HP_rnd_init) }, { HP_POP(rnd->final, HP_rnd_final) }, diff --git a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc index bd2ef870f..882be9475 100644 --- a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc +++ b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc @@ -3526,10 +3526,10 @@ bool HP_buyingstore_setup(struct map_session_data *sd, unsigned char slots) { } return retVal___; } -void HP_buyingstore_create(struct map_session_data *sd, int zenylimit, unsigned char result, const char *storename, const uint8 *itemlist, unsigned int count) { +void HP_buyingstore_create(struct map_session_data *sd, int zenylimit, unsigned char result, const char *storename, const struct PACKET_CZ_REQ_OPEN_BUYING_STORE_sub *itemlist, unsigned int count) { int hIndex = 0; if (HPMHooks.count.HP_buyingstore_create_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, int *zenylimit, unsigned char *result, const char **storename, const uint8 **itemlist, unsigned int *count); + void (*preHookFunc) (struct map_session_data **sd, int *zenylimit, unsigned char *result, const char **storename, const struct PACKET_CZ_REQ_OPEN_BUYING_STORE_sub **itemlist, unsigned int *count); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_buyingstore_create_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_buyingstore_create_pre[hIndex].func; @@ -3544,7 +3544,7 @@ void HP_buyingstore_create(struct map_session_data *sd, int zenylimit, unsigned HPMHooks.source.buyingstore.create(sd, zenylimit, result, storename, itemlist, count); } if (HPMHooks.count.HP_buyingstore_create_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, int zenylimit, unsigned char result, const char *storename, const uint8 *itemlist, unsigned int count); + void (*postHookFunc) (struct map_session_data *sd, int zenylimit, unsigned char result, const char *storename, const struct PACKET_CZ_REQ_OPEN_BUYING_STORE_sub *itemlist, unsigned int count); for (hIndex = 0; hIndex < HPMHooks.count.HP_buyingstore_create_post; hIndex++) { postHookFunc = HPMHooks.list.HP_buyingstore_create_post[hIndex].func; postHookFunc(sd, zenylimit, result, storename, itemlist, count); @@ -3604,10 +3604,10 @@ void HP_buyingstore_open(struct map_session_data *sd, int account_id) { } return; } -void HP_buyingstore_trade(struct map_session_data *sd, int account_id, unsigned int buyer_id, const uint8 *itemlist, unsigned int count) { +void HP_buyingstore_trade(struct map_session_data *sd, int account_id, unsigned int buyer_id, const struct PACKET_CZ_REQ_TRADE_BUYING_STORE_sub *itemlist, unsigned int count) { int hIndex = 0; if (HPMHooks.count.HP_buyingstore_trade_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, int *account_id, unsigned int *buyer_id, const uint8 **itemlist, unsigned int *count); + void (*preHookFunc) (struct map_session_data **sd, int *account_id, unsigned int *buyer_id, const struct PACKET_CZ_REQ_TRADE_BUYING_STORE_sub **itemlist, unsigned int *count); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_buyingstore_trade_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_buyingstore_trade_pre[hIndex].func; @@ -3622,7 +3622,7 @@ void HP_buyingstore_trade(struct map_session_data *sd, int account_id, unsigned HPMHooks.source.buyingstore.trade(sd, account_id, buyer_id, itemlist, count); } if (HPMHooks.count.HP_buyingstore_trade_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, int account_id, unsigned int buyer_id, const uint8 *itemlist, unsigned int count); + void (*postHookFunc) (struct map_session_data *sd, int account_id, unsigned int buyer_id, const struct PACKET_CZ_REQ_TRADE_BUYING_STORE_sub *itemlist, unsigned int count); for (hIndex = 0; hIndex < HPMHooks.count.HP_buyingstore_trade_post; hIndex++) { postHookFunc = HPMHooks.list.HP_buyingstore_trade_post[hIndex].func; postHookFunc(sd, account_id, buyer_id, itemlist, count); @@ -3630,11 +3630,11 @@ void HP_buyingstore_trade(struct map_session_data *sd, int account_id, unsigned } return; } -bool HP_buyingstore_search(struct map_session_data *sd, unsigned short nameid) { +bool HP_buyingstore_search(struct map_session_data *sd, int nameid) { int hIndex = 0; bool retVal___ = false; if (HPMHooks.count.HP_buyingstore_search_pre > 0) { - bool (*preHookFunc) (struct map_session_data **sd, unsigned short *nameid); + bool (*preHookFunc) (struct map_session_data **sd, int *nameid); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_buyingstore_search_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_buyingstore_search_pre[hIndex].func; @@ -3649,7 +3649,7 @@ bool HP_buyingstore_search(struct map_session_data *sd, unsigned short nameid) { retVal___ = HPMHooks.source.buyingstore.search(sd, nameid); } if (HPMHooks.count.HP_buyingstore_search_post > 0) { - bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, unsigned short nameid); + bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, int nameid); for (hIndex = 0; hIndex < HPMHooks.count.HP_buyingstore_search_post; hIndex++) { postHookFunc = HPMHooks.list.HP_buyingstore_search_post[hIndex].func; retVal___ = postHookFunc(retVal___, sd, nameid); @@ -7574,6 +7574,32 @@ void HP_clif_authok(struct map_session_data *sd) { } return; } +void HP_clif_auth_error(int fd, int errorCode) { + int hIndex = 0; + if (HPMHooks.count.HP_clif_auth_error_pre > 0) { + void (*preHookFunc) (int *fd, int *errorCode); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_auth_error_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_clif_auth_error_pre[hIndex].func; + preHookFunc(&fd, &errorCode); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.clif.auth_error(fd, errorCode); + } + if (HPMHooks.count.HP_clif_auth_error_post > 0) { + void (*postHookFunc) (int fd, int errorCode); + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_auth_error_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_clif_auth_error_post[hIndex].func; + postHookFunc(fd, errorCode); + } + } + return; +} void HP_clif_authrefuse(int fd, uint8 error_code) { int hIndex = 0; if (HPMHooks.count.HP_clif_authrefuse_pre > 0) { @@ -8068,10 +8094,10 @@ void HP_clif_useitemack(struct map_session_data *sd, int index, int amount, bool } return; } -void HP_clif_addcards(unsigned char *buf, struct item *item) { +void HP_clif_addcards(struct EQUIPSLOTINFO *buf, struct item *item) { int hIndex = 0; if (HPMHooks.count.HP_clif_addcards_pre > 0) { - void (*preHookFunc) (unsigned char **buf, struct item **item); + void (*preHookFunc) (struct EQUIPSLOTINFO **buf, struct item **item); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_addcards_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_clif_addcards_pre[hIndex].func; @@ -8086,7 +8112,7 @@ void HP_clif_addcards(unsigned char *buf, struct item *item) { HPMHooks.source.clif.addcards(buf, item); } if (HPMHooks.count.HP_clif_addcards_post > 0) { - void (*postHookFunc) (unsigned char *buf, struct item *item); + void (*postHookFunc) (struct EQUIPSLOTINFO *buf, struct item *item); for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_addcards_post; hIndex++) { postHookFunc = HPMHooks.list.HP_clif_addcards_post[hIndex].func; postHookFunc(buf, item); @@ -8094,32 +8120,6 @@ void HP_clif_addcards(unsigned char *buf, struct item *item) { } return; } -void HP_clif_addcards2(unsigned short *cards, struct item *item) { - int hIndex = 0; - if (HPMHooks.count.HP_clif_addcards2_pre > 0) { - void (*preHookFunc) (unsigned short **cards, struct item **item); - *HPMforce_return = false; - for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_addcards2_pre; hIndex++) { - preHookFunc = HPMHooks.list.HP_clif_addcards2_pre[hIndex].func; - preHookFunc(&cards, &item); - } - if (*HPMforce_return) { - *HPMforce_return = false; - return; - } - } - { - HPMHooks.source.clif.addcards2(cards, item); - } - if (HPMHooks.count.HP_clif_addcards2_post > 0) { - void (*postHookFunc) (unsigned short *cards, struct item *item); - for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_addcards2_post; hIndex++) { - postHookFunc = HPMHooks.list.HP_clif_addcards2_post[hIndex].func; - postHookFunc(cards, item); - } - } - return; -} void HP_clif_item_sub(unsigned char *buf, int n, struct item *i, struct item_data *id, int equip) { int hIndex = 0; if (HPMHooks.count.HP_clif_item_sub_pre > 0) { @@ -8224,10 +8224,36 @@ void HP_clif_cashshop_load(void) { } return; } -void HP_clif_package_announce(struct map_session_data *sd, unsigned short nameid, unsigned short containerid) { +void HP_clif_cashShopSchedule(int fd, struct map_session_data *sd) { + int hIndex = 0; + if (HPMHooks.count.HP_clif_cashShopSchedule_pre > 0) { + void (*preHookFunc) (int *fd, struct map_session_data **sd); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_cashShopSchedule_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_clif_cashShopSchedule_pre[hIndex].func; + preHookFunc(&fd, &sd); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.clif.cashShopSchedule(fd, sd); + } + if (HPMHooks.count.HP_clif_cashShopSchedule_post > 0) { + void (*postHookFunc) (int fd, struct map_session_data *sd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_cashShopSchedule_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_clif_cashShopSchedule_post[hIndex].func; + postHookFunc(fd, sd); + } + } + return; +} +void HP_clif_package_announce(struct map_session_data *sd, int nameid, int containerid) { int hIndex = 0; if (HPMHooks.count.HP_clif_package_announce_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, unsigned short *nameid, unsigned short *containerid); + void (*preHookFunc) (struct map_session_data **sd, int *nameid, int *containerid); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_package_announce_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_clif_package_announce_pre[hIndex].func; @@ -8242,7 +8268,7 @@ void HP_clif_package_announce(struct map_session_data *sd, unsigned short nameid HPMHooks.source.clif.package_announce(sd, nameid, containerid); } if (HPMHooks.count.HP_clif_package_announce_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, unsigned short nameid, unsigned short containerid); + void (*postHookFunc) (struct map_session_data *sd, int nameid, int containerid); for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_package_announce_post; hIndex++) { postHookFunc = HPMHooks.list.HP_clif_package_announce_post[hIndex].func; postHookFunc(sd, nameid, containerid); @@ -8250,10 +8276,10 @@ void HP_clif_package_announce(struct map_session_data *sd, unsigned short nameid } return; } -void HP_clif_item_drop_announce(struct map_session_data *sd, unsigned short nameid, char *monsterName) { +void HP_clif_item_drop_announce(struct map_session_data *sd, int nameid, char *monsterName) { int hIndex = 0; if (HPMHooks.count.HP_clif_item_drop_announce_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, unsigned short *nameid, char **monsterName); + void (*preHookFunc) (struct map_session_data **sd, int *nameid, char **monsterName); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_item_drop_announce_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_clif_item_drop_announce_pre[hIndex].func; @@ -8268,7 +8294,7 @@ void HP_clif_item_drop_announce(struct map_session_data *sd, unsigned short name HPMHooks.source.clif.item_drop_announce(sd, nameid, monsterName); } if (HPMHooks.count.HP_clif_item_drop_announce_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, unsigned short nameid, char *monsterName); + void (*postHookFunc) (struct map_session_data *sd, int nameid, char *monsterName); for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_item_drop_announce_post; hIndex++) { postHookFunc = HPMHooks.list.HP_clif_item_drop_announce_post[hIndex].func; postHookFunc(sd, nameid, monsterName); @@ -9066,6 +9092,32 @@ void HP_clif_changemap(struct map_session_data *sd, short m, int x, int y) { } return; } +void HP_clif_changemap_airship(struct map_session_data *sd, short m, int x, int y) { + int hIndex = 0; + if (HPMHooks.count.HP_clif_changemap_airship_pre > 0) { + void (*preHookFunc) (struct map_session_data **sd, short *m, int *x, int *y); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_changemap_airship_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_clif_changemap_airship_pre[hIndex].func; + preHookFunc(&sd, &m, &x, &y); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.clif.changemap_airship(sd, m, x, y); + } + if (HPMHooks.count.HP_clif_changemap_airship_post > 0) { + void (*postHookFunc) (struct map_session_data *sd, short m, int x, int y); + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_changemap_airship_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_clif_changemap_airship_post[hIndex].func; + postHookFunc(sd, m, x, y); + } + } + return; +} void HP_clif_changemapcell(int fd, int16 m, int x, int y, int type, enum send_target target) { int hIndex = 0; if (HPMHooks.count.HP_clif_changemapcell_pre > 0) { @@ -9274,6 +9326,32 @@ void HP_clif_changemapserver(struct map_session_data *sd, unsigned short map_ind } return; } +void HP_clif_changemapserver_airship(struct map_session_data *sd, unsigned short map_index, int x, int y, uint32 ip, uint16 port) { + int hIndex = 0; + if (HPMHooks.count.HP_clif_changemapserver_airship_pre > 0) { + void (*preHookFunc) (struct map_session_data **sd, unsigned short *map_index, int *x, int *y, uint32 *ip, uint16 *port); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_changemapserver_airship_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_clif_changemapserver_airship_pre[hIndex].func; + preHookFunc(&sd, &map_index, &x, &y, &ip, &port); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.clif.changemapserver_airship(sd, map_index, x, y, ip, port); + } + if (HPMHooks.count.HP_clif_changemapserver_airship_post > 0) { + void (*postHookFunc) (struct map_session_data *sd, unsigned short map_index, int x, int y, uint32 ip, uint16 port); + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_changemapserver_airship_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_clif_changemapserver_airship_post[hIndex].func; + postHookFunc(sd, map_index, x, y, ip, port); + } + } + return; +} void HP_clif_npcbuysell(struct map_session_data *sd, int id) { int hIndex = 0; if (HPMHooks.count.HP_clif_npcbuysell_pre > 0) { @@ -10147,14 +10225,14 @@ void HP_clif_skillcastcancel(struct block_list *bl) { } return; } -void HP_clif_skill_fail(struct map_session_data *sd, uint16 skill_id, enum useskill_fail_cause cause, int btype) { +void HP_clif_skill_fail(struct map_session_data *sd, uint16 skill_id, enum useskill_fail_cause cause, int btype, int32 item_id) { int hIndex = 0; if (HPMHooks.count.HP_clif_skill_fail_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, uint16 *skill_id, enum useskill_fail_cause *cause, int *btype); + void (*preHookFunc) (struct map_session_data **sd, uint16 *skill_id, enum useskill_fail_cause *cause, int *btype, int32 *item_id); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_skill_fail_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_clif_skill_fail_pre[hIndex].func; - preHookFunc(&sd, &skill_id, &cause, &btype); + preHookFunc(&sd, &skill_id, &cause, &btype, &item_id); } if (*HPMforce_return) { *HPMforce_return = false; @@ -10162,13 +10240,13 @@ void HP_clif_skill_fail(struct map_session_data *sd, uint16 skill_id, enum usesk } } { - HPMHooks.source.clif.skill_fail(sd, skill_id, cause, btype); + HPMHooks.source.clif.skill_fail(sd, skill_id, cause, btype, item_id); } if (HPMHooks.count.HP_clif_skill_fail_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, uint16 skill_id, enum useskill_fail_cause cause, int btype); + void (*postHookFunc) (struct map_session_data *sd, uint16 skill_id, enum useskill_fail_cause cause, int btype, int32 item_id); for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_skill_fail_post; hIndex++) { postHookFunc = HPMHooks.list.HP_clif_skill_fail_post[hIndex].func; - postHookFunc(sd, skill_id, cause, btype); + postHookFunc(sd, skill_id, cause, btype, item_id); } } return; @@ -10987,10 +11065,10 @@ void HP_clif_upgrademessage(int fd, int result, int item_id) { } return; } -void HP_clif_get_weapon_view(struct map_session_data *sd, unsigned short *rhand, unsigned short *lhand) { +void HP_clif_get_weapon_view(struct map_session_data *sd, int *rhand, int *lhand) { int hIndex = 0; if (HPMHooks.count.HP_clif_get_weapon_view_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, unsigned short **rhand, unsigned short **lhand); + void (*preHookFunc) (struct map_session_data **sd, int **rhand, int **lhand); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_get_weapon_view_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_clif_get_weapon_view_pre[hIndex].func; @@ -11005,7 +11083,7 @@ void HP_clif_get_weapon_view(struct map_session_data *sd, unsigned short *rhand, HPMHooks.source.clif.get_weapon_view(sd, rhand, lhand); } if (HPMHooks.count.HP_clif_get_weapon_view_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, unsigned short *rhand, unsigned short *lhand); + void (*postHookFunc) (struct map_session_data *sd, int *rhand, int *lhand); for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_get_weapon_view_post; hIndex++) { postHookFunc = HPMHooks.list.HP_clif_get_weapon_view_post[hIndex].func; postHookFunc(sd, rhand, lhand); @@ -11221,10 +11299,10 @@ void HP_clif_partytickack(struct map_session_data *sd, bool flag) { } return; } -void HP_clif_zc_config(struct map_session_data *sd, int type, int flag) { +void HP_clif_zc_config(struct map_session_data *sd, enum CZ_CONFIG type, int flag) { int hIndex = 0; if (HPMHooks.count.HP_clif_zc_config_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, int *type, int *flag); + void (*preHookFunc) (struct map_session_data **sd, enum CZ_CONFIG *type, int *flag); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_zc_config_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_clif_zc_config_pre[hIndex].func; @@ -11239,7 +11317,7 @@ void HP_clif_zc_config(struct map_session_data *sd, int type, int flag) { HPMHooks.source.clif.zc_config(sd, type, flag); } if (HPMHooks.count.HP_clif_zc_config_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, int type, int flag); + void (*postHookFunc) (struct map_session_data *sd, enum CZ_CONFIG type, int flag); for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_zc_config_post; hIndex++) { postHookFunc = HPMHooks.list.HP_clif_zc_config_post[hIndex].func; postHookFunc(sd, type, flag); @@ -13492,14 +13570,14 @@ void HP_clif_messagecolor(struct block_list *bl, uint32 color, const char *msg) } return; } -void HP_clif_disp_overhead(struct block_list *bl, const char *mes) { +void HP_clif_disp_overhead(struct block_list *bl, const char *mes, enum send_target target, struct block_list *target_bl) { int hIndex = 0; if (HPMHooks.count.HP_clif_disp_overhead_pre > 0) { - void (*preHookFunc) (struct block_list **bl, const char **mes); + void (*preHookFunc) (struct block_list **bl, const char **mes, enum send_target *target, struct block_list **target_bl); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_disp_overhead_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_clif_disp_overhead_pre[hIndex].func; - preHookFunc(&bl, &mes); + preHookFunc(&bl, &mes, &target, &target_bl); } if (*HPMforce_return) { *HPMforce_return = false; @@ -13507,12 +13585,38 @@ void HP_clif_disp_overhead(struct block_list *bl, const char *mes) { } } { - HPMHooks.source.clif.disp_overhead(bl, mes); + HPMHooks.source.clif.disp_overhead(bl, mes, target, target_bl); } if (HPMHooks.count.HP_clif_disp_overhead_post > 0) { - void (*postHookFunc) (struct block_list *bl, const char *mes); + void (*postHookFunc) (struct block_list *bl, const char *mes, enum send_target target, struct block_list *target_bl); for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_disp_overhead_post; hIndex++) { postHookFunc = HPMHooks.list.HP_clif_disp_overhead_post[hIndex].func; + postHookFunc(bl, mes, target, target_bl); + } + } + return; +} +void HP_clif_notify_playerchat(struct block_list *bl, const char *mes) { + int hIndex = 0; + if (HPMHooks.count.HP_clif_notify_playerchat_pre > 0) { + void (*preHookFunc) (struct block_list **bl, const char **mes); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_notify_playerchat_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_clif_notify_playerchat_pre[hIndex].func; + preHookFunc(&bl, &mes); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.clif.notify_playerchat(bl, mes); + } + if (HPMHooks.count.HP_clif_notify_playerchat_post > 0) { + void (*postHookFunc) (struct block_list *bl, const char *mes); + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_notify_playerchat_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_clif_notify_playerchat_post[hIndex].func; postHookFunc(bl, mes); } } @@ -14222,6 +14326,32 @@ void HP_clif_openvending(struct map_session_data *sd, int id, struct s_vending * } return; } +void HP_clif_openvendingAck(int fd, int result) { + int hIndex = 0; + if (HPMHooks.count.HP_clif_openvendingAck_pre > 0) { + void (*preHookFunc) (int *fd, int *result); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_openvendingAck_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_clif_openvendingAck_pre[hIndex].func; + preHookFunc(&fd, &result); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.clif.openvendingAck(fd, result); + } + if (HPMHooks.count.HP_clif_openvendingAck_post > 0) { + void (*postHookFunc) (int fd, int result); + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_openvendingAck_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_clif_openvendingAck_post[hIndex].func; + postHookFunc(fd, result); + } + } + return; +} void HP_clif_vendingreport(struct map_session_data *sd, int index, int amount, uint32 char_id, int zeny) { int hIndex = 0; if (HPMHooks.count.HP_clif_vendingreport_pre > 0) { @@ -18027,10 +18157,10 @@ void HP_clif_buyingstore_trade_failed_buyer(struct map_session_data *sd, short r } return; } -void HP_clif_buyingstore_update_item(struct map_session_data *sd, unsigned short nameid, unsigned short amount, uint32 char_id, int zeny) { +void HP_clif_buyingstore_update_item(struct map_session_data *sd, int nameid, unsigned short amount, uint32 char_id, int zeny) { int hIndex = 0; if (HPMHooks.count.HP_clif_buyingstore_update_item_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, unsigned short *nameid, unsigned short *amount, uint32 *char_id, int *zeny); + void (*preHookFunc) (struct map_session_data **sd, int *nameid, unsigned short *amount, uint32 *char_id, int *zeny); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_buyingstore_update_item_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_clif_buyingstore_update_item_pre[hIndex].func; @@ -18045,7 +18175,7 @@ void HP_clif_buyingstore_update_item(struct map_session_data *sd, unsigned short HPMHooks.source.clif.buyingstore_update_item(sd, nameid, amount, char_id, zeny); } if (HPMHooks.count.HP_clif_buyingstore_update_item_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, unsigned short nameid, unsigned short amount, uint32 char_id, int zeny); + void (*postHookFunc) (struct map_session_data *sd, int nameid, unsigned short amount, uint32 char_id, int zeny); for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_buyingstore_update_item_post; hIndex++) { postHookFunc = HPMHooks.list.HP_clif_buyingstore_update_item_post[hIndex].func; postHookFunc(sd, nameid, amount, char_id, zeny); @@ -18079,10 +18209,10 @@ void HP_clif_buyingstore_delete_item(struct map_session_data *sd, short index, u } return; } -void HP_clif_buyingstore_trade_failed_seller(struct map_session_data *sd, short result, unsigned short nameid) { +void HP_clif_buyingstore_trade_failed_seller(struct map_session_data *sd, short result, int nameid) { int hIndex = 0; if (HPMHooks.count.HP_clif_buyingstore_trade_failed_seller_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, short *result, unsigned short *nameid); + void (*preHookFunc) (struct map_session_data **sd, short *result, int *nameid); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_buyingstore_trade_failed_seller_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_clif_buyingstore_trade_failed_seller_pre[hIndex].func; @@ -18097,7 +18227,7 @@ void HP_clif_buyingstore_trade_failed_seller(struct map_session_data *sd, short HPMHooks.source.clif.buyingstore_trade_failed_seller(sd, result, nameid); } if (HPMHooks.count.HP_clif_buyingstore_trade_failed_seller_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, short result, unsigned short nameid); + void (*postHookFunc) (struct map_session_data *sd, short result, int nameid); for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_buyingstore_trade_failed_seller_post; hIndex++) { postHookFunc = HPMHooks.list.HP_clif_buyingstore_trade_failed_seller_post[hIndex].func; postHookFunc(sd, result, nameid); @@ -18915,10 +19045,10 @@ bool HP_clif_parse_roulette_db(void) { } return retVal___; } -void HP_clif_roulette_generate_ack(struct map_session_data *sd, unsigned char result, short stage, short prizeIdx, short bonusItemID) { +void HP_clif_roulette_generate_ack(struct map_session_data *sd, unsigned char result, short stage, short prizeIdx, int bonusItemID) { int hIndex = 0; if (HPMHooks.count.HP_clif_roulette_generate_ack_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, unsigned char *result, short *stage, short *prizeIdx, short *bonusItemID); + void (*preHookFunc) (struct map_session_data **sd, unsigned char *result, short *stage, short *prizeIdx, int *bonusItemID); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_roulette_generate_ack_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_clif_roulette_generate_ack_pre[hIndex].func; @@ -18933,7 +19063,7 @@ void HP_clif_roulette_generate_ack(struct map_session_data *sd, unsigned char re HPMHooks.source.clif.roulette_generate_ack(sd, result, stage, prizeIdx, bonusItemID); } if (HPMHooks.count.HP_clif_roulette_generate_ack_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, unsigned char result, short stage, short prizeIdx, short bonusItemID); + void (*postHookFunc) (struct map_session_data *sd, unsigned char result, short stage, short prizeIdx, int bonusItemID); for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_roulette_generate_ack_post; hIndex++) { postHookFunc = HPMHooks.list.HP_clif_roulette_generate_ack_post[hIndex].func; postHookFunc(sd, result, stage, prizeIdx, bonusItemID); @@ -25316,10 +25446,10 @@ void HP_clif_pRodexAddItem(int fd, struct map_session_data *sd) { } return; } -void HP_clif_rodex_add_item_result(struct map_session_data *sd, int16 idx, int16 amount, int8 result) { +void HP_clif_rodex_add_item_result(struct map_session_data *sd, int16 idx, int16 amount, enum rodex_add_item result) { int hIndex = 0; if (HPMHooks.count.HP_clif_rodex_add_item_result_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, int16 *idx, int16 *amount, int8 *result); + void (*preHookFunc) (struct map_session_data **sd, int16 *idx, int16 *amount, enum rodex_add_item *result); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_rodex_add_item_result_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_clif_rodex_add_item_result_pre[hIndex].func; @@ -25334,7 +25464,7 @@ void HP_clif_rodex_add_item_result(struct map_session_data *sd, int16 idx, int16 HPMHooks.source.clif.rodex_add_item_result(sd, idx, amount, result); } if (HPMHooks.count.HP_clif_rodex_add_item_result_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, int16 idx, int16 amount, int8 result); + void (*postHookFunc) (struct map_session_data *sd, int16 idx, int16 amount, enum rodex_add_item result); for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_rodex_add_item_result_post; hIndex++) { postHookFunc = HPMHooks.list.HP_clif_rodex_add_item_result_post[hIndex].func; postHookFunc(sd, idx, amount, result); @@ -25836,10 +25966,10 @@ void HP_clif_pRodexRequestZeny(int fd, struct map_session_data *sd) { } return; } -void HP_clif_rodex_request_zeny(struct map_session_data *sd, int8 opentype, int64 mail_id, int8 result) { +void HP_clif_rodex_request_zeny(struct map_session_data *sd, int8 opentype, int64 mail_id, enum rodex_get_zeny result) { int hIndex = 0; if (HPMHooks.count.HP_clif_rodex_request_zeny_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, int8 *opentype, int64 *mail_id, int8 *result); + void (*preHookFunc) (struct map_session_data **sd, int8 *opentype, int64 *mail_id, enum rodex_get_zeny *result); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_rodex_request_zeny_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_clif_rodex_request_zeny_pre[hIndex].func; @@ -25854,7 +25984,7 @@ void HP_clif_rodex_request_zeny(struct map_session_data *sd, int8 opentype, int6 HPMHooks.source.clif.rodex_request_zeny(sd, opentype, mail_id, result); } if (HPMHooks.count.HP_clif_rodex_request_zeny_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, int8 opentype, int64 mail_id, int8 result); + void (*postHookFunc) (struct map_session_data *sd, int8 opentype, int64 mail_id, enum rodex_get_zeny result); for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_rodex_request_zeny_post; hIndex++) { postHookFunc = HPMHooks.list.HP_clif_rodex_request_zeny_post[hIndex].func; postHookFunc(sd, opentype, mail_id, result); @@ -25888,10 +26018,10 @@ void HP_clif_pRodexRequestItems(int fd, struct map_session_data *sd) { } return; } -void HP_clif_rodex_request_items(struct map_session_data *sd, int8 opentype, int64 mail_id, int8 result) { +void HP_clif_rodex_request_items(struct map_session_data *sd, int8 opentype, int64 mail_id, enum rodex_get_items result) { int hIndex = 0; if (HPMHooks.count.HP_clif_rodex_request_items_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, int8 *opentype, int64 *mail_id, int8 *result); + void (*preHookFunc) (struct map_session_data **sd, int8 *opentype, int64 *mail_id, enum rodex_get_items *result); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_rodex_request_items_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_clif_rodex_request_items_pre[hIndex].func; @@ -25906,7 +26036,7 @@ void HP_clif_rodex_request_items(struct map_session_data *sd, int8 opentype, int HPMHooks.source.clif.rodex_request_items(sd, opentype, mail_id, result); } if (HPMHooks.count.HP_clif_rodex_request_items_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, int8 opentype, int64 mail_id, int8 result); + void (*postHookFunc) (struct map_session_data *sd, int8 opentype, int64 mail_id, enum rodex_get_items result); for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_rodex_request_items_post; hIndex++) { postHookFunc = HPMHooks.list.HP_clif_rodex_request_items_post[hIndex].func; postHookFunc(sd, opentype, mail_id, result); @@ -26545,10 +26675,10 @@ bool HP_clif_style_change_validate_requirements(struct map_session_data *sd, int } return retVal___; } -void HP_clif_stylist_send_rodexitem(struct map_session_data *sd, int16 itemid) { +void HP_clif_stylist_send_rodexitem(struct map_session_data *sd, int itemid) { int hIndex = 0; if (HPMHooks.count.HP_clif_stylist_send_rodexitem_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, int16 *itemid); + void (*preHookFunc) (struct map_session_data **sd, int *itemid); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_stylist_send_rodexitem_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_clif_stylist_send_rodexitem_pre[hIndex].func; @@ -26563,7 +26693,7 @@ void HP_clif_stylist_send_rodexitem(struct map_session_data *sd, int16 itemid) { HPMHooks.source.clif.stylist_send_rodexitem(sd, itemid); } if (HPMHooks.count.HP_clif_stylist_send_rodexitem_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, int16 itemid); + void (*postHookFunc) (struct map_session_data *sd, int itemid); for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_stylist_send_rodexitem_post; hIndex++) { postHookFunc = HPMHooks.list.HP_clif_stylist_send_rodexitem_post[hIndex].func; postHookFunc(sd, itemid); @@ -26649,6 +26779,58 @@ void HP_clif_style_change_response(struct map_session_data *sd, enum stylist_sho } return; } +void HP_clif_pPetEvolution(int fd, struct map_session_data *sd) { + int hIndex = 0; + if (HPMHooks.count.HP_clif_pPetEvolution_pre > 0) { + void (*preHookFunc) (int *fd, struct map_session_data **sd); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pPetEvolution_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_clif_pPetEvolution_pre[hIndex].func; + preHookFunc(&fd, &sd); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.clif.pPetEvolution(fd, sd); + } + if (HPMHooks.count.HP_clif_pPetEvolution_post > 0) { + void (*postHookFunc) (int fd, struct map_session_data *sd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pPetEvolution_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_clif_pPetEvolution_post[hIndex].func; + postHookFunc(fd, sd); + } + } + return; +} +void HP_clif_petEvolutionResult(int fd, enum pet_evolution_result result) { + int hIndex = 0; + if (HPMHooks.count.HP_clif_petEvolutionResult_pre > 0) { + void (*preHookFunc) (int *fd, enum pet_evolution_result *result); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_petEvolutionResult_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_clif_petEvolutionResult_pre[hIndex].func; + preHookFunc(&fd, &result); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.clif.petEvolutionResult(fd, result); + } + if (HPMHooks.count.HP_clif_petEvolutionResult_post > 0) { + void (*postHookFunc) (int fd, enum pet_evolution_result result); + for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_petEvolutionResult_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_clif_petEvolutionResult_post[hIndex].func; + postHookFunc(fd, result); + } + } + return; +} /* cmdline_interface */ void HP_cmdline_init(void) { int hIndex = 0; @@ -33371,11 +33553,11 @@ int HP_intif_parse(int fd) { } return retVal___; } -int HP_intif_create_pet(int account_id, int char_id, short pet_type, short pet_lv, short pet_egg_id, short pet_equip, short intimate, short hungry, char rename_flag, char incubate, char *pet_name) { +int HP_intif_create_pet(int account_id, int char_id, short pet_type, short pet_lv, int pet_egg_id, int pet_equip, short intimate, short hungry, char rename_flag, char incubate, char *pet_name) { int hIndex = 0; int retVal___ = 0; if (HPMHooks.count.HP_intif_create_pet_pre > 0) { - int (*preHookFunc) (int *account_id, int *char_id, short *pet_type, short *pet_lv, short *pet_egg_id, short *pet_equip, short *intimate, short *hungry, char *rename_flag, char *incubate, char **pet_name); + int (*preHookFunc) (int *account_id, int *char_id, short *pet_type, short *pet_lv, int *pet_egg_id, int *pet_equip, short *intimate, short *hungry, char *rename_flag, char *incubate, char **pet_name); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_intif_create_pet_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_intif_create_pet_pre[hIndex].func; @@ -33390,7 +33572,7 @@ int HP_intif_create_pet(int account_id, int char_id, short pet_type, short pet_l retVal___ = HPMHooks.source.intif.create_pet(account_id, char_id, pet_type, pet_lv, pet_egg_id, pet_equip, intimate, hungry, rename_flag, incubate, pet_name); } if (HPMHooks.count.HP_intif_create_pet_post > 0) { - int (*postHookFunc) (int retVal___, int account_id, int char_id, short pet_type, short pet_lv, short pet_egg_id, short pet_equip, short intimate, short hungry, char rename_flag, char incubate, char *pet_name); + int (*postHookFunc) (int retVal___, int account_id, int char_id, short pet_type, short pet_lv, int pet_egg_id, int pet_equip, short intimate, short hungry, char rename_flag, char incubate, char *pet_name); for (hIndex = 0; hIndex < HPMHooks.count.HP_intif_create_pet_post; hIndex++) { postHookFunc = HPMHooks.list.HP_intif_create_pet_post[hIndex].func; retVal___ = postHookFunc(retVal___, account_id, char_id, pet_type, pet_lv, pet_egg_id, pet_equip, intimate, hungry, rename_flag, incubate, pet_name); @@ -38171,11 +38353,11 @@ struct item_data* HP_itemdb_exists(int nameid) { } return retVal___; } -struct item_option* HP_itemdb_option_exists(int idx) { +struct itemdb_option* HP_itemdb_option_exists(int idx) { int hIndex = 0; - struct item_option* retVal___ = NULL; + struct itemdb_option* retVal___ = NULL; if (HPMHooks.count.HP_itemdb_option_exists_pre > 0) { - struct item_option* (*preHookFunc) (int *idx); + struct itemdb_option* (*preHookFunc) (int *idx); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_itemdb_option_exists_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_itemdb_option_exists_pre[hIndex].func; @@ -38190,7 +38372,7 @@ struct item_option* HP_itemdb_option_exists(int idx) { retVal___ = HPMHooks.source.itemdb.option_exists(idx); } if (HPMHooks.count.HP_itemdb_option_exists_post > 0) { - struct item_option* (*postHookFunc) (struct item_option* retVal___, int idx); + struct itemdb_option* (*postHookFunc) (struct itemdb_option* retVal___, int idx); for (hIndex = 0; hIndex < HPMHooks.count.HP_itemdb_option_exists_post; hIndex++) { postHookFunc = HPMHooks.list.HP_itemdb_option_exists_post[hIndex].func; retVal___ = postHookFunc(retVal___, idx); @@ -39069,10 +39251,10 @@ int HP_itemdb_validate_entry(struct item_data *entry, int n, const char *source) } return retVal___; } -void HP_itemdb_readdb_options_additional_fields(struct item_option *ito, struct config_setting_t *t, const char *source) { +void HP_itemdb_readdb_options_additional_fields(struct itemdb_option *ito, struct config_setting_t *t, const char *source) { int hIndex = 0; if (HPMHooks.count.HP_itemdb_readdb_options_additional_fields_pre > 0) { - void (*preHookFunc) (struct item_option **ito, struct config_setting_t **t, const char **source); + void (*preHookFunc) (struct itemdb_option **ito, struct config_setting_t **t, const char **source); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_itemdb_readdb_options_additional_fields_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_itemdb_readdb_options_additional_fields_pre[hIndex].func; @@ -39087,7 +39269,7 @@ void HP_itemdb_readdb_options_additional_fields(struct item_option *ito, struct HPMHooks.source.itemdb.readdb_options_additional_fields(ito, t, source); } if (HPMHooks.count.HP_itemdb_readdb_options_additional_fields_post > 0) { - void (*postHookFunc) (struct item_option *ito, struct config_setting_t *t, const char *source); + void (*postHookFunc) (struct itemdb_option *ito, struct config_setting_t *t, const char *source); for (hIndex = 0; hIndex < HPMHooks.count.HP_itemdb_readdb_options_additional_fields_post; hIndex++) { postHookFunc = HPMHooks.list.HP_itemdb_readdb_options_additional_fields_post[hIndex].func; postHookFunc(ito, t, source); @@ -39372,11 +39554,11 @@ void HP_itemdb_clear(bool total) { } return; } -struct item_combo* HP_itemdb_id2combo(unsigned short id) { +struct item_combo* HP_itemdb_id2combo(int id) { int hIndex = 0; struct item_combo* retVal___ = NULL; if (HPMHooks.count.HP_itemdb_id2combo_pre > 0) { - struct item_combo* (*preHookFunc) (unsigned short *id); + struct item_combo* (*preHookFunc) (int *id); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_itemdb_id2combo_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_itemdb_id2combo_pre[hIndex].func; @@ -39391,7 +39573,7 @@ struct item_combo* HP_itemdb_id2combo(unsigned short id) { retVal___ = HPMHooks.source.itemdb.id2combo(id); } if (HPMHooks.count.HP_itemdb_id2combo_post > 0) { - struct item_combo* (*postHookFunc) (struct item_combo* retVal___, unsigned short id); + struct item_combo* (*postHookFunc) (struct item_combo* retVal___, int id); for (hIndex = 0; hIndex < HPMHooks.count.HP_itemdb_id2combo_post; hIndex++) { postHookFunc = HPMHooks.list.HP_itemdb_id2combo_post[hIndex].func; retVal___ = postHookFunc(retVal___, id); @@ -45458,11 +45640,11 @@ bool HP_map_zone_mf_cache(int m, char *flag, char *params) { } return retVal___; } -unsigned short HP_map_zone_str2itemid(const char *name) { +int HP_map_zone_str2itemid(const char *name) { int hIndex = 0; - unsigned short retVal___ = 0; + int retVal___ = 0; if (HPMHooks.count.HP_map_zone_str2itemid_pre > 0) { - unsigned short (*preHookFunc) (const char **name); + int (*preHookFunc) (const char **name); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_map_zone_str2itemid_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_map_zone_str2itemid_pre[hIndex].func; @@ -45477,7 +45659,7 @@ unsigned short HP_map_zone_str2itemid(const char *name) { retVal___ = HPMHooks.source.map.zone_str2itemid(name); } if (HPMHooks.count.HP_map_zone_str2itemid_post > 0) { - unsigned short (*postHookFunc) (unsigned short retVal___, const char *name); + int (*postHookFunc) (int retVal___, const char *name); for (hIndex = 0; hIndex < HPMHooks.count.HP_map_zone_str2itemid_post; hIndex++) { postHookFunc = HPMHooks.list.HP_map_zone_str2itemid_post[hIndex].func; retVal___ = postHookFunc(retVal___, name); @@ -50217,6 +50399,92 @@ void HP_mob_clear_spawninfo(void) { } return; } +struct item_drop_ratio* HP_mob_get_item_drop_ratio(int nameid) { + int hIndex = 0; + struct item_drop_ratio* retVal___ = NULL; + if (HPMHooks.count.HP_mob_get_item_drop_ratio_pre > 0) { + struct item_drop_ratio* (*preHookFunc) (int *nameid); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_mob_get_item_drop_ratio_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_mob_get_item_drop_ratio_pre[hIndex].func; + retVal___ = preHookFunc(&nameid); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.mob.get_item_drop_ratio(nameid); + } + if (HPMHooks.count.HP_mob_get_item_drop_ratio_post > 0) { + struct item_drop_ratio* (*postHookFunc) (struct item_drop_ratio* retVal___, int nameid); + for (hIndex = 0; hIndex < HPMHooks.count.HP_mob_get_item_drop_ratio_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_mob_get_item_drop_ratio_post[hIndex].func; + retVal___ = postHookFunc(retVal___, nameid); + } + } + return retVal___; +} +void HP_mob_set_item_drop_ratio(int nameid, struct item_drop_ratio *ratio) { + int hIndex = 0; + if (HPMHooks.count.HP_mob_set_item_drop_ratio_pre > 0) { + void (*preHookFunc) (int *nameid, struct item_drop_ratio **ratio); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_mob_set_item_drop_ratio_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_mob_set_item_drop_ratio_pre[hIndex].func; + preHookFunc(&nameid, &ratio); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.mob.set_item_drop_ratio(nameid, ratio); + } + if (HPMHooks.count.HP_mob_set_item_drop_ratio_post > 0) { + void (*postHookFunc) (int nameid, struct item_drop_ratio *ratio); + for (hIndex = 0; hIndex < HPMHooks.count.HP_mob_set_item_drop_ratio_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_mob_set_item_drop_ratio_post[hIndex].func; + postHookFunc(nameid, ratio); + } + } + return; +} +int HP_mob_final_ratio_sub(union DBKey key, struct DBData *data, va_list ap) { + int hIndex = 0; + int retVal___ = 0; + if (HPMHooks.count.HP_mob_final_ratio_sub_pre > 0) { + int (*preHookFunc) (union DBKey *key, struct DBData **data, va_list ap); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_mob_final_ratio_sub_pre; hIndex++) { + va_list ap___copy; va_copy(ap___copy, ap); + preHookFunc = HPMHooks.list.HP_mob_final_ratio_sub_pre[hIndex].func; + retVal___ = preHookFunc(&key, &data, ap___copy); + va_end(ap___copy); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + va_list ap___copy; va_copy(ap___copy, ap); + retVal___ = HPMHooks.source.mob.final_ratio_sub(key, data, ap___copy); + va_end(ap___copy); + } + if (HPMHooks.count.HP_mob_final_ratio_sub_post > 0) { + int (*postHookFunc) (int retVal___, union DBKey key, struct DBData *data, va_list ap); + for (hIndex = 0; hIndex < HPMHooks.count.HP_mob_final_ratio_sub_post; hIndex++) { + va_list ap___copy; va_copy(ap___copy, ap); + postHookFunc = HPMHooks.list.HP_mob_final_ratio_sub_post[hIndex].func; + retVal___ = postHookFunc(retVal___, key, data, ap___copy); + va_end(ap___copy); + } + } + return retVal___; +} void HP_mob_destroy_mob_db(int index) { int hIndex = 0; if (HPMHooks.count.HP_mob_destroy_mob_db_pre > 0) { @@ -60707,11 +60975,11 @@ void HP_pc_check_skilltree(struct map_session_data *sd, int skill_id) { } return; } -int HP_pc_bonus_autospell(struct s_autospell *spell, int max, short id, short lv, short rate, short flag, short card_id) { +int HP_pc_bonus_autospell(struct s_autospell *spell, int max, short id, short lv, short rate, short flag, int card_id) { int hIndex = 0; int retVal___ = 0; if (HPMHooks.count.HP_pc_bonus_autospell_pre > 0) { - int (*preHookFunc) (struct s_autospell **spell, int *max, short *id, short *lv, short *rate, short *flag, short *card_id); + int (*preHookFunc) (struct s_autospell **spell, int *max, short *id, short *lv, short *rate, short *flag, int *card_id); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_pc_bonus_autospell_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_pc_bonus_autospell_pre[hIndex].func; @@ -60726,7 +60994,7 @@ int HP_pc_bonus_autospell(struct s_autospell *spell, int max, short id, short lv retVal___ = HPMHooks.source.pc.bonus_autospell(spell, max, id, lv, rate, flag, card_id); } if (HPMHooks.count.HP_pc_bonus_autospell_post > 0) { - int (*postHookFunc) (int retVal___, struct s_autospell *spell, int max, short id, short lv, short rate, short flag, short card_id); + int (*postHookFunc) (int retVal___, struct s_autospell *spell, int max, short id, short lv, short rate, short flag, int card_id); for (hIndex = 0; hIndex < HPMHooks.count.HP_pc_bonus_autospell_post; hIndex++) { postHookFunc = HPMHooks.list.HP_pc_bonus_autospell_post[hIndex].func; retVal___ = postHookFunc(retVal___, spell, max, id, lv, rate, flag, card_id); @@ -60734,11 +61002,11 @@ int HP_pc_bonus_autospell(struct s_autospell *spell, int max, short id, short lv } return retVal___; } -int HP_pc_bonus_autospell_onskill(struct s_autospell *spell, int max, short src_skill, short id, short lv, short rate, short card_id) { +int HP_pc_bonus_autospell_onskill(struct s_autospell *spell, int max, short src_skill, short id, short lv, short rate, int card_id) { int hIndex = 0; int retVal___ = 0; if (HPMHooks.count.HP_pc_bonus_autospell_onskill_pre > 0) { - int (*preHookFunc) (struct s_autospell **spell, int *max, short *src_skill, short *id, short *lv, short *rate, short *card_id); + int (*preHookFunc) (struct s_autospell **spell, int *max, short *src_skill, short *id, short *lv, short *rate, int *card_id); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_pc_bonus_autospell_onskill_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_pc_bonus_autospell_onskill_pre[hIndex].func; @@ -60753,7 +61021,7 @@ int HP_pc_bonus_autospell_onskill(struct s_autospell *spell, int max, short src_ retVal___ = HPMHooks.source.pc.bonus_autospell_onskill(spell, max, src_skill, id, lv, rate, card_id); } if (HPMHooks.count.HP_pc_bonus_autospell_onskill_post > 0) { - int (*postHookFunc) (int retVal___, struct s_autospell *spell, int max, short src_skill, short id, short lv, short rate, short card_id); + int (*postHookFunc) (int retVal___, struct s_autospell *spell, int max, short src_skill, short id, short lv, short rate, int card_id); for (hIndex = 0; hIndex < HPMHooks.count.HP_pc_bonus_autospell_onskill_post; hIndex++) { postHookFunc = HPMHooks.list.HP_pc_bonus_autospell_onskill_post[hIndex].func; retVal___ = postHookFunc(retVal___, spell, max, src_skill, id, lv, rate, card_id); @@ -62088,6 +62356,33 @@ bool HP_pc_isDeathPenaltyJob(uint16 job) { } return retVal___; } +bool HP_pc_has_second_costume(struct map_session_data *sd) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_pc_has_second_costume_pre > 0) { + bool (*preHookFunc) (struct map_session_data **sd); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_pc_has_second_costume_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_pc_has_second_costume_pre[hIndex].func; + retVal___ = preHookFunc(&sd); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.pc.has_second_costume(sd); + } + if (HPMHooks.count.HP_pc_has_second_costume_post > 0) { + bool (*postHookFunc) (bool retVal___, struct map_session_data *sd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_pc_has_second_costume_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_pc_has_second_costume_post[hIndex].func; + retVal___ = postHookFunc(retVal___, sd); + } + } + return retVal___; +} /* pcre_interface */ pcre* HP_libpcre_compile(const char *pattern, int options, const char **errptr, int *erroffset, const unsigned char *tableptr) { int hIndex = 0; @@ -62762,11 +63057,11 @@ int HP_pet_recv_petdata(int account_id, struct s_pet *p, int flag) { } return retVal___; } -int HP_pet_select_egg(struct map_session_data *sd, short egg_index) { +int HP_pet_select_egg(struct map_session_data *sd, int egg_index) { int hIndex = 0; int retVal___ = 0; if (HPMHooks.count.HP_pet_select_egg_pre > 0) { - int (*preHookFunc) (struct map_session_data **sd, short *egg_index); + int (*preHookFunc) (struct map_session_data **sd, int *egg_index); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_pet_select_egg_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_pet_select_egg_pre[hIndex].func; @@ -62781,7 +63076,7 @@ int HP_pet_select_egg(struct map_session_data *sd, short egg_index) { retVal___ = HPMHooks.source.pet.select_egg(sd, egg_index); } if (HPMHooks.count.HP_pet_select_egg_post > 0) { - int (*postHookFunc) (int retVal___, struct map_session_data *sd, short egg_index); + int (*postHookFunc) (int retVal___, struct map_session_data *sd, int egg_index); for (hIndex = 0; hIndex < HPMHooks.count.HP_pet_select_egg_post; hIndex++) { postHookFunc = HPMHooks.list.HP_pet_select_egg_post[hIndex].func; retVal___ = postHookFunc(retVal___, sd, egg_index); @@ -63447,6 +63742,32 @@ void HP_pet_read_db_clear(void) { } return; } +void HP_pet_read_db_sub_evolution(struct config_setting_t *t, int n) { + int hIndex = 0; + if (HPMHooks.count.HP_pet_read_db_sub_evolution_pre > 0) { + void (*preHookFunc) (struct config_setting_t **t, int *n); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_pet_read_db_sub_evolution_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_pet_read_db_sub_evolution_pre[hIndex].func; + preHookFunc(&t, &n); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.pet.read_db_sub_evolution(t, n); + } + if (HPMHooks.count.HP_pet_read_db_sub_evolution_post > 0) { + void (*postHookFunc) (struct config_setting_t *t, int n); + for (hIndex = 0; hIndex < HPMHooks.count.HP_pet_read_db_sub_evolution_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_pet_read_db_sub_evolution_post[hIndex].func; + postHookFunc(t, n); + } + } + return; +} /* quest_interface */ void HP_quest_init(bool minimal) { int hIndex = 0; @@ -63854,6 +64175,328 @@ struct quest_db* HP_quest_read_db_sub(struct config_setting_t *cs, int n, const } return retVal___; } +int HP_quest_questinfo_validate_icon(int icon) { + int hIndex = 0; + int retVal___ = 0; + if (HPMHooks.count.HP_quest_questinfo_validate_icon_pre > 0) { + int (*preHookFunc) (int *icon); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_icon_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_quest_questinfo_validate_icon_pre[hIndex].func; + retVal___ = preHookFunc(&icon); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.quest.questinfo_validate_icon(icon); + } + if (HPMHooks.count.HP_quest_questinfo_validate_icon_post > 0) { + int (*postHookFunc) (int retVal___, int icon); + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_icon_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_quest_questinfo_validate_icon_post[hIndex].func; + retVal___ = postHookFunc(retVal___, icon); + } + } + return retVal___; +} +void HP_quest_questinfo_refresh(struct map_session_data *sd) { + int hIndex = 0; + if (HPMHooks.count.HP_quest_questinfo_refresh_pre > 0) { + void (*preHookFunc) (struct map_session_data **sd); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_refresh_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_quest_questinfo_refresh_pre[hIndex].func; + preHookFunc(&sd); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.quest.questinfo_refresh(sd); + } + if (HPMHooks.count.HP_quest_questinfo_refresh_post > 0) { + void (*postHookFunc) (struct map_session_data *sd); + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_refresh_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_quest_questinfo_refresh_post[hIndex].func; + postHookFunc(sd); + } + } + return; +} +bool HP_quest_questinfo_validate(struct map_session_data *sd, struct questinfo *qi) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_quest_questinfo_validate_pre > 0) { + bool (*preHookFunc) (struct map_session_data **sd, struct questinfo **qi); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_quest_questinfo_validate_pre[hIndex].func; + retVal___ = preHookFunc(&sd, &qi); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.quest.questinfo_validate(sd, qi); + } + if (HPMHooks.count.HP_quest_questinfo_validate_post > 0) { + bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_quest_questinfo_validate_post[hIndex].func; + retVal___ = postHookFunc(retVal___, sd, qi); + } + } + return retVal___; +} +bool HP_quest_questinfo_validate_job(struct map_session_data *sd, struct questinfo *qi) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_quest_questinfo_validate_job_pre > 0) { + bool (*preHookFunc) (struct map_session_data **sd, struct questinfo **qi); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_job_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_quest_questinfo_validate_job_pre[hIndex].func; + retVal___ = preHookFunc(&sd, &qi); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.quest.questinfo_validate_job(sd, qi); + } + if (HPMHooks.count.HP_quest_questinfo_validate_job_post > 0) { + bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_job_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_quest_questinfo_validate_job_post[hIndex].func; + retVal___ = postHookFunc(retVal___, sd, qi); + } + } + return retVal___; +} +bool HP_quest_questinfo_validate_sex(struct map_session_data *sd, struct questinfo *qi) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_quest_questinfo_validate_sex_pre > 0) { + bool (*preHookFunc) (struct map_session_data **sd, struct questinfo **qi); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_sex_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_quest_questinfo_validate_sex_pre[hIndex].func; + retVal___ = preHookFunc(&sd, &qi); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.quest.questinfo_validate_sex(sd, qi); + } + if (HPMHooks.count.HP_quest_questinfo_validate_sex_post > 0) { + bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_sex_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_quest_questinfo_validate_sex_post[hIndex].func; + retVal___ = postHookFunc(retVal___, sd, qi); + } + } + return retVal___; +} +bool HP_quest_questinfo_validate_baselevel(struct map_session_data *sd, struct questinfo *qi) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_quest_questinfo_validate_baselevel_pre > 0) { + bool (*preHookFunc) (struct map_session_data **sd, struct questinfo **qi); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_baselevel_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_quest_questinfo_validate_baselevel_pre[hIndex].func; + retVal___ = preHookFunc(&sd, &qi); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.quest.questinfo_validate_baselevel(sd, qi); + } + if (HPMHooks.count.HP_quest_questinfo_validate_baselevel_post > 0) { + bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_baselevel_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_quest_questinfo_validate_baselevel_post[hIndex].func; + retVal___ = postHookFunc(retVal___, sd, qi); + } + } + return retVal___; +} +bool HP_quest_questinfo_validate_joblevel(struct map_session_data *sd, struct questinfo *qi) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_quest_questinfo_validate_joblevel_pre > 0) { + bool (*preHookFunc) (struct map_session_data **sd, struct questinfo **qi); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_joblevel_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_quest_questinfo_validate_joblevel_pre[hIndex].func; + retVal___ = preHookFunc(&sd, &qi); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.quest.questinfo_validate_joblevel(sd, qi); + } + if (HPMHooks.count.HP_quest_questinfo_validate_joblevel_post > 0) { + bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_joblevel_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_quest_questinfo_validate_joblevel_post[hIndex].func; + retVal___ = postHookFunc(retVal___, sd, qi); + } + } + return retVal___; +} +bool HP_quest_questinfo_validate_items(struct map_session_data *sd, struct questinfo *qi) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_quest_questinfo_validate_items_pre > 0) { + bool (*preHookFunc) (struct map_session_data **sd, struct questinfo **qi); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_items_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_quest_questinfo_validate_items_pre[hIndex].func; + retVal___ = preHookFunc(&sd, &qi); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.quest.questinfo_validate_items(sd, qi); + } + if (HPMHooks.count.HP_quest_questinfo_validate_items_post > 0) { + bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_items_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_quest_questinfo_validate_items_post[hIndex].func; + retVal___ = postHookFunc(retVal___, sd, qi); + } + } + return retVal___; +} +bool HP_quest_questinfo_validate_homunculus_level(struct map_session_data *sd, struct questinfo *qi) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_quest_questinfo_validate_homunculus_level_pre > 0) { + bool (*preHookFunc) (struct map_session_data **sd, struct questinfo **qi); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_homunculus_level_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_quest_questinfo_validate_homunculus_level_pre[hIndex].func; + retVal___ = preHookFunc(&sd, &qi); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.quest.questinfo_validate_homunculus_level(sd, qi); + } + if (HPMHooks.count.HP_quest_questinfo_validate_homunculus_level_post > 0) { + bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_homunculus_level_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_quest_questinfo_validate_homunculus_level_post[hIndex].func; + retVal___ = postHookFunc(retVal___, sd, qi); + } + } + return retVal___; +} +bool HP_quest_questinfo_validate_homunculus_type(struct map_session_data *sd, struct questinfo *qi) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_quest_questinfo_validate_homunculus_type_pre > 0) { + bool (*preHookFunc) (struct map_session_data **sd, struct questinfo **qi); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_homunculus_type_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_quest_questinfo_validate_homunculus_type_pre[hIndex].func; + retVal___ = preHookFunc(&sd, &qi); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.quest.questinfo_validate_homunculus_type(sd, qi); + } + if (HPMHooks.count.HP_quest_questinfo_validate_homunculus_type_post > 0) { + bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_homunculus_type_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_quest_questinfo_validate_homunculus_type_post[hIndex].func; + retVal___ = postHookFunc(retVal___, sd, qi); + } + } + return retVal___; +} +bool HP_quest_questinfo_validate_quests(struct map_session_data *sd, struct questinfo *qi) { + int hIndex = 0; + bool retVal___ = false; + if (HPMHooks.count.HP_quest_questinfo_validate_quests_pre > 0) { + bool (*preHookFunc) (struct map_session_data **sd, struct questinfo **qi); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_quests_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_quest_questinfo_validate_quests_pre[hIndex].func; + retVal___ = preHookFunc(&sd, &qi); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.quest.questinfo_validate_quests(sd, qi); + } + if (HPMHooks.count.HP_quest_questinfo_validate_quests_post > 0) { + bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, struct questinfo *qi); + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_validate_quests_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_quest_questinfo_validate_quests_post[hIndex].func; + retVal___ = postHookFunc(retVal___, sd, qi); + } + } + return retVal___; +} +void HP_quest_questinfo_vector_clear(int m) { + int hIndex = 0; + if (HPMHooks.count.HP_quest_questinfo_vector_clear_pre > 0) { + void (*preHookFunc) (int *m); + *HPMforce_return = false; + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_vector_clear_pre; hIndex++) { + preHookFunc = HPMHooks.list.HP_quest_questinfo_vector_clear_pre[hIndex].func; + preHookFunc(&m); + } + if (*HPMforce_return) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.quest.questinfo_vector_clear(m); + } + if (HPMHooks.count.HP_quest_questinfo_vector_clear_post > 0) { + void (*postHookFunc) (int m); + for (hIndex = 0; hIndex < HPMHooks.count.HP_quest_questinfo_vector_clear_post; hIndex++) { + postHookFunc = HPMHooks.list.HP_quest_questinfo_vector_clear_post[hIndex].func; + postHookFunc(m); + } + } + return; +} /* rnd_interface */ void HP_rnd_init(void) { int hIndex = 0; @@ -67098,14 +67741,14 @@ const char* HP_script_parse_line(const char *p) { } return retVal___; } -void HP_script_read_constdb(void) { +void HP_script_read_constdb(bool reload) { int hIndex = 0; if (HPMHooks.count.HP_script_read_constdb_pre > 0) { - void (*preHookFunc) (void); + void (*preHookFunc) (bool *reload); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_script_read_constdb_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_script_read_constdb_pre[hIndex].func; - preHookFunc(); + preHookFunc(&reload); } if (*HPMforce_return) { *HPMforce_return = false; @@ -67113,13 +67756,13 @@ void HP_script_read_constdb(void) { } } { - HPMHooks.source.script.read_constdb(); + HPMHooks.source.script.read_constdb(reload); } if (HPMHooks.count.HP_script_read_constdb_post > 0) { - void (*postHookFunc) (void); + void (*postHookFunc) (bool reload); for (hIndex = 0; hIndex < HPMHooks.count.HP_script_read_constdb_post; hIndex++) { postHookFunc = HPMHooks.list.HP_script_read_constdb_post[hIndex].func; - postHookFunc(); + postHookFunc(reload); } } return; @@ -69567,10 +70210,10 @@ bool HP_searchstore_open(struct map_session_data *sd, unsigned int uses, unsigne } return retVal___; } -void HP_searchstore_query(struct map_session_data *sd, unsigned char type, unsigned int min_price, unsigned int max_price, const unsigned short *itemlist, unsigned int item_count, const unsigned short *cardlist, unsigned int card_count) { +void HP_searchstore_query(struct map_session_data *sd, unsigned char type, unsigned int min_price, unsigned int max_price, const uint32 *itemlist, unsigned int item_count, const uint32 *cardlist, unsigned int card_count) { int hIndex = 0; if (HPMHooks.count.HP_searchstore_query_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, unsigned char *type, unsigned int *min_price, unsigned int *max_price, const unsigned short **itemlist, unsigned int *item_count, const unsigned short **cardlist, unsigned int *card_count); + void (*preHookFunc) (struct map_session_data **sd, unsigned char *type, unsigned int *min_price, unsigned int *max_price, const uint32 **itemlist, unsigned int *item_count, const uint32 **cardlist, unsigned int *card_count); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_searchstore_query_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_searchstore_query_pre[hIndex].func; @@ -69585,7 +70228,7 @@ void HP_searchstore_query(struct map_session_data *sd, unsigned char type, unsig HPMHooks.source.searchstore.query(sd, type, min_price, max_price, itemlist, item_count, cardlist, card_count); } if (HPMHooks.count.HP_searchstore_query_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, unsigned char type, unsigned int min_price, unsigned int max_price, const unsigned short *itemlist, unsigned int item_count, const unsigned short *cardlist, unsigned int card_count); + void (*postHookFunc) (struct map_session_data *sd, unsigned char type, unsigned int min_price, unsigned int max_price, const uint32 *itemlist, unsigned int item_count, const uint32 *cardlist, unsigned int card_count); for (hIndex = 0; hIndex < HPMHooks.count.HP_searchstore_query_post; hIndex++) { postHookFunc = HPMHooks.list.HP_searchstore_query_post[hIndex].func; postHookFunc(sd, type, min_price, max_price, itemlist, item_count, cardlist, card_count); @@ -69698,10 +70341,10 @@ void HP_searchstore_close(struct map_session_data *sd) { } return; } -void HP_searchstore_click(struct map_session_data *sd, int account_id, int store_id, unsigned short nameid) { +void HP_searchstore_click(struct map_session_data *sd, int account_id, int store_id, int nameid) { int hIndex = 0; if (HPMHooks.count.HP_searchstore_click_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, int *account_id, int *store_id, unsigned short *nameid); + void (*preHookFunc) (struct map_session_data **sd, int *account_id, int *store_id, int *nameid); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_searchstore_click_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_searchstore_click_pre[hIndex].func; @@ -69716,7 +70359,7 @@ void HP_searchstore_click(struct map_session_data *sd, int account_id, int store HPMHooks.source.searchstore.click(sd, account_id, store_id, nameid); } if (HPMHooks.count.HP_searchstore_click_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, int account_id, int store_id, unsigned short nameid); + void (*postHookFunc) (struct map_session_data *sd, int account_id, int store_id, int nameid); for (hIndex = 0; hIndex < HPMHooks.count.HP_searchstore_click_post; hIndex++) { postHookFunc = HPMHooks.list.HP_searchstore_click_post[hIndex].func; postHookFunc(sd, account_id, store_id, nameid); @@ -69777,15 +70420,15 @@ void HP_searchstore_clearremote(struct map_session_data *sd) { } return; } -bool HP_searchstore_result(struct map_session_data *sd, unsigned int store_id, int account_id, const char *store_name, unsigned short nameid, unsigned short amount, unsigned int price, const short *card, unsigned char refine) { +bool HP_searchstore_result(struct map_session_data *sd, unsigned int store_id, int account_id, const char *store_name, int nameid, unsigned short amount, unsigned int price, const int *card, unsigned char refine, const struct item_option *option) { int hIndex = 0; bool retVal___ = false; if (HPMHooks.count.HP_searchstore_result_pre > 0) { - bool (*preHookFunc) (struct map_session_data **sd, unsigned int *store_id, int *account_id, const char **store_name, unsigned short *nameid, unsigned short *amount, unsigned int *price, const short **card, unsigned char *refine); + bool (*preHookFunc) (struct map_session_data **sd, unsigned int *store_id, int *account_id, const char **store_name, int *nameid, unsigned short *amount, unsigned int *price, const int **card, unsigned char *refine, const struct item_option **option); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_searchstore_result_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_searchstore_result_pre[hIndex].func; - retVal___ = preHookFunc(&sd, &store_id, &account_id, &store_name, &nameid, &amount, &price, &card, &refine); + retVal___ = preHookFunc(&sd, &store_id, &account_id, &store_name, &nameid, &amount, &price, &card, &refine, &option); } if (*HPMforce_return) { *HPMforce_return = false; @@ -69793,13 +70436,13 @@ bool HP_searchstore_result(struct map_session_data *sd, unsigned int store_id, i } } { - retVal___ = HPMHooks.source.searchstore.result(sd, store_id, account_id, store_name, nameid, amount, price, card, refine); + retVal___ = HPMHooks.source.searchstore.result(sd, store_id, account_id, store_name, nameid, amount, price, card, refine, option); } if (HPMHooks.count.HP_searchstore_result_post > 0) { - bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, unsigned int store_id, int account_id, const char *store_name, unsigned short nameid, unsigned short amount, unsigned int price, const short *card, unsigned char refine); + bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, unsigned int store_id, int account_id, const char *store_name, int nameid, unsigned short amount, unsigned int price, const int *card, unsigned char refine, const struct item_option *option); for (hIndex = 0; hIndex < HPMHooks.count.HP_searchstore_result_post; hIndex++) { postHookFunc = HPMHooks.list.HP_searchstore_result_post[hIndex].func; - retVal___ = postHookFunc(retVal___, sd, store_id, account_id, store_name, nameid, amount, price, card, refine); + retVal___ = postHookFunc(retVal___, sd, store_id, account_id, store_name, nameid, amount, price, card, refine, option); } } return retVal___; @@ -76386,31 +77029,32 @@ int HP_skill_check_condition_castbegin_unknown(struct status_change *sc, uint16 } return retVal___; } -void HP_skill_check_condition_castend_unknown(struct map_session_data *sd, uint16 *skill_id, uint16 *skill_lv) { +bool HP_skill_check_condition_castend_unknown(struct map_session_data *sd, uint16 *skill_id, uint16 *skill_lv) { int hIndex = 0; + bool retVal___ = false; if (HPMHooks.count.HP_skill_check_condition_castend_unknown_pre > 0) { - void (*preHookFunc) (struct map_session_data **sd, uint16 **skill_id, uint16 **skill_lv); + bool (*preHookFunc) (struct map_session_data **sd, uint16 **skill_id, uint16 **skill_lv); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_skill_check_condition_castend_unknown_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_skill_check_condition_castend_unknown_pre[hIndex].func; - preHookFunc(&sd, &skill_id, &skill_lv); + retVal___ = preHookFunc(&sd, &skill_id, &skill_lv); } if (*HPMforce_return) { *HPMforce_return = false; - return; + return retVal___; } } { - HPMHooks.source.skill.check_condition_castend_unknown(sd, skill_id, skill_lv); + retVal___ = HPMHooks.source.skill.check_condition_castend_unknown(sd, skill_id, skill_lv); } if (HPMHooks.count.HP_skill_check_condition_castend_unknown_post > 0) { - void (*postHookFunc) (struct map_session_data *sd, uint16 *skill_id, uint16 *skill_lv); + bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, uint16 *skill_id, uint16 *skill_lv); for (hIndex = 0; hIndex < HPMHooks.count.HP_skill_check_condition_castend_unknown_post; hIndex++) { postHookFunc = HPMHooks.list.HP_skill_check_condition_castend_unknown_post[hIndex].func; - postHookFunc(sd, skill_id, skill_lv); + retVal___ = postHookFunc(retVal___, sd, skill_id, skill_lv); } } - return; + return retVal___; } bool HP_skill_get_requirement_off_unknown(struct status_change *sc, uint16 *skill_id) { int hIndex = 0; @@ -85631,11 +86275,11 @@ void HP_vending_purchase(struct map_session_data *sd, int aid, unsigned int uid, } return; } -bool HP_vending_search(struct map_session_data *sd, unsigned short nameid) { +bool HP_vending_search(struct map_session_data *sd, int nameid) { int hIndex = 0; bool retVal___ = false; if (HPMHooks.count.HP_vending_search_pre > 0) { - bool (*preHookFunc) (struct map_session_data **sd, unsigned short *nameid); + bool (*preHookFunc) (struct map_session_data **sd, int *nameid); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_vending_search_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_vending_search_pre[hIndex].func; @@ -85650,7 +86294,7 @@ bool HP_vending_search(struct map_session_data *sd, unsigned short nameid) { retVal___ = HPMHooks.source.vending.search(sd, nameid); } if (HPMHooks.count.HP_vending_search_post > 0) { - bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, unsigned short nameid); + bool (*postHookFunc) (bool retVal___, struct map_session_data *sd, int nameid); for (hIndex = 0; hIndex < HPMHooks.count.HP_vending_search_post; hIndex++) { postHookFunc = HPMHooks.list.HP_vending_search_post[hIndex].func; retVal___ = postHookFunc(retVal___, sd, nameid); diff --git a/src/plugins/Makefile.in b/src/plugins/Makefile.in index ef3f1124b..e90a04f8b 100644 --- a/src/plugins/Makefile.in +++ b/src/plugins/Makefile.in @@ -1,7 +1,7 @@ # This file is part of Hercules. # http://herc.ws - http://github.com/HerculesWS/Hercules # -# Copyright (C) 2013-2016 Hercules Dev Team +# Copyright (C) 2013-2018 Hercules Dev Team # # Hercules is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by diff --git a/src/plugins/constdb2doc.c b/src/plugins/constdb2doc.c index d211c46e2..3f681ea1a 100644 --- a/src/plugins/constdb2doc.c +++ b/src/plugins/constdb2doc.c @@ -86,7 +86,7 @@ void constdb2doc_constdb(void) /* Run */ fprintf(out_fp, "## Constants (db/constants.conf)\n\n"); - script->read_constdb(); + script->read_constdb(false); fprintf(out_fp, "\n"); fprintf(out_fp, "## Hardcoded Constants (source)\n\n"); diff --git a/src/plugins/db2sql.c b/src/plugins/db2sql.c index 38e5ead5d..57e68432e 100644 --- a/src/plugins/db2sql.c +++ b/src/plugins/db2sql.c @@ -242,7 +242,7 @@ int itemdb2sql_sub(struct config_setting_t *entry, int n, const char *source) StrBuf->Init(&buf); // id - StrBuf->Printf(&buf, "'%u',", it->nameid); + StrBuf->Printf(&buf, "'%u',", (uint32)it->nameid); // name_english SQL->EscapeString(NULL, e_name, it->name); @@ -449,7 +449,7 @@ void itemdb2sql_tableheader(void) "\n" "DROP TABLE IF EXISTS `%s`;\n" "CREATE TABLE `%s` (\n" - " `id` smallint(5) UNSIGNED NOT NULL DEFAULT '0',\n" + " `id` int(11) UNSIGNED NOT NULL DEFAULT '0',\n" " `name_english` varchar(50) NOT NULL DEFAULT '',\n" " `name_japanese` varchar(50) NOT NULL DEFAULT '',\n" " `type` tinyint(2) UNSIGNED NOT NULL DEFAULT '0',\n" diff --git a/src/plugins/script_mapquit.c b/src/plugins/script_mapquit.c index 767292f2d..b212ce1c6 100644 --- a/src/plugins/script_mapquit.c +++ b/src/plugins/script_mapquit.c @@ -2,7 +2,7 @@ * This file is part of Hercules. * http://herc.ws - http://github.com/HerculesWS/Hercules * - * Copyright (C) 2014-2015 Hercules Dev Team + * Copyright (C) 2014-2018 Hercules Dev Team * * Hercules is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by |