summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorai4rei <ai4rei@54d463be-8e91-2dee-dedb-b68131a5f0ec>2010-11-22 19:43:19 +0000
committerai4rei <ai4rei@54d463be-8e91-2dee-dedb-b68131a5f0ec>2010-11-22 19:43:19 +0000
commit7b0ba03960125e21809468587076523a67acd0cd (patch)
tree8e90b6bd9506409706b9e26bfd7857e21255f022
parent2a3ca1bcfa82023b3f890f19775b115e8a744b88 (diff)
downloadhercules-7b0ba03960125e21809468587076523a67acd0cd.tar.gz
hercules-7b0ba03960125e21809468587076523a67acd0cd.tar.bz2
hercules-7b0ba03960125e21809468587076523a67acd0cd.tar.xz
hercules-7b0ba03960125e21809468587076523a67acd0cd.zip
* Fixed disguising as player clone causing the client to crash while looking for non-existing NPC sprites (bugreport:4428, since r14387, related r14383).
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14488 54d463be-8e91-2dee-dedb-b68131a5f0ec
-rw-r--r--Changelog-Trunk.txt1
-rw-r--r--src/map/clif.c4
2 files changed, 3 insertions, 2 deletions
diff --git a/Changelog-Trunk.txt b/Changelog-Trunk.txt
index 19f2c6dd3..bb7b5e97b 100644
--- a/Changelog-Trunk.txt
+++ b/Changelog-Trunk.txt
@@ -9,6 +9,7 @@ Date Added
- This also fixes guild leader name being displayed and saved as "(null)" in the guild member list.
* Fixed guild and guild member exp truncation issue (bugreport:4130, since r14242). [Ai4rei]
- Fixed guild member position, hair, hair color, gender, class and level could potentially become corrupted due to shorts being read as ints (partially since r2986).
+ * Fixed disguising as player clone causing the client to crash while looking for non-existing NPC sprites (bugreport:4428, since r14387, related r14383). [Ai4rei]
2010/11/21
* Added msinttypes (rev. 26, http://msinttypes.googlecode.com/svn/trunk/) portability framework for Visual C++ compilers (related bugreport:4059). [Ai4rei]
* Added 64-bit variants of the socket and buffer I/O macros. [Ai4rei]
diff --git a/src/map/clif.c b/src/map/clif.c
index 087a41187..e55a27108 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -1017,10 +1017,10 @@ static int clif_set_unit_walking(struct block_list* bl, struct unit_data* ud, un
static void clif_setdisguise(struct block_list *bl, unsigned char *buf,int len)
{
#if PACKETVER >= 20091103
- WBUFB(buf,4)= 0x5; //NPC_MOB_TYPE
+ WBUFB(buf,4)= pcdb_checkid(status_get_viewdata(bl)->class_) ? 0x0 : 0x5; //PC_TYPE : NPC_MOB_TYPE
WBUFL(buf,5)=-bl->id;
#elif PACKETVER >= 20071106
- WBUFB(buf,2)= 0x5; //NPC_MOB_TYPE
+ WBUFB(buf,2)= pcdb_checkid(status_get_viewdata(bl)->class_) ? 0x0 : 0x5; //PC_TYPE : NPC_MOB_TYPE
WBUFL(buf,3)=-bl->id;
#else
WBUFL(buf,2)=-bl->id;