3
$\begingroup$

Is it possible to add driver to Scene.current_frame so that one scene's current frame can drive other scene's?

If not is there a way to link them continuously?

Thanks.

$\endgroup$
3
  • 2
    $\begingroup$ Isn't this just the same question as the one you asked yesterday? $\endgroup$ Commented Jun 2, 2016 at 14:32
  • $\begingroup$ @RayMairlot hmmm yeah saw comment after posted answer. Will leave on this one for now. $\endgroup$
    – batFINGER
    Commented Jun 2, 2016 at 14:55
  • $\begingroup$ @RayMairlot Yes, sorry about that. I didn't know about drivers then, so thought this was a more direct question. Will link that to this one. $\endgroup$
    – AhdSaji
    Commented Jun 2, 2016 at 16:55

1 Answer 1

2
$\begingroup$

You cannot add a driver to the frame_current property of the scene object, error message from console.

>>> C.scene.driver_add('frame_current')
Traceback (most recent call last):
  File "<blender_console>", line 1, in <module>
TypeError: bpy_struct.driver_add(): property "frame_current" not animatable

You could do something with frame change handlers.

import bpy

def lockscenes(scene):
    if scene.name == "Scene": # master scene
        f = scene.frame_current
        for scene in bpy.data.scenes:
            if scene.name == "Scene":
                continue
            scene.frame_set(f)
    return None

bpy.app.handlers.frame_change_post.append(lockscenes)
$\endgroup$
0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .