[Closed] Get selected keys as array
Hey everyone, been trying to get my head around this but I seem to fail despite reading the reference and searching forums
What I’m trying to do is to get an array of the selected keys (in Trackview or Trackbar), which subsequently let med change properties of respective key. Like: [I]$.pos.controller.X_Position.controller.keys.value ect.
I thought I could figure out, but apparently not. But I have a feeling it’s quite simple once you understand how.
Thanks for any enlightenment!
posX = $.pos.controller.X_Position.controller
for k=1 to posX.keys.count where iskeyselected posX k collect getKey posX k
something like this?
Well, my example shows a specific object and a specific controller, but what I seek is a script that collect keys regardless of what controller and object the keys belong to.
If I select keys 4 and 7 on $sphere001 the script should know this.
If I select keys 2, 6, and 9 on $box001 the script should know this.
My intention is actually to create a small panel that let me input numerical tangent values on many keys. Or maybe there is already such tool somewhere? I haven’t managed to find one myself though.