diff options
author | Matheus Macabu <mkbu95@gmail.com> | 2013-06-15 03:42:23 -0300 |
---|---|---|
committer | Euphy <euphy@rathena.org> | 2013-06-15 15:58:34 -0400 |
commit | f46f552f954a45387bffd6d7f672fb58100c9593 (patch) | |
tree | 2efc592e1524b1ed7a65695c4118643cd57dd7b7 /src/map/mail.c | |
parent | fa0c8cda0b2f68fa742572409c8f77e65d5d0011 (diff) | |
download | hercules-f46f552f954a45387bffd6d7f672fb58100c9593.tar.gz hercules-f46f552f954a45387bffd6d7f672fb58100c9593.tar.bz2 hercules-f46f552f954a45387bffd6d7f672fb58100c9593.tar.xz hercules-f46f552f954a45387bffd6d7f672fb58100c9593.zip |
Forgot to change something.
Also added mail interface for HPM.
Signed-off-by: Matheus Macabu <mkbu95@gmail.com>
Diffstat (limited to 'src/map/mail.c')
-rw-r--r-- | src/map/mail.c | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/src/map/mail.c b/src/map/mail.c index 299fb5117..24af018ad 100644 --- a/src/map/mail.c +++ b/src/map/mail.c @@ -72,7 +72,7 @@ unsigned char mail_setitem(struct map_session_data *sd, int idx, int amount) { return 0; } else { // Item Transfer idx -= 2; - mail_removeitem(sd, 0); + mail->removeitem(sd, 0); if( idx < 0 || idx >= MAX_INVENTORY ) return 1; @@ -121,8 +121,8 @@ bool mail_setattachment(struct map_session_data *sd, struct mail_message *msg) msg->zeny = sd->mail.zeny; // Removes the attachment from sender - mail_removeitem(sd,1); - mail_removezeny(sd,1); + mail->removeitem(sd,1); + mail->removezeny(sd,1); return true; } @@ -183,3 +183,18 @@ bool mail_invalid_operation(struct map_session_data *sd) return false; } + +void mail_defaults(void) +{ + mail = &mail_s; + + mail->clear = mail_clear; + mail->removeitem = mail_removeitem; + mail->removezeny = mail_removezeny; + mail->setitem = mail_setitem; + mail->setattachment = mail_setattachment; + mail->getattachment = mail_getattachment; + mail->openmail = mail_openmail; + mail->deliveryfail = mail_deliveryfail; + mail->invalid_operation = mail_invalid_operation; +}
\ No newline at end of file |