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

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

  /**
   * @augments {adventurejs.Verb}
   * @class help
   * @ajsnode game.dictionary.verbs.help
   * @ajsconstruct MyGame.createVerb({ "name": "help", [...] });
   * @ajsconstructedby adventurejs.Dictionary#createVerb
   * @hideconstructor
   * @ajsinstanceof Verb
   * @ajsnavheading UtilityVerbs
   * @summary Verb used to print help information.
   * @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; help</span>
   * </pre>
   * <p>
   * <strong>Help</strong> prints a help message.
   * </p>
   */
  A.Preverbs.help = {
    name: "help",
    synonyms: [],
    verb_prep_noun: ["get help", "show help"],

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

    do: function () {
      this.game.log("L1637", "log", "high", "help", "verbs");

      var msg = "";
      msg = "Help!";
      if (msg) this.game.print(msg, "");

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