Unity Tales a visual Novel Engine (Development Thread)

Jan 19, 2022
21
89
Tales Engine
Tales Engine.png

Hi and welcome to my development thread on working on my custom VN Engine on top of Unity. Im not new to game development but new to the visual novel genre. I always had a thing for visual novels and decided it was time to get some experience in this genre. I also had a keen interest in DAZ, I have never used it before but should be relatively easy with all the guides available.

Some things to note before starting my choices and scope

  1. This is not intended to be publicly released.
  2. This is not intended to be finished at all.
  3. This is something for me to learn (and most likely fail) from.

Engine choice
Well for me it was a very obvious choice I have been using Unity for over the span of 10 years. I still use it professionally on a daily basis. The hard part to decide was what kind of dependencies i would want to use and what is the general setup going to be.

Dialogs
The main thing that needs to be designed was a way to play dialogs in an easy way. One of my goals would be that you really don't need the Unity Editor anymore to write your game, also I would like the dialogs to be auto update-able with some kind of versioning (more on that later). Since building the VN Engine is a daunting task already, I decided to use as a base scripting language. It would need some extension to the extra stuff I have in mind.

  1. Speaker tagging
  2. Sound effects tagging
  3. Custom clickable events that are based on hidden overlaid choices

Storage
Since I explained I wanted the game to be auto-updatable It needs some kind of API, which I generally don't really like to build I opted for a simple solution for this project, namely S3 Storage it allows me to create buckets. This allows me to store the images and stories remotely and fetch updated versions once I made updates. This allows me to CRUD the game at any point of time. The downsides are that the costs of storing and bandwidth are on MY side instead of Steam's. I don't really have to care about people stealing your renders or story since most games can be unpacked easily anyway.

I do want to implement some kind of basic encryption so the images and story are not flat out steal-able. But anyone with basic knowledge would be able to decrypt the files if really wanted.

Sample
Code:
=== ALEX_VR_WORLD ===
~ background("alex-intro", false)
Yeez, is it that late already? Time to log off and return to the boring world #speaker:alex
#clear
*   [Reach for the headset to pull it off]
    You feel a sudden resistance as the headset begins to glitch. #speaker:narrator
    What the—? This isn't right. #speaker:alex
    -> GLITCH
*   [Shutdown the headset properly]
    Before you can reach the system menu, the entire system starts to glitch. #speaker:narrator
    No, no, no... come on, not now! #speaker:alex
    -> GLITCH
Image Sequence_001_0000.png

Keep an eye on this thread to follow my journey on creating my own Simple VN Engine, if you want a sneak peak on my journey you can use this link:
 
  • Like
Reactions: ulala9
Jan 19, 2022
21
89
Update:
I decided to work on a small visual novel build entirely on top of said engine. You need to test out your engine to know what's missing right :)

Please give me some slack on my Daz renders since this is the first week of me working with the program. And I don't have that many assets to play with

This story is about a brother (Alex) and sister (Sarah) that are very different from each other, The one is an introvert living in a virtual reality. The other one is outgoing and a people pleaser.

One fortunate day Alex's VR headset glitches out giving him the ability to control other people, Granted in its early stages he cannot control much. But who knows what he can do once he masters the ability :devilish:. In this journey he will discover the limits of his ability and of course the downsides of using the ability too much.

You can play an on-going development build that might work or not work


Let me know if you have ideas for the engine, features that are obviously missing.
(There is a lot missing the engine is a week old!)
And of course suggestions for the story.

Fun challenge let me know how easy it is to steal the renders or story from the game,

The Cast
Meet Sarah one of our cast members.

sarah-happy-fix-hair.png

And dorky Alex our main protagonist of this story
alex-remove-goggles.png
 
Last edited:

R1k0

Member
Sep 27, 2017
234
439
Expecting nothing I ran it on my phone and it even worked. After talking to Sarah in the kitchen, is there anything further? Looks nice, the sister is cute, though her emotions sometimes don't look natural, you know there's an emotion sliders and you don't have to put it at 100%, right?
 
Jan 19, 2022
21
89
Expecting nothing I ran it on my phone and it even worked.
Yeah it should work on Android at least, controls might be a bit finicky! its on my todo list.

After talking to Sarah in the kitchen, is there anything further?
No for now this is it, im actively working on the story. Progress will be slow since rendering takes a ton of time. Also the focus is on the feature set of the Engine so I will develop the story further based on the features I want to implement. If you have any suggestions let me know!

you know there's an emotion sliders and you don't have to put it at 100%, right?
Ah nope, TIL let me play/search with those values. Im just a week into DAZ :) (Loads to learn!)
 
Last edited:
  • Like
Reactions: R1k0

R1k0

Member
Sep 27, 2017
234
439
Yeah it should work on Android at least, controls might be a bit finicky! its on my todo list.


No for now this is it, im actively working on the story. Progress will be slow since rendering takes a ton of time. Also the focus is on the feature set of the Engine so I will develop the story further based on the features I want to implement. If you have any suggestions let me know!


Ah nope, TIL let me play/search with those values. Im just a week into DAZ :) (Loads to learn!)
"Progress will be slow since rendering takes a ton of time", it looks like you're rendering at 4K resolution, I think that's too much, and if the room is not bright enough and there are a lot of light sources in the room, rendering can take a long time. I don't know how powerful your computer is, but I would look for such settings that rendering takes 20-30 minutes, at least do 5-7 renders per day.
 
Jan 19, 2022
21
89
"Progress will be slow since rendering takes a ton of time", it looks like you're rendering at 4K resolution, I think that's too much, and if the room is not bright enough and there are a lot of light sources in the room, rendering can take a long time. I don't know how powerful your computer is, but I would look for such settings that rendering takes 20-30 minutes, at least do 5-7 renders per day.
Yeah i'm doing 4k renders at 25 minutes each at the moment. I can do two renders at the time but still it takes a long time compared to traditional game development hahah
 

osanaiko

Engaged Member
Modder
Jul 4, 2017
2,111
3,395
Yeah i'm doing 4k renders at 25 minutes each at the moment. I can do two renders at the time but still it takes a long time compared to traditional game development hahah
The "standard" Daz workflow, once you get some experience and confidence in working with Daz and doing good scene setup, is this:
- setup your scene,
- test render as small resolution/low samples to make sure it is not borked (no geometry pokethrough etc),
- save the scene file with some clever naming scheme.
- repeat for as many scenes as you have time.

Then overnight, you use an automated render queue tool (like Manfriday) to render the scenes one by one at high res/high samples.

This way you aren't wasting your creative time waiting for the final outputs.

Any issue you find in the final renders either are fixed and go back on the queue, or if minor, you can use spot-render tool and then an image editor to overlay the small fix patch.

Also consider using AI denoiser tools in moderation, it can turn 1000 (or less!) sample renders into ones that look like 5000-10000 samples - but there is some detail loss.
 
  • Like
Reactions: that_vn_programmer
Jan 19, 2022
21
89
Update:

I had some time this start of the week to create some new features. The update should be live on the :)
Thanks osanaiko for the detailed workflow, let me see if I can adapt some of those pointers!

  • Added a click to display the full dialog (allows you to instantly finish the animation)
  • Updated the renders to have a higher quality than before, (better compression quality)
  • Added a way to simply play video files (animations) (.h256)
  • Updated the story so you will always trigger your ability for the first time.
  • A lot of code clean up so it's very easy to integrate this Engine into a new Unity project.
  • Fixed the aspect ratio bug that would happen if you resized your browser window into anything other than 16:9
  • Working on a animation that you can trigger once master your ability :devilish:
You don't have permission to view the spoiler content. Log in or register now.
 
Last edited:
Jan 19, 2022
21
89
Update:

This week was full of changes for me, I wanted to start on the first GUI elements, I wanted to keep it as clean as possible so I opted for a clean hud.

You don't have permission to view the spoiler content. Log in or register now.

The time system that was decided on is based on slots instead of hours, this makes it more limited in scope but allows the user to not get confused with 24 hours in a day.
  • Morning
  • Afternoon
  • Evening
  • Night
Defining events in my system is pretty straight forward too, below you can find a sample event that will only be active if its a Tuesday and you finished some other events.

Code:
// WHISPERS OF CONTROL
// KITCHEN_EVENT_004
// DESCRIPTION:
// On Tuesday once you talked with the girls studying there will be an option to fetch some cold drinks from the refridgerator

=== KITCHEN_EVENT_004_START ===
~ temp event_active = current_day == Tuesday && items !? COLD_DRINK && kitchen_event_002_done
* {event_active} [Fetch cold beverages #marker:565.535.140.200]
    ~ background("alex-kitchen-grab-drinks", 0.25)
    Hmm.. I think the girls would want some ice-cold beverages. It’s a hot day, after all. #speaker:alex
    Lets prepare them and give them a small lemonade-break #speaker:alex
    ~ giveItem(COLD_DRINK)
    ~ background(kitchen_state, 0.25)
-> KITCHEN
This results in a new action that allows you to fetch beverages from the fridge, resulting in progression. This game is pretty barebones on its locations so these kind of hidden objectives should be fun as you unravel the story.

The beauty of using a 3D engine like Unity is that I can also incorporate realtime elements into the game, since our MC is a VR / Computer addict it made sense to make a computer like interface. Below you can find a work in progress computer that you can interact. The idea is that you can find your unlockables there and maybe other things that are story related.
You don't have permission to view the spoiler content. Log in or register now.
 
Last edited: