| 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 = { "Intelligent" }, |
| 21 |
MARKERS = { DROIDID1 = "614" }, |
| 22 |
BACKSTORY = "$$NAME$$ is the Red Guard\'s Computer Cluster maintainer and occasional $$DROIDID1$$ programmer." |
| 23 |
WIKI]]-- |
| 24 |
|
| 25 |
local Npc = FDrpg.get_npc() |
| 26 |
local Tux = FDrpg.get_tux() |
| 27 |
|
| 28 |
return { |
| 29 |
FirstTime = function() |
| 30 |
show("node0") |
| 31 |
if (Kevin:is_dead()) then |
| 32 |
show("node50") |
| 33 |
end |
| 34 |
end, |
| 35 |
|
| 36 |
EveryTime = function() |
| 37 |
if (Tux:has_item_backpack("Kevin's Data Cube")) then |
| 38 |
show("node6") |
| 39 |
end |
| 40 |
show("node99") |
| 41 |
end, |
| 42 |
|
| 43 |
{ |
| 44 |
id = "node0", |
| 45 |
text = _"Hi! I'm new here. ", |
| 46 |
code = function() |
| 47 |
Npc:says(_"Welcome, welcome! I'm Richard. I'm the computer guy around here.") |
| 48 |
Npc:says(_"I mostly work with this huge computer cluster here, although I also program the 614 bots in my spare time.") |
| 49 |
Npc:set_name("Richard - Programmer") |
| 50 |
hide("node0") show("node1", "node60") |
| 51 |
end, |
| 52 |
}, |
| 53 |
{ |
| 54 |
id = "node1", |
| 55 |
text = _"A computer cluster? What's that?", |
| 56 |
code = function() |
| 57 |
Npc:says(_"A cluster is a group of computers, connected in a way that helps them collaborate in solving problems.") |
| 58 |
Npc:says(_"As they say, 'two heads are better than one'. And we have a lot of heads here.") |
| 59 |
Npc:says(_"That is why I call this cluster 'Hydra'. A lot of heads indeed.") |
| 60 |
hide("node1") |
| 61 |
end, |
| 62 |
}, |
| 63 |
{ |
| 64 |
id = "node6", |
| 65 |
text = _"I have a data cube with some information. Can you tell me something more about it?", |
| 66 |
code = function() |
| 67 |
Npc:says(_"Interesting. Let me see this thing. Hmm... Yes, there is quite a lot of data in there. Maybe we could use Hydra to evaluate the data.") |
| 68 |
Npc:says(_"Hey, what do we have here? The data is already prepared for processing by a cluster just like ours. Wow! That's excellent!") |
| 69 |
Npc:says(_"I'll feed it into Hydra right away. Expect the results in a short while. Hydra has never let me down.") |
| 70 |
Tux:del_item_backpack("Kevin's Data Cube", 1) |
| 71 |
Tux:end_quest("A kingdom for a cluster!", _"Yes, that was simple. I wish everything else went as smoothly as this one did...") |
| 72 |
hide("node6") show("node9", "node10") |
| 73 |
end, |
| 74 |
}, |
| 75 |
{ |
| 76 |
id = "node9", |
| 77 |
text = _"Hey, did you get something out of that data cube?", |
| 78 |
code = function() |
| 79 |
Npc:says(_"Of course! I told you, Hydra has never failed me! I designed it myself, and I know computers very well. I never make mistakes.") |
| 80 |
Npc:says(_"Seems like the disruptor shield which thwarts all our attacks on Hell Fortress can be controlled from somewhere outside, or something like that.") |
| 81 |
Npc:says(_"I was busy servicing one of Hydra's nodes, but I sent the full report to Spencer. He will tell you more.") |
| 82 |
hide("node9") |
| 83 |
end, |
| 84 |
}, |
| 85 |
{ |
| 86 |
id = "node10", |
| 87 |
text = _"So... What's the story on those data cubes, anyway?", |
| 88 |
code = function() |
| 89 |
Npc:says(_"Well, they were originally developed for use with the Open-Pandora computing platform.") |
| 90 |
Tux:says(_"The what?") |
| 91 |
Npc:says(_"It was a handheld gaming computer, built on open-source software.") |
| 92 |
Npc:says(_"The device had limited storage capabilities, so an enterprising hacker designed the data cubes.") |
| 93 |
Npc:says(_"Those were the beginning days of open-source hardware. It's one of the few open-source innovations still around.") |
| 94 |
hide("node10") |
| 95 |
end, |
| 96 |
}, |
| 97 |
{ |
| 98 |
id = "node41", |
| 99 |
code = function() |
| 100 |
Tux:says(_"Sorry, my memory data bank is filled to the brim right now. Can't learn more until I get some more experience.") |
| 101 |
Npc:says_random(_"You Linarians are funny creatures. Come back later when you feel ready if you please.", |
| 102 |
_"I cannot teach you when you have no training points. Come back when you are more prepared.", |
| 103 |
_"You are not ready. Go kill some bots and come back.", |
| 104 |
_"Come back when you are mentally ready to learn.", |
| 105 |
_"Come back after some more practice in the field.", |
| 106 |
_"Waving those circuits in front of me when you are too unfocused to train won't help. I can take your money, but you won't learn anything.", |
| 107 |
_"Yeah, I don't think you have enough experience for this. Come back here after you see some more action.", |
| 108 |
_"Then come back when you have a real will to learn.", |
| 109 |
_"You don't have enough experience. Come here after you see some more action.") |
| 110 |
end, |
| 111 |
}, |
| 112 |
{ |
| 113 |
id = "node50", |
| 114 |
text = _"What can you teach me about hacking?", |
| 115 |
code = function() |
| 116 |
Npc:says(_"I can teach you everything, for a price of course.", "NO_WAIT") |
| 117 |
Npc:says(_"Three hundred per lesson, up front.", "NO_WAIT") |
| 118 |
hacking_level = get_program("Hacking") |
| 119 |
if (hacking_level > 8) then |
| 120 |
Npc:says(_"Sorry, there is no human alive that could give you further training.") |
| 121 |
hide("node51") |
| 122 |
else |
| 123 |
--; TRANSLATORS: %d = a number |
| 124 |
Npc:says(_"You will need %d training points.", hacking_level * 2) |
| 125 |
Npc:says(_"Still interested?") |
| 126 |
show("node51") |
| 127 |
end |
| 128 |
end, |
| 129 |
}, |
| 130 |
{ |
| 131 |
id = "node51", |
| 132 |
text = _"Yes, please teach me.", |
| 133 |
code = function() |
| 134 |
if (Tux:train_program(300, get_program("Hacking") * 2, "Hacking")) then |
| 135 |
Npc:says(_"Good. The most important thing about hacking is to understand the nature of the machine you want to hack.") |
| 136 |
Npc:says(_"Once you have figured out what the creators of the system were thinking when setting it up, you'll also know how to best hack it.") |
| 137 |
Npc:says(_"Now I see the feature set of your hacking program has already improved a lot.") |
| 138 |
hide("node51") show("node50") |
| 139 |
else |
| 140 |
if (Tux:get_gold() < 300 ) then |
| 141 |
next("node52") |
| 142 |
else |
| 143 |
next("node41") |
| 144 |
end |
| 145 |
end |
| 146 |
end, |
| 147 |
}, |
| 148 |
{ |
| 149 |
id = "node52", |
| 150 |
code = function() |
| 151 |
Tux:says_random(_"Hold on, I don't seem to have enough money right now.", |
| 152 |
_"This is embarrassing. I will come back when I have the amount of valuable circuits you desire.") |
| 153 |
Npc:says_random(_"Ok, come back when you can afford to pay me if you are interested.", |
| 154 |
_"Please don't bother me if you can't pay me.", |
| 155 |
_"You don't have enough money! I cannot afford to just give away training for free.", |
| 156 |
_"Come back when you have enough circuits.", |
| 157 |
_"So come back when you have some valuables.") |
| 158 |
end, |
| 159 |
}, |
| 160 |
{ |
| 161 |
id = "node60", |
| 162 |
text = _"What bot types do you know?", |
| 163 |
code = function() |
| 164 |
Npc:says(_"Well, I program the 614, so I know quite some things about the droids on this class.") |
| 165 |
Npc:says(_"Interested?") |
| 166 |
hide("node60") show("node61") |
| 167 |
end, |
| 168 |
}, |
| 169 |
{ |
| 170 |
id = "node61", |
| 171 |
text = _"Which bots are on 600s class?", |
| 172 |
code = function() |
| 173 |
Npc:says(_"The 600s class keeps the sentinel droids.", "NO_WAIT") |
| 174 |
Npc:says(_"They were projected mainly to protect a certain area from intruders, killing trespassers.") |
| 175 |
Npc:says(_"There is the [b]614[/b], made by Nicholson Company. They have some sort of [b]Exterminator[/b] inside. It's slow but a reliable droid.") |
| 176 |
Npc:says(_"There is also the [b]615[/b] droid. Nicholson Company didn't finish the project, which made them get affected by the Great Assault as well. They are much more dangerous than the 614, and much faster.") |
| 177 |
Npc:says(_"There is also the [b]629[/b] droid. It's slow, but its guns are powerful enough that such trivia doesn't matter.") |
| 178 |
Npc:says(_"There is also the [b]603[/b]. A lawnmower. It doesn't cause much damage, but his attack rate is incredibly fast and doesn't need recharging. Thankfully, it's a melee droid.") |
| 179 |
Npc:says(_"I only program the 614 droids, so my information about the others may be wrong.") |
| 180 |
hide("node61") |
| 181 |
end, |
| 182 |
}, |
| 183 |
{ |
| 184 |
id = "node99", |
| 185 |
text = _"See you later.", |
| 186 |
code = function() |
| 187 |
Npc:says(_"Take care, Linarian.") |
| 188 |
end_dialog() |
| 189 |
end, |
| 190 |
}, |
| 191 |
} |