30 Years of Hitchhiker's Guide to the Galaxy
John Gardner's Secret Generations $0.00 on Kindle

Updating to Inform7 Build 6L02

Screen Shot 2014-05-08 at 12.09.31 AM

I'm super excited about the new Inform7 Build 6L02 that came out earlier this week.  But as with prior releases, you may find a few "gotchas" as well as new things to think about.  In particular, this is a major (massive?) release -- the first in nearly 3 years.  And there are many improvements that look awesome.  Nonetheless, I thought I'd make a quick note of a few things I've seen in the changelog for people to keep in mind as they update their own code.

  • This release deprecates several old features and capabilities.  Most of these look fairly obscure and are not likely to have been intentionally used by many people.  However, I still found about a dozen cases of deprecated syntax, in the form of code written as:
    Change the right hand status line to .... 
    instead of:
    Now the right hand status line is ....     
  • If you want to check for this and other statements that may no longer work from within the "old" 6G60 Build, you can add the code:
    Use no deprecated features.
  • Of course, the reason I was using the deprecated form was because I cut and paste some example code from one of several extension I used.  Many popular extensions have already been updated and in other cases, it's fairly easy to update them yourself.  However, for some reason I couldn't get Aaron Reed's Player Experience Upgrade to compile properly.  Aaron has already updated most if not all of the individual extensions like Smarter Parser, Extended Grammer, Poor Man's mis-type etc.  Since a lot of core functions in Inform7 have been updated rendering the Player Experience Upgrade somewhat obsolete, so it's easiest to just to include the individual extensions you want to use.  That worked fine for me.

    Note: There's a longer discussion about other code changes that may be necessary to get your code to compile on the Intfiction forum.  And there's also a list of third party extension compatability list.  
  • I also ran into what appears to be a known issue regarding having a blank table that gets filled in later, such as is used with Emily Short's Menus extension, which I happen to use.  It seems there's been a change that has been described in the Intfiction forum.  The example program "Tabulation" is also unfortunately out of date, so it took me a bit of trial and error experimentation to get this to work properly.  The Menus extension also has a "consider" rule which must now be changed to "follow". I have no idea what it does, but it's a trivial change. If anyone needs the updated version of the "Tabulation" program, let me know.      

  • Scoring is now off by default.  So if you're doing an old-school game with scoring (like I am) then you need to add:

    Use scoring.

  • Indexed Text is gone.  Or at least, you don't have to declare some things as text and others as Indexed Text. Indexed Text still works, but it's not needed.  I haven't had a chance to try this out yet and I have a ton of code that works around all kinds of crazy things with Indexed Text and Tables.  Hopefully it will all work the same as before and I can start eliminating some of the hoops I was jumping through previously.

  • You can now declare variables with an initial value in one line, instead of two. So where you used to write:
    DialSpins is a number that varies.DialSpins is 1.

          You can now write:

                    DialSpins is initially 1.

  • You can now declare constants using the form:
    The Drink Limit is always 3.
  • There is now support for floating point arithmetic, in the form of what are called "real numbers" (as opposed to plain "numbers" which are integers).  Honestly, the last programming language I used that did not have floating point was Wozniak's Integer Basic on the Apple ][.  And that was pretty much eclipsed by the built-in Applesoft Basic when the Apple ][+ shipped in 1979.  So even though I don't actually use any floating point math in my game, this always struck me as an odd ommission.  Now Inform7 can sit proudly with the big boys at the great programming language bar.  You can add sine, cosine, arctangent, square root, and reciprocal functions of Pi and e to your heart's content.  No doubt someone will write a Bitcoin simulator extension pretty soon.
  • The Mac IDE has had a major re-write and has undergone a major rewrite improving the architecture, fixing many bugs, modernizing the UI and expanding the features. It also has a cool "London Underground" welcome screen.  The documentation has been updated including a new Zarf-supplied index as well as new examples.  The manuals is also now available for download in ePub format and the Recipe book is now much more "front and center" in the IDE.  

  • The Mac IDE appears to be much faster and more stable in dealing with large blocks of code when it needs to redo the syntax highlighting.  This used to be the bain of my existence whenever I was commenting out or moving code.  I am eager not to have to worry about the order in which I put comment braces.  (Really, there's no need to re-highlight the code that's off screen is there?)  Also the command history is supposed to work better on the Mac.  I never found it to be reliable in the past. 
  • The Index in the IDE provides a much more detailed view of the innards of your game including a library card view of the Bibliographic information, separate views of tables and figures and a much more detailed introspection of the Actions, Kinds, Phrasebook, Rules and Scenes in your game.  I think it will take several days or even weeks to appreciate the depth of information provided here.  But this looks very powerful indeed.
    Screen Shot 2014-05-08 at 12.10.14 AM

  • There's a also new Public Library of extensions accessible directly from within the Mac IDE.  So you don't have to download and manage the extensions by hand.  It appears that the IDE will automagically let you update extensions with the click of a button.  That sounds like a great feature, though I'm assuming that "undo" will let you back out any updates that cause problems.  The IDE can also automatically download all 67 up-to-date Inform7 extensions. (Twenty of the extension are built-in, such as Emily Short's Basic Help Menu and Basic Screen Effects, and Eric Eve's Epistemology and so on.)  
  • Extensions can now be made "adaptive" with a little more work on the part of the extension author.  What this means is there's a more generalized underlying mechanism for properly adding the correct viewpoint of the player, the grammatical tense to verbs, the plurality of nouns and so on.  (For those familiar with Emily Short's work, this is a bit like the Plurality extension on steroids.)  So if you're writing a game with a 1st person viewpoint set in the past or whatever, then the text emitted by extensions will no longer clash with the prose you've written.  If you're writing extensions, this is pretty cool.  And even for old-school second person present-tense games, your code can be much smarter about dealing with objects.  Emily Short has a very helpful post that describes in more detail things extension writers will need to keep in mind when updating their work.

  • Standard messages to the user are now neutral and much easier to customize rather than being old-school adventure game oriented.
  • Around 400 bugs have been fixed including some items that were really feature suggestions.  

This just scratches the surface of a few of the new capabilities in Inform7 6L02.  Nonetheless, a few questions remain:

  • When will the remaining extensions be updated?  I'm eager to see this happen, but obviously, this may take some time for extension authors.
  • How much work will be required to clean up all my ugly Indexed Text code?  
  • Will Aaron Reed update his fantastic book to show off some of the new features?  Heck, I've bought two copies already and I'd buy two more.  Even a softcopy update would be great.

For more info, head over the Inform7 site.  And if you have tips in using some of the new Inform7 features, feel free to add a comment below.  (And if I got some things wrong here, please let me know that also!)


Feed You can follow this conversation by subscribing to the comment feed for this post.

Thanks for providing that "Use no deprecated features" thing. I'm fixing all my stories now so that it won't cause issues in the future.

Happy to help. Though, I think this can be the tip of the iceberg. I'm still trying to figure out how to get all the various Extensions working. Most likely I am doing something wrong, but it will become easier once all extensions and related examples are fixed.

The comments to this entry are closed.