- reader.get("x", bbox.p1.x);
- reader.get("y", bbox.p1.y);
- reader.get("type", type);
- reader.get("use_path", use_path);
- sprite = sprite_manager->create("images/objects/flying_platform/platform.sprite");
- sprite->set_action(type);
- bbox.set_size(sprite->get_width(), sprite->get_height());
+ const lisp::Lisp* pathLisp = reader.get_lisp("path");
+ if(pathLisp == NULL)
+ throw std::runtime_error("No path specified for platform");
+ path.reset(new Path());
+ path->read(*pathLisp);
+ walker.reset(new PathWalker(path.get()));