/Motif

Primary LanguageJavaScript

VERY MUCH UNDER CONSTRUCTION

This will be a stack-based language where code is defined by the variation in text from one line to the next: reversing, rotating, or extending the words will each represent a different command.

The catch: only block drawing characters are recognized. Also, the interpreter hates boring code and will not process programs that lack visual interest.

VARIATIONS (this will change)

  • MOTIF = original (ESTABLISH MOTIF, SET NEW MOTIF)
  • PUSH (add the new things to the stack) = original with more at end (new things at the end)
  • EMIT = reverse
  • MUL = extend all
  • DIV = shorten all (except 1s)
  • SWAP / ROT (number of items determined by how many rotations in the code) = cycle (begin with a different one and wrap)
  • ADD = double one word
  • SUB = double two-word phrase
  • DROP = missing last word
  • DUP = whole thing twice
  • PUSH (from Input) = original with something new (different size from first item) in front

any block with three or more characters is a variable other blocks have no particular meaning