From 415cbb44d031e0a348d937c917c629913da0afce Mon Sep 17 00:00:00 2001 From: Stijn Buys Date: Fri, 18 Jul 2008 10:59:23 +0000 Subject: parse engine sound from .map model --- src/model/map.cc | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'src/model/map.cc') diff --git a/src/model/map.cc b/src/model/map.cc index 39e2b9c..972ae82 100644 --- a/src/model/map.cc +++ b/src/model/map.cc @@ -39,14 +39,25 @@ Model * Map::load(std::string const &name) if (mapfile.got_classname("worldspawn")) { + // new wordspawn + + } else if (mapfile.classname().compare("worldspawn") == 0 ) { + + // worldspawn attributes + if (mapfile.got_key_int("enginesound", u)) { + model->model_enginesound = u; + continue; + } + } else if (mapfile.got_classname("light")) { + // new light light = new Light(); model->add_light(light); } else if (mapfile.classname().compare("light") == 0 ) { - // light attributes + // light attributes if (mapfile.got_key_vector3f("origin", light->light_location)) { light->light_location *= SCALE; continue; -- cgit v1.2.3