Moved timelines code into a class on the inheritance hierarchy of object_basic. This is needed for script-local timeline code.
Timelines now generate object-local copies for relevant scripts. A virtual lookup is created per-object (but only for the timelines it uses, if any).
Copy local timeline variables into local objects.
Actions-based timelines are now properly recorded too.
Timelines and scripts interleave their dependencies seamlessly now. Allows chaining timelines and scripts, and correctly factoring back the variables, scripts, and timelines found in each layer.
Merge pull request #777 from sorlok/timelines_with_scr

Timelines internal to objects (fixes object+timeline+script)