1.3.6 update included some new functionality that I wanted to highlight in code scripts and identify its use.
RGB Image
One of the most requested features, this allows for Bitmap image directly from the Kinect camera’s color video. The image is pushed at 640×480 witch is the native resolution supported by the hardware. You will use the same MotionNexusCameraEvent as with depth – the only change being in the plugin settings.
//You must turn off depth image or depth will be automatically defaulted
var settings:MotionNexusPluginSettings=new MotionNexusPluginSettings(MotionNexusPluginSettings.USER_LOCAL);
settings.rgbImageEnabled=true;
MotionNexus.pluginSettings=settings;
Player Masking
Player masking is essentially a green screen or the depth image with the user cut out. The user is colored a solid color and removed from background leaving a transparent image. The masked images use the same MotionNexusCameraEvent as depth and RGB.

var settings:MotionNexusPluginSettings=new MotionNexusPluginSettings(MotionNexusPluginSettings.USER_LOCAL,true,false,false,true);
settings.playerMaskEnabled=true;
//settings.playerMaskSettings=[Red,Green,Blue,Alpha];
settings.playerMaskSettings=[120,180,200,1];
MotionNexus.pluginSettings=settings;
Mirroring
You now have the ability to control the mirroring of the skeleton, depth image, and RGB image. This can be done from the plugin settings.
var settings:MotionNexusPluginSettings=new MotionNexusPluginSettings(MotionNexusPluginSettings.USER_LOCAL,true,false,false,true);
settings.mirrorDepthImage=true;
settings.mirrorSkeleton=true;
MotionNexus.pluginSettings=settings;
Skeleton Events
Add and Remove of the skeleton are now events to help promote a clean user experience
MotionNexus.addEventListener(MotionNexusSkeletonEvent.USER_SKELETON_ADDED, onSkeletonAdded);
MotionNexus.addEventListener(MotionNexusSkeletonEvent.USER_SKELETON_UPDATED, onSkeletonUpdated);
MotionNexus.addEventListener(MotionNexusSkeletonEvent.USER_SKELETON_REMOVED, onSkeletonRemoved);
Speech Recognition Language support
This gives you the ability to provide speech recognition in multiple language scenarios. In order for this to work correctly you will need to download and install the corresponding speech pack http://www.microsoft.com/en-us/download/details.aspx?id=29864. After you have the correct speech pack installed you will want to reference the language identifier from here – http://msdn.microsoft.com/en-us/library/dd318693(VS.85).aspx.
When using the identifier you will need to use the base value. For example English United States is referenced as 0×0409, but instead you pass in 409. You will also want to look over the grammar rules to create a correct grammar file – http://msdn.microsoft.com/en-us/library/ms723632(v=vs.85).aspx
var settings:MotionNexusPluginSettings=new MotionNexusPluginSettings(MotionNexusPluginSettings.USER_LOCAL,true,false,false,true);
settings.speechRecognitionEnabled=true;
settings.speechRecognitionGrammarFile='Location of grammar file';
settings.speechRecognitionLanguage = '409';
MotionNexus.pluginSettings=settings;