Skip to content

Instantly share code, notes, and snippets.

@agermanidis
Last active May 10, 2018 23:02
Show Gist options
  • Save agermanidis/b1c8b69925bc13425e53d7595cee21bb to your computer and use it in GitHub Desktop.
Save agermanidis/b1c8b69925bc13425e53d7595cee21bb to your computer and use it in GitHub Desktop.
Bingo spec

Cyranoid Spec

A Script consists of instruction code, a set of roles, and related metadata (name, author, etc.).

Script
  code: executable code
  roles: [Role]
  metadata: dictionary

Performances are realizations of Scripts. They can only happen within a certain radius from a center.

Performance
  status: pending | started | failed | finished
  script: Script
  location: [float, float]
  radius: float
  start: date
  end: date
  characters: [Character]

Actors are the users of Cyranoid. They become different Characters in different Performances.

Actor
  location: [float, float]
  current_character: Character
  past_characters: [Characters]

Every Actor in a Performance assumes a Character with a given Role. Each Character has a state, consisting of their location, choices they've made so far, etc. The more interactive the Performance, the more state the Character likely carries.

Character
  role: Role
  state: dictionary

Roles are the kinds of Characters that Actors can play in the Performance. Script creators can set how many Actors can assume a given Role (one to infinite). Some roles may have more privileges than others (e.g. a Director role may alter the Performance in significant ways).

Role
  name: string
  min_actors: number
  max_actors: number

Instructions are commands that Characters receive during a Performance. They may be sentences that the Character has to say, actions to take, locations to go to.

Instruction
  type: string
  content: string
  start: date
  end: date

Prompts are requests sent to a Character to make a Choice that may alter the course of the Performance. They may have a fixed set of answers ("Do you want to follow the white rabbit? Y/N"), or they may allow free-form answers ("What did you dream about yesterday?")

Prompt
  question: string
  type: fixed | free-form
  answers: [string]

Choices are decisions that a Character can take in response to a Prompt.

Choice
  prompt: Prompt
  answer: string
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment