about summary refs log tree commit diff
path: root/src/game/client/components/chat.cpp
diff options
context:
space:
mode:
authorMagnus Auvinen <magnus.auvinen@gmail.com>2008-08-29 05:34:18 +0000
committerMagnus Auvinen <magnus.auvinen@gmail.com>2008-08-29 05:34:18 +0000
commit0511e1152a13ad99b51a819a75ef457404e86d4c (patch)
treed8e31b98f18f7e027ee72a9792248072d93e5852 /src/game/client/components/chat.cpp
parentb22dd1488cdae53d27215fda051fea9bfc72ac1d (diff)
downloadzcatch-0511e1152a13ad99b51a819a75ef457404e86d4c.tar.gz
zcatch-0511e1152a13ad99b51a819a75ef457404e86d4c.zip
added sound component
Diffstat (limited to 'src/game/client/components/chat.cpp')
-rw-r--r--src/game/client/components/chat.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/game/client/components/chat.cpp b/src/game/client/components/chat.cpp
index 1bdc7e85..9f48b292 100644
--- a/src/game/client/components/chat.cpp
+++ b/src/game/client/components/chat.cpp
@@ -7,6 +7,8 @@
 #include <game/client/gameclient.hpp>
 #include <game/client/gc_client.hpp>
 
+#include <game/client/components/sounds.hpp>
+
 #include "chat.hpp"
 
 void CHAT::on_reset()
@@ -17,8 +19,6 @@ void CHAT::on_reset()
 	current_line = 0;
 }
 
-
-
 void CHAT::con_say(void *result, void *user_data)
 {
 	((CHAT*)user_data)->say(0, console_arg_string(result, 0));
@@ -87,9 +87,9 @@ void CHAT::on_message(int msgtype, void *rawmsg)
 		add_line(msg->cid, msg->team, msg->message);
 
 		if(msg->cid >= 0) // TODO: repair me
-			snd_play(CHN_GUI, data->sounds[SOUND_CHAT_CLIENT].sounds[0].id, 0);
+			gameclient.sounds->play(SOUNDS::CHN_GUI, SOUND_CHAT_CLIENT, 0, vec2(0,0));
 		else
-			snd_play(CHN_GUI, data->sounds[SOUND_CHAT_SERVER].sounds[0].id, 0);
+			gameclient.sounds->play(SOUNDS::CHN_GUI, SOUND_CHAT_SERVER, 0, vec2(0,0));
 	}
 }