Pre-release
Adventure.js Docs Downloads
Score: 0 Moves: 0
//set.js
(function() {
  /*global adventurejs A*/ 
  "use strict";

	var p = adventurejs.Display.prototype;

  /**
	 * Provides a chainable shortcut method for setting a number of properties on the instance.
	 * @method adventurejs.Display#set
	 * @param {Object} props A generic object containing properties to copy to the DisplayObject instance.
	 * @returns {adventurejs.Display} Returns the instance the method is called on (useful for chaining calls.)
	 * @chainable
	*/
	p.set = function Display_set(props) 
  {
		if (props != null) 
    {
			for (var n in props) 
      { 
				this[n] = props[n]; 
			}
		}
		return this;
	};
}());