Pre-release
AdventureJS Docs Downloads
Score: 0 Moves: 0
// getAdjective.js

(function () {
  /* global AdventureJS A */

  var p = AdventureJS.Dictionary.prototype;

  /**
   * Determine whether string is recognized as an getAdjective
   * and return the string.
   * @memberOf AdventureJS.Dictionary
   * @method AdventureJS.Dictionary#getAdjective
   * @kind function
   * @param {String} word
   * @returns {String|Boolean}
   */
  p.getAdjective = function Dictionary_getAdjective(word) {
    if (this.adjectives.indexOf(word) > -1) return word;
    else return false;
  };
})();