} elseif ($do[0] == "spell") { include 'heal.php'; healspells($do[1]); } elseif ($do[0] == "showchar") { showchar(); } elseif ($do[0] == "onlinechar") { onlinechar($do[1]); } elseif ($do[0] == "showmap") { showmap(); } elseif ($do[0] == "babblebox") { babblebox(); } elseif ($do[0] == "ninja") { ninja(); } } else { donothing(); } function donothing() { global $userrow; if ($userrow["currentaction"] == "In Town") { $page = dotown(); $title = "Na Cidade"; } elseif ($userrow["currentaction"] == "Exploring") { $page = doexplore(); $title = "Explorando"; } elseif ($userrow["currentaction"] == "Fighting") { $page = dofight(); $title = "Lutando"; } display($page, $title);
if ($userrow["authlevel"] == 2) { die("Your account has been blocked. Please try back later."); } if (isset($_GET["do"])) { $do = explode(":", $_GET["do"]); if ($do[0] == "thread") { showthread($do[1], $do[2]); } elseif ($do[0] == "new") { newthread(); } elseif ($do[0] == "reply") { reply(); } elseif ($do[0] == "list") { donothing($do[1]); } } else { donothing(0); } function donothing($start = 0) { $query = doquery("SELECT * FROM {{table}} WHERE parent='0' ORDER BY newpostdate DESC LIMIT 20", "forum"); $page = "<table width=\"100%\"><tr><td style=\"padding:1px; background-color:black;\"><table width=\"100%\" style=\"margins:0px;\" cellspacing=\"1\" cellpadding=\"3\"><tr><th colspan=\"3\" style=\"background-color:#dddddd;\"><center><a href=\"forum.php?do=new\">New Thread</a></center></th></tr><tr><th width=\"50%\" style=\"background-color:#dddddd;\">Thread</th><th width=\"10%\" style=\"background-color:#dddddd;\">Replies</th><th style=\"background-color:#dddddd;\">Last Post</th></tr>\n"; $count = 1; if (mysql_num_rows($query) == 0) { $page .= "<tr><td style=\"background-color:#ffffff;\" colspan=\"3\"><b>No threads in forum.</b></td></tr>\n"; } else { while ($row = mysql_fetch_array($query)) { if ($count == 1) { $page .= "<tr><td style=\"background-color:#ffffff;\"><a href=\"forum.php?do=thread:" . $row["id"] . ":0\">" . $row["title"] . "</a></td><td style=\"background-color:#ffffff;\">" . $row["replies"] . "</td><td style=\"background-color:#ffffff;\">" . $row["newpostdate"] . "</td></tr>\n"; $count = 2; } else { $page .= "<tr><td style=\"background-color:#eeeeee;\"><a href=\"forum.php?do=thread:" . $row["id"] . ":0\">" . $row["title"] . "</a></td><td style=\"background-color:#eeeeee;\">" . $row["replies"] . "</td><td style=\"background-color:#eeeeee;\">" . $row["newpostdate"] . "</td></tr>\n";