+ renderable = &resources.get<GL::Scene>(opts.renderable_name);
+ }
+ else if(ext==".seq")
+ {
+ GL::SequenceTemplate *tmpl = load<GL::SequenceTemplate>(opts.renderable_name);
+ GL::SequenceBuilder bld(*tmpl);
+ sequence = bld.build(view);
+ }
+ else
+ throw usage_error("Unknown renderable type");
+
+ if(!opts.animation_name.empty())
+ {
+ if(!object)
+ throw usage_error("Must have an object to animate");
+
+ GL::Animation *anim = load<GL::Animation>(opts.animation_name);
+ anim_player = new GL::AnimationPlayer;
+ anim_object = new GL::AnimatedObject(*object);
+ anim_player->play(*anim_object, *anim);
+ renderable = anim_object;