Skip to content

Understanding JSON Features

eniamza edited this page Aug 16, 2020 · 3 revisions

Start With MetaData

  • name: Name is referred to story name. Name can contain spaces and Capitalization. Two stories can't hold same name. Also Two stories can't differ only in capitalization.
  • author: If you wrote the story then it's your name. If the story is based on a book or creation of another writer then you can put both your name and the writer's name.
  • description: Description is a short preview of the whole story. Be sure to make it attractive and filled with suspense

Questions

  • questions- Questions is an array which holds all the questions of a story
  • question- This is a visual question title which is actually presented to the player
  • option- is an array of options called opt which is presented under question titles
  • nextSituation- leads to next situation [Assigned by index position number in situations Array , starts count from 0]

Notes

  • question is presented in bold characters in discord
  • you can have unlimited opt as you want
  • you can have unlimited question as you want
  • nextSituation starts from 0. -1 means The End

Situations

Situations is an array which holds all situations. Situation 0 is the first situation of the story which is shown to player by default.

  • title- Title of the situation which is presented in bold character
  • description- The body of the situation. This is where you explain player's situation
  • nextQuestion- Number to the next question. Right after the situation is presented the bot will present the question mentioned here. Any question can be entered from questions array
  • jumpTo- This is an optional replacement of nextQuestion. This can lead from situation to situation. which means you can jump to another situation without showing a question

Note

  • jumpTo will promote a Type anything to continue
  • It's a good practice to spilt up situations whenever possible using jumpTo
Clone this wiki locally