diff options
author | Stijn Buys <ingar@osirion.org> | 2010-02-25 19:28:14 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2010-02-25 19:28:14 +0000 |
commit | 90fbc4c5caf5afd54920894319448b74967399ba (patch) | |
tree | d4a8fe5ccdcbe94f4a3e5e1115f5baed26e8c2e3 /src/model/model.cc | |
parent | 83757353860fa447c36d4078602efea36d7da94e (diff) |
added initial support for model sound tags,
moved sound code from client/targets.cc to client/soundext.cc,
added master volume cvar snd_volume
Diffstat (limited to 'src/model/model.cc')
-rw-r--r-- | src/model/model.cc | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/model/model.cc b/src/model/model.cc index 2ac2b50..5ba4deb 100644 --- a/src/model/model.cc +++ b/src/model/model.cc @@ -62,6 +62,12 @@ Model::~Model() delete(*flit); } model_flares.clear(); + + // delete all sound tags + for (Sounds::iterator sit = model_sounds.begin(); sit != model_sounds.end(); sit++) { + delete (*sit); + } + model_sounds.clear(); } void Model::set_radius(const float radius) @@ -94,6 +100,11 @@ void Model::add_flare(Flare *flare) model_flares.push_back(flare); } +void Model::add_sound(Sound *sound) +{ + model_sounds.push_back(sound); +} + void Model::add_dock(Dock *dock) { model_docks.push_back(dock); |