summaryrefslogtreecommitdiff
path: root/src/echar
diff options
context:
space:
mode:
Diffstat (limited to 'src/echar')
-rw-r--r--src/echar/char.c9
-rw-r--r--src/echar/char.h2
-rw-r--r--src/echar/init.c1
3 files changed, 11 insertions, 1 deletions
diff --git a/src/echar/char.c b/src/echar/char.c
index 037aa05..c0d80ba 100644
--- a/src/echar/char.c
+++ b/src/echar/char.c
@@ -177,11 +177,18 @@ void echar_parse_login_password_change_ack(int charFd)
}
}
-void echar_send_HC_ACK_CHARINFO_PER_PAGE_post(int fd, struct char_session_data *sd)
+void echar_send_HC_ACK_CHARINFO_PER_PAGE_post(int fd,
+ struct char_session_data *sd)
{
send_additional_slots(fd, sd);
}
+void echar_send_HC_ACK_CHARINFO_PER_PAGE_tail_pre(int *fdPtr __attribute__ ((unused)),
+ struct char_session_data **sdPtr __attribute__ ((unused)))
+{
+ hookStop();
+}
+
int echar_mmo_char_send_characters_post(int retVal,
int fd,
struct char_session_data* sd)
diff --git a/src/echar/char.h b/src/echar/char.h
index 708a558..23a9a4d 100644
--- a/src/echar/char.h
+++ b/src/echar/char.h
@@ -15,6 +15,8 @@ void echar_parse_login_password_change_ack(int charFd);
void echar_send_HC_ACK_CHARINFO_PER_PAGE_post(int fd, struct char_session_data *sd);
+void echar_send_HC_ACK_CHARINFO_PER_PAGE_tail_pre(int *fdPtr, struct char_session_data **sdPtr);
+
int echar_mmo_char_send_characters_post(int retVal, int fd, struct char_session_data *sd);
void send_additional_slots(int fd, struct char_session_data* sd);
diff --git a/src/echar/init.c b/src/echar/init.c
index 4e9faa6..5d55735 100644
--- a/src/echar/init.c
+++ b/src/echar/init.c
@@ -60,6 +60,7 @@ HPExport void plugin_init (void)
addHookPre(chr, parse_char_create_new_char, echar_parse_char_create_new_char);
addHookPre(chr, creation_failed, echar_creation_failed);
addHookPre(chr, parse_char_connect, echar_parse_char_connect_pre);
+ addHookPre(chr, send_HC_ACK_CHARINFO_PER_PAGE_tail, echar_send_HC_ACK_CHARINFO_PER_PAGE_tail_pre);
addHookPost(chr, send_HC_ACK_CHARINFO_PER_PAGE, echar_send_HC_ACK_CHARINFO_PER_PAGE_post);
addHookPost(chr, mmo_char_send_characters, echar_mmo_char_send_characters_post);