From 28ba97bdd8fb6ca352dc49dba01a66bd155ad523 Mon Sep 17 00:00:00 2001 From: Stijn Buys Date: Sat, 15 Nov 2008 19:24:55 +0000 Subject: entity extensions --- src/client/client.cc | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) (limited to 'src/client/client.cc') diff --git a/src/client/client.cc b/src/client/client.cc index 42ee5a0..061f29b 100644 --- a/src/client/client.cc +++ b/src/client/client.cc @@ -309,16 +309,6 @@ void Client::notify_message(const core::Message::Channel channel, const std::str con_print << message << std::endl; } -/* FIXME - - these notifications are hacks and need to be fixed -*/ - -void Client::notify_remove_sound(size_t source) -{ - audio::Sources::remove(source); -} - //--- engine functions -------------------------------------------- void Client::func_snd_restart(std::string const &args) @@ -326,8 +316,9 @@ void Client::func_snd_restart(std::string const &args) // unload entity sounds for (core::Entity::Registry::iterator it = core::Entity::registry().begin(); it != core::Entity::registry().end(); it++) { core::Entity *entity = (*it).second; - if (entity->state()) - entity->state()->clearsound(); + + if (ext_sound(entity)) + delete ext_sound(entity); } audio::reset(); -- cgit v1.2.3