summaryrefslogtreecommitdiff
path: root/src/map/chrif.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/map/chrif.c')
-rw-r--r--src/map/chrif.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/map/chrif.c b/src/map/chrif.c
index 6f3e35c0d..64194c1a2 100644
--- a/src/map/chrif.c
+++ b/src/map/chrif.c
@@ -209,7 +209,6 @@ int chrif_save(struct map_session_data *sd, int flag)
intif_saveregistry(sd, 2); //Save account regs
if (sd->state.reg_dirty&1)
intif_saveregistry(sd, 1); //Save account2 regs
-
#ifndef TXT_ONLY
if(charsave_method){ //New 'Local' save
charsave_savechar(sd->char_id, &sd->status);
@@ -228,6 +227,10 @@ int chrif_save(struct map_session_data *sd, int flag)
WFIFOB(char_fd,12) = (flag==1)?1:0; //Flag to tell char-server this character is quitting.
memcpy(WFIFOP(char_fd,13), &sd->status, sizeof(sd->status));
WFIFOSET(char_fd, WFIFOW(char_fd,2));
+
+ if (sd->hd && merc_is_hom_active(sd->hd))
+ merc_save(sd->hd);
+
if (flag)
sd->state.finalsave = 1; //Mark the last save as done.
return 0;