diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/common/HPMDataCheck.h | 1 | ||||
-rw-r--r-- | src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc | 4 | ||||
-rw-r--r-- | src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc | 1 | ||||
-rw-r--r-- | src/plugins/HPMHooking/HPMHooking_map.Hooks.inc | 26 |
4 files changed, 32 insertions, 0 deletions
diff --git a/src/common/HPMDataCheck.h b/src/common/HPMDataCheck.h index ae721af39..666d306db 100644 --- a/src/common/HPMDataCheck.h +++ b/src/common/HPMDataCheck.h @@ -587,6 +587,7 @@ HPExport const struct s_HPMDataCheck HPMDataCheck[] = { { "s_autospell", sizeof(struct s_autospell), SERVER_TYPE_MAP }, { "sg_data", sizeof(struct sg_data), SERVER_TYPE_MAP }, { "skill_tree_entry", sizeof(struct skill_tree_entry), SERVER_TYPE_MAP }, + { "skill_tree_requirement", sizeof(struct skill_tree_requirement), SERVER_TYPE_MAP }, { "weapon_data", sizeof(struct weapon_data), SERVER_TYPE_MAP }, #else #define MAP_PC_H diff --git a/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc b/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc index d9c2997d7..ccc908c33 100644 --- a/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc +++ b/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc @@ -4262,6 +4262,8 @@ struct { struct HPMHookPoint *HP_pc_follow_timer_post; struct HPMHookPoint *HP_pc_read_skill_tree_pre; struct HPMHookPoint *HP_pc_read_skill_tree_post; + struct HPMHookPoint *HP_pc_clear_skill_tree_pre; + struct HPMHookPoint *HP_pc_clear_skill_tree_post; struct HPMHookPoint *HP_pc_isUseitem_pre; struct HPMHookPoint *HP_pc_isUseitem_post; struct HPMHookPoint *HP_pc_show_steal_pre; @@ -10089,6 +10091,8 @@ struct { int HP_pc_follow_timer_post; int HP_pc_read_skill_tree_pre; int HP_pc_read_skill_tree_post; + int HP_pc_clear_skill_tree_pre; + int HP_pc_clear_skill_tree_post; int HP_pc_isUseitem_pre; int HP_pc_isUseitem_post; int HP_pc_show_steal_pre; diff --git a/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc b/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc index f13dfe93f..514a79ba1 100644 --- a/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc +++ b/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc @@ -2181,6 +2181,7 @@ struct HookingPointData HookingPoints[] = { { HP_POP(pc->autosave, HP_pc_autosave) }, { HP_POP(pc->follow_timer, HP_pc_follow_timer) }, { HP_POP(pc->read_skill_tree, HP_pc_read_skill_tree) }, + { HP_POP(pc->clear_skill_tree, HP_pc_clear_skill_tree) }, { HP_POP(pc->isUseitem, HP_pc_isUseitem) }, { HP_POP(pc->show_steal, HP_pc_show_steal) }, { HP_POP(pc->checkcombo, HP_pc_checkcombo) }, diff --git a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc index eee171ee4..96956f753 100644 --- a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc +++ b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc @@ -56817,6 +56817,32 @@ void HP_pc_read_skill_tree(void) { } return; } +void HP_pc_clear_skill_tree(void) { + int hIndex = 0; + if( HPMHooks.count.HP_pc_clear_skill_tree_pre ) { + void (*preHookFunc) (void); + *HPMforce_return = false; + for(hIndex = 0; hIndex < HPMHooks.count.HP_pc_clear_skill_tree_pre; hIndex++ ) { + preHookFunc = HPMHooks.list.HP_pc_clear_skill_tree_pre[hIndex].func; + preHookFunc(); + } + if( *HPMforce_return ) { + *HPMforce_return = false; + return; + } + } + { + HPMHooks.source.pc.clear_skill_tree(); + } + if( HPMHooks.count.HP_pc_clear_skill_tree_post ) { + void (*postHookFunc) (void); + for(hIndex = 0; hIndex < HPMHooks.count.HP_pc_clear_skill_tree_post; hIndex++ ) { + postHookFunc = HPMHooks.list.HP_pc_clear_skill_tree_post[hIndex].func; + postHookFunc(); + } + } + return; +} int HP_pc_isUseitem(struct map_session_data *sd, int n) { int hIndex = 0; int retVal___ = 0; |