----------------------------------------------------------------------
 * This file is part of Freedroid
 *
 * Freedroid is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 *
 * Freedroid is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Freedroid; see the file COPYING. If not, write to the 
 * Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, 
 * MA 02111-1307 USA
----------------------------------------------------------------------


If you have questions concerning FreedroidRPG, please send an email to:

freedroid-discussion@lists.sourceforge.net


Beginning of new chat dialog for character="XXXXX"
----------------------------------------------------------------------

<EveryTime LuaCode> 
--	name = get_player_name() -- We need to generate the option text of option 0 to use this properly
	if (has_cookie("terminals_disabled")) then
		npc_says(_" . ")
		end_dialog()
	else
		npc_says(_"Welcome to the Community Network.", "NO_WAIT")
		cli_says(_"Login : ", "NO_WAIT")
		if has_cookie("knows_c-net_users") then show(0, 1, 2, 3, 99) else show(0, 99) end
	end
	hide(10, 11, 12, 13, 14, 15, 16, 20, 21, 23, 24, 30, 31, 80, 81, 82, 83, 85, 86)
</LuaCode>
----------------------------------------------------------------------

Nr=0 Text="guest"
NO_TEXT
<LuaCode>
	username = get_player_name()
	terminal = username .. "@c-net:~$"
	tux_says("guest", "NO_WAIT")
	if (not has_cookie("terminal_logged_in")) then
		add_cookie("terminal_logged_in") 
		npc_says(_"First time login detected.")
		npc_says(_"Please enter your name", "NO_WAIT")
		cli_says(_"Name : ", "NO_WAIT")
		tux_says(username)
		npc_says(_"Please set password for your personalized guest login ".. username, "NO_WAIT")
		npc_says(_"Use at least one lower case letter, one upper case letter, one number, and one symbol.", "NO_WAIT")
		cli_says(_"Password : ", "NO_WAIT")
		tux_says("******")
	else
		cli_says(_"Name : ", "NO_WAIT")
		tux_says(username, "NO_WAIT")
		cli_says(_"Password : ", "NO_WAIT")
		tux_says("******", "NO_WAIT")
	end
	npc_says(_"Last login from dev/tty3 on unknown", "NO_WAIT")
	cli_says(terminal, "NO_WAIT")
	show(10, 20, 30, 80, 99) hide(0, 1, 2, 3)
</LuaCode>
----------------------------------------------------------------------

Nr=1 Text="root"
NO_TEXT
<LuaCode>
	tux_says("root", "NO_WAIT")
	cli_says(_"Password : ", "NO_WAIT")
	tux_says("******")
	--if (not has_cookie("knows_root_password")) then
		next(9)
	--else
	--	username = "root"
	--	terminal = username .. "@c-net:~$"
	--	npc_says(_"Last login from dev/tty3 on unknown" , "NO_WAIT")
	--	cli_says(terminal, "NO_WAIT")
	--	show(10, 20, 30, 80, 99) hide(0, 1, 2, 3)
	--end
</LuaCode>
----------------------------------------------------------------------

Nr=2 Text="lily"
NO_TEXT
<LuaCode>
	tux_says("lily", "NO_WAIT")
	cli_says(_"Password : ", "NO_WAIT")
	tux_says("******")
	if (not has_cookie("know_lily_password")) then
		next(9)
	else
		username = "lily"
		terminal = username .. "@c-net:~$"
		npc_says(_"Last login from dev/tty3 on unknown" , "NO_WAIT")
		cli_says(terminal, "NO_WAIT")
		show(10, 20, 30, 80, 99) hide(0, 1, 2, 3)
	end
</LuaCode>
----------------------------------------------------------------------

Nr=3 Text="cpain"
NO_TEXT
<LuaCode>
	tux_says("cpain", "NO_WAIT")
	cli_says(_"Password: ", "NO_WAIT")
	--if (not has_cookie("knows_sorenson_password")) then
		tux_says("******")
		next(9)
	--else
	--	tux_says("************************************")
	--	username = "cpain"
	--	terminal = username .. "@c-net:~$"
	--	npc_says(_"Last login from dev/tty3 on unknown" , "NO_WAIT")
	--	cli_says(terminal, "NO_WAIT")
	--	show(10, 20, 30, 80, 99) hide(0, 1, 2, 3)
	--end
</LuaCode>
----------------------------------------------------------------------

Nr=9 Text="BUG, REPORT ME! cnet node9" 
NO_TEXT
<LuaCode>
	npc_says(_"Login incorrect", "NO_WAIT")
	npc_says(_"Connection to c-net terminated.")
	end_dialog()
</LuaCode>
----------------------------------------------------------------------

Nr=10 Text="cd info_commands/" -- ../ date finger users whoami 
NO_TEXT
<LuaCode>
	terminal = username .. "@c-net:~/info_commands$"
	npc_says(" ", "NO_WAIT")
	cli_says(terminal, "NO_WAIT")
	show(11, 12, 13, 14, 15, 16) hide(10, 20, 30, 80, 99)
</LuaCode>
----------------------------------------------------------------------

Nr=11 Text="cd ../"
NO_TEXT
<LuaCode>
	terminal = username .. "@c-net:~$"
	npc_says(" ", "NO_WAIT")
	cli_says(terminal, "NO_WAIT")
	show(10, 20, 30, 80, 99) hide(11, 12, 13, 14, 15, 16)
</LuaCode>
----------------------------------------------------------------------

Nr=12 Text="date"
NO_TEXT
<LuaCode>
--	npc_says(get_date() ,"NO_WAIT")
	tux_says("date", "NO_WAIT")
	npc_says(_"Date unknown", "NO_WAIT")
	cli_says(terminal, "NO_WAIT")
</LuaCode>
----------------------------------------------------------------------

Nr=13 Text="finger"
NO_TEXT
<LuaCode>
	tux_says("finger", "NO_WAIT")
	if (not has_cookie("knows_c-net_users")) then add_cookie("knows_c-net_users") end
	npc_says("Login	Tty	Name", "NO_WAIT")
	npc_says("bossman	tty7	Spencer", "NO_WAIT")
	npc_says("cpain	tty5	Sorenson", "NO_WAIT")
	npc_says("guest	tty3	" .. get_player_name() .. "", "NO_WAIT")
	npc_says("lily	tty2	Lily Stone", "NO_WAIT")
	cli_says(terminal, "NO_WAIT")
</LuaCode>
----------------------------------------------------------------------

Nr=14 Text="users"
NO_TEXT
<LuaCode>
	tux_says("users", "NO_WAIT")
	npc_says("bossman cpain guest lily", "NO_WAIT")
	if (not has_cookie("knows_c-net_users")) then add_cookie("knows_c-net_users") end
	cli_says(terminal, "NO_WAIT")
</LuaCode>
----------------------------------------------------------------------

Nr=15 Text="whoami"
NO_TEXT
<LuaCode>
	tux_says("whoami", "NO_WAIT")
	npc_says(username, "NO_WAIT")
	cli_says(terminal, "NO_WAIT")
</LuaCode>
----------------------------------------------------------------------

Nr=16 Text="uname"
NO_TEXT
<LuaCode>
	tux_says("uname", "NO_WAIT")
	npc_says("Nkernel", "NO_WAIT")
	cli_says(terminal, "NO_WAIT")
</LuaCode>
----------------------------------------------------------------------

Nr=20 Text="cd file_commands/" -- ../ ls readdrive ./statistics.pl
NO_TEXT
<LuaCode>
	terminal = username .. "@c-net:~/file_commands$"
	npc_says(" ", "NO_WAIT")
	cli_says(terminal, "NO_WAIT")
	show(21, 23, 24) hide(10, 20, 30, 80, 99)
</LuaCode>
----------------------------------------------------------------------

Nr=21 Text="cd ../"
NO_TEXT
<LuaCode>
	terminal = username .. "@c-net:~$"
	npc_says(" ", "NO_WAIT")
	cli_says(terminal, "NO_WAIT")
	show(10, 20, 30, 80, 99) hide(21, 23, 24)
</LuaCode>
----------------------------------------------------------------------

--Nr=22 Text="ls"
NO_TEXT
<LuaCode>
	tux_says("ls", "NO_WAIT")
	npc_says(".", "NO_WAIT")
	npc_says("mountdisk.sh@", "NO_WAIT")
	npc_says("statistics.pl*", "NO_WAIT")
	cli_says(terminal, "NO_WAIT")
	show(23, 24)
</LuaCode>
----------------------------------------------------------------------

Nr=23 Text=_"mountdisk.sh"
NO_TEXT
<LuaCode>
	tux_says(_"./mountdisk.sh", "NO_WAIT")
	if (has_item_backpack("Kevin's Data Cube") > 0) then
		npc_says(_"Mounting volume \"Kevins_Security_File\"...")
		npc_says(_"Private memory and/or virtual address space exhausted.", "NO_WAIT")
		npc_says(_"Not enough free memory to load data file.", "NO_WAIT")
	elseif (has_quest(_"Deliverance") and (not done_quest(_"Deliverance")) and (has_item_backpack("Data cube") >0)) then
		npc_says(_"List for Spencer:")
		npc_says("Alastra, Maria Grazia", "NO_WAIT")
		npc_says("Arana, Pedro", "NO_WAIT")
		npc_says("Badea, Catalin", "NO_WAIT")
		npc_says("Bourdon, Pierre", "NO_WAIT")
		npc_says("Castellan, Simon", "NO_WAIT")
		npc_says("Cipicchio, Ted", "NO_WAIT")
		npc_says("Danakian, Hike", "NO_WAIT")
		npc_says("Degrande, Samuel", "NO_WAIT")
		npc_says("Gill, Andrew A. ", "NO_WAIT")
		npc_says("Griffiths, Ian", "NO_WAIT")
		npc_says("Hagman, Nick", "NO_WAIT")
		npc_says("Herron, Clint", "NO_WAIT")
		npc_says("Huillet, Arthur", "NO_WAIT")
		npc_says("Huszics, Stefan", "NO_WAIT")
		npc_says("Infrared", "NO_WAIT")
		npc_says("James", "NO_WAIT")
		npc_says("Kangas, Stefan", "NO_WAIT")
		npc_says("Kremer, David", "NO_WAIT")
		npc_says("Kruger, Matthias", "NO_WAIT")
		npc_says("Kucia, Jozef", "NO_WAIT")
		npc_says("Matei, Pavaluca", "NO_WAIT")
		npc_says("McCammon, Miles", "NO_WAIT")
		npc_says("Mendelson, Michael", "NO_WAIT")
		npc_says("Mourujarvi, Esa-Matti", "NO_WAIT")
		npc_says("Mustonen, Ari", "NO_WAIT")
		npc_says("Newton, Simon", "NO_WAIT")
		npc_says("Offermann, Sebastian", "NO_WAIT")
		npc_says("Parramore, Kurtis", "NO_WAIT")
		npc_says("Pepin-Perreault, Nicolas")
		npc_says("Picciani, Arvid", "NO_WAIT")
		npc_says("Pitoiset, Samuel", "NO_WAIT")
		npc_says("Pradet, Quentin", "NO_WAIT")
		npc_says("Prix, Johannes", "NO_WAIT")
		npc_says("Prix, Reinhard", "NO_WAIT")
		npc_says("rudi_s", "NO_WAIT")
		npc_says("Ryushu, Zombie", "NO_WAIT")
		npc_says("Salmela, Bastian", "NO_WAIT")
		npc_says("Starminn", "NO_WAIT")
		npc_says("Solovets, Alexander", "NO_WAIT")
		npc_says("Swietlicki, Karol", "NO_WAIT")
		npc_says("Tetar, Philippe", "NO_WAIT")
		npc_says("Thor", "NO_WAIT")
		npc_says("Voots, Ryan", "NO_WAIT")
		npc_says("Wood, JK", "NO_WAIT")
		npc_says("Winterer, Armin", "NO_WAIT")
		if (not has_cookie("deliverance_datacube_c-net_list")) then
			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.")
			add_cookie("deliverance_datacube_c-net_list")
		end
	else
		npc_says(_"no disk found", "NO_WAIT")
	end
	cli_says(terminal, "NO_WAIT")
</LuaCode>
----------------------------------------------------------------------

Nr=24 Text=_"statistics.pl"
NO_TEXT
<LuaCode>
	tux_says("./statistics.pl", "NO_WAIT")
	npc_says(_"Corrupted file.", "NO_WAIT")
--	npc_says(_"Bot #Dead# Tux #Hacked/Failed#Ratio", "NO_WAIT")
--	npc_says(print_stats(),"NO_WAIT")
	cli_says(terminal, "NO_WAIT")
</LuaCode>
----------------------------------------------------------------------

Nr=30 Text="cd documents/"
NO_TEXT
<LuaCode>
	terminal = username .. "@c-net:~/documents$"
	tux_says("cd documents/ ", "NO_WAIT")
	if (username == _"guest") then
	elseif (username =="root") then
		show(66)
	elseif (username =="lily") then -- no special files yet
	elseif (username =="cpain") then -- no special files yet
	end
	cli_says(terminal, "NO_WAIT")
	show(31) hide(10, 20, 30, 80, 99)
</LuaCode>
----------------------------------------------------------------------

Nr=31 Text="cd ../"
NO_TEXT
<LuaCode>
	terminal = username .. "@c-net:~$"
	npc_says(" ", "NO_WAIT")
	cli_says(terminal, "NO_WAIT")
	show(10, 20, 30, 80, 99) hide(31)
</LuaCode>
----------------------------------------------------------------------

Nr=66 Text=_"forkBOMB.sh -arm bomb"
<LuaCode>
	npc_says(_"bomb armed", "NO_WAIT")
	cli_says(terminal, "NO_WAIT")
	show(67, 68)
</LuaCode>
----------------------------------------------------------------------

Nr=67 Text=_"forkBOMB.sh -disarm bomb"
<LuaCode>
	npc_says(_"bomb defused", "NO_WAIT")
	cli_says("root@c-net:~$", "NO_WAIT")
	hide(67, 68) show(66)
</LuaCode>
----------------------------------------------------------------------

Nr=68 Text=_"forkBOMB.sh -execute"
<LuaCode>
	add_cookie("terminals_disabled")
	display_big_message("Terminals Disabled")
	npc_says(_"Script run. After logout this terminal will be disabled.", "NO_WAIT")
	cli_says(_"root@c-net:~$", "NO_WAIT")
--	add_xp(30) -- Eventually make this a quest goal.
</LuaCode>
----------------------------------------------------------------------

Nr=80 Text="cd games/"
NO_TEXT
<LuaCode>
	npc_says(" ", "NO_WAIT")
	terminal = username .. "@c-net:~/games$"
	cli_says(terminal, "NO_WAIT")
	show(81, 82, 83, 85, 86) hide(10, 20, 30, 80, 99)
</LuaCode>
----------------------------------------------------------------------

Nr=81 Text="cd ../"
NO_TEXT
<LuaCode>
	terminal = username .. "@c-net:~$"
	npc_says(" ", "NO_WAIT")
	cli_says(terminal, "NO_WAIT")
	show(10, 20, 30, 80, 99) hide(81, 82, 83, 85, 86)
</LuaCode>
----------------------------------------------------------------------

Nr=82 Text="nethack"
NO_TEXT
<LuaCode>
	tux_says("./nethack", "NO_WAIT")
	run_subdialog("c-net_sub_nethack.dialog")
	cli_says(terminal, "NO_WAIT")
</LuaCode>
----------------------------------------------------------------------

Nr=83 Text=_"global_thermonuclear_war"
NO_TEXT
<LuaCode>
	tux_says(_"./global_thermonuclear_war", "NO_WAIT")
	npc_says_random(_"Sorry, only winning move is not to play. New game?", _"Mankind exterminated. You lost!", _"No victory possible. LOSER! Play again?", _"Everyone dies, new game?", "NO_WAIT")
	cli_says(terminal, "NO_WAIT")
</LuaCode>
----------------------------------------------------------------------

Nr=85 Text=_"tetris"
NO_TEXT
<LuaCode>
	tux_says(_"./tetris", "NO_WAIT")
	npc_says("Never gonna give you up,")
	npc_says("Never gonna let you down,")
	npc_says("Never gonna run around and desert you.")
	npc_says("Never gonna make you cry,")
	npc_says("Never gonna say goodbye,")
	npc_says("Never gonna tell a lie and hurt you.")
	--left out gettext markers on purpose
	cli_says(terminal, "NO_WAIT")
	hide(85)
</LuaCode>
----------------------------------------------------------------------

Nr=86 Text=_"progress_quest"
NO_TEXT
<LuaCode>
	tux_says(_"./progress_quest", "NO_WAIT")
	if (not has_cookie("playing_progress_quest")) then
		add_cookie("playing_progress_quest")
		npc_says(_"Roll your Stats.")
		hide(81, 82, 83, 85, 86)
		next(87)
	else
		npc_says(_"You are already playing Progress Quest:")
		npc_says_random(_"You are selling an item!", _"You are killing a creature!", _"You are gaining a level!", _"You are casting a spell!")
		cli_says(terminal, "NO_WAIT")
	end
</LuaCode>
----------------------------------------------------------------------

Nr=87 Text=_"BUG c-net node 87 -- ROLL STATS"
NO_TEXT
<LuaCode>
	local str = math.random(0,6) + math.random(0,6) + math.random(0,6)
	local con = math.random(0,6) + math.random(0,6) + math.random(0,6)
	local dex = math.random(0,6) + math.random(0,6) + math.random(0,6)
	local int = math.random(0,6) + math.random(0,6) + math.random(0,6)
	local wis = math.random(0,6) + math.random(0,6) + math.random(0,6)
	local cha = math.random(0,6) + math.random(0,6) + math.random(0,6)
	npc_says(string.format(_"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")
	show(88, 89)
</LuaCode>
----------------------------------------------------------------------

Nr=88 Text=_"Accept Character"
NO_TEXT
<LuaCode>
	npc_says(_"Welcome to Progress Quest!")
	cli_says(terminal, "NO_WAIT")
	show(81, 82, 83, 85, 86) hide(88, 89)
</LuaCode>
----------------------------------------------------------------------

Nr=89 Text=_"Reroll Character"
NO_TEXT
<LuaCode>
	next(87)
</LuaCode>
----------------------------------------------------------------------

Nr=99 Text="logout"
NO_TEXT
<LuaCode>
	tux_says("logout", "NO_WAIT")
	npc_says(_"Connection to c-net closed.")
--	set_internet_login_time()
	end_dialog()
</LuaCode>
----------------------------------------------------------------------

End of chat dialog for character="XXXXX"
