summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/plugins/HPMHooking/HPMHooking.HPMHooksCore.inc12
-rw-r--r--src/plugins/HPMHooking/HPMHooking.HookingPoints.inc3
-rw-r--r--src/plugins/HPMHooking/HPMHooking.Hooks.inc43
3 files changed, 13 insertions, 45 deletions
diff --git a/src/plugins/HPMHooking/HPMHooking.HPMHooksCore.inc b/src/plugins/HPMHooking/HPMHooking.HPMHooksCore.inc
index feb929dbc..db4a8e5b2 100644
--- a/src/plugins/HPMHooking/HPMHooking.HPMHooksCore.inc
+++ b/src/plugins/HPMHooking/HPMHooking.HPMHooksCore.inc
@@ -2001,10 +2001,8 @@ struct {
struct HPMHookPoint *HP_guild_get_alliance_count_post;
struct HPMHookPoint *HP_guild_castle_reconnect_sub_pre;
struct HPMHookPoint *HP_guild_castle_reconnect_sub_post;
- struct HPMHookPoint *HP_gstorage_id2storage_pre;
- struct HPMHookPoint *HP_gstorage_id2storage_post;
- struct HPMHookPoint *HP_gstorage_id2storage2_pre;
- struct HPMHookPoint *HP_gstorage_id2storage2_post;
+ struct HPMHookPoint *HP_gstorage_ensure_pre;
+ struct HPMHookPoint *HP_gstorage_ensure_post;
struct HPMHookPoint *HP_gstorage_init_pre;
struct HPMHookPoint *HP_gstorage_init_post;
struct HPMHookPoint *HP_gstorage_final_pre;
@@ -7040,10 +7038,8 @@ struct {
int HP_guild_get_alliance_count_post;
int HP_guild_castle_reconnect_sub_pre;
int HP_guild_castle_reconnect_sub_post;
- int HP_gstorage_id2storage_pre;
- int HP_gstorage_id2storage_post;
- int HP_gstorage_id2storage2_pre;
- int HP_gstorage_id2storage2_post;
+ int HP_gstorage_ensure_pre;
+ int HP_gstorage_ensure_post;
int HP_gstorage_init_pre;
int HP_gstorage_init_post;
int HP_gstorage_final_pre;
diff --git a/src/plugins/HPMHooking/HPMHooking.HookingPoints.inc b/src/plugins/HPMHooking/HPMHooking.HookingPoints.inc
index 7c6e6305b..69913405a 100644
--- a/src/plugins/HPMHooking/HPMHooking.HookingPoints.inc
+++ b/src/plugins/HPMHooking/HPMHooking.HookingPoints.inc
@@ -1014,8 +1014,7 @@ struct HookingPointData HookingPoints[] = {
{ HP_POP(guild->get_alliance_count, HP_guild_get_alliance_count) },
{ HP_POP(guild->castle_reconnect_sub, HP_guild_castle_reconnect_sub) },
/* gstorage */
- { HP_POP(gstorage->id2storage, HP_gstorage_id2storage) },
- { HP_POP(gstorage->id2storage2, HP_gstorage_id2storage2) },
+ { HP_POP(gstorage->ensure, HP_gstorage_ensure) },
{ HP_POP(gstorage->init, HP_gstorage_init) },
{ HP_POP(gstorage->final, HP_gstorage_final) },
{ HP_POP(gstorage->delete, HP_gstorage_delete) },
diff --git a/src/plugins/HPMHooking/HPMHooking.Hooks.inc b/src/plugins/HPMHooking/HPMHooking.Hooks.inc
index 4cc8bbf18..c4935ea1b 100644
--- a/src/plugins/HPMHooking/HPMHooking.Hooks.inc
+++ b/src/plugins/HPMHooking/HPMHooking.Hooks.inc
@@ -26430,14 +26430,14 @@ void HP_guild_castle_reconnect_sub(void *key, void *data, va_list ap) {
return;
}
/* gstorage */
-struct guild_storage* HP_gstorage_id2storage(int guild_id) {
+struct guild_storage* HP_gstorage_ensure(int guild_id) {
int hIndex = 0;
struct guild_storage* retVal___ = NULL;
- if( HPMHooks.count.HP_gstorage_id2storage_pre ) {
+ if( HPMHooks.count.HP_gstorage_ensure_pre ) {
struct guild_storage* (*preHookFunc) (int *guild_id);
*HPMforce_return = false;
- for(hIndex = 0; hIndex < HPMHooks.count.HP_gstorage_id2storage_pre; hIndex++ ) {
- preHookFunc = HPMHooks.list.HP_gstorage_id2storage_pre[hIndex].func;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_gstorage_ensure_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_gstorage_ensure_pre[hIndex].func;
retVal___ = preHookFunc(&guild_id);
}
if( *HPMforce_return ) {
@@ -26446,39 +26446,12 @@ struct guild_storage* HP_gstorage_id2storage(int guild_id) {
}
}
{
- retVal___ = HPMHooks.source.gstorage.id2storage(guild_id);
+ retVal___ = HPMHooks.source.gstorage.ensure(guild_id);
}
- if( HPMHooks.count.HP_gstorage_id2storage_post ) {
+ if( HPMHooks.count.HP_gstorage_ensure_post ) {
struct guild_storage* (*postHookFunc) (struct guild_storage* retVal___, int *guild_id);
- for(hIndex = 0; hIndex < HPMHooks.count.HP_gstorage_id2storage_post; hIndex++ ) {
- postHookFunc = HPMHooks.list.HP_gstorage_id2storage_post[hIndex].func;
- retVal___ = postHookFunc(retVal___, &guild_id);
- }
- }
- return retVal___;
-}
-struct guild_storage* HP_gstorage_id2storage2(int guild_id) {
- int hIndex = 0;
- struct guild_storage* retVal___ = NULL;
- if( HPMHooks.count.HP_gstorage_id2storage2_pre ) {
- struct guild_storage* (*preHookFunc) (int *guild_id);
- *HPMforce_return = false;
- for(hIndex = 0; hIndex < HPMHooks.count.HP_gstorage_id2storage2_pre; hIndex++ ) {
- preHookFunc = HPMHooks.list.HP_gstorage_id2storage2_pre[hIndex].func;
- retVal___ = preHookFunc(&guild_id);
- }
- if( *HPMforce_return ) {
- *HPMforce_return = false;
- return retVal___;
- }
- }
- {
- retVal___ = HPMHooks.source.gstorage.id2storage2(guild_id);
- }
- if( HPMHooks.count.HP_gstorage_id2storage2_post ) {
- struct guild_storage* (*postHookFunc) (struct guild_storage* retVal___, int *guild_id);
- for(hIndex = 0; hIndex < HPMHooks.count.HP_gstorage_id2storage2_post; hIndex++ ) {
- postHookFunc = HPMHooks.list.HP_gstorage_id2storage2_post[hIndex].func;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_gstorage_ensure_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_gstorage_ensure_post[hIndex].func;
retVal___ = postHookFunc(retVal___, &guild_id);
}
}