diff options
author | Haru <haru@dotalux.com> | 2019-08-25 21:13:16 +0200 |
---|---|---|
committer | Haru <haru@dotalux.com> | 2019-09-23 00:05:14 +0200 |
commit | 20a1f4facea1dc58112b5d2609533dc554b0574b (patch) | |
tree | 707162fd5a9a79405e8be1c471e3fa7144c6a73d /src | |
parent | 76f8d6ac833277c1095a234856527d9cb8a47f0d (diff) | |
download | hercules-20a1f4facea1dc58112b5d2609533dc554b0574b.tar.gz hercules-20a1f4facea1dc58112b5d2609533dc554b0574b.tar.bz2 hercules-20a1f4facea1dc58112b5d2609533dc554b0574b.tar.xz hercules-20a1f4facea1dc58112b5d2609533dc554b0574b.zip |
HPM Hooks Update
Signed-off-by: Haru <haru@dotalux.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/plugins/HPMHooking/HPMHooking.Defs.inc | 4 | ||||
-rw-r--r-- | src/plugins/HPMHooking/HPMHooking_map.Hooks.inc | 12 |
2 files changed, 8 insertions, 8 deletions
diff --git a/src/plugins/HPMHooking/HPMHooking.Defs.inc b/src/plugins/HPMHooking/HPMHooking.Defs.inc index 5e79b3fe3..666bdc11d 100644 --- a/src/plugins/HPMHooking/HPMHooking.Defs.inc +++ b/src/plugins/HPMHooking/HPMHooking.Defs.inc @@ -4682,8 +4682,8 @@ typedef void (*HPMHOOK_pre_map_addiddb) (struct block_list **bl); typedef void (*HPMHOOK_post_map_addiddb) (struct block_list *bl); typedef void (*HPMHOOK_pre_map_deliddb) (struct block_list **bl); typedef void (*HPMHOOK_post_map_deliddb) (struct block_list *bl); -typedef struct map_session_data* (*HPMHOOK_pre_map_nick2sd) (const char **nick); -typedef struct map_session_data* (*HPMHOOK_post_map_nick2sd) (struct map_session_data* retVal___, const char *nick); +typedef struct map_session_data* (*HPMHOOK_pre_map_nick2sd) (const char **nick, bool *allow_partial); +typedef struct map_session_data* (*HPMHOOK_post_map_nick2sd) (struct map_session_data* retVal___, const char *nick, bool allow_partial); typedef struct mob_data* (*HPMHOOK_pre_map_getmob_boss) (int16 *m); typedef struct mob_data* (*HPMHOOK_post_map_getmob_boss) (struct mob_data* retVal___, int16 m); typedef struct mob_data* (*HPMHOOK_pre_map_id2boss) (int *id); diff --git a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc index 247087159..9442d1c05 100644 --- a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc +++ b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc @@ -47650,15 +47650,15 @@ void HP_map_deliddb(struct block_list *bl) { } return; } -struct map_session_data* HP_map_nick2sd(const char *nick) { +struct map_session_data* HP_map_nick2sd(const char *nick, bool allow_partial) { int hIndex = 0; struct map_session_data* retVal___ = NULL; if (HPMHooks.count.HP_map_nick2sd_pre > 0) { - struct map_session_data* (*preHookFunc) (const char **nick); + struct map_session_data* (*preHookFunc) (const char **nick, bool *allow_partial); *HPMforce_return = false; for (hIndex = 0; hIndex < HPMHooks.count.HP_map_nick2sd_pre; hIndex++) { preHookFunc = HPMHooks.list.HP_map_nick2sd_pre[hIndex].func; - retVal___ = preHookFunc(&nick); + retVal___ = preHookFunc(&nick, &allow_partial); } if (*HPMforce_return) { *HPMforce_return = false; @@ -47666,13 +47666,13 @@ struct map_session_data* HP_map_nick2sd(const char *nick) { } } { - retVal___ = HPMHooks.source.map.nick2sd(nick); + retVal___ = HPMHooks.source.map.nick2sd(nick, allow_partial); } if (HPMHooks.count.HP_map_nick2sd_post > 0) { - struct map_session_data* (*postHookFunc) (struct map_session_data* retVal___, const char *nick); + struct map_session_data* (*postHookFunc) (struct map_session_data* retVal___, const char *nick, bool allow_partial); for (hIndex = 0; hIndex < HPMHooks.count.HP_map_nick2sd_post; hIndex++) { postHookFunc = HPMHooks.list.HP_map_nick2sd_post[hIndex].func; - retVal___ = postHookFunc(retVal___, nick); + retVal___ = postHookFunc(retVal___, nick, allow_partial); } } return retVal___; |