Beispiel #1
0
        public void Well()
        {
            string[] messageArray = new string[]
            {
                "Looks like I could get some refreshing water to drink here. But I see no bucket...",
            };

            SoundManager.PlaySound(SoundManager.Sound.well, control.GetPosition());
            string message = messageArray[Random.Range(0, messageArray.Length)];

            textwriterSingle = Textwriter.AddWriter_Static(displayText, message, 0.03f, true, true);
        }
Beispiel #2
0
        public void Texttrigger()
        {
            string[] messageArray = new string[]
            {
                "There is a house! I hope there are people there. I am starving.",
            };

            SoundManager.PlaySound(SoundManager.Sound.ausblick, control.GetPosition());
            string message = messageArray[Random.Range(0, messageArray.Length)];

            textwriterSingle = Textwriter.AddWriter_Static(displayText, message, 0.03f, true, true);
        }
Beispiel #3
0
        public void Crocus()
        {
            string[] messageArray = new string[]
            {
                "I wonder how these flowers got so big and shiny!"
            };

            SoundManager.PlaySound(SoundManager.Sound.crocus, control.GetPosition());
            string message = messageArray[Random.Range(0, messageArray.Length)];

            textwriterSingle = Textwriter.AddWriter_Static(displayText, message, 0.03f, true, true);
        }
Beispiel #4
0
        public void Scene()
        {
            string[] messageArray = new string[]
            {
                "This is a steep descent. Hopefully there is another way out of this valley... I have no idea where I am.",
            };

            SoundManager.PlaySound(SoundManager.Sound.szene1, control.GetPosition());
            string message = messageArray[Random.Range(0, messageArray.Length)];

            textwriterSingle = Textwriter.AddWriter_Static(displayText, message, 0.03f, true, true);
        }
Beispiel #5
0
        public void Pear()
        {
            string[] messageArray = new string[]
            {
                "I won't try these pears. They are as big as the apples... they'll probably taste just as terrible!"
            };

            SoundManager.PlaySound(SoundManager.Sound.pear, control.GetPosition());
            string message = messageArray[Random.Range(0, messageArray.Length)];

            textwriterSingle = Textwriter.AddWriter_Static(displayText, message, 0.03f, true, true);
        }
Beispiel #6
0
        public void Tulip()
        {
            string[] messageArray = new string[]
            {
                "What a beautiful tulip. It is gigantic, someone must have used a lot of fertilizer.",
            };

            SoundManager.PlaySound(SoundManager.Sound.tulip, control.GetPosition());
            string message = messageArray[Random.Range(0, messageArray.Length)];

            textwriterSingle = Textwriter.AddWriter_Static(displayText, message, 0.03f, true, true);
        }
Beispiel #7
0
        public void Cemetery()
        {
            string[] messageArray = new string[]
            {
                "A cemetery next to an abandoned house. Well, that's a little scary, I wouldn't want to be here alone at night!"
            };

            SoundManager.PlaySound(SoundManager.Sound.cemetery, control.GetPosition());
            string message = messageArray[Random.Range(0, messageArray.Length)];

            textwriterSingle = Textwriter.AddWriter_Static(displayText, message, 0.03f, true, true);
        }
Beispiel #8
0
        public void Water()
        {
            string[] messageArray = new string[]
            {
                "How refreshing, water from a well on a hot summer day. But do I taste something odd? Probably not, I must be dehydrated from the sun.",
            };

            SoundManager.PlaySound(SoundManager.Sound.drink, control.GetPosition());
            SoundManager.PlaySound(SoundManager.Sound.water, control.GetPosition());
            string message = messageArray[Random.Range(0, messageArray.Length)];

            textwriterSingle = Textwriter.AddWriter_Static(displayText, message, 0.03f, true, true);
        }
Beispiel #9
0
        public void Letter()
        {
            string[] messageArray = new string[]
            {
                "A Letter from scientists. Looks pretty old. Maybe it reveals what has happened here.",
            };

            SoundManager.PlaySound(SoundManager.Sound.book, control.GetPosition());
            SoundManager.PlaySound(SoundManager.Sound.letterpickup, control.GetPosition());
            string message = messageArray[Random.Range(0, messageArray.Length)];

            textwriterSingle = Textwriter.AddWriter_Static(displayText, message, 0.03f, true, true);
        }
Beispiel #10
0
        public void Apple()
        {
            string[] messageArray = new string[]
            {
                "What a gigantic apple, how did it become this big? It tastes terrible though, I need a drink to get rid of the taste.",
            };

            SoundManager.PlaySound(SoundManager.Sound.apple, control.GetPosition());
            SoundManager.PlaySound(SoundManager.Sound.applebite, control.GetPosition());
            string message = messageArray[Random.Range(0, messageArray.Length)];

            textwriterSingle = Textwriter.AddWriter_Static(displayText, message, 0.03f, true, true);
        }
Beispiel #11
0
        public void Something()
        {
            string[] messageArray = new string[]
            {
                "This flower looks pretty but somewhat off, just like some other things around here... I can't put my finger on it.",
            };

            SoundManager.PlaySound(SoundManager.Sound.pickup, control.GetPosition());
            SoundManager.PlaySound(SoundManager.Sound.flower, control.GetPosition());
            string message = messageArray[Random.Range(0, messageArray.Length)];

            textwriterSingle = Textwriter.AddWriter_Static(displayText, message, 0.03f, true, true);
        }
Beispiel #12
0
        public void Key()
        {
            string[] messageArray = new string[]
            {
                "Seems like this key hasn't been used in a while. Maybe we'll find the right lock for it.",
            };

            SoundManager.PlaySound(SoundManager.Sound.pickup, control.GetPosition());
            SoundManager.PlaySound(SoundManager.Sound.key1, control.GetPosition());
            string message = messageArray[Random.Range(0, messageArray.Length)];

            textwriterSingle = Textwriter.AddWriter_Static(displayText, message, 0.03f, true, true);
        }
Beispiel #13
0
        private IEnumerator FadeOutRoutine(TextWriterSingle tws)
        {
            TextMeshProUGUI text = tws.GetText();

            Debug.Log("Ich verschwinde");
            for (float t = 0.01f; t < 3f; t += Time.deltaTime)
            {
                text.color = Color.Lerp(originalColor, Color.clear, Mathf.Min(1, t / 3f));
                Debug.Log("verschwinde....");
                yield return(null);
            }
            text.enabled = false;
        }
Beispiel #14
0
        public void Diary()
        {
            string[] messageArray = new string[]
            {
                "This diary shocked me. The boy seems distraught. I can't just walk away without knwoing what happened to him and his family.",
            };

            SoundManager.PlaySound(SoundManager.Sound.book, control.GetPosition());
            SoundManager.PlaySound(SoundManager.Sound.diarypickup, control.GetPosition());
            string message = messageArray[Random.Range(0, messageArray.Length)];

            textwriterSingle = Textwriter.AddWriter_Static(displayText, message, 0.03f, true, true);
        }
Beispiel #15
0
 private void Update()
 {
     for (int i = 0; i < textWriterSingleList.Count; i++)
     {
         //textWriterSingleList[i].GetText().enabled = true;
         textWriterSingleList[i].GetText().color = textColor;
         bool destroyInstance = textWriterSingleList[i].WriteText();
         if (destroyInstance)
         {
             TextWriterSingle tws = textWriterSingleList[i];
             FadeOut(tws);
             originalColor = Color.white;
             Debug.Log("Jetzt bin ich weg");
             textWriterSingleList.Remove(tws);
             i--;
         }
     }
 }
Beispiel #16
0
 private void Awake()
 {
     textWriterSingle = this;
 }
Beispiel #17
0
 public void FadeOut(TextWriterSingle tws)
 {
     StartCoroutine(FadeOutRoutine(tws));
 }