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

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

  /**
   * @augments {adventurejs.Verb}
   * @class hint
   * @ajsnode game.dictionary.verbs.hint
   * @ajsconstruct MyGame.createVerb({ "name": "hint", [...] });
   * @ajsconstructedby adventurejs.Dictionary#createVerb
   * @hideconstructor
   * @ajsinstanceof Verb
   * @ajsnavheading UtilityVerbs
   * @summary Verb used to get hints.
   * @tutorial BasicVerbs_Subscriptions
   * @tutorial AdvancedVerbs_VerbAnatomy
   * @tutorial AdvancedVerbs_VerbProcess
   * @tutorial AdvancedVerbs_ModifyVerbs
   * @tutorial AdvancedVerbs_ModifyVerbs
   * @classdesc
   * <pre class="display border outline">
   * <span class="ajs-player-input">&gt; hint</span>
   * </pre>
   * <p>
   * <strong>Hints</strong> prints a list of hints.
   * </p>
   */
  A.Preverbs.hint = {
    name: "hint",
    synonyms: ["hints"],
    verb_prep_noun: ["get hint", "show hint", "get hints", "show hints"],

    /**
     * @ajsverbstructures
     * @memberof hint
     */
    accepts_structures: ["verb"],

    do: function () {
      this.game.log("L1589", "log", "high", "hint", "verbs");
      this.game.hintManager.openDialog();

      return true;
    },
  };
})();