summaryrefslogtreecommitdiff
path: root/src/plugins/HPMHooking/HPMHooking.Hooks.inc
diff options
context:
space:
mode:
authorHercules.ws <Hercules@efficiently.awesome>2014-01-12 16:28:42 +0100
committerHerculesWSAPI <Hercules@efficiently.awesome>2014-01-12 16:28:42 +0100
commitf345e3e50558920cf9a8e7fe142e3e6234b2ee32 (patch)
tree093db86877b629d0ef739e18d8da30583f87ed59 /src/plugins/HPMHooking/HPMHooking.Hooks.inc
parent209d15e07d52a52c110b01f4bad0b52080a69550 (diff)
downloadhercules-f345e3e50558920cf9a8e7fe142e3e6234b2ee32.tar.gz
hercules-f345e3e50558920cf9a8e7fe142e3e6234b2ee32.tar.bz2
hercules-f345e3e50558920cf9a8e7fe142e3e6234b2ee32.tar.xz
hercules-f345e3e50558920cf9a8e7fe142e3e6234b2ee32.zip
HPM Hooks Update
Signed-off-by: HerculesWSAPI <Hercules@efficiently.awesome>
Diffstat (limited to 'src/plugins/HPMHooking/HPMHooking.Hooks.inc')
-rw-r--r--src/plugins/HPMHooking/HPMHooking.Hooks.inc25
1 files changed, 25 insertions, 0 deletions
diff --git a/src/plugins/HPMHooking/HPMHooking.Hooks.inc b/src/plugins/HPMHooking/HPMHooking.Hooks.inc
index cca7405e5..9bbb01ade 100644
--- a/src/plugins/HPMHooking/HPMHooking.Hooks.inc
+++ b/src/plugins/HPMHooking/HPMHooking.Hooks.inc
@@ -55078,6 +55078,31 @@ int HP_script_array_free_db(DBKey key, DBData *data, va_list ap) {
}
return retVal___;
}
+void HP_script_array_ensure_zero(struct script_state *st, struct map_session_data *sd, int64 uid, struct DBMap **ref) {
+ int hIndex = 0;
+ if( HPMHooks.count.HP_script_array_ensure_zero_pre ) {
+ void (*preHookFunc) (struct script_state *st, struct map_session_data *sd, int64 *uid, struct DBMap **ref);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_script_array_ensure_zero_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_script_array_ensure_zero_pre[hIndex].func;
+ preHookFunc(st, sd, &uid, ref);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return;
+ }
+ }
+ {
+ HPMHooks.source.script.array_ensure_zero(st, sd, uid, ref);
+ }
+ if( HPMHooks.count.HP_script_array_ensure_zero_post ) {
+ void (*postHookFunc) (struct script_state *st, struct map_session_data *sd, int64 *uid, struct DBMap **ref);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_script_array_ensure_zero_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_script_array_ensure_zero_post[hIndex].func;
+ postHookFunc(st, sd, &uid, ref);
+ }
+ }
+ return;
+}
void HP_script_reg_destroy_single(struct map_session_data *sd, int64 reg, struct script_reg_state *data) {
int hIndex = 0;
if( HPMHooks.count.HP_script_reg_destroy_single_pre ) {