diff options
author | ultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2008-10-06 08:11:49 +0000 |
---|---|---|
committer | ultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2008-10-06 08:11:49 +0000 |
commit | 1bbcb672ef6f8f6f4c60448d97ab07eca94a96bc (patch) | |
tree | a8d5b893f27e889c04ebc31e735fc741e1b8a24b /src/map | |
parent | 5f9d736e2bce10e9b96c0bf3218392f3a1c82ea4 (diff) | |
download | hercules-1bbcb672ef6f8f6f4c60448d97ab07eca94a96bc.tar.gz hercules-1bbcb672ef6f8f6f4c60448d97ab07eca94a96bc.tar.bz2 hercules-1bbcb672ef6f8f6f4c60448d97ab07eca94a96bc.tar.xz hercules-1bbcb672ef6f8f6f4c60448d97ab07eca94a96bc.zip |
Fixed knockback not updating the client position of disguised players (bugreport:2308).
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@13261 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map')
-rw-r--r-- | src/map/clif.c | 36 | ||||
-rw-r--r-- | src/map/clif.h | 4 |
2 files changed, 22 insertions, 18 deletions
diff --git a/src/map/clif.c b/src/map/clif.c index 35c9afc8c..99eee9ffe 100644 --- a/src/map/clif.c +++ b/src/map/clif.c @@ -1334,22 +1334,22 @@ int clif_blown(struct block_list *bl) /*========================================== * *------------------------------------------*/ -int clif_fixpos(struct block_list *bl) +void clif_fixpos(struct block_list *bl) { - unsigned char buf[16]; - - nullpo_retr(0, bl); + unsigned char buf[10]; + nullpo_retv(bl); - WBUFW(buf,0)=0x88; - WBUFL(buf,2)=bl->id; - WBUFW(buf,6)=bl->x; - WBUFW(buf,8)=bl->y; + WBUFW(buf,0) = 0x88; + WBUFL(buf,2) = bl->id; + WBUFW(buf,6) = bl->x; + WBUFW(buf,8) = bl->y; clif_send(buf, packet_len(0x88), bl, AREA); - if (disguised(bl)) { - WBUFL(buf,2)=-bl->id; + + if( disguised(bl) ) + { + WBUFL(buf,2) = -bl->id; clif_send(buf, packet_len(0x88), bl, SELF); } - return 0; } /*========================================== @@ -7263,18 +7263,22 @@ int clif_charnameupdate (struct map_session_data *ssd) return 0; } -int clif_slide(struct block_list *bl, int x, int y){ +void clif_slide(struct block_list *bl, int x, int y) +{ unsigned char buf[10]; - - nullpo_retr(0, bl); + nullpo_retv(bl); WBUFW(buf, 0) = 0x01ff; WBUFL(buf, 2) = bl->id; WBUFW(buf, 6) = x; WBUFW(buf, 8) = y; - clif_send(buf, packet_len(0x1ff), bl, AREA); - return 0; + + if( disguised(bl) ) + { + WBUFL(buf,2) = -bl->id; + clif_send(buf, packet_len(0x1ff), bl, SELF); + } } /*------------------------------------------ diff --git a/src/map/clif.h b/src/map/clif.h index 6ff91a957..ee3222920 100644 --- a/src/map/clif.h +++ b/src/map/clif.h @@ -119,8 +119,8 @@ void clif_move(struct unit_data *ud); //area void clif_changemap(struct map_session_data*,short,int,int); //self void clif_changemapserver(struct map_session_data* sd, unsigned short map_index, int x, int y, uint32 ip, uint16 port); //self int clif_blown(struct block_list *); // area -int clif_slide(struct block_list *,int,int); // area -int clif_fixpos(struct block_list *); // area +void clif_slide(struct block_list *,int,int); // area +void clif_fixpos(struct block_list *); // area int clif_npcbuysell(struct map_session_data*,int); //self int clif_buylist(struct map_session_data*,struct npc_data*); //self int clif_selllist(struct map_session_data*); //self |