Debian Codegraph @

data/storyline/act2/dialogs/MrSaves.lua

raw
1 ---------------------------------------------------------------------
2 -- This file is part of Freedroid
3 --
4 -- Freedroid is free software; you can redistribute it and/or modify
5 -- it under the terms of the GNU General Public License as published by
6 -- the Free Software Foundation; either version 2 of the License, or
7 -- (at your option) any later version.
8 --
9 -- Freedroid is distributed in the hope that it will be useful,
10 -- but WITHOUT ANY WARRANTY; without even the implied warranty of
11 -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 -- GNU General Public License for more details.
13 --
14 -- You should have received a copy of the GNU General Public License
15 -- along with Freedroid; see the file COPYING. If not, write to the
16 -- Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston,
17 -- MA 02111-1307 USA
18 ----------------------------------------------------------------------
19 --[[WIKI
20 PERSONALITY = { "Weird", "Mysterious", "Riddles", "Omniscient?", "Crypt" },
21 PURPOSE = "$$NAME$$ is just an useless character which may spawn between Acts and player will wonder why he does that and what he's talking about.",
22 BACKSTORY = "$$NAME$$ is an anomaly. No one knows where he comes from, why he is here, or even if he should be in FreedroidRPG to begin with. He was not added by FreedroidRPG staff, and seems pretty happy in playing mind games with Tux. But, who is this man, who all he does all day is staring the sky? He might be holding a big secret, but you'll never know. All you can do for now is fry your brain, trying to understand why he just stares the sky, without doing anything, as if everything is going as it should be going... including you."
23 WIKI]]--
24
25 local Npc = FDrpg.get_npc()
26 local Tux = FDrpg.get_tux()
27
28 return {
29 FirstTime = function()
30 Saves_times=0
31 end,
32
33 EveryTime = function()
34 Saves_times=Saves_times + 1
35
36 -- I like to salute people correctly, so get the correct game time
37 local day, hour, minute = game_date()
38 if (hour >= 18 or hour < 6) then
39 Npc:says(_"Good evening!")
40 elseif (hour < 12 and hour >= 6) then
41 Npc:says(_"Good morning!")
42 elseif (hour < 18 and hour >= 12) then
43 Npc:says(_"Good afternoon!")
44 end
45
46 if (not has_met("MrSaves")) then
47 Tux:says(_"...Hello.")
48 Npc:says(_"I am Mr. Saves, the Watcher of Stories!")
49 Npc:set_name(_"Mr. Saves, Watcher of Stories")
50 Npc:says(_"The weather is grim again, don't you think? Ah, I love mental games. All the better when no one can understand them.")
51 --Tux:says(_"...No one asked.")
52 Tux:says(_"Uhm... great, I think?")
53 show("weird", "alive", "lazy", "node99")
54 elseif (Saves_times == 8) then
55 Npc:says(_"You don't have anything better to do, do you?")
56 Npc:says(_"I repeated the same thing seven times and you still come to bother me.")
57 Npc:says(_"Seven is a number of luck, though. Here, take this program update and don't show up again.")
58 Tux:improve_program("Animal Magnetism")
59 Npc:says(_"[b]Animal Magnetism skill updated![/b]")
60 Npc:says(_"If you do, I'll repeat myself until I manage to bore you out.")
61 Tux:says(_"Uhm... Thanks?")
62 Npc:says(_"Now get going. You have more important things to do.")
63 end_dialog()
64 else
65 Npc:says(_"The sky is in a pretty blue azure today...") -- He could give different colors to sky based on player progress.
66 end
67 end,
68 -- The first time you talk to Mr. Saves, you are presented the opportunity to do questions (most IRC-quotes based)
69 {
70 id = "alive",
71 text = _"Why are you alive? Why are the bots not attacking you?",
72 code = function()
73 Npc:says(_"I don't exist under normal circumstances.") -- IRC quote
74 Tux:says(_"Makes sense, you cannot attack something which doesn't exist.")
75 Tux:says(_"...No wait. It doesn't. If you don't exist, I can't talk to you either!")
76 Npc:says(_"Well, with strange aeons, even Mr. Saves may die.") -- IRC quote from quote “with strange aeons, even death may die”
77 Tux:says(_"...You know what? You're weird. I bet the bots are just afraid of getting close to you.")
78 hide('alive')
79 end,
80 },
81 {
82 id = "weird",
83 text = _"You're weird.",
84 code = function()
85 Npc:says(_"That's my purpose in life.") -- IRC quote
86 Tux:says(_"That only makes you weirder!")
87 Npc:says(_"If you think too much about it, you'll end up overheating.")
88 Npc:says(_"I advice you to drop this subject.")
89 hide('weird')
90 end,
91 },
92 {
93 id = "lazy",
94 text = _"What are you doing?",
95 code = function()
96 Npc:says(_"Volunteer work.")
97 Tux:says(_"I don't see you working.")
98 Npc:says(_"Well, that's because we volunteer for things exactly so that we can be lazy on them.") -- IRC quote
99 Tux:says("...")
100 hide('lazy')
101 end,
102 },
103 {
104 id = "node99",
105 text = _"Er, uhm... Good bye?",
106 code = function()
107 play_sound("effects/Menu_Item_Selected_Sound_1.ogg")
108 end_dialog()
109 end,
110 },
111 }