- Home /
Interactive Story: Where to begin?
Hello! Recently I have been thinking about creating a Very basic interactive story game. I was inspired by the new game Detroit: Become Human in which there are scenes that play out and then you are given choices that can change the ending of plot of the story. I am thinking about starting with a basic system to just see how it would work. I have searched youtube but I am unable to find a good tutorial that just helps me learn the basics.
So, my question is: Where can I find a good tutorial or example video that can help me better understand on how to make interactive story games?
Answer by Trevdevs · Jun 26, 2018 at 03:10 AM
This is exactly what my current project is let me give you a rundown of what i'm doing.
I create a scriptableObject that stores each chapter/segment of the story.
I create a class that writes text to the screen letter by letter. Here is that class
using System.Collections; using UnityEngine; using UnityEngine.UI;
public class TextWriter : MonoBehaviour { public Chapter chapter; public Text story;
public Button[] choices; public InputField input; public bool isDone; public IEnumerator Write() { string newText = ""; for(int i = 0; i < phrase.text.Length + 1; i++) { newText = phrase.text.Substring(0, i); story.text = newText; yield return new WaitForSeconds(phrase.speed); } isDone = true; } }
I create buttons that give the player a choice each choice will load a new segment of the story based on their choices.
also a simple google search found me some stuff like this cheers! :)
Thank you. That makes much more sense! So when you have the choices and someone chooses a button that button will call a function that begins another one of these segments correct?
Your answer
Follow this Question
Related Questions
Multiple Cars not working 1 Answer
Distribute terrain in zones 3 Answers
2D Game example 2 Answers
Make objects move around, then bounce off and continue moving. NOT WORKING 1 Answer
Raycast chase player, avoid walls.. raycast detailed C# tutorial? 0 Answers