What’s in Dreamweb?

Dreamweb was the first game of many things. It was the first task scheduled on my proposal. It was the first time I worked on an RPG game

The most significant first though, is that it was the first engine that didn’t put text right into the code. This was challenging in many ways.

Finding text

It’s not that hard to me now, but at first it was baffling to look at the code and guess where the text was. It felt endless when I first did it, and couldn’t estimate how long it would take.

The good news is that every time I found text, it felt good. No matter how much is left to do. It’s like finding an easter egg (I suppose. Never did.)

Another thing to consider would be the dynamics. I was stuck for why certain text doesn’t get speeched after putting on TTS for over a month. Mystery prevailed until I realized that there was another part of TTS interrupting it.

Set language for different versions

The game comes in 7 different languages. We would want the TTS to interpret the code according to what version it is playing on. It also took experiments to find out what was the encoding for each language, which is then passed to TTS man.

Bible quote for opening story

We though it would be cool to have the opening bible quote TTSed in different languages. So we set off to do that.

The challenge was that only the Russian version has translation. So I searched online for different translation, then the community for suggestions.

The quote in Russian was already translated, but not stored in text format. So I scanned it with a picture to text app.

Next is encoding the text into utf-8. Quite messy job. Cmd+d (or ctrl+d) (select same text, to batch select “\x”s) was extremely handy in this case.


We need to allow the player to use speech with human voice and TTS of objects at the same time. So we separated the checkbox for TTS for objects and TTS for subtitles.

We would also like to cancel the original speech if TTS for subtitles are there. To do this, we need the variable that signifies if Speech is enabled.

Tidy the code

It was considered that we create a function to avoid repeated code. It turned out to be quite difficult to avoid repetition of anything but nullptr check & encoding. This wasn’t carried out, but made me more intentional when choosing how to code, because both ways have their own philosophy.

Although I am able describe the main activities in the PR with not so much text, it took me longer than Griffon from start to finish (not finished yet at time writing)

It’s hard to imagine at the start that so much could be added.


Leave a Comment