EDIT New script! Hide layers with no animation
Moderators: Víctor Paredes, Belgarath, slowtiger
- Víctor Paredes
- Site Admin
- Posts: 5814
- Joined: Wed Jan 26, 2005 12:18 am
- Location: Barcelona/Chile
- Contact:
EDIT New script! Hide layers with no animation
Hi, I'm working in a character which has lots of point animation in many of its layers, so I'm constantly navigating between the layers to edit them. The issue is having the layers with no animation also visible in the Layers window makes that navigation much harder.
I love the idea of using filters in the layers palette (and use them a lot), but I'm missing a "show animated layers only" filter. So I thought that maybe it would be possible to create a script that automatically put an "animated" tag into all the layers with any key in the mainline, so then I can quickly filter the layers using that tag.
Do you think that is possible?
Thank you very much.
I love the idea of using filters in the layers palette (and use them a lot), but I'm missing a "show animated layers only" filter. So I thought that maybe it would be possible to create a script that automatically put an "animated" tag into all the layers with any key in the mainline, so then I can quickly filter the layers using that tag.
Do you think that is possible?
Thank you very much.






Moho co-owner
Previously Rigged animation supervisor: My father's dragon, Wolfwalkers & Star Wars Visions "Screecher's Reach"
My personal Youtube Channel
- synthsin75
- Posts: 10253
- Joined: Mon Jan 14, 2008 11:20 pm
- Location: Oklahoma
- Contact:
Re: Script request: Tag all layers with keyframes in Mainlin
Here you go, Victor.
https://drive.google.com/uc?export=down ... YvpSxvcjsy
It's a menu script. It will add the "animated" tag to any layer with animation and remove the tag if animation has been deleted.
https://drive.google.com/uc?export=down ... YvpSxvcjsy
It's a menu script. It will add the "animated" tag to any layer with animation and remove the tag if animation has been deleted.
Last edited by synthsin75 on Fri Aug 20, 2021 5:55 pm, edited 1 time in total.
- Wes
Donations: https://www.paypal.com/paypalme/synthsin75 (Thx, everyone.)
https://www.youtube.com/user/synthsin75
Scripting reference: https://mohoscripting.com/
Donations: https://www.paypal.com/paypalme/synthsin75 (Thx, everyone.)
https://www.youtube.com/user/synthsin75
Scripting reference: https://mohoscripting.com/
- Víctor Paredes
- Site Admin
- Posts: 5814
- Joined: Wed Jan 26, 2005 12:18 am
- Location: Barcelona/Chile
- Contact:
Re: Script request: Tag all layers with keyframes in Mainlin
Thank you very much, Wes! You are very generous.
This is fantastic and will save me a lot of time in this and future projects. And, of course, I recommend everyone to use it, it really simplifies the layer navigation and correction process.
To install it:
- Go to File -> Open Custom Content Folder
- In the folder, navigate to Moho Pro\scripts\menu\
- Drag the syn_tag_animated.lua into any of that folders, or create a new one (in my case, I put it in a new folder called "Animation")
- Go back to Moho and press Ctrl+Alt+Shift+L (or Cmd+Alt+Shift+L if you are using a Mac) to refresh the scripts
To use it:
- Simply go to the go to the menu Scripts/Animation and select the script. The script will add the "animated" tag to every layer which has animation
- To show only the layers with animation, go to the Layers window and select "Tags Contain..." in the Filter section and write "animated"
Now, if you want to see the whole project keyframes in the Timeline, simply select all that filtered layers.
Maybe this sounds small, but at least for me is a huge help
Thanks again!
This is fantastic and will save me a lot of time in this and future projects. And, of course, I recommend everyone to use it, it really simplifies the layer navigation and correction process.
To install it:
- Go to File -> Open Custom Content Folder
- In the folder, navigate to Moho Pro\scripts\menu\
- Drag the syn_tag_animated.lua into any of that folders, or create a new one (in my case, I put it in a new folder called "Animation")
- Go back to Moho and press Ctrl+Alt+Shift+L (or Cmd+Alt+Shift+L if you are using a Mac) to refresh the scripts
To use it:
- Simply go to the go to the menu Scripts/Animation and select the script. The script will add the "animated" tag to every layer which has animation
- To show only the layers with animation, go to the Layers window and select "Tags Contain..." in the Filter section and write "animated"
Now, if you want to see the whole project keyframes in the Timeline, simply select all that filtered layers.
Maybe this sounds small, but at least for me is a huge help

Thanks again!






Moho co-owner
Previously Rigged animation supervisor: My father's dragon, Wolfwalkers & Star Wars Visions "Screecher's Reach"
My personal Youtube Channel
- Víctor Paredes
- Site Admin
- Posts: 5814
- Joined: Wed Jan 26, 2005 12:18 am
- Location: Barcelona/Chile
- Contact:
Re: Script request: Tag all layers with keyframes in Mainlin
Oh, Wes, I'm sorry to bother, but noticed the script also adds the tag to the containers (groups, bones, switches, etc), even if they don't have keyframes themselves. Is there any way to avoid that behavior?
Thanks and sorry again.
Thanks and sorry again.






Moho co-owner
Previously Rigged animation supervisor: My father's dragon, Wolfwalkers & Star Wars Visions "Screecher's Reach"
My personal Youtube Channel
- synthsin75
- Posts: 10253
- Joined: Mon Jan 14, 2008 11:20 pm
- Location: Oklahoma
- Contact:
Re: Script request: Tag all layers with keyframes in Mainlin
I've updated the above link. It should only tag keyframed layers now.
- Wes
Donations: https://www.paypal.com/paypalme/synthsin75 (Thx, everyone.)
https://www.youtube.com/user/synthsin75
Scripting reference: https://mohoscripting.com/
Donations: https://www.paypal.com/paypalme/synthsin75 (Thx, everyone.)
https://www.youtube.com/user/synthsin75
Scripting reference: https://mohoscripting.com/
- Víctor Paredes
- Site Admin
- Posts: 5814
- Joined: Wed Jan 26, 2005 12:18 am
- Location: Barcelona/Chile
- Contact:
Re: Script request: Tag all layers with keyframes in Mainlin
Thank you very much, Wes. It is working perfectly!synthsin75 wrote:I've updated the above link. It should only tag keyframed layers now.






Moho co-owner
Previously Rigged animation supervisor: My father's dragon, Wolfwalkers & Star Wars Visions "Screecher's Reach"
My personal Youtube Channel
- synthsin75
- Posts: 10253
- Joined: Mon Jan 14, 2008 11:20 pm
- Location: Oklahoma
- Contact:
Re: EDIT New script! Hide layers with no animation
Glad I could help, Victor. You're always real good at describing what you need a script to do.
- Wes
Donations: https://www.paypal.com/paypalme/synthsin75 (Thx, everyone.)
https://www.youtube.com/user/synthsin75
Scripting reference: https://mohoscripting.com/
Donations: https://www.paypal.com/paypalme/synthsin75 (Thx, everyone.)
https://www.youtube.com/user/synthsin75
Scripting reference: https://mohoscripting.com/
Re: Script request: Tag all layers with keyframes in Mainlin
Ah, thanks Wes! I has just made a similar script last week but to get around the problem of tagging non animated layers I had a loop running that checks all the animation channels of a layer. Just using this ClearLayerKeyCount function seems a lot faster, do you know how it works/what exactly it does? I'm guessing it clears the keys and forces a recalculation of the key count, but do you know if there's any side effects that I should be aware of?synthsin75 wrote:I've updated the above link. It should only tag keyframed layers now.
- synthsin75
- Posts: 10253
- Joined: Mon Jan 14, 2008 11:20 pm
- Location: Oklahoma
- Contact:
Re: Script request: Tag all layers with keyframes in Mainlin
I wasn't sure what all it did at first, but from my tests, the key count seems to remain the last highest count (even when some are deleted) until cleared...and it recounts them. I didn't find any side effects.GaryC wrote:Ah, thanks Wes! I has just made a similar script last week but to get around the problem of tagging non animated layers I had a loop running that checks all the animation channels of a layer. Just using this ClearLayerKeyCount function seems a lot faster, do you know how it works/what exactly it does? I'm guessing it clears the keys and forces a recalculation of the key count, but do you know if there's any side effects that I should be aware of?synthsin75 wrote:I've updated the above link. It should only tag keyframed layers now.
- Wes
Donations: https://www.paypal.com/paypalme/synthsin75 (Thx, everyone.)
https://www.youtube.com/user/synthsin75
Scripting reference: https://mohoscripting.com/
Donations: https://www.paypal.com/paypalme/synthsin75 (Thx, everyone.)
https://www.youtube.com/user/synthsin75
Scripting reference: https://mohoscripting.com/
Re: Script request: Tag all layers with keyframes in Mainlin
Sounds good, I implemented it now and seems to be working great. Thanks!synthsin75 wrote:I wasn't sure what all it did at first, but from my tests, the key count seems to remain the last highest count (even when some are deleted) until cleared...and it recounts them. I didn't find any side effects.