SilasSpeech.cs 14.6 KB
Newer Older
1
2
3
4
5
6
7
8
using System.Collections;
using System.Collections.Generic;
using UnityEngine;


public class SilasSpeech : MonoBehaviour, Character {

    private Queue<string> conversation = new Queue<string>();
9
    private Queue<string[]> responseQueue = new Queue<string[]>();
10

11
12
    private string[] currentResponses;

13
14
15
16
    public float getLevel() {
        return GameManager.SilasLevel;
    }

17
18
19
20
    public string getName() {
        return "Silas";
    }

21
22
    public string GreetingMessage(){
        loadConversation();
23
        
24
        if ((int)GameManager.getLevel(getName()) == 1) {
25
            currentResponses = new string[] { "Hi there", "Umm hello?", "clumsily mime 'Hello'" };
26
27
            return "...";

28
        } else if ((int)GameManager.getLevel(getName()) == 2) {
29
30
31
            currentResponses = new string[] { "stage 2 greeting response" };
            return "stage 2 greeetiong";

32
        } else if ((int)GameManager.getLevel(getName()) == 3) {
33
34
35
            currentResponses = new string[] { "stage 3 greeting response" };
            return "stage 3 greeting";

36
        } else if ((int)GameManager.getLevel(getName()) == 4) {
37
38
39
40
41
            currentResponses = new string[] { "stage 4 greeting response" };
            return "stage 4 greeting";

        }
        return "Something has gone terribly wrong: The stage is: " + GameManager.ConversationStage;
42
43
    }
    public string GoodbyeMessage(){
44
        currentResponses = new string[] { };
45
        return "Oh no don't go, talking is so fun!";
46
47
48
    }

    public string ProximityMessage(){
gstuitje's avatar
gstuitje committed
49
        currentResponses = new string[] { };
50
        return "did someone enter my invisible box!";
51
52
    }
    public string butthurtGoodbye(){
53
        currentResponses = new string[] { };
54
55
56
57
        return "its just white makeup, i swear!";
    }

    public string nothingMoreToSay() {
58
        if (GameManager.HasTalkedToAhava) {
59
60
61
62
63
64
65
66
            if((int)GameManager.getLevel(getName()) == 4)
            {
                currentResponses = new string[] { "wow, tell me more amazing things!", "my ears are blessed!", "I'm just trying to listen harder!" };
            }
            else {
                currentResponses = new string[] { "wow, tell me mo...", "my ears are ble...", "I'm just tryi..." };
            }

mmaluschnig's avatar
mmaluschnig committed
67
            switch (Random.Range(0, 14)) {
68
69
70
71
72
73
74
75
76
77
78
79
80
81
                case 0: return "According to circus superstition, it's unlucky to wear green in the ring, hopefully you'll be okay!";
                case 1: return "A 'josser' is an outsider who joins the circus!";
                case 2: return "The word clown is believed to come from the Icelandic word klunni, meaning a clumsy person!";
                case 3: return "A street mime was so committed that he actually got stuck in his imaginary box and died of starvation!";
                case 4: return "Banging your head against the wall burns 150 calories an hour!";
                case 5: return "29th May is officially 'Put a Pillow on your Fridge Day'!";
                case 6: return "in 2017 more people were kiled from injuries caused by taking a selfie than by shark attacks!";
                case 7: return "Did you know Honey Bees can recognise human faces!";
                case 8: return "A small child could swim through the veins of a Blue Whale!";
                case 9: return "pirates wore earings because they believed it improved their eyesight!";
                case 10: return "20th March is Snowman Burning day to celebrate the end of winter!";
                case 11: return "Sometimes it sounds like Simon is trying to communicate, I wonder what he's saying!";
                case 12: return "It takes 11 clowns to screw in a lightbulb, 10 to make the pyramid, then one more to put in the light bulb!";
                case 13: return "I heard there was a flying circus run by a group called Monty Python, Maybe one day I can join!";
82
83
84
85
                default:
                    return "...";
            }
        } else {
86
            currentResponses = new string[] { };
87
            return "...";
88
89
90
91
92
        }
    }

    public string converse() {
        if (conversation.Count > 0) {
93
            currentResponses = responseQueue.Dequeue();
94
95
96
97
98
99
100
            return conversation.Dequeue();
        } else {
            return nothingMoreToSay();
        }
    }

    private void loadConversation() {
101
        conversation.Clear();
102
103
        responseQueue.Clear();

104
105
106
107
        if (GameManager.SilasTutorial)
        {
            loadTutorialConversation();

108
        }else if ((int)GameManager.getLevel(getName()) == 1) {
109
110
            conversationStage1();

111
        } else if ((int)GameManager.getLevel(getName()) == 2) {
112
113
            conversationStage2();

114
        } else if ((int)GameManager.getLevel(getName()) == 3) {
115
116
            conversationStage3();

117
        } else if ((int)GameManager.getLevel(getName()) == 4) {
118
119
120
121
122
123
124
125
126
127
            conversationStage4();

        }
    }

    public string[] getResponses() {
        return currentResponses;
    }

    private void conversationStage1() {
128
        if (GameManager.HasTalkedToAhava) {
129
130
            conversation.Enqueue("HaHaHa got you! Thought i was a mime didnt ya?!");
            responseQueue.Enqueue(new string[] { "wow you fooled m...", "nah not reall..." });
131

132
133
            conversation.Enqueue("The names Silas, they call me the unspeakable round here!");
            responseQueue.Enqueue(new string[] { "why is tha...", "cant think wh...", "slow down plea..." });
134

135
136
            conversation.Enqueue("Not really sure why they call me unspeakable but it sounds cool doesnt it!");
            responseQueue.Enqueue(new string[] { "Yes!", "people are joking arou...", "I'm learning why fa..." });
137

138
139
            conversation.Enqueue("anyway have you seen my show 'Mime Mime' its the talk of the circus!");
            responseQueue.Enqueue(new string[] { "not ye...", "ive played i...!", "isnt that just a rip off of Dance dance revo..." });
140

141
            conversation.Enqueue("...well its mostly just me talking about it but they say its the best");
142
            responseQueue.Enqueue(new string[] { "keep talki...!", "okay sto..." });
143

144
            conversation.Enqueue("...well i say its the best");
145
            responseQueue.Enqueue(new string[] { "It is gre...", "please stop talki..." });
146
147
        } else{
            conversation.Enqueue("...");
148
            responseQueue.Enqueue(new string[] { "?", "=(", "'mime' a wave" });
149

150
            conversation.Enqueue("....");
151
            responseQueue.Enqueue(new string[] { "?", "=(", "'mime' an annoyed wave" });
152
153

            conversation.Enqueue(".......");
154
            responseQueue.Enqueue(new string[] { "?", "=(", "'mime' a really angry wave" });
155
156

            conversation.Enqueue("...................................");
157
158
159
            responseQueue.Enqueue(new string[] { "?", "=(", "'mime' something not family friendly" });
            conversation.Enqueue("....Talk to the bearded lady!....");
            responseQueue.Enqueue(new string[] { "Oh right", "=)", "'mime' a slight apology" });
160
        }
161
    }
162

163
    private void conversationStage2() {
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
        conversation.Enqueue("Hey! thanks for dancing with me!");
        responseQueue.Enqueue(new string[] { "It was nothi...", "I had a lot of fu...", "maybe one day I can lea..."});

        conversation.Enqueue("If you keep dancing like that maybe one day I can copy you!");
        responseQueue.Enqueue(new string[] { "I don't thi...", "'Mime' a thumbs up", "That's what I was trying to sa..." });

        conversation.Enqueue("Anyways, what do you think of the performance?!");
        responseQueue.Enqueue(new string[] { "It's great bu...", "It's oka...", "It's the wors..." });

        conversation.Enqueue("Oh I'm so glad you like it! It's so nice to have a partner!");
        responseQueue.Enqueue(new string[] { "I like being with you t...", "Can you stop talking so fa...", "that's not wha..." });

        conversation.Enqueue("Maybe we can be partners for ever and ever and ever and ever!!!!");
        responseQueue.Enqueue(new string[] { "'Mime' a heart", "I'd lik...", "I think we should see other peo..." });

        conversation.Enqueue("Talking is so much fun!");
        responseQueue.Enqueue(new string[] { "especially with yo...", "sometimes it can b...", "Not with yo..." });

        conversation.Enqueue("Especially when I have so much fun stuff to tell you!");
        responseQueue.Enqueue(new string[] { "*listen more carefully*", "'mime' a bored expression", "please don..." });


186
187
188
189

    }

    private void conversationStage3() {
190
191
192
193
194
195
196
197
        conversation.Enqueue("Phew, you're starting to get real good! Almost as good as me!");
        responseQueue.Enqueue(new string[] { "Pant loudly", "I can still feel the swe...", "Maybe you're just taking it too ea..."  });

        conversation.Enqueue("I bet you're starting to wonder how I'm so on time with the music!");
        responseQueue.Enqueue(new string[] { "Years of mime universi...?", "You probably chea...", "Not reall..." });

        conversation.Enqueue("It's all about my commimement! I started on slow versions and then sped them up as it became easy!");
        responseQueue.Enqueue(new string[] { "That's a great ide...", "Maybe I can do tha...", "That sounds like a lot of wor..." });
198

199
200
201
202
203
204
205
206
207
208
209
        conversation.Enqueue("I know what you're thinking, being a mime is about fun, not hard work!");
        responseQueue.Enqueue(new string[] { "half the fun is in the wor...", "I wasn't thinki...", "nothing about miming is fu..." });

        conversation.Enqueue("But sometimes a good mime has to break out of his invisible skill ceiling and climb the rope of success!");
        responseQueue.Enqueue(new string[] { "But I need hel...", "Maybe I'll give it a sho...", "that was disgusti..." });

        conversation.Enqueue("Don't worry though, I'll be here to keep training you up!");
        responseQueue.Enqueue(new string[] { "'Mime' a heart", "thank yo...", "I don't need yo..." });

        conversation.Enqueue("And tell you lots of awesome stuff!");
        responseQueue.Enqueue(new string[] { "*listen more carefully*", "'mime' a bored expression", "please don..." });
210
211
212
    }

    private void conversationStage4() {
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
        conversation.Enqueue("It's so amazing how far you've come! It's like you're coming out of your invisible box!");
        responseQueue.Enqueue(new string[] { "'mime' rosey red cheeks", "It's almost like it doesn't matter how wel...", "I kno..." });

        conversation.Enqueue("No need to be embarressed! I was new and skillful too once!");
        responseQueue.Enqueue(new string[] { "I'm not embarres...", "I'm not even that goo...", "How modest of yo..."});

        conversation.Enqueue("I just wish there was some way I could reward you for all your hard work!");
        responseQueue.Enqueue(new string[] { "A rewa...?", "That's not necessar...", "I don't wan..." });

        conversation.Enqueue("I have an idea!");
        responseQueue.Enqueue(new string[] { "'mime' excitement?", "really it's oka...", "please sto..." });

        conversation.Enqueue("*Simon blows you a kiss*");
        responseQueue.Enqueue(new string[] { "'mime' a blow kiss back", "'mime a disturbed expression'", "urgggh..." });

        conversation.Enqueue("Hehe, just kidding! *He speaks slower* I have another idea.");
        responseQueue.Enqueue(new string[] { "Thanks, but I really don't need a reward.", "'mime' a disturbed expression", "This is getting weird." });

        conversation.Enqueue("Go on, say anything you like *he 'mimes' a smile*");
        responseQueue.Enqueue(new string[] { "Wait, I can finally finish a sentence?", "this is weird.", "Why won't you just be quiet for two seconds." });

        conversation.Enqueue("I'm sorry, I know why they call me Silas the unspeakable *he 'mimes' a sad face*");
        responseQueue.Enqueue(new string[] { "How come? *'mime' a sad face*", "oh it's not that bad", "finally it's over" });

        conversation.Enqueue("It's cause I talk so fast, it's just that I'm so scared of people not hearing all I have to say. But with you I feel safe!");
        responseQueue.Enqueue(new string[] { "I'll always listen to you", "I'm glad you trust me", "Weird friendship, but okay" });

        conversation.Enqueue("Now how about talking about some fun stuff!");
        responseQueue.Enqueue(new string[] { "*listen more carefully than normal*", "'mime' a bored expression jokingly", "please don't let me stop you" });
242

243
    }
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261

   private void loadTutorialConversation()
    {
        conversation.Enqueue("Oh hey, so nice of you to come perform with me!");
        responseQueue.Enqueue(new string[] { "okay" });

        conversation.Enqueue("We're gonna have so much fun!");
        responseQueue.Enqueue(new string[] { "okay" });

        conversation.Enqueue("Or at least, I'll have so much fun!");
        responseQueue.Enqueue(new string[] { "Get on with it" });

        conversation.Enqueue("All you have to do to perform with me is dance, for me it's pretty natural!");
        responseQueue.Enqueue(new string[] { "I don't know how" });

        conversation.Enqueue("but if it wasn't natural I'd know that anyone can use the Q W E or R keys to daaaaannceee.");
        responseQueue.Enqueue(new string[] { "okay" });

nedboy3's avatar
nedboy3 committed
262
        conversation.Enqueue("WOW, your dancing is so good it lights up those convenient looking boxes!");
263
264
265
266
267
268
269
270
271
272
273
274
275
276
        responseQueue.Enqueue(new string[] { "okay" });

        conversation.Enqueue("How about I let you know what amazing moves I'm going to do? And you can copy me!");
        responseQueue.Enqueue(new string[] { "okay" });

        conversation.Enqueue("I'll use my super secret mime sign language by sending instructions from those mimetastic pillars to your right. Ready?!");
        responseQueue.Enqueue(new string[] { "okay" });

        conversation.Enqueue("Here I go, hit it when it's in it's square, I'll go easy this time!");
        responseQueue.Enqueue(new string[] { "okay" });

        conversation.Enqueue("Hit it now!");
        responseQueue.Enqueue(new string[] { "okay" });

nedboy3's avatar
nedboy3 committed
277
278
279
280
        conversation.Enqueue("Nice job! green fireworks represent a perfect hit, yellow fireworks represent an okay hit, and the angry red ball means you almost missed!");
        responseQueue.Enqueue(new string[] { "okay" });

        conversation.Enqueue("Nice job! green fireworks represent a perfect hit, yellow fireworks represent an okay hit, and the angry red ball means you almost missed!");
281
282
283
284
285
286
287
288
289
290
291
        responseQueue.Enqueue(new string[] { "okay" });

        conversation.Enqueue("let's try a few more of my definitely different moves!");
        responseQueue.Enqueue(new string[] { "okay" });

        conversation.Enqueue("This time I've gotta go fast, you can do it!");
        responseQueue.Enqueue(new string[] { "okay" });

        conversation.Enqueue("I think you've got the idea now! Time for us to do this for real!");
        responseQueue.Enqueue(new string[] { "okay" });
    }
292
}