What do you guys know about the "Adventures" format?

0 votes
asked Dec 7, 2017 by silamander (390 points)
More specifically how to create and use the stat system. But any tips on getting into the format would be nice.

2 Answers

0 votes
answered Dec 7, 2017 by greyelf (90,650 points)

Are you asking about the Adventures Twine 2 compatible story format by Longwelwind?

If so then I personally didn't know it existed.

commented Dec 8, 2017 by silamander (390 points)
Yeah. That one exactly. I really love how it looks and feels but I'm not sure how to navigate the syntax at times.
commented Dec 9, 2017 by Chapel (47,970 points)

My understanding is its based on Snowman, which is (essentially) just JavaScript, so it uses JavaScript syntax, along with markdown for formatting. It's documentation is here. I haven't used adventures yet, so I don't know how helpful I'll be, but can you give us an example of what you've tried and tell us how it went wrong? 

0 votes
answered Mar 4 by KaiBlob1 (140 points)

I found the following quote from the creator on the Github page:


A small part of the stat system is already available in the game, actually, but it's not 100% polished, thus why it's hidden.

If you want to enable it, put this in the Javascript script of your story (Click on the name of your story on the bottom-left, then "Edit story Javascript"):

window.config = {
  "enableStats": true,
  "stats": [
      name: "Strength"
      name: "Dexterity"
      name: "Intelligence"

You can of course change the list of available stats by adding or removing elements in the list.

You have access to those methods to interact with the stats (keep in mind that a stat cannot be lower than 0):

character.addStat("Strength", 4); // Add 4 to the `Strength` stat
character.removeStat("Intelligence", 10); // Removes 10 to the `Intelligence` stat (not lower than 0)
character.setStat("Intelligence", 10); // Set the `Intelligence` stat to 10
character.getStat("Strength"); // Returns the amount of points in the `Strength` stat
character.hasStat("Dexterity", 8); // Returns `true` if the character has at least 8 in the `Dexterity` stat, `false` otherwise

For example:

The merchant must have sold a lot of goods today, as his purse looked full

<% if (character.hasStat("Dexterity", 6)) { %>
  [[Steal the purse of the merchant|Steal]]
<% } else { %>
  It'd be too hard to steal without being seen.
<% } %>
Welcome to Twine Q&A, where you can ask questions and receive answers from other members of the community.

You can also find hints and information on Twine on the official wiki and the old forums archive.

See a spam question? Flag it instead of downvoting. A question flagged enough times will automatically be hidden while moderators review it.