summaryrefslogtreecommitdiff
path: root/src/map
diff options
context:
space:
mode:
Diffstat (limited to 'src/map')
-rw-r--r--src/map/clif.c5
-rw-r--r--src/map/mail.c3
2 files changed, 5 insertions, 3 deletions
diff --git a/src/map/clif.c b/src/map/clif.c
index e688ac467..b2cc2881a 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -13687,8 +13687,11 @@ void clif_parse_Mail_getattach(int fd, struct map_session_data *sd)
if( sd->mail.inbox.msg[i].zeny < 1 && (sd->mail.inbox.msg[i].item.nameid < 1 || sd->mail.inbox.msg[i].item.amount < 1) )
return;
- if( ( sd->mail.inbox.msg[i].zeny + sd->mail.inbox.msg[i].zeny ) > MAX_ZENY )
+ if( sd->mail.inbox.msg[i].zeny + sd->status.zeny > MAX_ZENY )
+ {
+ clif_Mail_getattachment(fd, 1);
return;
+ }
if( sd->mail.inbox.msg[i].item.nameid > 0 )
{
diff --git a/src/map/mail.c b/src/map/mail.c
index bb1063fbf..249f93abc 100644
--- a/src/map/mail.c
+++ b/src/map/mail.c
@@ -46,8 +46,7 @@ int mail_removeitem(struct map_session_data *sd, short flag)
int mail_removezeny(struct map_session_data *sd, short flag)
{
nullpo_ret(sd);
- if( ( sd->status.zeny + sd->mail.zeny ) > MAX_ZENY )
- return 1;
+
if (flag && sd->mail.zeny > 0)
{ //Zeny send
log_zeny(sd, LOG_TYPE_MAIL, sd, -sd->mail.zeny);