summaryrefslogtreecommitdiff
path: root/src/plugins/HPMHooking/HPMHooking.Hooks.inc
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/HPMHooking/HPMHooking.Hooks.inc')
-rw-r--r--src/plugins/HPMHooking/HPMHooking.Hooks.inc38
1 files changed, 6 insertions, 32 deletions
diff --git a/src/plugins/HPMHooking/HPMHooking.Hooks.inc b/src/plugins/HPMHooking/HPMHooking.Hooks.inc
index 626040e7a..606197a6c 100644
--- a/src/plugins/HPMHooking/HPMHooking.Hooks.inc
+++ b/src/plugins/HPMHooking/HPMHooking.Hooks.inc
@@ -32693,14 +32693,14 @@ int HP_itemdb_readdb_sql(const char *tablename) {
}
return retVal___;
}
-uint64 HP_itemdb_unique_id(int8 flag, int64 value) {
+uint64 HP_itemdb_unique_id(struct map_session_data *sd) {
int hIndex = 0;
uint64 retVal___ = 0;
if( HPMHooks.count.HP_itemdb_unique_id_pre ) {
- uint64 (*preHookFunc) (int8 *flag, int64 *value);
+ uint64 (*preHookFunc) (struct map_session_data *sd);
for(hIndex = 0; hIndex < HPMHooks.count.HP_itemdb_unique_id_pre; hIndex++ ) {
preHookFunc = HPMHooks.list.HP_itemdb_unique_id_pre[hIndex].func;
- retVal___ = preHookFunc(&flag, &value);
+ retVal___ = preHookFunc(sd);
}
if( *HPMforce_return ) {
*HPMforce_return = false;
@@ -32708,39 +32708,13 @@ uint64 HP_itemdb_unique_id(int8 flag, int64 value) {
}
}
{
- retVal___ = HPMHooks.source.itemdb.unique_id(flag, value);
+ retVal___ = HPMHooks.source.itemdb.unique_id(sd);
}
if( HPMHooks.count.HP_itemdb_unique_id_post ) {
- uint64 (*postHookFunc) (uint64 retVal___, int8 *flag, int64 *value);
+ uint64 (*postHookFunc) (uint64 retVal___, struct map_session_data *sd);
for(hIndex = 0; hIndex < HPMHooks.count.HP_itemdb_unique_id_post; hIndex++ ) {
postHookFunc = HPMHooks.list.HP_itemdb_unique_id_post[hIndex].func;
- retVal___ = postHookFunc(retVal___, &flag, &value);
- }
- }
- return retVal___;
-}
-int HP_itemdb_uid_load(void) {
- int hIndex = 0;
- int retVal___ = 0;
- if( HPMHooks.count.HP_itemdb_uid_load_pre ) {
- int (*preHookFunc) (void);
- for(hIndex = 0; hIndex < HPMHooks.count.HP_itemdb_uid_load_pre; hIndex++ ) {
- preHookFunc = HPMHooks.list.HP_itemdb_uid_load_pre[hIndex].func;
- retVal___ = preHookFunc();
- }
- if( *HPMforce_return ) {
- *HPMforce_return = false;
- return retVal___;
- }
- }
- {
- retVal___ = HPMHooks.source.itemdb.uid_load();
- }
- if( HPMHooks.count.HP_itemdb_uid_load_post ) {
- int (*postHookFunc) (int retVal___);
- for(hIndex = 0; hIndex < HPMHooks.count.HP_itemdb_uid_load_post; hIndex++ ) {
- postHookFunc = HPMHooks.list.HP_itemdb_uid_load_post[hIndex].func;
- retVal___ = postHookFunc(retVal___);
+ retVal___ = postHookFunc(retVal___, sd);
}
}
return retVal___;