| 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 |
|
| 20 |
local Npc = FDrpg.get_npc() |
| 21 |
local Tux = FDrpg.get_tux() |
| 22 |
|
| 23 |
return { |
| 24 |
EveryTime = function() |
| 25 |
play_sound("effects/Menu_Item_Deselected_Sound_0.ogg") |
| 26 |
-- name = Tux:get_player_name() -- We need to generate the option text of option 0 to use this properly |
| 27 |
if (c_net_terminals_disabled) then |
| 28 |
Npc:says(" . ") |
| 29 |
end_dialog() |
| 30 |
else |
| 31 |
Npc:says(_"Welcome to the Community Network.", "NO_WAIT") |
| 32 |
cli_says(_"Login : ", "NO_WAIT") |
| 33 |
if (knows_c_net_users) then |
| 34 |
show("node1", "node2", "node3") |
| 35 |
end |
| 36 |
show("node0", "node99") |
| 37 |
end |
| 38 |
hide("node10", "node11", "node12", "node13", "node14", "node15", "node16", "node20", "node21", "node23", "node24", "node30", "node31", "node80", "node81", "node82", "node83", "node85", "node86") |
| 39 |
end, |
| 40 |
|
| 41 |
------------------------------ |
| 42 |
-- c-net-nethack_sub |
| 43 |
-- |
| 44 |
{ |
| 45 |
topic = "c-net-nethack_sub", |
| 46 |
generator = include("c-net-nethack_sub"), |
| 47 |
}, |
| 48 |
-- |
| 49 |
------------------------------ |
| 50 |
|
| 51 |
{ |
| 52 |
id = "node0", |
| 53 |
--; TRANSLATORS: use lowercase for translation |
| 54 |
text = _"guest", |
| 55 |
echo_text = false, |
| 56 |
code = function() |
| 57 |
c_net_username = Tux:get_player_name() |
| 58 |
c_net_prompt = c_net_username .. "@c-net:~$" |
| 59 |
--; TRANSLATORS: use lowercase for translation |
| 60 |
Tux:says(_"guest", "NO_WAIT") |
| 61 |
if (not c_net_terminal_logged_in) then |
| 62 |
c_net_terminal_logged_in = true |
| 63 |
Npc:says(_"First time login detected.") |
| 64 |
Npc:says(_"Please enter your name", "NO_WAIT") |
| 65 |
cli_says(_"Name : ", "NO_WAIT") |
| 66 |
Tux:says(c_net_username) |
| 67 |
--; TRANSLATORS: %s = c_net_username |
| 68 |
Npc:says(_"Please set password for your personalized guest login, %s", c_net_username, "NO_WAIT") |
| 69 |
Npc:says(_"Use at least one lower case letter, one upper case letter, one number, and one symbol.", "NO_WAIT") |
| 70 |
cli_says(_"Password : ", "NO_WAIT") |
| 71 |
Tux:says(_"******") |
| 72 |
else |
| 73 |
cli_says(_"Name : ", "NO_WAIT") |
| 74 |
Tux:says(c_net_username, "NO_WAIT") |
| 75 |
cli_says(_"Password : ", "NO_WAIT") |
| 76 |
Tux:says(_"******", "NO_WAIT") |
| 77 |
end |
| 78 |
Npc:says(_"Last login from /dev/tty3 on unknown", "NO_WAIT") |
| 79 |
cli_says(c_net_prompt, "NO_WAIT") |
| 80 |
show("node10", "node20", "node30", "node80", "node99") hide("node0", "node1", "node2", "node3") |
| 81 |
end, |
| 82 |
}, |
| 83 |
{ |
| 84 |
id = "node1", |
| 85 |
text = "root", |
| 86 |
echo_text = false, |
| 87 |
code = function() |
| 88 |
Tux:says("root", "NO_WAIT") |
| 89 |
cli_says(_"Password : ", "NO_WAIT") |
| 90 |
Tux:says("******") |
| 91 |
--if (not knows_root_password) then |
| 92 |
next("node9") |
| 93 |
--else |
| 94 |
-- c_net_username = "root" |
| 95 |
-- c_net_prompt = c_net_username .. "@c-net:~$" |
| 96 |
-- Npc:says(_"Last login from /dev/tty3 on unknown" , "NO_WAIT") |
| 97 |
-- cli_says(c_net_prompt, "NO_WAIT") |
| 98 |
-- show("node10", "node20", "node30", "node80", "node99") hide("node0", "node1", "node2", "node3") |
| 99 |
--end |
| 100 |
end, |
| 101 |
}, |
| 102 |
{ |
| 103 |
id = "node2", |
| 104 |
text = "lily", |
| 105 |
echo_text = false, |
| 106 |
code = function() |
| 107 |
Tux:says("lily", "NO_WAIT") |
| 108 |
cli_says(_"Password : ", "NO_WAIT") |
| 109 |
if (not know_lily_password) then |
| 110 |
Tux:says("******") |
| 111 |
next("node9") |
| 112 |
else |
| 113 |
Tux:says("****") |
| 114 |
c_net_username = "lily" |
| 115 |
c_net_prompt = c_net_username .. "@c-net:~$" |
| 116 |
Npc:says(_"Last login from /dev/tty3 on unknown" , "NO_WAIT") |
| 117 |
cli_says(c_net_prompt, "NO_WAIT") |
| 118 |
show("node10", "node20", "node30", "node80", "node99") hide("node0", "node1", "node2", "node3") |
| 119 |
end |
| 120 |
end, |
| 121 |
}, |
| 122 |
{ |
| 123 |
id = "node3", |
| 124 |
text = "cpain", |
| 125 |
echo_text = false, |
| 126 |
code = function() |
| 127 |
Tux:says("cpain", "NO_WAIT") |
| 128 |
cli_says(_"Password: ", "NO_WAIT") |
| 129 |
--if (not knows_sorenson_password) then |
| 130 |
Tux:says("******") |
| 131 |
next("node9") |
| 132 |
--else |
| 133 |
-- Tux:says("************************************") |
| 134 |
-- c_net_username = "cpain" |
| 135 |
-- c_net_prompt = c_net_username .. "@c-net:~$" |
| 136 |
-- Npc:says(_"Last login from /dev/tty3 on unknown" , "NO_WAIT") |
| 137 |
-- cli_says(c_net_prompt, "NO_WAIT") |
| 138 |
-- show("node10", "node20", "node30", "node80", "node99") hide("node0", "node1", "node2", "node3") |
| 139 |
--end |
| 140 |
end, |
| 141 |
}, |
| 142 |
{ |
| 143 |
id = "node9", |
| 144 |
code = function() |
| 145 |
Npc:says(_"Login incorrect", "NO_WAIT") |
| 146 |
Npc:says(_"Connection to c-net terminated.") |
| 147 |
play_sound("effects/Menu_Item_Selected_Sound_1.ogg") |
| 148 |
end_dialog() |
| 149 |
end, |
| 150 |
}, |
| 151 |
{ |
| 152 |
-- ../ date finger users whoami |
| 153 |
id = "node10", |
| 154 |
text = "cd info_commands/", |
| 155 |
echo_text = false, |
| 156 |
code = function() |
| 157 |
c_net_prompt = c_net_username .. "@c-net:~/info_commands$" |
| 158 |
Npc:says(" ", "NO_WAIT") |
| 159 |
cli_says(c_net_prompt, "NO_WAIT") |
| 160 |
show("node11", "node12", "node13", "node14", "node15", "node16") hide("node10", "node20", "node30", "node80", "node99") |
| 161 |
end, |
| 162 |
}, |
| 163 |
{ |
| 164 |
id = "node11", |
| 165 |
text = "cd ../", |
| 166 |
echo_text = false, |
| 167 |
code = function() |
| 168 |
c_net_prompt = c_net_username .. "@c-net:~$" |
| 169 |
Npc:says(" ", "NO_WAIT") |
| 170 |
cli_says(c_net_prompt, "NO_WAIT") |
| 171 |
show("node10", "node20", "node30", "node80", "node99") hide("node11", "node12", "node13", "node14", "node15", "node16") |
| 172 |
end, |
| 173 |
}, |
| 174 |
{ |
| 175 |
id = "node12", |
| 176 |
text = "date", |
| 177 |
echo_text = false, |
| 178 |
code = function() |
| 179 |
Tux:says("date", "NO_WAIT") |
| 180 |
local day, hour, minute = game_date() |
| 181 |
--; TRANSLATORS: It shows the ingame date in format: Day day, hour:minute |
| 182 |
Npc:says(_"Day %d, %02d:%02d", day, hour, minute, "NO_WAIT") |
| 183 |
cli_says(c_net_prompt, "NO_WAIT") |
| 184 |
end, |
| 185 |
}, |
| 186 |
{ |
| 187 |
id = "node13", |
| 188 |
text = "finger", |
| 189 |
echo_text = false, |
| 190 |
code = function() |
| 191 |
Tux:says("finger", "NO_WAIT") |
| 192 |
knows_c_net_users = true |
| 193 |
--; TRANSLATORS: this represents the head of a table |
| 194 |
Npc:says(_"Login Tty Name", "NO_WAIT") |
| 195 |
Npc:says("bossman tty7 Spencer", "NO_WAIT") |
| 196 |
Npc:says("cpain tty5 Sorenson", "NO_WAIT") |
| 197 |
--; TRANSLATORS: %s=Tux:get_player_name() |
| 198 |
Npc:says("guest tty3 %s ", Tux:get_player_name(), "NO_WAIT") |
| 199 |
Npc:says("lily tty2 Lily Stone", "NO_WAIT") |
| 200 |
cli_says(c_net_prompt, "NO_WAIT") |
| 201 |
end, |
| 202 |
}, |
| 203 |
{ |
| 204 |
id = "node14", |
| 205 |
text = "users", |
| 206 |
echo_text = false, |
| 207 |
code = function() |
| 208 |
Tux:says("users", "NO_WAIT") |
| 209 |
Npc:says("bossman cpain guest lily", "NO_WAIT") |
| 210 |
knows_c_net_users = true |
| 211 |
cli_says(c_net_prompt, "NO_WAIT") |
| 212 |
end, |
| 213 |
}, |
| 214 |
{ |
| 215 |
id = "node15", |
| 216 |
text = "whoami", |
| 217 |
echo_text = false, |
| 218 |
code = function() |
| 219 |
Tux:says("whoami", "NO_WAIT") |
| 220 |
Npc:says(c_net_username, "NO_WAIT") |
| 221 |
cli_says(c_net_prompt, "NO_WAIT") |
| 222 |
end, |
| 223 |
}, |
| 224 |
{ |
| 225 |
id = "node16", |
| 226 |
text = "uname", |
| 227 |
echo_text = false, |
| 228 |
code = function() |
| 229 |
Tux:says("uname", "NO_WAIT") |
| 230 |
Npc:says("Nkernel", "NO_WAIT") |
| 231 |
cli_says(c_net_prompt, "NO_WAIT") |
| 232 |
end, |
| 233 |
}, |
| 234 |
{ |
| 235 |
-- ../ ls readdrive ./statistics.pl |
| 236 |
id = "node20", |
| 237 |
text = "cd file_commands/", |
| 238 |
echo_text = false, |
| 239 |
code = function() |
| 240 |
c_net_prompt = c_net_username .. "@c-net:~/file_commands$" |
| 241 |
Npc:says(" ", "NO_WAIT") |
| 242 |
cli_says(c_net_prompt, "NO_WAIT") |
| 243 |
show("node21", "node23", "node24", "node70") hide("node10", "node20", "node30", "node80", "node99") |
| 244 |
end, |
| 245 |
}, |
| 246 |
{ |
| 247 |
id = "node21", |
| 248 |
text = "cd ../", |
| 249 |
echo_text = false, |
| 250 |
code = function() |
| 251 |
c_net_prompt = c_net_username .. "@c-net:~$" |
| 252 |
Npc:says(" ", "NO_WAIT") |
| 253 |
cli_says(c_net_prompt, "NO_WAIT") |
| 254 |
show("node10", "node20", "node30", "node80", "node99") hide("node21", "node23", "node24", "node70") |
| 255 |
end, |
| 256 |
}, |
| 257 |
{ |
| 258 |
id = "node23", |
| 259 |
text = _"mountdisk.sh", |
| 260 |
echo_text = false, |
| 261 |
code = function() |
| 262 |
Tux:says(_"./mountdisk.sh", "NO_WAIT") |
| 263 |
if (Tux:has_item_backpack("Kevin's Data Cube")) then |
| 264 |
Npc:says(_"Mounting volume \"Kevins_Security_File\"...") |
| 265 |
Npc:says(_"Private memory and/or virtual address space exhausted.", "NO_WAIT") |
| 266 |
Npc:says(_"Not enough free memory to load data file.", "NO_WAIT") |
| 267 |
elseif (Tux:has_quest("Deliverance")) and |
| 268 |
(not Tux:done_quest("Deliverance")) and |
| 269 |
(Tux:has_item_backpack("Data cube")) then |
| 270 |
Npc:says(_"List for Spencer:") |
| 271 |
Npc:says("Alastra, Maria Grazia", "NO_WAIT") |
| 272 |
Npc:says("Arana, Pedro", "NO_WAIT") |
| 273 |
Npc:says("Badea, Catalin", "NO_WAIT") |
| 274 |
Npc:says("Bourdon, Pierre", "NO_WAIT") |
| 275 |
Npc:says("Castellan, Simon", "NO_WAIT") |
| 276 |
Npc:says("Cipicchio, Ted", "NO_WAIT") |
| 277 |
Npc:says("Danakian, Hike", "NO_WAIT") |
| 278 |
Npc:says("Degrande, Samuel", "NO_WAIT") |
| 279 |
Npc:says("Gill, Andrew A. ", "NO_WAIT") |
| 280 |
Npc:says("Griffiths, Ian", "NO_WAIT") |
| 281 |
Npc:says("Hagman, Nick", "NO_WAIT") |
| 282 |
Npc:says("Herron, Clint", "NO_WAIT") |
| 283 |
Npc:says("Huillet, Arthur", "NO_WAIT") |
| 284 |
Npc:says("Huszics, Stefan", "NO_WAIT") |
| 285 |
Npc:says("Infrared", "NO_WAIT") |
| 286 |
Npc:says("James", "NO_WAIT") |
| 287 |
Npc:says("Kangas, Stefan", "NO_WAIT") |
| 288 |
Npc:says("Kremer, David", "NO_WAIT") |
| 289 |
Npc:says("Kruger, Matthias", "NO_WAIT") |
| 290 |
Npc:says("Kucia, Jozef", "NO_WAIT") |
| 291 |
Npc:says("Matei, Pavaluca", "NO_WAIT") |
| 292 |
Npc:says("McCammon, Miles", "NO_WAIT") |
| 293 |
Npc:says("Mendelson, Michael", "NO_WAIT") |
| 294 |
Npc:says("Mourujarvi, Esa-Matti", "NO_WAIT") |
| 295 |
Npc:says("Mustonen, Ari", "NO_WAIT") |
| 296 |
Npc:says("Newton, Simon", "NO_WAIT") |
| 297 |
Npc:says("Offermann, Sebastian", "NO_WAIT") |
| 298 |
Npc:says("Parramore, Kurtis", "NO_WAIT") |
| 299 |
Npc:says("Pepin-Perreault, Nicolas") |
| 300 |
Npc:says("Picciani, Arvid", "NO_WAIT") |
| 301 |
Npc:says("Pitoiset, Samuel", "NO_WAIT") |
| 302 |
Npc:says("Pradet, Quentin", "NO_WAIT") |
| 303 |
Npc:says("Prix, Johannes", "NO_WAIT") |
| 304 |
Npc:says("Prix, Reinhard", "NO_WAIT") |
| 305 |
Npc:says("rudi_s", "NO_WAIT") |
| 306 |
Npc:says("Ryushu, Zombie", "NO_WAIT") |
| 307 |
Npc:says("Salmela, Bastian", "NO_WAIT") |
| 308 |
Npc:says("Starminn", "NO_WAIT") |
| 309 |
Npc:says("Solovets, Alexander", "NO_WAIT") |
| 310 |
Npc:says("Swietlicki, Karol", "NO_WAIT") |
| 311 |
Npc:says("Tetar, Philippe", "NO_WAIT") |
| 312 |
Npc:says("Thor", "NO_WAIT") |
| 313 |
Npc:says("Voots, Ryan", "NO_WAIT") |
| 314 |
Npc:says("Wood, JK", "NO_WAIT") |
| 315 |
Npc:says("Winterer, Armin", "NO_WAIT") |
| 316 |
if (not deliverance_datacube_c_net_list) then |
| 317 |
Tux:update_quest("Deliverance", _"I found a terminal in the town which could read the data cube Francis gave me. It looks like there was a list of names on it, but I have no clue what's the deal with these names.") |
| 318 |
deliverance_datacube_c_net_list = true |
| 319 |
end |
| 320 |
else |
| 321 |
Npc:says(_"no disk found", "NO_WAIT") |
| 322 |
end |
| 323 |
cli_says(c_net_prompt, "NO_WAIT") |
| 324 |
end, |
| 325 |
}, |
| 326 |
{ |
| 327 |
id = "node24", |
| 328 |
text = _"statistics.pl", |
| 329 |
echo_text = false, |
| 330 |
code = function() |
| 331 |
Tux:says("./statistics.pl", "NO_WAIT") |
| 332 |
Npc:says(_"Corrupted file.", "NO_WAIT") |
| 333 |
-- Npc:says(_"Bot #Dead# Tux #Hacked/Failed#Ratio", "NO_WAIT") |
| 334 |
-- Npc:says(print_stats(),"NO_WAIT") |
| 335 |
cli_says(c_net_prompt, "NO_WAIT") |
| 336 |
end, |
| 337 |
}, |
| 338 |
{ |
| 339 |
id = "node30", |
| 340 |
text = "cd documents/", |
| 341 |
echo_text = false, |
| 342 |
code = function() |
| 343 |
c_net_prompt = c_net_username .. "@c-net:~/documents$" |
| 344 |
Tux:says("cd documents/", "NO_WAIT") |
| 345 |
if (c_net_username =="root") then |
| 346 |
show("node66") |
| 347 |
end |
| 348 |
--if (c_net_username == "guest") then |
| 349 |
--elseif (c_net_username =="lily") then -- no special files yet |
| 350 |
--elseif (c_net_username =="cpain") then -- no special files yet |
| 351 |
--end |
| 352 |
cli_says(c_net_prompt, "NO_WAIT") |
| 353 |
show("node31") hide("node10", "node20", "node30", "node80", "node99") |
| 354 |
end, |
| 355 |
}, |
| 356 |
{ |
| 357 |
id = "node31", |
| 358 |
text = "cd ../", |
| 359 |
echo_text = false, |
| 360 |
code = function() |
| 361 |
c_net_prompt = c_net_username .. "@c-net:~$" |
| 362 |
Npc:says(" ", "NO_WAIT") |
| 363 |
cli_says(c_net_prompt, "NO_WAIT") |
| 364 |
show("node10", "node20", "node30", "node80", "node99") hide("node31") |
| 365 |
end, |
| 366 |
}, |
| 367 |
{ |
| 368 |
id = "node66", |
| 369 |
text = _"forkBOMB.sh -arm bomb", |
| 370 |
code = function() |
| 371 |
Npc:says(_"bomb armed", "NO_WAIT") |
| 372 |
cli_says(c_net_prompt, "NO_WAIT") |
| 373 |
show("node67", "node68") |
| 374 |
end, |
| 375 |
}, |
| 376 |
{ |
| 377 |
id = "node67", |
| 378 |
text = _"forkBOMB.sh -disarm bomb", |
| 379 |
code = function() |
| 380 |
Npc:says(_"bomb defused", "NO_WAIT") |
| 381 |
cli_says("root@c-net:~$", "NO_WAIT") |
| 382 |
hide("node67", "node68") show("node66") |
| 383 |
end, |
| 384 |
}, |
| 385 |
{ |
| 386 |
id = "node68", |
| 387 |
text = _"forkBOMB.sh -execute", |
| 388 |
code = function() |
| 389 |
c_net_terminals_disabled = true |
| 390 |
display_big_message(_"Terminals Disabled") |
| 391 |
Npc:says(_"Script run. After logout this terminal will be disabled.", "NO_WAIT") |
| 392 |
cli_says(_"root@c-net:~$", "NO_WAIT") |
| 393 |
-- Tux:add_xp(30) -- Eventually make this a quest goal. |
| 394 |
end, |
| 395 |
}, |
| 396 |
{ |
| 397 |
id = "node70", |
| 398 |
text = _"radio.sh", |
| 399 |
code = function() |
| 400 |
--; TRANSLATORS: "tracks" refers to music songs/music |
| 401 |
Npc:says(_"Valid tracks:", "NO_WAIT") |
| 402 |
Npc:says("Ambience, Bleostrada, HellFortressEntrance, ImperialArmy, NewTutorialStage, TechBattle, TheBeginning, underground, AmbientBattle, hellforce, HellFortressTwo, menu, Suspicion, temple, town") |
| 403 |
|
| 404 |
local try_again_radio = true |
| 405 |
|
| 406 |
while (try_again_radio) do |
| 407 |
local track = user_input_string(_"please enter track") |
| 408 |
if (track == "Ambience" ) or |
| 409 |
(track == "AmbientBattle" ) or |
| 410 |
(track == "Bleostrada" ) or |
| 411 |
(track == "hellforce" ) or |
| 412 |
(track == "HellFortressEntrance" ) or |
| 413 |
(track == "HellFortressTwo" ) or |
| 414 |
(track == "ImperialArmy" ) or |
| 415 |
(track == "menu" ) or |
| 416 |
(track == "NewTutorialStage" ) or |
| 417 |
(track == "Suspicion" ) or |
| 418 |
(track == "TechBattle" ) or |
| 419 |
(track == "temple" ) or |
| 420 |
(track == "TheBeginning" ) or |
| 421 |
(track == "town" ) or |
| 422 |
(track == "underground" ) or |
| 423 |
(running_benchmark()) then |
| 424 |
switch_background_music(track .. ".ogg") |
| 425 |
town_track = track |
| 426 |
try_again_radio = false |
| 427 |
next("node20") |
| 428 |
elseif (track == "exit" ) then |
| 429 |
try_again_radio = false |
| 430 |
next("node20") |
| 431 |
else |
| 432 |
--; TRANSLATORS: "tracks" refers to music songs/music |
| 433 |
Npc:says(_"WARNING, '%s' not a valid track.", track) |
| 434 |
--; TRANSLATORS: "'exit'" must not be translated |
| 435 |
Npc:says(_"enter 'exit' to exit.") |
| 436 |
Npc:says(_"Please retry.") |
| 437 |
Npc:says(_"Valid tracks:", "NO_WAIT") |
| 438 |
Npc:says("Ambience, Bleostrada, HellFortressEntrance, ImperialArmy, NewTutorialStage, TechBattle, TheBeginning, underground, AmbientBattle, hellforce, HellFortressTwo, menu, Suspicion, temple, town") |
| 439 |
end |
| 440 |
end |
| 441 |
|
| 442 |
end, |
| 443 |
}, |
| 444 |
{ |
| 445 |
id = "node80", |
| 446 |
text = "cd games/", |
| 447 |
echo_text = false, |
| 448 |
code = function() |
| 449 |
Npc:says(" ", "NO_WAIT") |
| 450 |
c_net_prompt = c_net_username .. "@c-net:~/games$" |
| 451 |
cli_says(c_net_prompt, "NO_WAIT") |
| 452 |
show("node81", "node82", "node83", "node85", "node86") hide("node10", "node20", "node30", "node80", "node99") |
| 453 |
end, |
| 454 |
}, |
| 455 |
{ |
| 456 |
id = "node81", |
| 457 |
text = "cd ../", |
| 458 |
echo_text = false, |
| 459 |
code = function() |
| 460 |
c_net_prompt = c_net_username .. "@c-net:~$" |
| 461 |
Npc:says(" ", "NO_WAIT") |
| 462 |
cli_says(c_net_prompt, "NO_WAIT") |
| 463 |
show("node10", "node20", "node30", "node80", "node99") hide("node81", "node82", "node83", "node85", "node86") |
| 464 |
end, |
| 465 |
}, |
| 466 |
{ |
| 467 |
id = "node82", |
| 468 |
text = "nethack", |
| 469 |
echo_text = false, |
| 470 |
code = function() |
| 471 |
Tux:says("./nethack", "NO_WAIT") |
| 472 |
push_topic("c-net-nethack_sub") |
| 473 |
-- call c-net-nethack_sub subdialog |
| 474 |
next("c-net-nethack_sub.everytime") |
| 475 |
end, |
| 476 |
}, |
| 477 |
{ |
| 478 |
-- called after the end of c-net-nethack_sub subdialog |
| 479 |
id = "after-c-net-nethack_sub", |
| 480 |
code = function() |
| 481 |
pop_topic() |
| 482 |
cli_says(c_net_prompt, "NO_WAIT") |
| 483 |
end, |
| 484 |
}, |
| 485 |
{ |
| 486 |
id = "node83", |
| 487 |
text = _"global_thermonuclear_war", |
| 488 |
echo_text = false, |
| 489 |
code = function() |
| 490 |
Tux:says(_"./global_thermonuclear_war", "NO_WAIT") |
| 491 |
Npc:says_random(_"Sorry, only winning move is not to play. New game?", |
| 492 |
_"Mankind exterminated. You lost!", |
| 493 |
_"No victory possible. LOSER! Play again?", |
| 494 |
_"Everyone dies, new game?", "NO_WAIT") |
| 495 |
cli_says(c_net_prompt, "NO_WAIT") |
| 496 |
end, |
| 497 |
}, |
| 498 |
{ |
| 499 |
id = "node85", |
| 500 |
text = _"tetris", |
| 501 |
echo_text = false, |
| 502 |
code = function() |
| 503 |
Tux:says(_"./tetris", "NO_WAIT") |
| 504 |
Npc:says("Never gonna give you up,") |
| 505 |
Npc:says("Never gonna let you down,") |
| 506 |
Npc:says("Never gonna run around and desert you.") |
| 507 |
Npc:says("Never gonna make you cry,") |
| 508 |
Npc:says("Never gonna say goodbye,") |
| 509 |
Npc:says("Never gonna tell a lie and hurt you.") |
| 510 |
--left out gettext markers on purpose |
| 511 |
cli_says(c_net_prompt, "NO_WAIT") |
| 512 |
hide("node85") |
| 513 |
end, |
| 514 |
}, |
| 515 |
{ |
| 516 |
id = "node86", |
| 517 |
text = "progress_quest", |
| 518 |
echo_text = false, |
| 519 |
code = function() |
| 520 |
Tux:says("./progress_quest", "NO_WAIT") |
| 521 |
if (not playing_progress_quest) then |
| 522 |
playing_progress_quest = true |
| 523 |
Npc:says(_"Roll your Stats.") |
| 524 |
hide("node81", "node82", "node83", "node85", "node86") |
| 525 |
next("node87") |
| 526 |
else |
| 527 |
Npc:says(_"You are already playing Progress Quest:") |
| 528 |
Npc:says_random(_"You are selling an item!", |
| 529 |
_"You are killing a creature!", |
| 530 |
_"You are gaining a level!", |
| 531 |
_"You are casting a spell!") |
| 532 |
cli_says(c_net_prompt, "NO_WAIT") |
| 533 |
end |
| 534 |
end, |
| 535 |
}, |
| 536 |
{ |
| 537 |
id = "node87", |
| 538 |
code = function() |
| 539 |
local str = math.random(0,6) + math.random(0,6) + math.random(0,6) |
| 540 |
local con = math.random(0,6) + math.random(0,6) + math.random(0,6) |
| 541 |
local dex = math.random(0,6) + math.random(0,6) + math.random(0,6) |
| 542 |
local int = math.random(0,6) + math.random(0,6) + math.random(0,6) |
| 543 |
local wis = math.random(0,6) + math.random(0,6) + math.random(0,6) |
| 544 |
local cha = math.random(0,6) + math.random(0,6) + math.random(0,6) |
| 545 |
Npc:says(_"You rolled Stats of STR: [b]%d[/b], CON: [b]%d[/b], DEX: [b]%d[/b], INT: [b]%d[/b], WIS: [b]%d[/b], CHA: [b]%d[/b].", str, con, dex, int, wis, cha, "NO_WAIT") |
| 546 |
show("node88", "node89") |
| 547 |
end, |
| 548 |
}, |
| 549 |
{ |
| 550 |
id = "node88", |
| 551 |
text = _"Accept Character", |
| 552 |
echo_text = false, |
| 553 |
code = function() |
| 554 |
--; TRANSLATORS: "Progress Quest" should not be translated |
| 555 |
Npc:says(_"Welcome to Progress Quest!") |
| 556 |
cli_says(c_net_prompt, "NO_WAIT") |
| 557 |
show("node81", "node82", "node83", "node85", "node86") hide("node88", "node89") |
| 558 |
end, |
| 559 |
}, |
| 560 |
{ |
| 561 |
id = "node89", |
| 562 |
text = _"Reroll Character", |
| 563 |
echo_text = false, |
| 564 |
code = function() |
| 565 |
next("node87") |
| 566 |
end, |
| 567 |
}, |
| 568 |
{ |
| 569 |
id = "node99", |
| 570 |
text = "logout", |
| 571 |
echo_text = false, |
| 572 |
code = function() |
| 573 |
Tux:says("logout", "NO_WAIT") |
| 574 |
--; TRANSLATORS: "c-net" should probably not be translated |
| 575 |
Npc:says(_"Connection to c-net closed.") |
| 576 |
-- set_internet_login_time() |
| 577 |
play_sound("effects/Menu_Item_Selected_Sound_1.ogg") |
| 578 |
end_dialog() |
| 579 |
end, |
| 580 |
}, |
| 581 |
} |