Pre-release
Adventure.js Docs Downloads
Score: 0 Moves: 0
// IOVallowOnce.js
(function() {
	/*global adventurejs A*/ 
  "use strict";
  var p = adventurejs.Asset.prototype;	
  /**
   * <strong>IOVallowOnce</strong> is a method to check whether 
   * this asset is subscribed to allow the specified verb to act on it
   * as an indirect object only once.
   * @memberOf adventurejs.Asset
   * @method adventurejs.Asset#IOVallowOnce
   * @param {String} verb
   * @returns {Boolean}
   */
  p.IOVallowOnce = function Asset_IOVallowOnce(verb)
  {
    if( !verb || !this.game.dictionary.verbs[verb] ) return false;
    if( !this.iov[verb]?.enabled ) return false;
    return this.iov[verb].once;
  }
}());