summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2018-12-16 08:59:03 +0300
committerAndrei Karas <akaras@inbox.ru>2018-12-16 08:59:03 +0300
commit4b2e8684a9874ba435197936a4a9220510ff671f (patch)
tree11a7121f30031a2a850015eced3803f060514fa3 /src
parentad608a2b826a792834531bfe54ae6b5a12692f50 (diff)
downloadhercules-4b2e8684a9874ba435197936a4a9220510ff671f.tar.gz
hercules-4b2e8684a9874ba435197936a4a9220510ff671f.tar.bz2
hercules-4b2e8684a9874ba435197936a4a9220510ff671f.tar.xz
hercules-4b2e8684a9874ba435197936a4a9220510ff671f.zip
Update HPM.
Diffstat (limited to 'src')
-rw-r--r--src/common/HPMDataCheck.h2
-rw-r--r--src/plugins/HPMHooking/HPMHooking.Defs.inc2
-rw-r--r--src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc4
-rw-r--r--src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc1
-rw-r--r--src/plugins/HPMHooking/HPMHooking_map.Hooks.inc26
5 files changed, 34 insertions, 1 deletions
diff --git a/src/common/HPMDataCheck.h b/src/common/HPMDataCheck.h
index 7cd73b9dd..bfd01ec30 100644
--- a/src/common/HPMDataCheck.h
+++ b/src/common/HPMDataCheck.h
@@ -627,6 +627,7 @@ HPExport const struct s_HPMDataCheck HPMDataCheck[] = {
{ "PACKET_CZ_CHECKNAME", sizeof(struct PACKET_CZ_CHECKNAME), SERVER_TYPE_MAP },
{ "PACKET_CZ_MEMORIALDUNGEON_COMMAND", sizeof(struct PACKET_CZ_MEMORIALDUNGEON_COMMAND), SERVER_TYPE_MAP },
{ "PACKET_CZ_OPEN_UI", sizeof(struct PACKET_CZ_OPEN_UI), SERVER_TYPE_MAP },
+ { "PACKET_CZ_PARTY_CONFIG", sizeof(struct PACKET_CZ_PARTY_CONFIG), SERVER_TYPE_MAP },
{ "PACKET_CZ_PC_BUY_CASH_POINT_ITEM", sizeof(struct PACKET_CZ_PC_BUY_CASH_POINT_ITEM), SERVER_TYPE_MAP },
{ "PACKET_CZ_PC_BUY_CASH_POINT_ITEM_sub", sizeof(struct PACKET_CZ_PC_BUY_CASH_POINT_ITEM_sub), SERVER_TYPE_MAP },
{ "PACKET_CZ_PC_PURCHASE_ITEMLIST", sizeof(struct PACKET_CZ_PC_PURCHASE_ITEMLIST), SERVER_TYPE_MAP },
@@ -680,7 +681,6 @@ HPExport const struct s_HPMDataCheck HPMDataCheck[] = {
{ "PACKET_ZC_ADD_ITEM_TO_STORE", sizeof(struct PACKET_ZC_ADD_ITEM_TO_STORE), SERVER_TYPE_MAP },
{ "PACKET_ZC_ADD_MEMBER_TO_GROUP", sizeof(struct PACKET_ZC_ADD_MEMBER_TO_GROUP), SERVER_TYPE_MAP },
{ "PACKET_ZC_AUTOSPELLLIST", sizeof(struct PACKET_ZC_AUTOSPELLLIST), SERVER_TYPE_MAP },
- { "PACKET_ZC_CAMERA_INFO", sizeof(struct PACKET_ZC_CAMERA_INFO), SERVER_TYPE_MAP },
{ "PACKET_ZC_CASH_ITEM_DELETE", sizeof(struct PACKET_ZC_CASH_ITEM_DELETE), SERVER_TYPE_MAP },
{ "PACKET_ZC_CASH_TIME_COUNTER", sizeof(struct PACKET_ZC_CASH_TIME_COUNTER), SERVER_TYPE_MAP },
{ "PACKET_ZC_CHECKNAME", sizeof(struct PACKET_ZC_CHECKNAME), SERVER_TYPE_MAP },
diff --git a/src/plugins/HPMHooking/HPMHooking.Defs.inc b/src/plugins/HPMHooking/HPMHooking.Defs.inc
index 7cca3ed6c..9fdb68989 100644
--- a/src/plugins/HPMHooking/HPMHooking.Defs.inc
+++ b/src/plugins/HPMHooking/HPMHooking.Defs.inc
@@ -2650,6 +2650,8 @@ typedef void (*HPMHOOK_pre_clif_camera_showWindow) (struct map_session_data **sd
typedef void (*HPMHOOK_post_clif_camera_showWindow) (struct map_session_data *sd);
typedef void (*HPMHOOK_pre_clif_camera_change) (struct map_session_data **sd, float *range, float *rotation, float *latitude, enum send_target *target);
typedef void (*HPMHOOK_post_clif_camera_change) (struct map_session_data *sd, float range, float rotation, float latitude, enum send_target target);
+typedef void (*HPMHOOK_pre_clif_pCameraInfo) (int *fd, struct map_session_data **sd);
+typedef void (*HPMHOOK_post_clif_pCameraInfo) (int fd, struct map_session_data *sd);
typedef void (*HPMHOOK_pre_clif_item_preview) (struct map_session_data **sd, int *n);
typedef void (*HPMHOOK_post_clif_item_preview) (struct map_session_data *sd, int n);
typedef bool (*HPMHOOK_pre_clif_enchant_equipment) (struct map_session_data **sd, enum equip_pos *pos, int *cardSlot, int *cardId);
diff --git a/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc b/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc
index 0220a7956..d2c269bdd 100644
--- a/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc
+++ b/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc
@@ -2242,6 +2242,8 @@ struct {
struct HPMHookPoint *HP_clif_camera_showWindow_post;
struct HPMHookPoint *HP_clif_camera_change_pre;
struct HPMHookPoint *HP_clif_camera_change_post;
+ struct HPMHookPoint *HP_clif_pCameraInfo_pre;
+ struct HPMHookPoint *HP_clif_pCameraInfo_post;
struct HPMHookPoint *HP_clif_item_preview_pre;
struct HPMHookPoint *HP_clif_item_preview_post;
struct HPMHookPoint *HP_clif_enchant_equipment_pre;
@@ -8889,6 +8891,8 @@ struct {
int HP_clif_camera_showWindow_post;
int HP_clif_camera_change_pre;
int HP_clif_camera_change_post;
+ int HP_clif_pCameraInfo_pre;
+ int HP_clif_pCameraInfo_post;
int HP_clif_item_preview_pre;
int HP_clif_item_preview_post;
int HP_clif_enchant_equipment_pre;
diff --git a/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc b/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc
index c3fe751ad..050050ee1 100644
--- a/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc
+++ b/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc
@@ -1145,6 +1145,7 @@ struct HookingPointData HookingPoints[] = {
{ HP_POP(clif->pMemorialDungeonCommand, HP_clif_pMemorialDungeonCommand) },
{ HP_POP(clif->camera_showWindow, HP_clif_camera_showWindow) },
{ HP_POP(clif->camera_change, HP_clif_camera_change) },
+ { HP_POP(clif->pCameraInfo, HP_clif_pCameraInfo) },
{ HP_POP(clif->item_preview, HP_clif_item_preview) },
{ HP_POP(clif->enchant_equipment, HP_clif_enchant_equipment) },
{ HP_POP(clif->pReqRemainTime, HP_clif_pReqRemainTime) },
diff --git a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc
index 6fab14490..32196d061 100644
--- a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc
+++ b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc
@@ -29225,6 +29225,32 @@ void HP_clif_camera_change(struct map_session_data *sd, float range, float rotat
}
return;
}
+void HP_clif_pCameraInfo(int fd, struct map_session_data *sd) {
+ int hIndex = 0;
+ if (HPMHooks.count.HP_clif_pCameraInfo_pre > 0) {
+ void (*preHookFunc) (int *fd, struct map_session_data **sd);
+ *HPMforce_return = false;
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pCameraInfo_pre; hIndex++) {
+ preHookFunc = HPMHooks.list.HP_clif_pCameraInfo_pre[hIndex].func;
+ preHookFunc(&fd, &sd);
+ }
+ if (*HPMforce_return) {
+ *HPMforce_return = false;
+ return;
+ }
+ }
+ {
+ HPMHooks.source.clif.pCameraInfo(fd, sd);
+ }
+ if (HPMHooks.count.HP_clif_pCameraInfo_post > 0) {
+ void (*postHookFunc) (int fd, struct map_session_data *sd);
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pCameraInfo_post; hIndex++) {
+ postHookFunc = HPMHooks.list.HP_clif_pCameraInfo_post[hIndex].func;
+ postHookFunc(fd, sd);
+ }
+ }
+ return;
+}
void HP_clif_item_preview(struct map_session_data *sd, int n) {
int hIndex = 0;
if (HPMHooks.count.HP_clif_item_preview_pre > 0) {