summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorshennetsind <shennetsind@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-05-24 21:08:21 +0000
committershennetsind <shennetsind@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-05-24 21:08:21 +0000
commit21aab2567e2059bd2d377d70fc1b437e5cc28b0e (patch)
treed45836a490c986ae6a890b69f65d3b84416b2742 /src
parent4b01558cea5a03dc39503030f5469a33aa2d7b1f (diff)
downloadhercules-21aab2567e2059bd2d377d70fc1b437e5cc28b0e.tar.gz
hercules-21aab2567e2059bd2d377d70fc1b437e5cc28b0e.tar.bz2
hercules-21aab2567e2059bd2d377d70fc1b437e5cc28b0e.tar.xz
hercules-21aab2567e2059bd2d377d70fc1b437e5cc28b0e.zip
Follow up r16143 minor minor performance improvement
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16145 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src')
-rw-r--r--src/map/clif.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/map/clif.c b/src/map/clif.c
index d626c94b1..97e96ec8e 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -4132,7 +4132,6 @@ int clif_damage(struct block_list* src, struct block_list* dst, unsigned int tic
{
unsigned char buf[33];
struct status_change *sc;
- int dir=0;
#if PACKETVER < 20071113
const int cmd = 0x8a;
#else
@@ -4151,8 +4150,6 @@ int clif_damage(struct block_list* src, struct block_list* dst, unsigned int tic
}
}
- dir = unit_getdir(src);
-
WBUFW(buf,0)=cmd;
WBUFL(buf,2)=src->id;
WBUFL(buf,6)=dst->id;
@@ -4201,8 +4198,9 @@ int clif_damage(struct block_list* src, struct block_list* dst, unsigned int tic
clif_send(buf,packet_len(cmd),src,SELF);
}
- if(src == dst)
- unit_setdir(src,dir);
+ if(src == dst) {
+ unit_setdir(src,unit_getdir(src));
+ }
//Return adjusted can't walk delay for further processing.
return clif_calc_walkdelay(dst,ddelay,type,damage+damage2,div);
}