Monday, 23 February 2015

Revisiting Contexts

So... the v3.1 Patch Format has only been in public for, well, a few weeks, and I'm already thinking of upgrading it. The reason? Again, it boils down to trying to get support for VX Ace and custom scripts shoehorned in.

Now, it's important to preface this with the following: v3.1 patches will have a transparent upgrade to v3.2. Unlike the transition from v2.x to v3.x, which involved the creation of entirely new classes of context (as well as syntax, persistence etc), the v3.1 to v3.2 transition is much milder, and only involves rewriting contexts. The absolute worst case is that some of the older style contexts will remain, but that's it.

The reason for this is that there's a tiny corner case in how Ruby files were processed. The corner case meant that it was impossible for certain classes to be seen by the patcher as an entity in and of themselves (although the patcher did see their constituent parts). This meant that the newer, adaptable detectors never saw what they needed to detect, and... well, it didn't go well.

What's the benefit for this? Well, ignoring the addition of VX Ace support, my test VX Ace game includes some custom scripts for what I'd call 'inter-party recap of goal events'. These are simply common events, but they're in a non-standard file. The older, fixed structure detectors missed them completely, and would require some custom code adding to the patch to make it work. The newer adaptable detector finds it without issue.

Downsides? Well, it's a little slower, and I'm still trying to weed out some of the things that don't need translation. For example, I thought it'd be reasonable to translate any name attribute as a string, but it turns out there's a lot of names in a game which are only for the developer to see. That's slightly annoying.

Anyhow, I'm hoping for VX Ace + custom data support early next month, once the v3.2 patch format is ironed out. Hopefully that will go well.

No comments:

Post a Comment

Note: only a member of this blog may post a comment.