summaryrefslogtreecommitdiff
path: root/src/map/clif.c
diff options
context:
space:
mode:
authorai4rei <ai4rei@54d463be-8e91-2dee-dedb-b68131a5f0ec>2010-11-28 22:43:10 +0000
committerai4rei <ai4rei@54d463be-8e91-2dee-dedb-b68131a5f0ec>2010-11-28 22:43:10 +0000
commitf5211cd347e39ea4c97c354006811cd251961687 (patch)
tree2b333464005bbb08bd465d9dceafb73018d97b11 /src/map/clif.c
parentdc1175bda087b4b4ce657a114225b5daefbcf5c4 (diff)
downloadhercules-f5211cd347e39ea4c97c354006811cd251961687.tar.gz
hercules-f5211cd347e39ea4c97c354006811cd251961687.tar.bz2
hercules-f5211cd347e39ea4c97c354006811cd251961687.tar.xz
hercules-f5211cd347e39ea4c97c354006811cd251961687.zip
* Added emotion_type enumeration for clif_emotion constants.
- Made clif_parse_Emotion use clif_emotion, rather than having it's code inlined. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14518 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/clif.c')
-rw-r--r--src/map/clif.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/src/map/clif.c b/src/map/clif.c
index c99dab0b2..85b7d8667 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -9063,10 +9063,8 @@ void clif_parse_ChangeDir(int fd, struct map_session_data *sd)
*------------------------------------------*/
void clif_parse_Emotion(int fd, struct map_session_data *sd)
{
- unsigned char buf[64];
-
if (battle_config.basic_skill_check == 0 || pc_checkskill(sd, NV_BASIC) >= 2) {
- if (RFIFOB(fd,2) == 34) {// prevent use of the mute emote [Valaris]
+ if (RFIFOB(fd,2) == E_MUTE) {// prevent use of the mute emote [Valaris]
clif_skill_fail(sd, 1, 0, 1);
return;
}
@@ -9077,11 +9075,8 @@ void clif_parse_Emotion(int fd, struct map_session_data *sd)
return;
}
sd->emotionlasttime = time(NULL) + 1; // not more than 1 per second (using /commands the client can spam it)
-
- WBUFW(buf,0) = 0xc0;
- WBUFL(buf,2) = sd->bl.id;
- WBUFB(buf,6) = RFIFOB(fd,2);
- clif_send(buf, packet_len(0xc0), &sd->bl, AREA);
+
+ clif_emotion(&sd->bl, RFIFOB(fd,2));
} else
clif_skill_fail(sd, 1, 0, 1);
}