How can I know the type of animation key using MXS?


Hi guys,
This is my first post on this forum so I hope that I writte in the correct spot.

I’m trying to check the type of keys using MaxScript. The idea is to copy/paste animations in biped but I need to also paste FreeKeys, SlidingKeys and PlantedKeys, the thing is that I don’t want to save an (.bip) file.

Searching on google and also on this forum I found this:

The thing is that I’m working with biped and I want to check is there is a Sliding key for example.
The code to create a sliding key is ( biped.setSlidingKey ) but I don’t kwow how check using MXS if the key in( X frame) is an position key or a PlantedKey instead.

Any help would be greatly appreciated.

Thanks in advance.


Searching on internet I found this code. Is there any better solution to do the job?

   for t = animationRange.start to animationRange.end do
    	at time t
    		gki = getKeyIndex $.controller t
    		if gki > 0 then
    			gbk = biped.getkey $.controller gki
    			if  gbk.ikBlend  == 1.0 then print "sliding key" else print "The Black Keys" 


That is the proper way to check. Also, for a planted key check Join To Previous Key (ikJoinedPivot).


Thank you Martinez to take the time to answer. I’m going to try it and let see what I get.