Pre-release
Adventure.js Docs Downloads
Score: 0 Moves: 0
// setPosition.js
(function () {
  /*global adventurejs A*/
  "use strict";
  var p = adventurejs.Tangible.prototype;
  /**
   * Set this asset's global position.
   * @memberOf adventurejs.Tangible
   * @method adventurejs.Tangible#setPosition
   * @param {Object} params
   * @returns {Object}
   */
  p.setPosition = function Tangible_setPosition(params) {
    this.position.x = params.x || this.position.x;
    this.position.y = params.y || this.position.y;
    this.position.z = params.z || this.position.z;
    return this.position;
  };
})();