summaryrefslogtreecommitdiff
path: root/src/plugins/HPMHooking/HPMHooking_char.Hooks.inc
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/HPMHooking/HPMHooking_char.Hooks.inc')
-rw-r--r--src/plugins/HPMHooking/HPMHooking_char.Hooks.inc530
1 files changed, 468 insertions, 62 deletions
diff --git a/src/plugins/HPMHooking/HPMHooking_char.Hooks.inc b/src/plugins/HPMHooking/HPMHooking_char.Hooks.inc
index aecffbecd..3669b2da8 100644
--- a/src/plugins/HPMHooking/HPMHooking_char.Hooks.inc
+++ b/src/plugins/HPMHooking/HPMHooking_char.Hooks.inc
@@ -4216,67 +4216,123 @@ int HP_chr_online_data_cleanup(int tid, int64 tick, int id, intptr_t data) {
}
return retVal___;
}
-void HP_chr_sql_config_read(const char *cfgName) {
+bool HP_chr_sql_config_read(const char *filename, bool imported) {
int hIndex = 0;
+ bool retVal___ = false;
if( HPMHooks.count.HP_chr_sql_config_read_pre ) {
- void (*preHookFunc) (const char **cfgName);
+ bool (*preHookFunc) (const char **filename, bool *imported);
*HPMforce_return = false;
for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_sql_config_read_pre; hIndex++ ) {
preHookFunc = HPMHooks.list.HP_chr_sql_config_read_pre[hIndex].func;
- preHookFunc(&cfgName);
+ retVal___ = preHookFunc(&filename, &imported);
}
if( *HPMforce_return ) {
*HPMforce_return = false;
- return;
+ return retVal___;
}
}
{
- HPMHooks.source.chr.sql_config_read(cfgName);
+ retVal___ = HPMHooks.source.chr.sql_config_read(filename, imported);
}
if( HPMHooks.count.HP_chr_sql_config_read_post ) {
- void (*postHookFunc) (const char *cfgName);
+ bool (*postHookFunc) (bool retVal___, const char *filename, bool imported);
for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_sql_config_read_post; hIndex++ ) {
postHookFunc = HPMHooks.list.HP_chr_sql_config_read_post[hIndex].func;
- postHookFunc(cfgName);
+ retVal___ = postHookFunc(retVal___, filename, imported);
}
}
- return;
+ return retVal___;
}
-void HP_chr_config_dispatch(char *w1, char *w2) {
+bool HP_chr_sql_config_read_registry(const char *filename, const struct config_t *config, bool imported) {
int hIndex = 0;
- if( HPMHooks.count.HP_chr_config_dispatch_pre ) {
- void (*preHookFunc) (char **w1, char **w2);
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_chr_sql_config_read_registry_pre ) {
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
*HPMforce_return = false;
- for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_dispatch_pre; hIndex++ ) {
- preHookFunc = HPMHooks.list.HP_chr_config_dispatch_pre[hIndex].func;
- preHookFunc(&w1, &w2);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_sql_config_read_registry_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_chr_sql_config_read_registry_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &config, &imported);
}
if( *HPMforce_return ) {
*HPMforce_return = false;
- return;
+ return retVal___;
}
}
{
- HPMHooks.source.chr.config_dispatch(w1, w2);
+ retVal___ = HPMHooks.source.chr.sql_config_read_registry(filename, config, imported);
}
- if( HPMHooks.count.HP_chr_config_dispatch_post ) {
- void (*postHookFunc) (char *w1, char *w2);
- for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_dispatch_post; hIndex++ ) {
- postHookFunc = HPMHooks.list.HP_chr_config_dispatch_post[hIndex].func;
- postHookFunc(w1, w2);
+ if( HPMHooks.count.HP_chr_sql_config_read_registry_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_sql_config_read_registry_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_chr_sql_config_read_registry_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
}
}
- return;
+ return retVal___;
}
-int HP_chr_config_read(const char *cfgName) {
+bool HP_chr_sql_config_read_pc(const char *filename, const struct config_t *config, bool imported) {
int hIndex = 0;
- int retVal___ = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_chr_sql_config_read_pc_pre ) {
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_sql_config_read_pc_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_chr_sql_config_read_pc_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &config, &imported);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.chr.sql_config_read_pc(filename, config, imported);
+ }
+ if( HPMHooks.count.HP_chr_sql_config_read_pc_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_sql_config_read_pc_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_chr_sql_config_read_pc_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
+ }
+ }
+ return retVal___;
+}
+bool HP_chr_sql_config_read_guild(const char *filename, const struct config_t *config, bool imported) {
+ int hIndex = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_chr_sql_config_read_guild_pre ) {
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_sql_config_read_guild_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_chr_sql_config_read_guild_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &config, &imported);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.chr.sql_config_read_guild(filename, config, imported);
+ }
+ if( HPMHooks.count.HP_chr_sql_config_read_guild_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_sql_config_read_guild_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_chr_sql_config_read_guild_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
+ }
+ }
+ return retVal___;
+}
+bool HP_chr_config_read(const char *filename, bool imported) {
+ int hIndex = 0;
+ bool retVal___ = false;
if( HPMHooks.count.HP_chr_config_read_pre ) {
- int (*preHookFunc) (const char **cfgName);
+ bool (*preHookFunc) (const char **filename, bool *imported);
*HPMforce_return = false;
for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_pre; hIndex++ ) {
preHookFunc = HPMHooks.list.HP_chr_config_read_pre[hIndex].func;
- retVal___ = preHookFunc(&cfgName);
+ retVal___ = preHookFunc(&filename, &imported);
}
if( *HPMforce_return ) {
*HPMforce_return = false;
@@ -4284,13 +4340,336 @@ int HP_chr_config_read(const char *cfgName) {
}
}
{
- retVal___ = HPMHooks.source.chr.config_read(cfgName);
+ retVal___ = HPMHooks.source.chr.config_read(filename, imported);
}
if( HPMHooks.count.HP_chr_config_read_post ) {
- int (*postHookFunc) (int retVal___, const char *cfgName);
+ bool (*postHookFunc) (bool retVal___, const char *filename, bool imported);
for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_post; hIndex++ ) {
postHookFunc = HPMHooks.list.HP_chr_config_read_post[hIndex].func;
- retVal___ = postHookFunc(retVal___, cfgName);
+ retVal___ = postHookFunc(retVal___, filename, imported);
+ }
+ }
+ return retVal___;
+}
+bool HP_chr_config_read_database(const char *filename, const struct config_t *config, bool imported) {
+ int hIndex = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_chr_config_read_database_pre ) {
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_database_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_chr_config_read_database_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &config, &imported);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.chr.config_read_database(filename, config, imported);
+ }
+ if( HPMHooks.count.HP_chr_config_read_database_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_database_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_chr_config_read_database_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
+ }
+ }
+ return retVal___;
+}
+bool HP_chr_config_read_console(const char *filename, const struct config_t *config, bool imported) {
+ int hIndex = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_chr_config_read_console_pre ) {
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_console_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_chr_config_read_console_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &config, &imported);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.chr.config_read_console(filename, config, imported);
+ }
+ if( HPMHooks.count.HP_chr_config_read_console_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_console_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_chr_config_read_console_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
+ }
+ }
+ return retVal___;
+}
+bool HP_chr_config_read_player_fame(const char *filename, const struct config_t *config, bool imported) {
+ int hIndex = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_chr_config_read_player_fame_pre ) {
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_player_fame_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_chr_config_read_player_fame_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &config, &imported);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.chr.config_read_player_fame(filename, config, imported);
+ }
+ if( HPMHooks.count.HP_chr_config_read_player_fame_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_player_fame_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_chr_config_read_player_fame_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
+ }
+ }
+ return retVal___;
+}
+bool HP_chr_config_read_player_deletion(const char *filename, const struct config_t *config, bool imported) {
+ int hIndex = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_chr_config_read_player_deletion_pre ) {
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_player_deletion_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_chr_config_read_player_deletion_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &config, &imported);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.chr.config_read_player_deletion(filename, config, imported);
+ }
+ if( HPMHooks.count.HP_chr_config_read_player_deletion_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_player_deletion_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_chr_config_read_player_deletion_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
+ }
+ }
+ return retVal___;
+}
+bool HP_chr_config_read_player_name(const char *filename, const struct config_t *config, bool imported) {
+ int hIndex = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_chr_config_read_player_name_pre ) {
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_player_name_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_chr_config_read_player_name_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &config, &imported);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.chr.config_read_player_name(filename, config, imported);
+ }
+ if( HPMHooks.count.HP_chr_config_read_player_name_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_player_name_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_chr_config_read_player_name_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
+ }
+ }
+ return retVal___;
+}
+void HP_chr_config_set_start_item(const struct config_setting_t *setting) {
+ int hIndex = 0;
+ if( HPMHooks.count.HP_chr_config_set_start_item_pre ) {
+ void (*preHookFunc) (const struct config_setting_t **setting);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_set_start_item_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_chr_config_set_start_item_pre[hIndex].func;
+ preHookFunc(&setting);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return;
+ }
+ }
+ {
+ HPMHooks.source.chr.config_set_start_item(setting);
+ }
+ if( HPMHooks.count.HP_chr_config_set_start_item_post ) {
+ void (*postHookFunc) (const struct config_setting_t *setting);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_set_start_item_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_chr_config_set_start_item_post[hIndex].func;
+ postHookFunc(setting);
+ }
+ }
+ return;
+}
+bool HP_chr_config_read_player_new(const char *filename, const struct config_t *config, bool imported) {
+ int hIndex = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_chr_config_read_player_new_pre ) {
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_player_new_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_chr_config_read_player_new_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &config, &imported);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.chr.config_read_player_new(filename, config, imported);
+ }
+ if( HPMHooks.count.HP_chr_config_read_player_new_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_player_new_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_chr_config_read_player_new_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
+ }
+ }
+ return retVal___;
+}
+bool HP_chr_config_read_player(const char *filename, const struct config_t *config, bool imported) {
+ int hIndex = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_chr_config_read_player_pre ) {
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_player_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_chr_config_read_player_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &config, &imported);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.chr.config_read_player(filename, config, imported);
+ }
+ if( HPMHooks.count.HP_chr_config_read_player_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_player_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_chr_config_read_player_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
+ }
+ }
+ return retVal___;
+}
+bool HP_chr_config_read_permission(const char *filename, const struct config_t *config, bool imported) {
+ int hIndex = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_chr_config_read_permission_pre ) {
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_permission_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_chr_config_read_permission_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &config, &imported);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.chr.config_read_permission(filename, config, imported);
+ }
+ if( HPMHooks.count.HP_chr_config_read_permission_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_permission_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_chr_config_read_permission_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
+ }
+ }
+ return retVal___;
+}
+bool HP_chr_config_set_ip(const char *type, const char *value, uint32 *out_ip, char *out_ip_str) {
+ int hIndex = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_chr_config_set_ip_pre ) {
+ bool (*preHookFunc) (const char **type, const char **value, uint32 **out_ip, char **out_ip_str);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_set_ip_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_chr_config_set_ip_pre[hIndex].func;
+ retVal___ = preHookFunc(&type, &value, &out_ip, &out_ip_str);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.chr.config_set_ip(type, value, out_ip, out_ip_str);
+ }
+ if( HPMHooks.count.HP_chr_config_set_ip_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *type, const char *value, uint32 *out_ip, char *out_ip_str);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_set_ip_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_chr_config_set_ip_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, type, value, out_ip, out_ip_str);
+ }
+ }
+ return retVal___;
+}
+bool HP_chr_config_read_inter(const char *filename, const struct config_t *config, bool imported) {
+ int hIndex = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_chr_config_read_inter_pre ) {
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_inter_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_chr_config_read_inter_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &config, &imported);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.chr.config_read_inter(filename, config, imported);
+ }
+ if( HPMHooks.count.HP_chr_config_read_inter_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_inter_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_chr_config_read_inter_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
+ }
+ }
+ return retVal___;
+}
+bool HP_chr_config_read_top(const char *filename, const struct config_t *config, bool imported) {
+ int hIndex = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_chr_config_read_top_pre ) {
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_top_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_chr_config_read_top_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &config, &imported);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.chr.config_read_top(filename, config, imported);
+ }
+ if( HPMHooks.count.HP_chr_config_read_top_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_chr_config_read_top_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_chr_config_read_top_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
}
}
return retVal___;
@@ -6427,33 +6806,6 @@ int HP_inter_accreg_fromsql(int account_id, int char_id, int fd, int type) {
}
return retVal___;
}
-int HP_inter_config_read(const char *cfgName) {
- int hIndex = 0;
- int retVal___ = 0;
- if( HPMHooks.count.HP_inter_config_read_pre ) {
- int (*preHookFunc) (const char **cfgName);
- *HPMforce_return = false;
- for(hIndex = 0; hIndex < HPMHooks.count.HP_inter_config_read_pre; hIndex++ ) {
- preHookFunc = HPMHooks.list.HP_inter_config_read_pre[hIndex].func;
- retVal___ = preHookFunc(&cfgName);
- }
- if( *HPMforce_return ) {
- *HPMforce_return = false;
- return retVal___;
- }
- }
- {
- retVal___ = HPMHooks.source.inter.config_read(cfgName);
- }
- if( HPMHooks.count.HP_inter_config_read_post ) {
- int (*postHookFunc) (int retVal___, const char *cfgName);
- for(hIndex = 0; hIndex < HPMHooks.count.HP_inter_config_read_post; hIndex++ ) {
- postHookFunc = HPMHooks.list.HP_inter_config_read_post[hIndex].func;
- retVal___ = postHookFunc(retVal___, cfgName);
- }
- }
- return retVal___;
-}
int HP_inter_vlog(char *fmt, va_list ap) {
int hIndex = 0;
int retVal___ = 0;
@@ -6681,6 +7033,60 @@ void HP_inter_final(void) {
}
return;
}
+bool HP_inter_config_read(const char *filename, bool imported) {
+ int hIndex = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_inter_config_read_pre ) {
+ bool (*preHookFunc) (const char **filename, bool *imported);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_inter_config_read_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_inter_config_read_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &imported);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.inter.config_read(filename, imported);
+ }
+ if( HPMHooks.count.HP_inter_config_read_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_inter_config_read_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_inter_config_read_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, imported);
+ }
+ }
+ return retVal___;
+}
+bool HP_inter_config_read_connection(const char *filename, const struct config_t *config, bool imported) {
+ int hIndex = 0;
+ bool retVal___ = false;
+ if( HPMHooks.count.HP_inter_config_read_connection_pre ) {
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_inter_config_read_connection_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_inter_config_read_connection_pre[hIndex].func;
+ retVal___ = preHookFunc(&filename, &config, &imported);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.inter.config_read_connection(filename, config, imported);
+ }
+ if( HPMHooks.count.HP_inter_config_read_connection_post ) {
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_inter_config_read_connection_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_inter_config_read_connection_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
+ }
+ }
+ return retVal___;
+}
/* inter_mail_interface */
int HP_inter_mail_sql_init(void) {
int hIndex = 0;
@@ -15726,15 +16132,15 @@ void HP_pincode_check(int fd, struct char_session_data *sd) {
}
return;
}
-bool HP_pincode_config_read(char *w1, char *w2) {
+bool HP_pincode_config_read(const char *filename, const struct config_t *config, bool imported) {
int hIndex = 0;
bool retVal___ = false;
if( HPMHooks.count.HP_pincode_config_read_pre ) {
- bool (*preHookFunc) (char **w1, char **w2);
+ bool (*preHookFunc) (const char **filename, const struct config_t **config, bool *imported);
*HPMforce_return = false;
for(hIndex = 0; hIndex < HPMHooks.count.HP_pincode_config_read_pre; hIndex++ ) {
preHookFunc = HPMHooks.list.HP_pincode_config_read_pre[hIndex].func;
- retVal___ = preHookFunc(&w1, &w2);
+ retVal___ = preHookFunc(&filename, &config, &imported);
}
if( *HPMforce_return ) {
*HPMforce_return = false;
@@ -15742,13 +16148,13 @@ bool HP_pincode_config_read(char *w1, char *w2) {
}
}
{
- retVal___ = HPMHooks.source.pincode.config_read(w1, w2);
+ retVal___ = HPMHooks.source.pincode.config_read(filename, config, imported);
}
if( HPMHooks.count.HP_pincode_config_read_post ) {
- bool (*postHookFunc) (bool retVal___, char *w1, char *w2);
+ bool (*postHookFunc) (bool retVal___, const char *filename, const struct config_t *config, bool imported);
for(hIndex = 0; hIndex < HPMHooks.count.HP_pincode_config_read_post; hIndex++ ) {
postHookFunc = HPMHooks.list.HP_pincode_config_read_post[hIndex].func;
- retVal___ = postHookFunc(retVal___, w1, w2);
+ retVal___ = postHookFunc(retVal___, filename, config, imported);
}
}
return retVal___;