Made some animation action support, along with sequences and blocks (simultaneous actions) and a shorthand to use all of that mess, so now I can do things like this:
new Sequence() ..add(new Block() ..field(c2, #alpha, 0, 1, 3500) ..field(c2, #x, 32, 732, 7000)) ..field(c2, #alpha, 1, 0, 3500) ..run();
Why do I need all that for a simple VN API (yes, I’m not going to parse a script right now, just making an internal DSL for simplicity’s sake, much like Ren’Py 1)? Pretty much these things:
- Things like “first I want that character to change pose with fade, then I want the other one to change pose with fade while he starts speaking”;
- Easier skip and rollback – as long as I keep track of each sprite position and other parameters I can just run or finalize actions whenever I need to skip or continue from a given script “line”;
- If I’ll have to parse a script later, the execution tree will pretty much consist of actions and branching points – for something simple that seems fairly adequate.
And I’ve started writing said VN API, SaeScript, though didn’t make much progress yet.