summaryrefslogtreecommitdiff
path: root/src/map/clif.c
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2018-07-06 00:46:35 +0300
committerAndrei Karas <akaras@inbox.ru>2018-07-15 20:36:16 +0300
commit304f26bf681ac8c003c1979da4855426be60bb09 (patch)
tree21aa0f5314a40a41b2b26131228c7eb72b460146 /src/map/clif.c
parent3a970959f9e0a2589c98355a0ff7afbbde5bf212 (diff)
downloadhercules-304f26bf681ac8c003c1979da4855426be60bb09.tar.gz
hercules-304f26bf681ac8c003c1979da4855426be60bb09.tar.bz2
hercules-304f26bf681ac8c003c1979da4855426be60bb09.tar.xz
hercules-304f26bf681ac8c003c1979da4855426be60bb09.zip
Update packet ZC_FEED_PET.
Diffstat (limited to 'src/map/clif.c')
-rw-r--r--src/map/clif.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/map/clif.c b/src/map/clif.c
index a666f4724..56be573c4 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -7328,15 +7328,17 @@ static void clif_pet_emotion(struct pet_data *pd, int param)
static void clif_pet_food(struct map_session_data *sd, int foodid, int fail)
{
int fd;
+ struct PACKET_ZC_FEED_PET p;
nullpo_retv(sd);
- fd=sd->fd;
- WFIFOHEAD(fd,packet_len(0x1a3));
- WFIFOW(fd,0)=0x1a3;
- WFIFOB(fd,2)=fail;
- WFIFOW(fd,3)=foodid;
- WFIFOSET(fd,packet_len(0x1a3));
+ fd = sd->fd;
+ WFIFOHEAD(fd, sizeof(p));
+ p.packetType = 0x1a3;
+ p.result = fail;
+ p.itemId = foodid;
+ memcpy(WFIFOP(fd, 0), &p, sizeof(p));
+ WFIFOSET(fd, sizeof(p));
}
/// Presents a list of skills that can be auto-spelled (ZC_AUTOSPELLLIST).