2.5 Delete Action?

I have been using 2.5 and I have added a keyframe to the cube. In the GraphEditor I can see the keyframe and the action on the left. I don’t want the keyframes any more so I select them an delete them. Now I have an empty action, but I can’t get rid of it. Is this normal? How do I delete the action in Blender 2.5?

I would also like to know! :slight_smile:

Anyone? Is there way to delete multiple actions at same time? I have so many useless actions and I want to clean my scene.

:o I allways delete the keys in DopeSheet with the certitude to ALSO delete the correspondant “Actions”… Aren’t these the exact and same thing!!! :o

I just tried this. I opened a file with one action in the dopesheet, changed the dopesheet to action editor. The field that has the name of the action has a couple icons to the right, one is number of users, one is ‘+’ sign for adding actions, one is a ‘x’ for removing actions. Hover over the ‘x’ and a pop up tells you to shift click to force removal upon saving. I shift clicked the ‘x’ and saved the file, then reopened the file and action was gone. No need to shut down and restart blender as you have to in 2.49b.

I hope this ‘force removal’ has been implemented throughout Blender…

Remove multiple actions is must have! Imagine if you have 1000 actions and have to remove them one by one…

Thanks revolt_randy. That way I can delete actions one by one, but I still have 1000 actions to delete.

Is there any way to select them all or set of them and delete?

Seconded, that it would be very handy to be able to delete multiple actions at once and avoid clutter. (I was hoping i might be able to do it by navigating to the Actions folder within the .blend from another scene using Append, or by datablocks - but no such luck :0( )
As it is, it seems kind of odd that you have to save and reload before your deleting of one action can take effect.

maybe you should look into the
python-section of the forum

to manage multiple (up to 1000 ?) objects, actions
one can make use of:
“animation_data_clear” for an object
“user_clear” for an action

then, after a save and reload, the not-any-more-used instances are gone.

If - after a reload, a action is still there, then there are still other objects
using this action or! the action is still part of an nla.

Hopefully this commit in my soc branch is sufficient.

I’ll also look at a “Clear useless action” operator.
EDIT: http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=37099
Use operator search to run this. Perhaps this should go in the menus for the Outliner or so?

Like test-dr says; unchecking the [F] next to the actions you don’t want >shift click the [X] next to the actions>save>Ctrl+O to open a new file> then reopen the previous file and they’ll be gone.

Hey test-dr - the info you give here looks handy so thanks… but I (along with i’m sure quite a few other animators around here) know next to nothing about Python (is it Version 3 Blender uses now?) so if you could point us to any step-by-step info about how to use the ‘user_clear’ function (or command, or whatever you coders call it :0D) on multiple actions at once, that would be really useful

Aligorith, Hello (your blog posts are really helpful, btw!), Clear Useless Action sounds super-useful! Though i guess its worth adding that, more often than not, i want to bulk-clear actions still have f-curves too.
Again, an typical artists question: how do you search for an operator? Is there a tutorial? :0)
(thanks for your patience)

to search for an ?operator? as a program-routine, that is not available
with a menu-entry is done in the window with the spacebar in blender-2.5x.
For example to use the routines like “Make fur”, “Make smoke” …
with the selected object in the 3D-View, press spacebar and in the pop-up
of the window search for those names … and there are a lot more.
One i did use often is the “bake action” routine to get the constraints baked for an armature.
To use python snippets without better knowledge is like creating
hundreds of objects an then asking how to select and delete.
So i can only provide a simple “script”, because i dont know
what selection-crits are possible. This will do it for all
objects and all actions (normaly people use special names and
can do a selection for the wanted action)

for o in bpy.data.objects:
for a in bpy.data.actions:

i am shure, i already saw such examples in the python-part of the forum, maybe with some special usage.

I also use something like this to delete only fake actions…

import bpy
for a in bpy.data.actions:
    if a.users == 1 and a.use_fake_user:

You will find all your old blends are bloated with actions of deleted objects…
hopefully not any more after Aligorith’s commits…!

Cheers both of you - that was very helpful (and as a bonus, alerted me to the Bake Constraint script, which looks useful!)

Thanks Aligorith for the fast action! I’ll have to check out a new build and this feature.