How to use Maxscript to add animation group nodes?

maxScriptManager = dotNetObject “Max2Babylon.MaxScriptManager”
maxScriptManager.RenameAnimationGroup aniGroup “TestAni”
testAni=maxScriptManager.GetAnimationGroupByName “TestAni”

id = $.handle
type = dotnetclass “System.UInt32”
uID = dotnet.ValueToDotNetObject id type

maxScriptManager.AddNodeInAnimationGroup testAni uID

format "AnimationGroupNodes is % " testAni.AnimationGroupNodes

Assiging to @Guillaume_Pelletier our exporter master :slight_smile:

Be aware that there might be a slight delay with his answers related to the vacations

Hey guys, i will try to have a look this week. Have a great christmas.

1 Like

Ok Guys, there was a bug which prevent script to relay on the correct AnimationGroup to add the node. I solved it and publish a PR related to it. Be aware that there might be a delay for the PR to be merge.
Assuming a Group named “Animation” exist, the following script

manager = dotNetObject “Max2Babylon.MaxScriptManager”
g = manager.GetAnimationGroupByName “Animation”
id = $.handle
manager.AddNodeInAnimationGroup g id

works now.

Happy christmas.


GG @Guillaume_Pelletier

Happy christmas.