[PLUGIN] Multi-Use Story Engine (Introduction)

This forum is currently in read-only mode.
0 favourites
From the Asset Store
Comprehensive localization solution for Construct 3 projects, no addons required!
  • M

    ulti-

    U

    se

    S

    tory

    E

    ngine

    Yet another thing I'm working on. Part of MUSE is much simpler to understand, and part of it is a little more complicated. If you choose to ignore the complex part, is basically a large collection of name generators from scifi, fantasy, and real world cultures. It can also generate the names of several kinds of places and several kinds of objects. Everything from african tribal names to feudal japanese and space faring insectoid races. These random names are seeded as well. All of this is pretty easy to understand, and it's difficult to see why I would want an entire plugin dedicated to this seemingly simple function. That's where the complicated portion of MUSE comes in.

    MUSE is a prose generator. Not that it generates prose FOR you, but it can help. Whereas GridTree can easily help you layout geological things - MUSE can help you easily layout chronological things. You pass MUSE the current time and a seed, and the general period of the data you are looking for. Period is kind of like, how long each portion of this data lasts - weather would be shorter periods, while things like political changes and species extinction would be much much longer. MUSE will then tell you the current state of the world based on the time you gave it. (If it's raining, who is in control, etc.) So say for instance you passed it the REAL WORLD time, then things would happen while you aren't playing the game. While you sleep. Say you passed it the time elapsed since the game started - then the game would pause while it was closed. There are two modes that MUSE can run in in this way - one generates a markov chain of "states", as I explained above, which describe events. The second method is going to output you a list of numbers. Explaining this one will require a picture, since we call it the "falling elevator", and the picture will explain why we call it that better than I ever could.

    The picture is rather large, so here's a link to it. Notice that in the picture, the elevator is as tall as three floors. This represents the list of numbers that MUSE will output to you. As you can imagine, the elevator only travels in one direction, which we call "gravity" but for this example we will call "time", and as it does so, older numbers fall off the top end of the list, and new numbers appear at the bottom of the list. Whereas the first method of MUSE will tell you the state of the world, this could be used for a list of entities that come and go. You can even ask MUSE how old an entity is by seeing where on the "elevator" it currently is. So if these numbers represented NPCs for example, the ones near the top of the list would have more gear since they've been in the world longer.

    You can explain them disappearing from the list however you wish. In Void Runner our ships have a small chance to appear as wrecks on planetary surfaces rather than ships if they are on the very top part of the list. This creates a story for the player. For most of the ships however, they simply disappear, and the player needs to fill in the blanks. The pilot moved on to another sector, or whatever.

    The main purpose of MUSE is the chronological stuff allowing you to generate procedural events and histories - the procedural names are icing on the cake. I've been working on it for a bit as a side project. I am working on MUSE and GridTree side by side as my time allows and my interests change - so it is quite likely that both of them will come out at around the same time. I figured this also merited an introduction thread since it will be out around the time of GridTree.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Wow, they weren't kidding when they said you were working on a lot of plugins! Good job!

  • Arsonide, this is amazing! It opens a whole new world of possibilities.

    looking forward for the release of both plugins. They're awesome!

    Congratulations on the great work.

  • This seems like it will be quite a interesting plugin. I am looking forward to testing it.

  • Construct Community - You're my only hope! Well...I mean not really...but you could really help out. Not to mention have custom names ready for your game right when MUSE is released. The syllable based name generator is complete for MUSE, and it loads from files called "syllable sets". I have created a toolkit to help you make these. The toolset includes a python script that will do all the dirty work for you, a couple of example scripts, and also a very early version of a MUSE application that will let you test your syllable sets. I'm going to straight up copy the readme file here. If any of you have any questions at all, please reply with them.

    [quote:3v8737bf]This should help you generate syllable sets for MUSE. I'm releasing it early so the community can contribute sets while I finish the actual plugin. MUSE will actually ship with two name generator actions. One will load from these syllable sets, and another one will generate letter by letter from a set of rules you define. Right now I only have the syllable generator, and I need your help making syllable sets for it! I've made these sets as easy for you to make and test as I possibly can.

    To use the Syllable Set Generator, simply fill the text files with your syllables - either put each one on a new line, or separate them with spaces, the generator can detect either or. Then double click Syllable Set Generator.py when you are done. The python script will automatically populate syllables.ini with your chosen syllables in a way that Muse can understand.

    A prefix and suffix are attached to the beginning and end of the name if you have any defined. First appears first in a name, last appears last. Middle can appear multiple times, between the minimum and maximum middle numbers. Then of course you can have a name generated more than once between the prefix and suffix if you like.

    For examples of first/middle/last: Bo rai cho. El yn dor. Or you can just skip the middle one: Blood letter. Lake wood. Say you wanted to turn that into a modern city district - add a suffix: Lake wood Heights. There's plenty of flexibility here. It's all up to you to flesh it out. I'd appreciate if you guys would post your sets on the MUSE forum thread when you make them so I can get a repository going for the release of the plugin. I already have a TON of sets...but this is something that can only grow larger.

    If you are still confused, I have included examples in the Examples folder. These are example syllable sets. I found most of them on the internet. You can make your own and test them with the Syllable Set Tester, or you can find them on the internet and add them. It's up to you. The Syllable Set Tester is also in this folder. It is a very early version of Muse, and it uses syllables.ini to generate names from, so rename anything you want to try out and move it to this directory under that name if you would like to try something with the tester. I have elven male loaded by default.

    Anything you make and upload to the forum thread is automatically attributed to you. When you run the python script it will ask you for your name, which is embedded into the syllable set automatically as a comment on the top line. Any syllable sets uploaded between now and the release of Muse will be included in the original release.

    Download the Syllable Set Generator!

  • This is really amazing stuff Arsonide. You are a plugin making machine!

    I can't wait to try this stuff out in a space game!

  • Here's a list of "southern" names.

    I tried to do a copypasta from some list I found on the net, but I left too many spaces... and well Im tired.

    Anybody that wants to format it correctly can have full credit for the "Redneck Names" list.

    Edit:

    Looks like simply posting the list fixed the format issue.

    http://dl.dropbox.com/u/666516/Rednecks-Male.ini

  • He's after new syllable sets Newt, not lists of names.

    I'm going to have a play with this now.

    Incidentally Arsonide, did you base any of this on Umbra's work?

    I remember reading up on this for my game a while back, and his was one of the better techniques for implementing this.

    Anyway, I'm going to see what syllable lists I can come up with.

    Great work again.

    Krush.

  • Yeah, but it works, and we wouldn't want to leave out all the Nascar fans.

    Also list fixed about, replaced with ini.

  • Yeah, but it works, and we wouldn't want to leave out all the Nascar fans.

    Lol.

    Generating 2 names using the same list is interesting, but it does work.

    Just ask Jessie Dwayne and Dwayne Jessie.

    I'm not sure about Bo Bo though.

    Using MUSE as intended, with sets of syllables, is harder than it looks too.

    Unless some serious thought is put into it, you end up with all sorts of nonsense.

    Maybe it's time to study some existing lists.

    Anyone found a comprehensive list on the Internet yet?

    I can only find one here and there so far.

    Having fun playing with this though.

    Krush.

  • Just pick a few consonants, and all the vowels, and switch em around to test.

    http://dl.dropbox.com/u/666516/Caveman.ini

  • Quick poll. I'm implementing the time expressions for Muse (you input a time to the history generator). There are two possible options.

    The first option is UnixTime. UnixTime is my real time option - where your world continues to evolve while the game isn't running. UnixTime returns the number of seconds since midnight, January 1, 1970. It constantly, reliably, moves up by one. Moving by one is good for this purpose, because that means the changes will subtly change over time rather than sudden radical changes. The problem with Unix Time is that due to memory constraints, in 2038, it will fail. I don't know why this bothers me so much, as by then Construct 5 will be pumping out much cooler games than this, but it bothers me enough that I'm implementing my own special version of UnixTime I'm calling MuseTime. In UnixTime, midnight - January 1, 1970 is referred to as the "epoch". MuseTime will be referred to as an expression, much like UnixTime, with one exception. You will be able to set your own epoch. That way, you can set it to whenever the game first begins, or whatever, and the player has a good solid 68 years before it loops back on itself. (Which would cause a sudden change of history within your game.) If players are playing your game for 68 years - I doubt you'll be worrying about this.

    The second option is counting the number of seconds your game has been running, in which case the game will pause while you are not playing. This will come with "Punch In" and "Punch Out" actions to start and stop the clock. My question to you guys is that this is going to need to save data. Would you rather this data be serialized with Construct's native savegames, controlled via the "Save" action, or would you rather this data be saved in an external file. Personally I've never used Construct's save action and have no idea how and if it works, but, and I've always wanted to say this: modifying that external file WILL result in unexpected time travel. That's something you probably want to avoid.

    Anyway what do you think?

  • definitely definitely a separate non construct native Save action, and also an expression to get any data that will be saved in case you want to integrate it with a different game save system.

    Also, by 2 options, did you mean that the story engine will have both as an option? or that you're trying to decide which now, because I can definitely see how both would be useful

  • It will have both as an option. Also by "story engine" I mean the procedural chronology stuff. You still set up your story and such. For instance, you can tell Muse that every 10-15 minutes the weather changes in your game, and that these are the weather options: rain, sun, snow. (Or make it geologically based, or whatever, so it snows more in the north). Regardless. Muse will tell you what it's doing right now when you pass it this time expression.

    You can also ask Muse for a list of entities that are currently in an area at any given point in time.

    So it doesn't really generate the story for you, but it gives the player a sense that things are happening. It's procedural chronology. I can also add some prose generators in later if you guys want, but they'll look pretty silly compared to this organic event based system.

  • Yeah "Play time" with saves, and unix time, sounds good.

    Unix time with Gridtree could make for some very interesting combination's.

    You could basically have a game that plays itself.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)