Visual representations of branches in IFs

Hi! So… I’m looking for what the title says :sweat_smile:
For the longest time, I’ve been trying to write an interactive novel, but I get stuck pretty quickly, for many reasons. So I gathered it was too complex of a project to start on my own (it was a fantasy/romance game with one too many variables). Therefore, I decided to settle - for now- for a smaller project… Something more manageable. But I find myself stuck again! I thought that if the choices were pretty straightforward and all of them leaded to branches, it would be easy, but even with a limited variable number, I would end with a huge Pascal triangle worth of results! That’s not simple at all. So I’m stuck again, overwhelmed at the prospect. I think I’m a little bit blinded to possibilities? I know it can be done in a simpler way, I’m just… In need of inspiration.
I’m having trouble picturing (I’m a visual learner) how it could work. Do you have rough sketches of how you manage to do it in your own IF or how do they do it in famous ones? (and if so, could you share them here?) Where could I find something like this?
Thank you in advance for any help you could provide me. I know it may be too much to ask for.

1 Like

You might find this to be of value:

9 Likes

edit: oh hell yeah what aletheia gave you is way better lol

I think, and please take my thoughts with salt, that there are a couple things here that might help you out, because it definitely can get very overwhelming when you’re just trying to think it out or write it straight from your brain.

There’s for sure software that you can use to make flowcharts, but honestly I’ve always found that just drawing it out on a piece of paper is both simpler and more conducive to (the way my brain does) organization. Also it’s always free and you don’t have to waste time learning extra software, however simple, which is especially nice if you’re just learning choicescript too.

There’s also code-diving, if it will help you to see how things are organized in other games. I know you can do it with steam (though I honestly can’t remember how, but I know there’s a thread or two about it) but iirc, it’s a bit messy to look at, and you can also do it with dashingdon by just putting /scenes at the end of the url and picking the one you want to see (which is not messy at all to parse, assuming the author’s code is generally pretty clean).

Lastly, there’s just the sorting out of how you want your branches to work, which depends in part on exactly how branching your narrative is. There are several ways to write branching code (which is one reason why I think code diving would be useful). Something that helps me is to think about my outline and note down, in a vertical line, all my bottleneck points and then fill in the branching stuff in between as needed, so I can kind of visually see where a lot of my “clumps” are going to be. That just makes it easier for me to stay mentally organized when I go to write.

I don’t know how experienced you already are with the language and structuring projects, but if you don’t already know how to use it, the biggest thing I suggest is sifting through the wiki and understanding multireplace because multireplace can save you a lot of time and space when it comes to “branches that aren’t really branches” (like pronouns, flavor text, small dialogue changes, all sorts of stuff that you might initially think you need an *if or a specific *goto/label for that you really might not).

I know I have some physical notes around here and if I can find them after work tomorrow, I’m happy to PM you some pictures of them, if that would be more helpful than my vaguely gestures explanations lol

1 Like

If you would like to see some ways how branching can be done in Twine, maybe as another inspiration, there is a Tumblr that shows this for some games:Twine Garden v2.

2 Likes

Maybe this can be of help. (There’s more if you search for “branch” on the forum)
Also, use the randomtest with this tool to find the max/min of your stats at a given point to know in what range to set your checks. Pretty useful when you start to advance in your game and calculating stats in a specific branch becomes a hassle.

I would also recommend limiting yourself on the branching, which can get out of hand really quickly if you don’t have it in check. And ideate, plan, and restrict the mechanic your game is going to use so it doesn’t become uncontrollable. You can have some leeway of course, but if every stat change can lead to an innumerable amount of consequences you should probably dial it down a bit.

7 Likes

These diagrams are perfect. Thank you for linking them!

I’ll also add that most ChoiceScript games tend to follow the branch-and-bottleneck model, which gives enough significant choice and single-playthrough length without thousands of different endings to write or without a ton of PC death. I believe ChoiceScript can also handle some Quest-type interludes, but it can be tricky and cumbersome to code and very hard to test.

2 Likes

This article doesn’t include visuals, but gives some good insight into how most CoG games handle their end states.

4 Likes

Omg thanks to everyone :heart: all of your answers have been very useful! Now I have a better picture of how to continue, I was quite mind-blocked :joy:

1 Like