diff options
Diffstat (limited to 'src/plugins/HPMHooking/HPMHooking_map.Hooks.inc')
-rw-r--r-- | src/plugins/HPMHooking/HPMHooking_map.Hooks.inc | 39 |
1 files changed, 33 insertions, 6 deletions
diff --git a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc index 3407c3268..9b518d097 100644 --- a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc +++ b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc @@ -35481,15 +35481,15 @@ int HP_map_moveblock(struct block_list *bl, int x1, int y1, int64 tick) { } return retVal___; } -int HP_map_count_oncell(int16 m, int16 x, int16 y, int type) { +int HP_map_count_oncell(int16 m, int16 x, int16 y, int type, int flag) { int hIndex = 0; int retVal___ = 0; if( HPMHooks.count.HP_map_count_oncell_pre ) { - int (*preHookFunc) (int16 *m, int16 *x, int16 *y, int *type); + int (*preHookFunc) (int16 *m, int16 *x, int16 *y, int *type, int *flag); *HPMforce_return = false; for(hIndex = 0; hIndex < HPMHooks.count.HP_map_count_oncell_pre; hIndex++ ) { preHookFunc = HPMHooks.list.HP_map_count_oncell_pre[hIndex].func; - retVal___ = preHookFunc(&m, &x, &y, &type); + retVal___ = preHookFunc(&m, &x, &y, &type, &flag); } if( *HPMforce_return ) { *HPMforce_return = false; @@ -35497,13 +35497,13 @@ int HP_map_count_oncell(int16 m, int16 x, int16 y, int type) { } } { - retVal___ = HPMHooks.source.map.count_oncell(m, x, y, type); + retVal___ = HPMHooks.source.map.count_oncell(m, x, y, type, flag); } if( HPMHooks.count.HP_map_count_oncell_post ) { - int (*postHookFunc) (int retVal___, int16 *m, int16 *x, int16 *y, int *type); + int (*postHookFunc) (int retVal___, int16 *m, int16 *x, int16 *y, int *type, int *flag); for(hIndex = 0; hIndex < HPMHooks.count.HP_map_count_oncell_post; hIndex++ ) { postHookFunc = HPMHooks.list.HP_map_count_oncell_post[hIndex].func; - retVal___ = postHookFunc(retVal___, &m, &x, &y, &type); + retVal___ = postHookFunc(retVal___, &m, &x, &y, &type, &flag); } } return retVal___; @@ -35589,6 +35589,33 @@ int HP_map_search_freecell(struct block_list *src, int16 m, int16 *x, int16 *y, } return retVal___; } +bool HP_map_closest_freecell(int16 m, int16 *x, int16 *y, int type, int flag) { + int hIndex = 0; + bool retVal___ = false; + if( HPMHooks.count.HP_map_closest_freecell_pre ) { + bool (*preHookFunc) (int16 *m, int16 *x, int16 *y, int *type, int *flag); + *HPMforce_return = false; + for(hIndex = 0; hIndex < HPMHooks.count.HP_map_closest_freecell_pre; hIndex++ ) { + preHookFunc = HPMHooks.list.HP_map_closest_freecell_pre[hIndex].func; + retVal___ = preHookFunc(&m, x, y, &type, &flag); + } + if( *HPMforce_return ) { + *HPMforce_return = false; + return retVal___; + } + } + { + retVal___ = HPMHooks.source.map.closest_freecell(m, x, y, type, flag); + } + if( HPMHooks.count.HP_map_closest_freecell_post ) { + bool (*postHookFunc) (bool retVal___, int16 *m, int16 *x, int16 *y, int *type, int *flag); + for(hIndex = 0; hIndex < HPMHooks.count.HP_map_closest_freecell_post; hIndex++ ) { + postHookFunc = HPMHooks.list.HP_map_closest_freecell_post[hIndex].func; + retVal___ = postHookFunc(retVal___, &m, x, y, &type, &flag); + } + } + return retVal___; +} int HP_map_quit(struct map_session_data *sd) { int hIndex = 0; int retVal___ = 0; |