// crawl.js
(function () {
/*global adventurejs A*/
"use strict";
/**
* @augments {adventurejs.Verb}
* @class crawl
* @ajsnode game.dictionary.verbs.crawl
* @ajsconstruct MyGame.createVerb({ "name": "crawl", [...] });
* @ajsconstructedby adventurejs.Dictionary#createVerb
* @hideconstructor
* @ajsinstanceof Verb
* @ajsnavheading LocomotionVerbs
* @summary Verb meaning crawl on an asset or travel in specified direction.
* @tutorial Scripting_VerbSubscriptions
* @tutorial Verbs_VerbAnatomy
* @tutorial Verbs_VerbProcess
* @tutorial Verbs_ModifyVerbs
* @tutorial Verbs_WriteVerbs
* @classdesc
* <pre class="display border outline">
* <span class="input">> crawl</span>
* You crawl on the floor. You find a pea!
* </pre>
* Crawl extends core verb <a href="go.html">go</a>.
* It checks whether "crawl" is contextually available
* before forwarding to "go" for further handling.
* @ajsverbreactions
* @ajsverbphases doBeforeTry, doAfterTry, doBeforeSuccess, doAfterSuccess
*/
A.Preverbs.crawl = {
name: "crawl",
prettyname: "crawl",
past_tense: "crawled",
synonyms: ["crawl"],
type: { locomotion: true, travel: true },
extends: { go: true },
in_can_mean_on: true,
player_must_be: {
not_constrained: true,
able_to_crawl: true,
},
/**
* @ajsverbstructures
* @memberof crawl
*/
accepts_structures: [
"verb",
"verb noun",
"verb preposition",
"verb preposition noun",
"verb noun preposition noun",
],
/**
* @memberof crawl
* @ajsverbphrase
* phrase1:
* {
* accepts_noun: true,
* noun1_must_be: {
* known: true,
* tangible: true,
* present: true,
* visible: true,
* reachable: true,
* },
* accepts_preposition: true,
* },
*/
phrase1: {
accepts_noun: true,
noun1_must_be: {
known: true,
tangible: true,
present: true,
visible: true,
reachable: true,
},
accepts_preposition: true,
},
/**
* @memberof crawl
* @ajsverbphrase
* phrase2:
* {
* accepts_noun: true,
* noun1_must_be: {
* known: true,
* tangible: true,
* present: true,
* visible: true,
* reachable: true,
* },
* accepts_preposition: true,
* },
*/
phrase2: {
accepts_noun: true,
noun1_must_be: {
known: true,
tangible: true,
present: true,
visible: true,
reachable: true,
},
accepts_preposition: true,
},
/**
* @memberof crawl
* @ajsverbparams
* with_params: {},
*/
with_params: {},
do: function () {
this.game.dictionary.doVerb("go");
},
}; // END p.preverbs.push
})();