ChronicleHub: a QBN engine like StoryNexus

Hello!

Let me start off with sharing my labor of love:

NOTE: You will not be able to register an account just yet, unless you’re whitelisted. The platform is in an Alpha test phase, and to sniff out bugs, I want to control who is able to sign up right now.

When joining this forum, I was introduced to the term Quality Based Narrative for the first time. It solved some problems I had writing, and I began playing Fallen London as a result to learn about how it works in practice. Turns out, I absolutely fell in love with it. So I figured, I can do this myself!

I first tried building a prototype, but didn’t get too far. Solo development was really getting to me, but I got the basics working.

Then I implemented a QBN system in another prototype, and really got the data model figured out.

During this time, people on the Fallen London Discord kept sharing how much they missed using StoryNexus. I know DendryNexus exists, but it seemed a little too technical for many to use.

So, I figured I could just make my own. What a coincidence that StoryNexus would announce completely shutting down sometime during the past week.

Introducing: Chronicle Hub
Chronicle Hub is a QBN platform, to make games much like Fallen London and old StoryNexus games, all hosted online.

It features quite a host of options for building QBN games, different layout styles and visual themes, and a full creator studio for building the games, as well as ScribeScript, a domain specific language I wrote up to insert variables into text and reference qualities in-line. I am not about to list everything here just now, so I’ll just share some screenshots and mostly let this serve as an announcement as something I’m working on and have nearly fully functional!

If you have any questions, or would like to help test this, please let me know :slight_smile:

18 Likes

Extremely exciting! Thanks for making this. I wonder if the old StoryNexus games could be recreated somehow (with author permission)

2 Likes

I’ve been wondering the same! If I recall correctly, StoryNexus authors were able to download their source files in the past, and I had been working on export and import logic for Chronicle Hub JSON files. If someone who made and eventually downloaded their StoryNexus game would be kind enough to share their file, I could try and figure out if I can create mapping logic for it

2 Likes

I never used StoryNexus (because by the time I first took a look, it was already clearly defunct) but I do love QBN as a concept — enough that I wrote my own QBN suite for Twine. It’s great to see someone announce a tool that isn’t a duplication of ChoiceScript with added AI :smiley:

3 Likes

I think @cchennnn’s DendryNexus is already a good fit for restoring StoryNexus games. How does ChronicleHub compare/contrast with DendryNexus?

5 Likes

There’s the Black Crown Project dump. I know Ursula Vernon has a private copy of the data for her game (Cryptic Stitching, I believe?). The format isn’t too bad except that they kept adding on properties for every little thing instead of consolidating, so there’s a lot of it. It’s also very nearly the same format as Sunless Sea uses, so if you have that game you could grab those data files as an example.

Zarf asked on the Failbetter Discourse thread about preservation and only got the response that authors had “a good long window of opportunity to export them” but the couple of authors that I’ve asked in the past had no idea that exporting was an option, so…

1 Like

This is very intriguing! Are you only approving accounts for people who are willing to take on alpha testing responsibilities at the moment, or are you open to random people nosing around without doing proper testing as long as it’s not a total free-for-all? I’d love to get a closer look but I’m not sure I can commit to being helpful.

6 Likes

I’ll be honest, I have no idea how it compares exactly. This thing was mostly built because I felt like building something, moreso than learning DendryNexus. So, you’ll have to tell me :joy:

Thank you! I’ll give this a look, and with permission see if I can upload and run it on this platform. It’s useful at least to see the data model and an actual export.

I am approving anyone who is aware of the fact there might still be a ton of bugs in the system, but is otherwise willing to give it a try! I mostly want to prevent opening up the floodgates before I have all important security features in place and the last obvious bugs sorted out.

2 Likes

This looks phenomenal and as one of the Storynexus lamenters whose game decks were chewed up after support ended, I recognize all kinds of SN features. This looks like a premium version of that.

Is development and hosting on the website only, or is there a separate IDE?
Are games exportable as playable websites?

This is always my question that few devs are usually interested in - is there existing or planned support for ambient music and sounds? (There’s nothing so satisfying as hearing coins jingle when you loot something!) When I worked with Storynexus, I took advantage of hack-y code someone helped me with that would play music and sounds from a remote webpage I had arranged and were called with some mysterious JS code in the text that I was and still am too dumb to understand and/or remember.

I would love to poke around and I’m really good at finding how to break things constructively! (If you’re looking for people to mess around inside it.)

4 Likes

Sorry if it was mentioned and I just glossed over it, but is the technology behind it open source, or will it be at some point?

Not specifically that I don’t trust you, but we’ve seen the fate of StoryNexus, so I’d want to have some sort of guarantee that my work and other’s will not be lost if ever your platform shuts down.

Because, you know, otherwise it does look really great!

4 Likes

Hey story Nexus work isn’t lost yet you can still play the games last I checked and theoretically move the content to another platform if you was the owner . Cyber punk dreams is a former story Nexus game that has moved to another platform and seems to have found a decent audience . I actually say it’s better than the others in this regard because the site remained up for at about 12 years most of them don’t last 2 years .

I think ppl forget that fail better games abandoned the platform only like two years after creating it . They then just let it waste a way for years until officially shitting it down in like 2019 .They will be deleting it for good next month . I wonder if this game engine over comes the problem that story Nexus had one of the issues was in order for a game to really be playable or exiting it needs to have an abundance of content . A lot of story Nexus games had unlimited actions unlike fallen london set actions to 20 per day . So you could essentially run through all the content in like 30 minutes the games got repetitive very fast .

I’m really iffy on this model because fallen london literally only works due to gate keeping its content with out the gate keeping in place and without the depth of content these type of games fall apart pretty fast .

2 Likes

So, this is currently what is haunting my mind the most, and why the current version is whitelist-only. Nothing on the internet is truly for forever, but I wanted to make the experience of creating and publishing as friction-less as possible. Some of the main features I still need to implement are the ability to export your data and save it locally, and more frequent database backups rather than just full server backups. The last thing I’d want to happen is to be responsible for people’s lost work. Ergo, whitelist until I can guarantee full data safety.

Regarding open source, I have considered this, but I might once I feel less embarrassed about parts of the source code. Other than that, I had considered building a sort of docker application allowing people to self-host using exported data. I want to give this the best shot it has at life if possible. I truly lament people’s lost creative efforts on any platform, and I’d hope to make sure such a thing doesn’t happen here.

Speaking of, currently I have decided to keep everything within the website itself. I am heavily considering exportable websites, but I know not everyone is equally technically minded, so the emphasis right now is on one central platform both for easy discoverability, and ease of use. This also ties into features regarding collaboration and shared development.

This is a point that I am still racking my brain over. I am currently paying for hosting costs myself, which means I also have limited persistent memory to work with. To prevent link rot in images, I have elected to allow people to upload images to the server directly, or indeed define a link to an externally hosted image in the ‘image definition’ in the image library. This system works well, but it means I already need to be memory conscious.

What is difficult with sound is that I need to make really, really sure I can store those sounds, or make sure a system can import externally hosted sounds while minimising the risk of link rot, or just accept the risk of link rot happening.

Another idea I had was to have a custom music parser, upload a custom soundfont to the system, and then write a domain specific language to parse that soundfont into music. However, I fear this might just be my over-enthusiastic designer brain speaking, rather than a feature people would appreciate digging into. Still, I might just do it this way to preserve storage, and then upload a set of default sound files.

TL;DR on some of the technical verbiage I casually threw in.

TL;DR on 'link rot'
**Link rot** is a phenomenon where links to external websites and the resources they host stop working, either because the link no longer points to the right address, the website is down, or the website is no longer hosting the resource. You'll often see this with old forum posts pointing to resources on the internet, but when you click the link, you'll get a 'page not found' error.

The same can happen with images, where you upload an image somewhere like imgur, but it suddenly being deleted at one point because imgur would only store the image for a limited amount of time. This means you would have to keep updating and refreshing links for your resources once you notice the link no longer works.

TL;DR on soundfonts and domain specific languages
A soundfont is basically a set of default sounds a system can draw from to render its soundscape. For example, if Arial is your default font in writing, Midi sounds built into the computer are your default 'sounds' for different things. So a piano always sounds the same on most PCs using a specific sound card, same with drums and bass.

A soundfont overwrites those defaults. It will tell the midi parser “Hey, don’t use your default piano when I tell you to play a piano sound, use the one I give you.” A famous example is the soundfont from RuneScape. A very specific set of sounds used to generate all music in RuneScape, since it needed to be very memory conscious when it launched in 2007. So instead of storing the music files, it just generated the music using midi and its recognisable soundfont, much like tracker music does.

A domain specific language or DSL is a programming or parse-able language or syntax usually written to work within a specific environment. ChronicleHub uses something I called “ScribeScript” which is just text formatted in a certain way so the parser will understand it. For example, when it sees {} brackets, it will know that it needs to evaluate and resolve whatever is between the brackets. If it sees a { $quality }, it will know to insert the level of that quality into the text, unless it’s a String-type quality, in which case it will insert the StringValue associated with that quality (useful for something like the $player_name or $player_title for example). It even has support for $item.source, which is specific logic I built in so that the text can refer to where you got a specific item from, to really make the world feel like a living, breathing thing.

When I refer to a DSL in regards to music, I am thinking of something like the way strudel has a custom language which is converted to midi and played with soundfonts, or Mabinogi’s MML, or Music Macro Language

So this is a big one for me as well. @HanonO or @JoshGrams mentioned this in another post I made a while back (I think, I have been digging through my history trying to find the precise quote, but I seem to be unable to find it). QBN games only work with sufficient content already in place. That is a challenge.

Edit: Apparently this is from a blog post by Emily Short where she states:

QBN does pose some challenges of scale at both the high and the low end. I think StoryNexus is hard on new authors because the content tends to be uninteresting until there are a fair number of storylets in the database, so it’s hard to feel like you’re really rolling until you’ve spent quite a bit of time in the tool. Conversely, when you’ve got very large amounts of content, you may find that the list of available storylets gets overwhelming for the player.

This is why I made the choice for an online platform initially. What I currently have implemented is the ability to collaborate with other people on the same world, making it so you can all put the pieces in place to build a game together (though I still need to debug this). Collaborators can be limited in their role, so they can only modify the parts of the world/story they have created, for example. My dream is to see multiple people work together on one world to create something beautiful as a result, and I hope this will happen at some point. I’ve already invited a friend of mine to collaborate on a world of my own!

In addition, I have added the ability for the creator to define how their action economy works, how long their timer is, whether card draws cost actions, how many actions clicking an option costs by default, how much is regained once a timer runs out, etc.

Another big part of the plan is to have a community resources tab, where people can upload self-contained stories, carousels, interconnected storylets, decks, images, etc. so that you could feasibly construct a world or story using bits and pieces from other people. This would be fantastic for something like a Dungeons and Dragons-like Fantasy world where it’s less about the precise lore, and more about just having something to do. Sometimes good enough is good enough.

6 Likes

Just from looking DendryNexus’ readme, the main difference seems to be that ChronicleHub replicates the no/low code GUI of StoryNexus while DendryNexus requires coding knowledge throughout (I can’t tell if it has a GUI because there’s no pictures in the readme). As well, CH is on a website and doesn’t require self-hosting/compiling on the command line, etc. That’s already a huge draw to ChronicleHub for me!

(…) using DendryNexus is not recommended unless you have used dendry previously, are somewhat familiar with the StoryNexus paradign, and can debug js/html/css.

8 Likes

You’d have to track down someone who got one of those exports – I assume authors of StoryNexus games should still be able to get one by emailing Failbetter if they do it right away.

But to preview a bit of how this works, StoryNexus games exist entirely as rows across several tables in a relational database (plus their image assets). There’s no actual “code” to a StoryNexus game, just data; I assume that authors who got exports got a dump of this data.

It should be possible, theoretically, to either reimplement StoryNexus whole hog (using a database as a backing data) or to build software that automatically converts this into something like a Dendry game. But of course this is all contingent on supporting every StoryNexus feature, none of which are really comprehensively documented, etc. I don’t believe DendryNexus has this kind of automation available, it just implements StoryNexus-like features so you can manually reconstruct your game in it?

I do think open-sourcing and making it possible for people to self-host this are kind of paramount if you want this to function as a way to preserve StoryNexus games, though.

3 Likes

So, since I built a platform anyway, the conversion would mostly be a small technical challenge I think.

My hunch is that StoryNexus relied on a SQL database, whereas I built an engine with JSON files at their core.

The challenge will mostly be in identifying which StoryNexus features correspond to which Chronicle Hub features, identify what features might still be missing and implement those, and then write a script which handles the mapping of StoryNexus (SQL) tables to Chronicle Hub JSON.

I’m planning to look into what is already available to write the conversion logic.

1 Like

Do you have any plans to implement alternative color schemes for the site interface? I have trouble reading light text on a dark background for too long.

2 Likes

I genuinely had not considered this might be an issue, but now that you have told me, yes, I will make plans. I’ll make sure to update the .css file and build in functionality for alternative interface color schemes.

2 Likes

Seconding that export (both as JSON or the like with all the data, to be imported into something else, and as a standalone web page to be played) is a very important feature. With the impending demise of StoryNexus, I think a lot of people would appreciate an assurance that your platform going down wouldn’t similarly render their games unplayable! (This community, on the whole, cares a lot about archiving, so having a way to export your game that can be shoved in a ZIP file, extracted thirty years in the future, and still played successfully, is highly valued.)

2 Likes

Absolutely! It’s on the to-do at the very least. Export functionality first, file docker after that

1 Like

Okay that sounds interesting . Are you imagine more open world games ??

I would like to be white listed I had a more narrative driven story based idea but I havent seen any examples of that done using a QBN system. All the QBN games I’ve seen none have set characters , or anything resembling a plot .

In the other thread I was essentially asking if this type of game model can work with games that have an actual plot with set characters . Games that are more like last of us in written form .