From ca15680b184ae630ee90eaa4f71faab19f8fe20e Mon Sep 17 00:00:00 2001 From: shennetsind Date: Fri, 11 Oct 2013 15:20:09 -0300 Subject: Fixed Char Deletion Bug on 2013++ Clients Thanks to LuLu who pointed us in the right direction, http://hercules.ws/board/topic/2453-help-open-pull-request-fixing-char-deletion-time-in-2013-client/ Signed-off-by: shennetsind --- src/char/char.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/char/char.c b/src/char/char.c index 5a51130de..bbf561651 100644 --- a/src/char/char.c +++ b/src/char/char.c @@ -1897,7 +1897,7 @@ int mmo_char_tobuf(uint8* buffer, struct mmo_charstatus* p) { offset += MAP_NAME_LENGTH_EXT; #endif #if PACKETVER >= 20100803 - WBUFL(buf,124) = TOL(p->delete_date); + WBUFL(buf,124) = p->delete_date; offset += 4; #endif #if PACKETVER >= 20110111 @@ -3565,7 +3565,12 @@ void char_delete2_ack(int fd, int char_id, uint32 result, time_t delete_date) WFIFOW(fd,0) = 0x828; WFIFOL(fd,2) = char_id; WFIFOL(fd,6) = result; - WFIFOL(fd,10) = TOL(delete_date); +#if PACKETVER >= 20130000 + WFIFOL(fd,10) = delete_date - time(NULL); +#else + WFIFOL(fd,10) = delete_date; + +#endif WFIFOSET(fd,14); } -- cgit v1.2.3-60-g2f50