2021-12-12 03:41:54 -05:00
|
|
|
|
// This new syntax should be easier to parse although parsing wasn't really the issue with the last syntax
|
|
|
|
|
// I really want the syntax to feel a lot more like the actual script for a play or something of the sort
|
|
|
|
|
|
|
|
|
|
// THINK ABOUT THIS Newlines are the end of a statement in this syntax, I think this mirrors text formatting pretty well
|
|
|
|
|
|
|
|
|
|
// I find that the "BEGIN" things in some older languages are actually quite fitting
|
|
|
|
|
BEGIN Scene1
|
|
|
|
|
|
|
|
|
|
Command "test"
|
|
|
|
|
Do 5 [2, 3, 6]
|
|
|
|
|
|
|
|
|
|
Set var 2
|
|
|
|
|
|
|
|
|
|
// Make the actual commands like Lisp, not the entire language
|
|
|
|
|
// strip the outermost brackets since this syntax will be parsed line by line
|
|
|
|
|
Set var2 (=? var 1)
|
|
|
|
|
Set var3 (+ var var2)
|
|
|
|
|
|
|
|
|
|
// Enter and exit dialogue mode with <<- and ->>
|
|
|
|
|
<<-
|
2021-12-17 01:05:38 -05:00
|
|
|
|
// Comments are only legal at the beginning like this in Dialogue mode
|
2021-12-12 03:41:54 -05:00
|
|
|
|
// IDEA: once NVL is parsed, set up indices for each line
|
|
|
|
|
// Make another program to match audio
|
|
|
|
|
[Alex]
|
|
|
|
|
Hello. Welcome to dialogue mode.
|
|
|
|
|
Every new line is a new "click". I discarded the "pause" idea.
|
|
|
|
|
|
|
|
|
|
[Bailey]
|
|
|
|
|
Je ne suis plus Alex.
|
2021-12-13 14:04:12 -05:00
|
|
|
|
Ça ne m'arrête pas de vous démontrer notre support multilingue noblement distingué.
|
2021-12-12 03:41:54 -05:00
|
|
|
|
|
|
|
|
|
[Catherine]
|
|
|
|
|
CJKテスト!
|
|
|
|
|
夏はマシンガン。
|
|
|
|
|
|
|
|
|
|
[Dick]
|
|
|
|
|
I present my idea for markup syntax here.
|
|
|
|
|
It is something like [b,i]{this}.
|
|
|
|
|
It's kind of like KP's TyperTags, only that you can specify more than one effect in the square brackets in front.
|
|
|
|
|
If the effect is parametrized in some way invoke it like [wiggle_y(5)]{this}.
|
|
|
|
|
Then naturally we would have ruby like [rb("that")]{this} (important feature, trust me).
|
|
|
|
|
|
|
|
|
|
[Elliot]
|
|
|
|
|
To grab a value from the environment, do it like this: ${var}.
|
|
|
|
|
This is also the syntax to evaluate a command from dialogue mode.
|
|
|
|
|
If the return is void it will say "undefined" or something like that.
|
|
|
|
|
|
2021-12-17 01:05:38 -05:00
|
|
|
|
// Dialogue mode commands have to be one liners an cannot have trailing comments (arbitrary)
|
|
|
|
|
*! This "is a command in dialogue mode."
|
2021-12-12 03:41:54 -05:00
|
|
|
|
*! Set var (+ var 1)
|
|
|
|
|
|
|
|
|
|
[NARRATION]
|
|
|
|
|
Thanks!
|
|
|
|
|
|
|
|
|
|
*! ClearDialog
|
|
|
|
|
|
|
|
|
|
->>
|
|
|
|
|
|
|
|
|
|
// something like Choice can load the index of the choice the user selects into a variable
|
|
|
|
|
Choice var4 ["Apple", "Orange"]
|
|
|
|
|
|
|
|
|
|
// After thinking about this for a while I think it would be a good idea
|
|
|
|
|
// to have ways to terminate a scene other than END, for instance JUMP can be an alternative like this:
|
|
|
|
|
// JUMP Scene2
|
|
|
|
|
// we can equally do something like this
|
2021-12-13 14:04:12 -05:00
|
|
|
|
// JUMP (switch var4 [[0, RouteA], [1, RouteB], [default, RouteC]])
|
2021-12-12 03:41:54 -05:00
|
|
|
|
|
|
|
|
|
END
|