From ac2c5e7b2d74728563371ed204d84369ba743ac6 Mon Sep 17 00:00:00 2001 From: codemaster Date: Sun, 9 Jan 2005 23:08:31 +0000 Subject: * Added the @sound command and the NPC command of soundeffectall - works just like soundeffect, but plays for everyone in the area [Codemaster] [SVN 942] git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/branches/stable@942 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/map/clif.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'src/map/clif.c') diff --git a/src/map/clif.c b/src/map/clif.c index 825e18e96..062fe02c4 100644 --- a/src/map/clif.c +++ b/src/map/clif.c @@ -7209,6 +7209,24 @@ void clif_soundeffect(struct map_session_data *sd,struct block_list *bl,char *na return; } + +int clif_soundeffectall(struct block_list *bl, char *name, int type) +{ + unsigned char buf[31]; + memset(buf, 0, packet_len_table[0x1d3]); + + nullpo_retr(0, bl); + + WBUFW(buf,0)=0x1d3; + memcpy(WBUFP(buf,2), name, 24); + WBUFB(buf,26)=type; + WBUFL(buf,27)=0; + WBUFL(buf,31)=bl->id; + clif_send(buf, packet_len_table[0x1d3], bl, AREA); + + return 0; +} + // displaying special effects (npcs, weather, etc) [Valaris] int clif_specialeffect(struct block_list *bl, int type, int flag) { unsigned char buf[24]; -- cgit v1.2.3-70-g09d2