summaryrefslogtreecommitdiff
path: root/src/plugins/HPMHooking
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/HPMHooking')
-rw-r--r--src/plugins/HPMHooking/HPMHooking.Defs.inc10
-rw-r--r--src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc12
-rw-r--r--src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc3
-rw-r--r--src/plugins/HPMHooking/HPMHooking_map.Hooks.inc90
4 files changed, 107 insertions, 8 deletions
diff --git a/src/plugins/HPMHooking/HPMHooking.Defs.inc b/src/plugins/HPMHooking/HPMHooking.Defs.inc
index e3fbb178e..0c63a98b6 100644
--- a/src/plugins/HPMHooking/HPMHooking.Defs.inc
+++ b/src/plugins/HPMHooking/HPMHooking.Defs.inc
@@ -1228,8 +1228,8 @@ typedef void (*HPMHOOK_pre_clif_map_type) (struct map_session_data **sd, enum ma
typedef void (*HPMHOOK_post_clif_map_type) (struct map_session_data *sd, enum map_type type);
typedef void (*HPMHOOK_pre_clif_maptypeproperty2) (struct block_list **bl, enum send_target *t);
typedef void (*HPMHOOK_post_clif_maptypeproperty2) (struct block_list *bl, enum send_target t);
-typedef void (*HPMHOOK_pre_clif_changemapserver) (struct map_session_data **sd, unsigned short *map_index, int *x, int *y, uint32 *ip, uint16 *port);
-typedef void (*HPMHOOK_post_clif_changemapserver) (struct map_session_data *sd, unsigned short map_index, int x, int y, uint32 ip, uint16 port);
+typedef void (*HPMHOOK_pre_clif_changemapserver) (struct map_session_data **sd, unsigned short *map_index, int *x, int *y, uint32 *ip, uint16 *port, char **dnsHost);
+typedef void (*HPMHOOK_post_clif_changemapserver) (struct map_session_data *sd, unsigned short map_index, int x, int y, uint32 ip, uint16 port, char *dnsHost);
typedef void (*HPMHOOK_pre_clif_changemapserver_airship) (struct map_session_data **sd, unsigned short *map_index, int *x, int *y, uint32 *ip, uint16 *port);
typedef void (*HPMHOOK_post_clif_changemapserver_airship) (struct map_session_data *sd, unsigned short map_index, int x, int y, uint32 ip, uint16 port);
typedef void (*HPMHOOK_pre_clif_npcbuysell) (struct map_session_data **sd, int *id);
@@ -2542,6 +2542,10 @@ typedef void (*HPMHOOK_pre_clif_hat_effect) (struct block_list **bl, struct bloc
typedef void (*HPMHOOK_post_clif_hat_effect) (struct block_list *bl, struct block_list *tbl, enum send_target target);
typedef void (*HPMHOOK_pre_clif_hat_effect_single) (struct block_list **bl, uint16 *effectId, bool *enable);
typedef void (*HPMHOOK_post_clif_hat_effect_single) (struct block_list *bl, uint16 effectId, bool enable);
+typedef void (*HPMHOOK_pre_clif_overweight_percent) (struct map_session_data **sd);
+typedef void (*HPMHOOK_post_clif_overweight_percent) (struct map_session_data *sd);
+typedef void (*HPMHOOK_pre_clif_pChangeDress) (int *fd, struct map_session_data **sd);
+typedef void (*HPMHOOK_post_clif_pChangeDress) (int fd, struct map_session_data *sd);
typedef bool (*HPMHOOK_pre_clif_pAttendanceDB) (void);
typedef bool (*HPMHOOK_post_clif_pAttendanceDB) (bool retVal___);
typedef bool (*HPMHOOK_pre_clif_attendancedb_libconfig_sub) (struct config_setting_t **it, int *n, const char **source);
@@ -2584,6 +2588,8 @@ typedef void (*HPMHOOK_pre_clif_pPetEvolution) (int *fd, struct map_session_data
typedef void (*HPMHOOK_post_clif_pPetEvolution) (int fd, struct map_session_data *sd);
typedef void (*HPMHOOK_pre_clif_petEvolutionResult) (int *fd, enum pet_evolution_result *result);
typedef void (*HPMHOOK_post_clif_petEvolutionResult) (int fd, enum pet_evolution_result result);
+typedef void (*HPMHOOK_pre_clif_party_dead_notification) (struct map_session_data **sd);
+typedef void (*HPMHOOK_post_clif_party_dead_notification) (struct map_session_data *sd);
#endif // MAP_CLIF_H
#ifdef COMMON_CORE_H /* cmdline */
typedef void (*HPMHOOK_pre_cmdline_init) (void);
diff --git a/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc b/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc
index fadab9ea7..c4394d7f4 100644
--- a/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc
+++ b/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc
@@ -2134,6 +2134,10 @@ struct {
struct HPMHookPoint *HP_clif_hat_effect_post;
struct HPMHookPoint *HP_clif_hat_effect_single_pre;
struct HPMHookPoint *HP_clif_hat_effect_single_post;
+ struct HPMHookPoint *HP_clif_overweight_percent_pre;
+ struct HPMHookPoint *HP_clif_overweight_percent_post;
+ struct HPMHookPoint *HP_clif_pChangeDress_pre;
+ struct HPMHookPoint *HP_clif_pChangeDress_post;
struct HPMHookPoint *HP_clif_pAttendanceDB_pre;
struct HPMHookPoint *HP_clif_pAttendanceDB_post;
struct HPMHookPoint *HP_clif_attendancedb_libconfig_sub_pre;
@@ -2176,6 +2180,8 @@ struct {
struct HPMHookPoint *HP_clif_pPetEvolution_post;
struct HPMHookPoint *HP_clif_petEvolutionResult_pre;
struct HPMHookPoint *HP_clif_petEvolutionResult_post;
+ struct HPMHookPoint *HP_clif_party_dead_notification_pre;
+ struct HPMHookPoint *HP_clif_party_dead_notification_post;
struct HPMHookPoint *HP_cmdline_init_pre;
struct HPMHookPoint *HP_cmdline_init_post;
struct HPMHookPoint *HP_cmdline_final_pre;
@@ -8679,6 +8685,10 @@ struct {
int HP_clif_hat_effect_post;
int HP_clif_hat_effect_single_pre;
int HP_clif_hat_effect_single_post;
+ int HP_clif_overweight_percent_pre;
+ int HP_clif_overweight_percent_post;
+ int HP_clif_pChangeDress_pre;
+ int HP_clif_pChangeDress_post;
int HP_clif_pAttendanceDB_pre;
int HP_clif_pAttendanceDB_post;
int HP_clif_attendancedb_libconfig_sub_pre;
@@ -8721,6 +8731,8 @@ struct {
int HP_clif_pPetEvolution_post;
int HP_clif_petEvolutionResult_pre;
int HP_clif_petEvolutionResult_post;
+ int HP_clif_party_dead_notification_pre;
+ int HP_clif_party_dead_notification_post;
int HP_cmdline_init_pre;
int HP_cmdline_init_post;
int HP_cmdline_final_pre;
diff --git a/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc b/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc
index 57728fbc4..e5584cc43 100644
--- a/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc
+++ b/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc
@@ -1091,6 +1091,8 @@ struct HookingPointData HookingPoints[] = {
{ HP_POP(clif->pClanMessage, HP_clif_pClanMessage) },
{ HP_POP(clif->hat_effect, HP_clif_hat_effect) },
{ HP_POP(clif->hat_effect_single, HP_clif_hat_effect_single) },
+ { HP_POP(clif->overweight_percent, HP_clif_overweight_percent) },
+ { HP_POP(clif->pChangeDress, HP_clif_pChangeDress) },
{ HP_POP(clif->pAttendanceDB, HP_clif_pAttendanceDB) },
{ HP_POP(clif->attendancedb_libconfig_sub, HP_clif_attendancedb_libconfig_sub) },
{ HP_POP(clif->attendance_timediff, HP_clif_attendance_timediff) },
@@ -1112,6 +1114,7 @@ struct HookingPointData HookingPoints[] = {
{ HP_POP(clif->style_change_response, HP_clif_style_change_response) },
{ HP_POP(clif->pPetEvolution, HP_clif_pPetEvolution) },
{ HP_POP(clif->petEvolutionResult, HP_clif_petEvolutionResult) },
+ { HP_POP(clif->party_dead_notification, HP_clif_party_dead_notification) },
/* cmdline_interface */
{ HP_POP(cmdline->init, HP_cmdline_init) },
{ HP_POP(cmdline->final, HP_cmdline_final) },
diff --git a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc
index e224a10bc..f2ce1505c 100644
--- a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc
+++ b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc
@@ -10679,14 +10679,14 @@ void HP_clif_maptypeproperty2(struct block_list *bl, enum send_target t) {
}
return;
}
-void HP_clif_changemapserver(struct map_session_data *sd, unsigned short map_index, int x, int y, uint32 ip, uint16 port) {
+void HP_clif_changemapserver(struct map_session_data *sd, unsigned short map_index, int x, int y, uint32 ip, uint16 port, char *dnsHost) {
int hIndex = 0;
if (HPMHooks.count.HP_clif_changemapserver_pre > 0) {
- void (*preHookFunc) (struct map_session_data **sd, unsigned short *map_index, int *x, int *y, uint32 *ip, uint16 *port);
+ void (*preHookFunc) (struct map_session_data **sd, unsigned short *map_index, int *x, int *y, uint32 *ip, uint16 *port, char **dnsHost);
*HPMforce_return = false;
for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_changemapserver_pre; hIndex++) {
preHookFunc = HPMHooks.list.HP_clif_changemapserver_pre[hIndex].func;
- preHookFunc(&sd, &map_index, &x, &y, &ip, &port);
+ preHookFunc(&sd, &map_index, &x, &y, &ip, &port, &dnsHost);
}
if (*HPMforce_return) {
*HPMforce_return = false;
@@ -10694,13 +10694,13 @@ void HP_clif_changemapserver(struct map_session_data *sd, unsigned short map_ind
}
}
{
- HPMHooks.source.clif.changemapserver(sd, map_index, x, y, ip, port);
+ HPMHooks.source.clif.changemapserver(sd, map_index, x, y, ip, port, dnsHost);
}
if (HPMHooks.count.HP_clif_changemapserver_post > 0) {
- void (*postHookFunc) (struct map_session_data *sd, unsigned short map_index, int x, int y, uint32 ip, uint16 port);
+ void (*postHookFunc) (struct map_session_data *sd, unsigned short map_index, int x, int y, uint32 ip, uint16 port, char *dnsHost);
for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_changemapserver_post; hIndex++) {
postHookFunc = HPMHooks.list.HP_clif_changemapserver_post[hIndex].func;
- postHookFunc(sd, map_index, x, y, ip, port);
+ postHookFunc(sd, map_index, x, y, ip, port, dnsHost);
}
}
return;
@@ -27813,6 +27813,58 @@ void HP_clif_hat_effect_single(struct block_list *bl, uint16 effectId, bool enab
}
return;
}
+void HP_clif_overweight_percent(struct map_session_data *sd) {
+ int hIndex = 0;
+ if (HPMHooks.count.HP_clif_overweight_percent_pre > 0) {
+ void (*preHookFunc) (struct map_session_data **sd);
+ *HPMforce_return = false;
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_overweight_percent_pre; hIndex++) {
+ preHookFunc = HPMHooks.list.HP_clif_overweight_percent_pre[hIndex].func;
+ preHookFunc(&sd);
+ }
+ if (*HPMforce_return) {
+ *HPMforce_return = false;
+ return;
+ }
+ }
+ {
+ HPMHooks.source.clif.overweight_percent(sd);
+ }
+ if (HPMHooks.count.HP_clif_overweight_percent_post > 0) {
+ void (*postHookFunc) (struct map_session_data *sd);
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_overweight_percent_post; hIndex++) {
+ postHookFunc = HPMHooks.list.HP_clif_overweight_percent_post[hIndex].func;
+ postHookFunc(sd);
+ }
+ }
+ return;
+}
+void HP_clif_pChangeDress(int fd, struct map_session_data *sd) {
+ int hIndex = 0;
+ if (HPMHooks.count.HP_clif_pChangeDress_pre > 0) {
+ void (*preHookFunc) (int *fd, struct map_session_data **sd);
+ *HPMforce_return = false;
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pChangeDress_pre; hIndex++) {
+ preHookFunc = HPMHooks.list.HP_clif_pChangeDress_pre[hIndex].func;
+ preHookFunc(&fd, &sd);
+ }
+ if (*HPMforce_return) {
+ *HPMforce_return = false;
+ return;
+ }
+ }
+ {
+ HPMHooks.source.clif.pChangeDress(fd, sd);
+ }
+ if (HPMHooks.count.HP_clif_pChangeDress_post > 0) {
+ void (*postHookFunc) (int fd, struct map_session_data *sd);
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pChangeDress_post; hIndex++) {
+ postHookFunc = HPMHooks.list.HP_clif_pChangeDress_post[hIndex].func;
+ postHookFunc(fd, sd);
+ }
+ }
+ return;
+}
bool HP_clif_pAttendanceDB(void) {
int hIndex = 0;
bool retVal___ = false;
@@ -28366,6 +28418,32 @@ void HP_clif_petEvolutionResult(int fd, enum pet_evolution_result result) {
}
return;
}
+void HP_clif_party_dead_notification(struct map_session_data *sd) {
+ int hIndex = 0;
+ if (HPMHooks.count.HP_clif_party_dead_notification_pre > 0) {
+ void (*preHookFunc) (struct map_session_data **sd);
+ *HPMforce_return = false;
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_party_dead_notification_pre; hIndex++) {
+ preHookFunc = HPMHooks.list.HP_clif_party_dead_notification_pre[hIndex].func;
+ preHookFunc(&sd);
+ }
+ if (*HPMforce_return) {
+ *HPMforce_return = false;
+ return;
+ }
+ }
+ {
+ HPMHooks.source.clif.party_dead_notification(sd);
+ }
+ if (HPMHooks.count.HP_clif_party_dead_notification_post > 0) {
+ void (*postHookFunc) (struct map_session_data *sd);
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_party_dead_notification_post; hIndex++) {
+ postHookFunc = HPMHooks.list.HP_clif_party_dead_notification_post[hIndex].func;
+ postHookFunc(sd);
+ }
+ }
+ return;
+}
/* cmdline_interface */
void HP_cmdline_init(void) {
int hIndex = 0;