12th week, the ink & inky, Unity dialogue system


Hi guys, 

We are glad to announce the last week's result.

We used "Ink" to make dialogue data. 
https://www.inklestudios.com/ink/

It reduces many times. When I made a similar system, I spent 1~2 months making it before. 
today, Let me say how to make it.

When we download the inky editor from here: https://github.com/inkle/inky/releases/tag/0.13.0
and put some data like it. 

in the unity C#, We can use it by just 2 lines. 

1. We have to parse this data.
 public void NewStory(TextAsset inkfile)
    {
        inkAsset = inkfile;
        currentStory = new Story(inkAsset.text);
    }

this method will parse the compiled ink file to the Story object. 

2. and we have to read the line. 

if (currentStory.canContinue)  storyline.txt = currentStory.Continue();

That's it. 
If currentStory.canContinue => false ===> We should finish the dialog. 

add more complexity, below data had the choice data ( "*" => it is choice ) and the tag data ( "#" )


the different points are just 2, 


1. if the currentStory has the choices, we can know it by the below code.
if (currentStory.currentChoices.Count > 0)
{
            storyline.choices = currentStory.currentChoices;
}


it is just List<Choice>(). We can show it by looping. 

2. Tag.  The below code shows how to parse the #talker:XXXX data to EnumType


We think, We should begin to make the stage scene by this week!

Of cause, Many things remained. 
- Casino system
- Shop system
- Cooking system etc...

We have to make these systems during scene tasks. 

See you next week!

Leave a comment

Log in with itch.io to leave a comment.