diff options
author | shennetsind <ind@henn.et> | 2013-06-15 05:00:04 -0300 |
---|---|---|
committer | shennetsind <ind@henn.et> | 2013-06-15 05:00:04 -0300 |
commit | cf78bebc95e3387cf7fbe0720825bacb95c1b61a (patch) | |
tree | e895ec5f3f9baa111476af18607ec292f06d9df6 /src/map/mail.c | |
parent | 1dd4882c00b82d9a2f138211dbc2c8c542e2af88 (diff) | |
parent | de3f4423058405636c76e05cd87a6eae0bfa7707 (diff) | |
download | hercules-cf78bebc95e3387cf7fbe0720825bacb95c1b61a.tar.gz hercules-cf78bebc95e3387cf7fbe0720825bacb95c1b61a.tar.bz2 hercules-cf78bebc95e3387cf7fbe0720825bacb95c1b61a.tar.xz hercules-cf78bebc95e3387cf7fbe0720825bacb95c1b61a.zip |
Merge branch 'master' of https://github.com/HerculesWS/Hercules
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 |