<commit_before>/**
*  @module cloudkid
*/
(function() {
	
	"use strict";

	/**
	*  [PIXI Only] Animator for interacting with Spine animations
	*  @class PixiAnimator
	*/
	var PixiAnimator = function()
	{
		this._timelines = [];
		this._boundUpdate = this._update.bind(this);
	};
	
	var p = PixiAnimator.prototype = {};
	
	/**
	* A reference to this instance of PixiAnimator. This is internal to PixiAnimator and can't be accessed externally.
	* @property {PixiAnimator} _instance
	* @private
	* @static
	*/
	var _instance = null;
	
	/**
	* The collection of AnimTimelines that are playing
	* @property {Array} _timelines
	* @private
	*/
	p._timelines = null;
	
	/**
	* The number of animations
	* @property {int} _numAnims
	* @private
	*/
	p._numAnims = 0;
	
	/**
	* A string reference to PixiAnimator's update callback
	* so it can be removed in the event that there are no
	* animations to play
	* @property {String} _updateAlias
	* @private
	*/
	p._updateAlias = "animator";
	
	/**
	* The function that PixiAnimator uses for update calls. Do not modify.
	* @property {function} _boundUpdate
	* @private
	*/
	p._boundUpdate = null;
	
	/**
	* The instance of cloudkid.Audio or cloudkid.Sound for playing audio along with animations.
	* 
	* @property {cloudkid.Audio|cloudkid.Sound} soundLib
	* @public
	*/
	p.soundLib = null;
	
	/**
	 * Stored collection of AnimTimelines. This is internal to PixiAnimator and can't be accessed externally.
	 * @property {Array} _animPool
	 * @private
	 * @static
	 */
	var _animPool = null;
	
	/**
	*  The global captions object to use with animator
	*  @property {cloudkid.Captions} captions
	*  @public
	*/
	p.captions = null;

	/**
	 * Initializes the singleton instance of PixiAnimator.
	 * @method init
	 * @static
	 */
	PixiAnimator.init = function()
	{
		_instance = new PixiAnimator();
		_animPool = [];
	};
	
	/**
	* Getter for the reference to this instance of PixiAnimator
	* @property {PixiAnimator} instance
	* @readOnly
	* @static
	*/
	Object.defineProperty(PixiAnimator, "instance",
	{
		get: function() { return _instance; }
	});
	
	/**
	* Play a specified animation
	* 
	* @function play
	* @param {PIXI.MovieClip|PIXI.Spine} clip The clip to play
	* @param {String} anim The alias for the animation to play
	* @param {Object|function} [options] The object of optional parameters or onComplete callback function
	* @param {function} [options.callback=null] The function to call once the animation has finished
	* @param {bool} [options.loop=false] Whether the animation should loop
	* @param {int} [options.speed=1] The speed at which to play the animation
	* @param {int} [options.startTime=0] The time in milliseconds into the animation to start.
	* @param {Object|String} [options.soundData=null] Data about a sound to sync the animation to, as an alias or in the format {alias:"MyAlias", start:0}.
	*        start is the seconds into the animation to start playing the sound. If it is omitted or soundData is a string, it defaults to 0.
	*/
	p.play = function(clip, anim, options, loop, speed, startTime, soundData)
	{<commit_msg>Fixed inaccurate parameter doc in PixiAnimator.<commit_after>/**
*  @module cloudkid
*/
(function() {
	
	"use strict";

	/**
	*  [PIXI Only] Animator for interacting with Spine animations
	*  @class PixiAnimator
	*/
	var PixiAnimator = function()
	{
		this._timelines = [];
		this._boundUpdate = this._update.bind(this);
	};
	
	var p = PixiAnimator.prototype = {};
	
	/**
	* A reference to this instance of PixiAnimator. This is internal to PixiAnimator and can't be accessed externally.
	* @property {PixiAnimator} _instance
	* @private
	* @static
	*/
	var _instance = null;
	
	/**
	* The collection of AnimTimelines that are playing
	* @property {Array} _timelines
	* @private
	*/
	p._timelines = null;
	
	/**
	* The number of animations
	* @property {int} _numAnims
	* @private
	*/
	p._numAnims = 0;
	
	/**
	* A string reference to PixiAnimator's update callback
	* so it can be removed in the event that there are no
	* animations to play
	* @property {String} _updateAlias
	* @private
	*/
	p._updateAlias = "animator";
	
	/**
	* The function that PixiAnimator uses for update calls. Do not modify.
	* @property {function} _boundUpdate
	* @private
	*/
	p._boundUpdate = null;
	
	/**
	* The instance of cloudkid.Audio or cloudkid.Sound for playing audio along with animations.
	* 
	* @property {cloudkid.Audio|cloudkid.Sound} soundLib
	* @public
	*/
	p.soundLib = null;
	
	/**
	 * Stored collection of AnimTimelines. This is internal to PixiAnimator and can't be accessed externally.
	 * @property {Array} _animPool
	 * @private
	 * @static
	 */
	var _animPool = null;
	
	/**
	*  The global captions object to use with animator
	*  @property {cloudkid.Captions} captions
	*  @public
	*/
	p.captions = null;

	/**
	 * Initializes the singleton instance of PixiAnimator.
	 * @method init
	 * @static
	 */
	PixiAnimator.init = function()
	{
		_instance = new PixiAnimator();
		_animPool = [];
	};
	
	/**
	* Getter for the reference to this instance of PixiAnimator
	* @property {PixiAnimator} instance
	* @readOnly
	* @static
	*/
	Object.defineProperty(PixiAnimator, "instance",
	{
		get: function() { return _instance; }
	});
	
	/**
	* Play a specified animation
	* 
	* @function play
	* @param {PIXI.MovieClip|PIXI.Spine} clip The clip to play
	* @param {String|Array} anim Depending on the type of clip, this could be one of several things.
	*
	* If animating a MovieClip, this should be the array of Textures that is the animation (or null to use the existing array on the clip).
	*
	* If animating a Spine object:
	* - If anim is a string it will play that single animation by name.
	* - If anim is an array of strings it will play as a list of animations (only the last one can loop).
	* - If anim is an array of objects (with anim, loop, and speed properties) then multiple animations will be played simultaneously.
	*    When multiple animations play, animation stops when any non looping animation ends.
	* @param {Object|function} [options] The object of optional parameters or onComplete callback function
	* @param {function} [options.callback=null] The function to call once the animation has finished
	* @param {bool} [options.loop=false] Whether the animation should loop
	* @param {int} [options.speed=1] The speed at which to play the animation
	* @param {int} [options.startTime=0] The time in milliseconds into the animation to start.
	* @param {Object|String} [options.soundData=null] Data about a sound to sync the animation to, as an alias or in the format {alias:"MyAlias", start:0}.
	*        start is the seconds into the animation to start playing the sound. If it is omitted or soundData is a string, it defaults to 0.
	*/
	p.play = function(clip, anim, options, loop, speed, startTime, soundData)
	{
{'fraction_non_alphanumeric': 0.10523998238661382, 'fraction_numerical': 0.0014677821811243212, 'mean_word_length': 3.6480218281036834, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3699664', 'n_tokens_mistral': 2282, 'n_tokens_neox': 2114, 'n_words': 785}