Home Artists Posts Import Register

Content

My dialogue script was supposed to be more human readable than xml (which I considered for the purpose). So the first thing I came up with was pretty simple.

||

{start_index} "Hello"

    [hello_pointer] Hello, do I know you?

||

The {} brackets enclose the dialogue branch index address and the [] brackets enclose the dialogue option pointer that will decide the next dialogue branch index if the option is taken. There can, of course, be arbitrary number of dialogue options in a single dialogue branch (there's just one in this example for simplicity).

The || (double bars?) chop the dialogue file into pieces (dialogue branches) that contain the npc dialogue and the available dialogue options.

Indexes and pointers can have arbitrary strings but cannot use special characters the scripting itself uses. You can make descriptive addresses to make editing easier.

So that's the whole thing? You can make any kind of a dialogue tree just using those pieces, right? I thought so too. Problem with this kind of a tree format is the fact it cannot use text efficiently. Using this simple form will result in unmanageable large dialogue files that have a lot of repeated segments if you want to have even cosmetic npc responses to dialogue options.

For example:

||

{start_index} "Hello."

    [hello_pointer_1] Hello, do I know you?
    [hello_pointer_2] Hi!

||

If even one "different enough" dialogue option is added to the list, the dialogue cannot direct to the same response as before (It can, but npc might seem like they're being rude or extremely forgetful). To have two different responses you have to add two completely different dialogue branches. That's natural for a dialogue tree? Right?

It starts to look like this:

||

{hello_pointer_1} "No, we've never met. Do you like potatoes?"

    [potatoes_awesome] Yeah! Potatoes are awesome.
    [potatoes_lame] No, not really. 

||

 {hello_pointer_2} "Do you like potatoes? " 

   [potatoes_awesome] Yeah! Potatoes are awesome.
   [potatoes_lame] No, not really.

||

Because how written stories work (even the interactive ones) the writer will always want to direct the player experience in some way but the simple version of the dialogue tree format is simply too unwieldy, too volatile to bloat to allow natural responses to simple details in dialogue.

So we give the branch arbitrary number of indexes:

||

{hello_pointer_1} "No, we've never met. Do you like potatoes?" {hello_pointer_2} "Do you like potatoes? " 

    [potatoes_awesome] Yeah! Potatoes are awesome.
    [potatoes_lame] No, not really.

||

Pure efficiency! Now the writer can give more reactive responses to varied dialogue options without creating a complete duplicate for each one. I realized this trick after writing many, many pages of bloated dialogue text and I can't imagine doing any dialogue trees without this feature, it felt like realizing you can use your legs to walk and don't have to use your tongue to drag you forward. 

The less duplication, less text and less logical nodes you have in the dialogue file, the better. It makes adding text and editing far easier and you can more content with less time. Less text you have to edit means you will less likely create bugs in the script.

Comments

No comments found for this post.