summaryrefslogtreecommitdiff
path: root/src/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins')
-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.inc86
-rw-r--r--src/plugins/dbghelpplug.c4
-rw-r--r--src/plugins/sample.c2
5 files changed, 69 insertions, 38 deletions
diff --git a/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc b/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc
index c7f63c708..09f33bff6 100644
--- a/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc
+++ b/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc
@@ -933,6 +933,8 @@ struct {
struct HPMHookPoint *HP_clif_broadcast_post;
struct HPMHookPoint *HP_clif_broadcast2_pre;
struct HPMHookPoint *HP_clif_broadcast2_post;
+ struct HPMHookPoint *HP_clif_messagecolor_self_pre;
+ struct HPMHookPoint *HP_clif_messagecolor_self_post;
struct HPMHookPoint *HP_clif_messagecolor_pre;
struct HPMHookPoint *HP_clif_messagecolor_post;
struct HPMHookPoint *HP_clif_disp_overhead_pre;
@@ -947,8 +949,6 @@ struct {
struct HPMHookPoint *HP_clif_message_post;
struct HPMHookPoint *HP_clif_messageln_pre;
struct HPMHookPoint *HP_clif_messageln_post;
- struct HPMHookPoint *HP_clif_colormes_pre;
- struct HPMHookPoint *HP_clif_colormes_post;
struct HPMHookPoint *HP_clif_process_message_pre;
struct HPMHookPoint *HP_clif_process_message_post;
struct HPMHookPoint *HP_clif_wisexin_pre;
@@ -3861,6 +3861,8 @@ struct {
struct HPMHookPoint *HP_pc_addspiritball_post;
struct HPMHookPoint *HP_pc_delspiritball_pre;
struct HPMHookPoint *HP_pc_delspiritball_post;
+ struct HPMHookPoint *HP_pc_getmaxspiritball_pre;
+ struct HPMHookPoint *HP_pc_getmaxspiritball_post;
struct HPMHookPoint *HP_pc_addfame_pre;
struct HPMHookPoint *HP_pc_addfame_post;
struct HPMHookPoint *HP_pc_famerank_pre;
@@ -6138,6 +6140,8 @@ struct {
int HP_clif_broadcast_post;
int HP_clif_broadcast2_pre;
int HP_clif_broadcast2_post;
+ int HP_clif_messagecolor_self_pre;
+ int HP_clif_messagecolor_self_post;
int HP_clif_messagecolor_pre;
int HP_clif_messagecolor_post;
int HP_clif_disp_overhead_pre;
@@ -6152,8 +6156,6 @@ struct {
int HP_clif_message_post;
int HP_clif_messageln_pre;
int HP_clif_messageln_post;
- int HP_clif_colormes_pre;
- int HP_clif_colormes_post;
int HP_clif_process_message_pre;
int HP_clif_process_message_post;
int HP_clif_wisexin_pre;
@@ -9066,6 +9068,8 @@ struct {
int HP_pc_addspiritball_post;
int HP_pc_delspiritball_pre;
int HP_pc_delspiritball_post;
+ int HP_pc_getmaxspiritball_pre;
+ int HP_pc_getmaxspiritball_post;
int HP_pc_addfame_pre;
int HP_pc_addfame_post;
int HP_pc_famerank_pre;
diff --git a/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc b/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc
index 9f9f4ba07..8c1456412 100644
--- a/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc
+++ b/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc
@@ -477,6 +477,7 @@ struct HookingPointData HookingPoints[] = {
{ HP_POP(clif->disp_message, HP_clif_disp_message) },
{ HP_POP(clif->broadcast, HP_clif_broadcast) },
{ HP_POP(clif->broadcast2, HP_clif_broadcast2) },
+ { HP_POP(clif->messagecolor_self, HP_clif_messagecolor_self) },
{ HP_POP(clif->messagecolor, HP_clif_messagecolor) },
{ HP_POP(clif->disp_overhead, HP_clif_disp_overhead) },
{ HP_POP(clif->msgtable, HP_clif_msgtable) },
@@ -484,7 +485,6 @@ struct HookingPointData HookingPoints[] = {
{ HP_POP(clif->msgtable_skill, HP_clif_msgtable_skill) },
{ HP_POP(clif->message, HP_clif_message) },
{ HP_POP(clif->messageln, HP_clif_messageln) },
- { HP_POP(clif->colormes, HP_clif_colormes) },
{ HP_POP(clif->process_message, HP_clif_process_message) },
{ HP_POP(clif->wisexin, HP_clif_wisexin) },
{ HP_POP(clif->wisall, HP_clif_wisall) },
@@ -1962,6 +1962,7 @@ struct HookingPointData HookingPoints[] = {
{ HP_POP(pc->delinvincibletimer, HP_pc_delinvincibletimer) },
{ HP_POP(pc->addspiritball, HP_pc_addspiritball) },
{ HP_POP(pc->delspiritball, HP_pc_delspiritball) },
+ { HP_POP(pc->getmaxspiritball, HP_pc_getmaxspiritball) },
{ HP_POP(pc->addfame, HP_pc_addfame) },
{ HP_POP(pc->famerank, HP_pc_famerank) },
{ HP_POP(pc->set_hate_mob, HP_pc_set_hate_mob) },
diff --git a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc
index 58b9e1b4a..c623747aa 100644
--- a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc
+++ b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc
@@ -12381,10 +12381,36 @@ void HP_clif_broadcast2(struct block_list *bl, const char *mes, size_t len, unsi
}
return;
}
-void HP_clif_messagecolor(struct block_list *bl, unsigned int color, const char *msg) {
+void HP_clif_messagecolor_self(int fd, uint32 color, const char *msg) {
+ int hIndex = 0;
+ if( HPMHooks.count.HP_clif_messagecolor_self_pre ) {
+ void (*preHookFunc) (int *fd, uint32 *color, const char *msg);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_clif_messagecolor_self_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_clif_messagecolor_self_pre[hIndex].func;
+ preHookFunc(&fd, &color, msg);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return;
+ }
+ }
+ {
+ HPMHooks.source.clif.messagecolor_self(fd, color, msg);
+ }
+ if( HPMHooks.count.HP_clif_messagecolor_self_post ) {
+ void (*postHookFunc) (int *fd, uint32 *color, const char *msg);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_clif_messagecolor_self_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_clif_messagecolor_self_post[hIndex].func;
+ postHookFunc(&fd, &color, msg);
+ }
+ }
+ return;
+}
+void HP_clif_messagecolor(struct block_list *bl, uint32 color, const char *msg) {
int hIndex = 0;
if( HPMHooks.count.HP_clif_messagecolor_pre ) {
- void (*preHookFunc) (struct block_list *bl, unsigned int *color, const char *msg);
+ void (*preHookFunc) (struct block_list *bl, uint32 *color, const char *msg);
*HPMforce_return = false;
for(hIndex = 0; hIndex < HPMHooks.count.HP_clif_messagecolor_pre; hIndex++ ) {
preHookFunc = HPMHooks.list.HP_clif_messagecolor_pre[hIndex].func;
@@ -12399,7 +12425,7 @@ void HP_clif_messagecolor(struct block_list *bl, unsigned int color, const char
HPMHooks.source.clif.messagecolor(bl, color, msg);
}
if( HPMHooks.count.HP_clif_messagecolor_post ) {
- void (*postHookFunc) (struct block_list *bl, unsigned int *color, const char *msg);
+ void (*postHookFunc) (struct block_list *bl, uint32 *color, const char *msg);
for(hIndex = 0; hIndex < HPMHooks.count.HP_clif_messagecolor_post; hIndex++ ) {
postHookFunc = HPMHooks.list.HP_clif_messagecolor_post[hIndex].func;
postHookFunc(bl, &color, msg);
@@ -12563,33 +12589,6 @@ void HP_clif_messageln(const int fd, const char *mes) {
}
return;
}
-int HP_clif_colormes(int fd, enum clif_colors color, const char *msg) {
- int hIndex = 0;
- int retVal___ = 0;
- if( HPMHooks.count.HP_clif_colormes_pre ) {
- int (*preHookFunc) (int *fd, enum clif_colors *color, const char *msg);
- *HPMforce_return = false;
- for(hIndex = 0; hIndex < HPMHooks.count.HP_clif_colormes_pre; hIndex++ ) {
- preHookFunc = HPMHooks.list.HP_clif_colormes_pre[hIndex].func;
- retVal___ = preHookFunc(&fd, &color, msg);
- }
- if( *HPMforce_return ) {
- *HPMforce_return = false;
- return retVal___;
- }
- }
- {
- retVal___ = HPMHooks.source.clif.colormes(fd, color, msg);
- }
- if( HPMHooks.count.HP_clif_colormes_post ) {
- int (*postHookFunc) (int retVal___, int *fd, enum clif_colors *color, const char *msg);
- for(hIndex = 0; hIndex < HPMHooks.count.HP_clif_colormes_post; hIndex++ ) {
- postHookFunc = HPMHooks.list.HP_clif_colormes_post[hIndex].func;
- retVal___ = postHookFunc(retVal___, &fd, &color, msg);
- }
- }
- return retVal___;
-}
bool HP_clif_process_message(struct map_session_data *sd, int format, char **name_, size_t *namelen_, char **message_, size_t *messagelen_) {
int hIndex = 0;
bool retVal___ = false;
@@ -51662,6 +51661,33 @@ int HP_pc_delspiritball(struct map_session_data *sd, int count, int type) {
}
return retVal___;
}
+int HP_pc_getmaxspiritball(struct map_session_data *sd, int min) {
+ int hIndex = 0;
+ int retVal___ = 0;
+ if( HPMHooks.count.HP_pc_getmaxspiritball_pre ) {
+ int (*preHookFunc) (struct map_session_data *sd, int *min);
+ *HPMforce_return = false;
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_pc_getmaxspiritball_pre; hIndex++ ) {
+ preHookFunc = HPMHooks.list.HP_pc_getmaxspiritball_pre[hIndex].func;
+ retVal___ = preHookFunc(sd, &min);
+ }
+ if( *HPMforce_return ) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.pc.getmaxspiritball(sd, min);
+ }
+ if( HPMHooks.count.HP_pc_getmaxspiritball_post ) {
+ int (*postHookFunc) (int retVal___, struct map_session_data *sd, int *min);
+ for(hIndex = 0; hIndex < HPMHooks.count.HP_pc_getmaxspiritball_post; hIndex++ ) {
+ postHookFunc = HPMHooks.list.HP_pc_getmaxspiritball_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, sd, &min);
+ }
+ }
+ return retVal___;
+}
void HP_pc_addfame(struct map_session_data *sd, int count) {
int hIndex = 0;
if( HPMHooks.count.HP_pc_addfame_pre ) {
diff --git a/src/plugins/dbghelpplug.c b/src/plugins/dbghelpplug.c
index bf43c0b23..ac72b8eb2 100644
--- a/src/plugins/dbghelpplug.c
+++ b/src/plugins/dbghelpplug.c
@@ -217,8 +217,8 @@ typedef struct _InternalData {
// Extended information printed in the console
#define DBG_EXTENDED_INFORMATION \
- "Please report the crash in the bug tracker:\n" \
- "http://hercules.ws/board/tracker/\n"
+ "Please report the crash in our Issues tracker:\n" \
+ "https://github.com/HerculesWS/Hercules/issues\n"
// Print object children?
// WARNING: This will generate huge dump files!
diff --git a/src/plugins/sample.c b/src/plugins/sample.c
index 03d32b1f3..82cb198bd 100644
--- a/src/plugins/sample.c
+++ b/src/plugins/sample.c
@@ -107,7 +107,7 @@ int my_pc_dropitem_post(int retVal, struct map_session_data *sd,int *n,int *amou
if( my_pc_dropitem_storage ) {/* signs whether pre-hook did this */
char output[99];
safesnprintf(output,99,"[ Warning ] you can only drop 1 item at a time, capped from %d to 1",my_pc_dropitem_storage);
- clif->colormes(sd->fd,COLOR_RED,output);
+ clif->messagecolor_self(sd->fd, COLOR_RED, output);
}
return 1;
}