summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--html/assets/main.js5
-rw-r--r--[-rwxr-xr-x]html/includes/clanbase.php0
-rwxr-xr-xhtml/includes/config.php6
-rw-r--r--[-rwxr-xr-x]html/includes/config_pic.php0
-rw-r--r--[-rwxr-xr-x]html/includes/countries.php0
-rw-r--r--[-rwxr-xr-x]html/includes/ftp.php2
-rw-r--r--[-rwxr-xr-x]html/includes/ftp_class.php0
-rw-r--r--[-rwxr-xr-x]html/includes/ftp_class_native.php0
-rw-r--r--[-rwxr-xr-x]html/includes/ftp_class_pure.php0
-rw-r--r--[-rwxr-xr-x]html/includes/ftp_class_sockets.php0
-rw-r--r--[-rwxr-xr-x]html/includes/geoip.inc0
-rw-r--r--[-rwxr-xr-x]html/includes/hints.php6
-rwxr-xr-xhtml/includes/teamstats.php338
-rw-r--r--[-rwxr-xr-x]html/includes/weaponstats.php48
-rw-r--r--[-rwxr-xr-x]html/pages/admin/acelog.php4
-rw-r--r--[-rwxr-xr-x]html/pages/admin/aclog.php228
-rw-r--r--[-rwxr-xr-x]html/pages/admin/dmatch.php4
-rw-r--r--[-rwxr-xr-x]html/pages/admin/dplayer.php2
-rw-r--r--[-rwxr-xr-x]html/pages/admin/dpmatch.php2
-rw-r--r--[-rwxr-xr-x]html/pages/admin/editgames.php2
-rw-r--r--[-rwxr-xr-x]html/pages/admin/editgamestype.php6
-rw-r--r--[-rwxr-xr-x]html/pages/admin/editweapons.php2
-rw-r--r--[-rwxr-xr-x]html/pages/admin/ipsearch.php2
-rw-r--r--[-rwxr-xr-x]html/pages/admin/main.php51
-rw-r--r--[-rwxr-xr-x]html/pages/admin/mplayers.php2
-rw-r--r--[-rwxr-xr-x]html/pages/admin/mservers.php2
-rw-r--r--[-rwxr-xr-x]html/pages/admin/pban.php4
-rw-r--r--[-rwxr-xr-x]html/pages/admin/pinfo.php4
-rw-r--r--[-rwxr-xr-x]html/pages/admin/plm.php34
-rw-r--r--[-rwxr-xr-x]html/pages/admin/recalcflags.php2
-rw-r--r--[-rwxr-xr-x]html/pages/admin/recalcranking.php2
-rw-r--r--[-rwxr-xr-x]html/pages/admin/utdclog.php4
-rw-r--r--[-rwxr-xr-x]html/pages/admin/utdcshot.php0
-rwxr-xr-xhtml/pages/credits.php661
-rw-r--r--[-rwxr-xr-x]html/pages/dpmatch.php2
-rwxr-xr-xhtml/pages/graph_mbreakdown.php247
-rw-r--r--[-rwxr-xr-x]html/pages/graph_pbreakdown.php2
-rwxr-xr-xhtml/pages/help.php477
-rwxr-xr-xhtml/pages/home.php266
-rw-r--r--[-rwxr-xr-x]html/pages/maps.php42
-rw-r--r--[-rwxr-xr-x]html/pages/maps_info.php507
-rwxr-xr-xhtml/pages/match_info.php115
-rw-r--r--[-rwxr-xr-x]html/pages/match_info_ass.php8
-rw-r--r--[-rwxr-xr-x]html/pages/match_info_bt.php2
-rw-r--r--[-rwxr-xr-x]html/pages/match_info_ctf.php634
-rw-r--r--[-rwxr-xr-x]html/pages/match_info_killsmatrix.php58
-rw-r--r--[-rwxr-xr-x]html/pages/match_info_lms.php27
-rwxr-xr-xhtml/pages/match_info_other.php206
-rw-r--r--[-rwxr-xr-x]html/pages/match_info_other2.php40
-rwxr-xr-xhtml/pages/match_player.php165
-rw-r--r--[-rwxr-xr-x]html/pages/match_report.php9
-rw-r--r--[-rwxr-xr-x]html/pages/players_explain_ranking.php66
-rwxr-xr-xhtml/pages/players_info.php694
-rw-r--r--[-rwxr-xr-x]html/pages/players_search.php46
-rw-r--r--[-rwxr-xr-x]html/pages/rank_extended.php26
-rw-r--r--[-rwxr-xr-x]html/pages/report.php0
-rw-r--r--[-rwxr-xr-x]html/pages/report/bbcode.php0
-rw-r--r--[-rwxr-xr-x]html/pages/report/clanbase.php0
-rw-r--r--[-rwxr-xr-x]html/pages/report/index.htm0
-rw-r--r--[-rwxr-xr-x]html/pages/report_cb.php6
-rw-r--r--[-rwxr-xr-x]html/pages/servers.php18
-rw-r--r--[-rwxr-xr-x]html/pages/servers_info.php208
-rw-r--r--[-rwxr-xr-x]html/pages/servers_query.php6
-rwxr-xr-xhtml/pages/totals.php565
64 files changed, 3118 insertions, 2747 deletions
diff --git a/html/assets/main.js b/html/assets/main.js
index b1e9b9e..5863530 100644
--- a/html/assets/main.js
+++ b/html/assets/main.js
@@ -8,4 +8,9 @@ $(document).ready(function() {
window.document.location = $(this).attr("href");
}
});
+
+ // Credits changelog toggle
+ $(".changeLog").click(function() {
+ $("#contentChangeLog").slideToggle(300);
+ });
});
diff --git a/html/includes/clanbase.php b/html/includes/clanbase.php
index 5ad7640..5ad7640 100755..100644
--- a/html/includes/clanbase.php
+++ b/html/includes/clanbase.php
diff --git a/html/includes/config.php b/html/includes/config.php
index 55b9ffe..77d42fa 100755
--- a/html/includes/config.php
+++ b/html/includes/config.php
@@ -1,9 +1,9 @@
<?php
// Database connection details
-$dbname = "utstats";
-$hostname = "localhost";
-$uname = "root";
+$dbname = "";
+$hostname = "";
+$uname = "";
$upass = "";
// The key needed to run the import script
diff --git a/html/includes/config_pic.php b/html/includes/config_pic.php
index e70aee5..e70aee5 100755..100644
--- a/html/includes/config_pic.php
+++ b/html/includes/config_pic.php
diff --git a/html/includes/countries.php b/html/includes/countries.php
index 4de8dde..4de8dde 100755..100644
--- a/html/includes/countries.php
+++ b/html/includes/countries.php
diff --git a/html/includes/ftp.php b/html/includes/ftp.php
index 7e058a3..1a6e7ee 100755..100644
--- a/html/includes/ftp.php
+++ b/html/includes/ftp.php
@@ -109,7 +109,7 @@ function ftpupdate()
if (!$ftp_debug) {
- if ($html) echo'<table class="box" border="0" cellpadding="1" cellspacing="2" style="table-layout:fixed"><tr><td class="smheading" align="center" height="25" width="550" colspan="2">';
+ if ($html) echo'<table class="zebra box" border="0" cellpadding="0" cellspacing="0" style="table-layout:fixed"><tr><td class="smheading" align="center" height="25" width="550" colspan="2">';
echo "FTP Transferring Log Files...\n";
diff --git a/html/includes/ftp_class.php b/html/includes/ftp_class.php
index 5281379..5281379 100755..100644
--- a/html/includes/ftp_class.php
+++ b/html/includes/ftp_class.php
diff --git a/html/includes/ftp_class_native.php b/html/includes/ftp_class_native.php
index 4f7f1df..4f7f1df 100755..100644
--- a/html/includes/ftp_class_native.php
+++ b/html/includes/ftp_class_native.php
diff --git a/html/includes/ftp_class_pure.php b/html/includes/ftp_class_pure.php
index e7806db..e7806db 100755..100644
--- a/html/includes/ftp_class_pure.php
+++ b/html/includes/ftp_class_pure.php
diff --git a/html/includes/ftp_class_sockets.php b/html/includes/ftp_class_sockets.php
index 8cfd27f..8cfd27f 100755..100644
--- a/html/includes/ftp_class_sockets.php
+++ b/html/includes/ftp_class_sockets.php
diff --git a/html/includes/geoip.inc b/html/includes/geoip.inc
index a095469..a095469 100755..100644
--- a/html/includes/geoip.inc
+++ b/html/includes/geoip.inc
diff --git a/html/includes/hints.php b/html/includes/hints.php
index b8da8de..7ba11a3 100755..100644
--- a/html/includes/hints.php
+++ b/html/includes/hints.php
@@ -24,10 +24,8 @@ $hint['Multis'] =
"text" => "Special event: If you manage to kill more 2 than people within a short space of time you get a Double Kill, 3 is a Multi Kill etc"
);
-$hint['Sprees'] =
- array ( "caption" => "Killing Sprees",
- "text" => "Special event: If you manage to kill 5 or more opponents without dying yourself, you will be on a killing spree. If you kill more than 10 opponents, you are on a rampage, etc."
- );
+$hint['Sprees'] = "Special event: If you manage to kill 5 or more opponents without dying yourself, you will be on a killing spree. If you kill more than 10 opponents, you are on a rampage, etc."
+ ;
$hint['EFF'] = array ( "caption" => "Efficiency",
"text" => "A ratio that denotes the player's kill skill by comparing it with his overall performance. A perfect efficiency is equal to 1 (100%), anything less than 0.5 (50%) is below average.<br>Formula: Kills / (Kills + Deaths + Suicides [+Team Kills])"
diff --git a/html/includes/teamstats.php b/html/includes/teamstats.php
index b2116b9..d0b1b58 100755
--- a/html/includes/teamstats.php
+++ b/html/includes/teamstats.php
@@ -1,182 +1,176 @@
<?php
+
function teamstats($mid, $title, $extra = NULL, $extratitle = NULL, $order = 'gamescore DESC') {
- global $gamename, $gid;
-
- $r_info = small_query("SELECT teamgame, t0score, t1score, t2score, t3score FROM uts_match WHERE id = '$mid'");
- if (!$r_info) die("Match not found");
-
- $teams = ($r_info['teamgame'] == 'True') ? true : false;
- $teamscore[-1] = 0;
- $teamscore[0] = $r_info['t0score'];
- $teamscore[1] = $r_info['t1score'];
- $teamscore[2] = $r_info['t2score'];
- $teamscore[3] = $r_info['t3score'];
-
- $cols = 10;
- if ($teams) $cols++;
- if ($extra) $cols++;
- $oldteam = -1;
-
- echo'
- <table class="box zebra" border="0" cellpadding="0" cellspacing="0" width="700">
- <tbody>
- <tr>
- <th class="heading" colspan="'.$cols.'" align="center">'.htmlentities($title).'</th>
- </tr>';
-
- $sql_players = "SELECT pi.name, pi.banned, p.pid, p.team, p.country, p.gametime, p.gamescore, p.frags, p.deaths, p.suicides, p.teamkills, p.eff, p.accuracy, p.ttl, p.rank".(($extra) ? ', p.'.$extra.' AS '.$extra : '')."
- FROM uts_player AS p, uts_pinfo AS pi WHERE p.pid = pi.id AND matchid = $mid
- ORDER BY".(($teams) ? ' team ASC,' : '')." $order";
- $q_players = mysql_query($sql_players) or die(mysql_error());
- $header = true;
- teamstats_init_totals($totals, $num);
-
- while ($r_players = zero_out(mysql_fetch_array($q_players))) {
- $r_players['dom_cp'] = $r_players['gamescore'] - $r_players['frags'];
- $r_players['team'] = intval($r_players['team']);
-
- if ($teams and $oldteam != $r_players['team']) {
- if ($r_players['team'] != 0) teamstats_team_totals($totals, $num, $teams, $extra, $teamscore[$oldteam]);
- $oldteam = $r_players['team'];
- teamstats_init_totals($totals, $num, $extra);
-
- switch(intval($r_players['team'])) {
- case 0: $teamname = 'Red'; break;
- case 1: $teamname = 'Blue'; break;
- case 2: $teamname = 'Green'; break;
- case 3: $teamname = 'Gold'; break;
- }
-
- echo'<tr><td class="'.$teamname.'" colspan="'.$cols.'" align="center">Team: '.$teamname.'</td></tr>';
- $header = true;
- }
-
- if ($header) {
- $header = false;
- echo '
- <tr>
- <th class="smheading" align="center">Player</th>
- <th class="smheading" align="center" width="50">Time</th>
- <th class="smheading" align="center" width="50">Score</th>';
- if ($extra) echo '<th class="smheading" align="center" width="50">'.htmlentities($extratitle).'</th>';
- echo'
- <th class="smheading tooltip" align="center" width="40" title="Frags: A player\'s frag count is equal to their kills minus suicides. In team games team kills (not team suicides) are also subtracted from the player\'s kills.">F</th>
- <th class="smheading tooltip" align="center" width="40" title="Kills: Number of times a player kills another player.">K</th>
- <th class="smheading tooltip" align="center" width="40" title="Deaths: Number of times a player gets killed by another player.">D</th>
- <th class="smheading tooltip" align="center" width="40" title="Suicides: Number of times a player dies due to action of their own cause. Suicides can be environment induced (drowning, getting crushed, falling) or weapon related (fatal splash damage from their own weapon).">S</th>';
- if ($teams) echo '<th class="smheading tooltip" align="center" width="40" title="Team Kills: Number of times a player in a team based game kills someone on their own team.">TK</th>';
- echo '
- <th class="smheading tooltip" align="center" width="55" title="Efficiency: A ratio that denotes the player\'s kill skill by comparing it with his overall performance. A perfect efficiency is equal to 1 (100%), anything less than 0.5 (50%) is below average. Formula: Kills / (Kills + Deaths + Suicides [+Team Kills])">Eff.</th>
- <th class="smheading tooltip" align="center" width="55" title="Accuracy: Overall accuracy when using all weapons. Most accurate in insta but also very accurate in normal weapons.">Acc.</th>
- <th class="smheading tooltip" align="center" width="50" title="Average Time to Live: The length of time a player is in a game in seconds divided by how many times he/she dies, thus giving an average time of how long he/she will live.">Avg TTL</th>
- </tr>';
- }
-
- $eff = get_dp($r_players['eff']);
- $acc = get_dp($r_players['accuracy']);
- $ttl = GetMinutes($r_players['ttl']);
- $kills = $r_players['frags'] + $r_players['suicides'];
- $pname = $r_players['name'];
-
- $totals['gamescore'] += $r_players['gamescore'];
- if ($extra) $totals[$extra] += $r_players[$extra];
- $totals['frags'] += $r_players['frags'];
- $totals['kills'] += $kills;
- $totals['deaths'] += $r_players['deaths'];
- $totals['suicides'] += $r_players['suicides'];
- $totals['teamkills'] += $r_players['teamkills'];
- $totals['eff'] += $r_players['eff'];
- $totals['acc'] += $r_players['accuracy'];
- $totals['ttl'] += $r_players['ttl'];
- $num++;
-
- if ($r_players['banned'] == 'Y') {
- $eff = '-';
- $acc = '-';
- $ttl = '-';
- $kills = '-';
- $r_players['gamescore'] = '-';
- $r_players[$extra] = '-';
- $r_players['frags'] = '-';
- $r_players['deaths'] = '-';
- $r_players['suicides'] = '-';
- $r_players['teamkills'] = '-';
- }
-
- $class = ($num % 2) ? 'grey' : 'grey2';
- echo '<tr class="clickableRow" href="./?p=matchp&amp;mid='.$mid.'&amp;pid='.$r_players['pid'].'">';
-
- if ($r_players['banned'] != 'Y') {
- echo '<td nowrap align="left"><a href="./?p=matchp&amp;mid='.$mid.'&amp;pid='.$r_players['pid'].'">'.FormatPlayerName($r_players['country'], $r_players['pid'], $r_players['name'], $gid, $gamename, true, $r_players['rank']).'</a></td>';
- } else {
- echo '<td nowrap align="left"><span style="text-decoration: line-through;">'.FormatPlayerName($r_players['country'], $r_players['pid'], $r_players['name'], $gid, $gamename, true, $r_players['rank']).'</span></td>';
- }
-
- echo '<td class="'.$class.'" align="center">'.GetMinutes($r_players['gametime'] / TIMERATIO).'</td>';
- echo '<td class="'.$class.'" align="center">'.$r_players['gamescore'].'</td>';
-
- if ($extra) echo '<td class="'.$class.'" align="center">'.$r_players[$extra].'</td>';
-
- echo '<td class="'.$class.'" align="center">'.$r_players['frags'].'</td>';
- echo '<td class="'.$class.'" align="center">'.$kills.'</td>';
- echo '<td class="'.$class.'" align="center">'.$r_players['deaths'].'</td>';
- echo '<td class="'.$class.'" align="center">'.$r_players['suicides'].'</td>';
-
- if ($teams) echo '<td class="'.$class.'" align="center">'.$r_players['teamkills'].'</td>';
-
- echo '<td align="center">'.$eff.'</td>';
- echo '<td align="center">'.$acc.'</td>';
- echo '<td align="center">'.$ttl.'</td>';
- echo '</tr>';
- }
-
- teamstats_team_totals($totals, $num, $teams, $extra, $teamscore[$oldteam]);
-
- echo '</tbody></table><br>';
+ global $gamename, $gid;
+ $r_info = small_query("SELECT teamgame, t0score, t1score, t2score, t3score FROM uts_match WHERE id = '$mid'");
+ if (!$r_info) die("Match not found");
+
+ $teams = ($r_info['teamgame'] == 'True') ? true : false;
+ $teamscore[-1] = 0;
+ $teamscore[0] = $r_info['t0score'];
+ $teamscore[1] = $r_info['t1score'];
+ $teamscore[2] = $r_info['t2score'];
+ $teamscore[3] = $r_info['t3score'];
+
+ $cols = 10;
+ if ($teams) $cols++;
+ if ($extra) $cols++;
+
+ $oldteam = -1;
+
+ echo'
+ <table class="box zebra" border="0" cellpadding="0" cellspacing="0" width="700">
+ <tbody><tr>
+ <th class="heading" colspan="'.$cols.'" align="center">'.htmlentities($title).'</th>
+ </tr>';
+
+ $sql_players = "SELECT pi.name, pi.banned, p.pid, p.team, p.country, p.gametime, p.gamescore, p.frags, p.deaths, p.suicides, p.teamkills, p.eff, p.accuracy, p.ttl, p.rank".(($extra) ? ', p.'.$extra.' AS '.$extra : '')."
+ FROM uts_player AS p, uts_pinfo AS pi WHERE p.pid = pi.id AND matchid = $mid
+ ORDER BY".(($teams) ? ' team ASC,' : '')." $order";
+ $q_players = mysql_query($sql_players) or die(mysql_error());
+ $header = true;
+ teamstats_init_totals($totals, $num);
+
+ while ($r_players = zero_out(mysql_fetch_array($q_players))) {
+ $r_players['dom_cp'] = $r_players['gamescore'] - $r_players['frags'];
+ $r_players['team'] = intval($r_players['team']);
+
+ if ($teams and $oldteam != $r_players['team']) {
+ if ($r_players['team'] != 0) teamstats_team_totals($totals, $num, $teams, $extra, $teamscore[$oldteam]);
+ $oldteam = $r_players['team'];
+ teamstats_init_totals($totals, $num, $extra);
+
+ switch(intval($r_players['team'])) {
+ case 0: $teamname = 'Red'; break;
+ case 1: $teamname = 'Blue'; break;
+ case 2: $teamname = 'Green'; break;
+ case 3: $teamname = 'Gold'; break;
+ }
+
+ echo'<tr><td class="'.$teamname.'" colspan="'.$cols.'" align="center">Team: '.$teamname.'</td></tr>';
+ $header = true;
+ }
+ if ($header) {
+ $header = false;
+ echo '
+ <tr>
+ <th class="smheading " align="center">Player</th>
+ <th class="smheading " align="center" width="50">Time</th>
+ <th class="smheading " align="center" width="50">Score</th>';
+ if ($extra) echo '<th class="smheading " align="center" width="50">'.htmlentities($extratitle).'</th>';
+ echo '
+ <th class="smheading tooltip" align="center" width="40" title="Frags: A player\'s frag count is equal to their kills minus suicides. In team games team kills (not team suicides) are also subtracted from the player\'s kills.">F</th>
+ <th class="smheading tooltip" align="center" width="40" title="Kills: Number of times a player kills another player.">K</th>
+ <th class="smheading tooltip" align="center" width="40" title="Deaths: Number of times a player gets killed by another player.">D</th>
+ <th class="smheading tooltip" align="center" width="40" title="Suicides: Number of times a player dies due to action of their own cause. Suicides can be environment induced (drowning, getting crushed, falling) or weapon related (fatal splash damage from their own weapon).">S</th>';
+ if ($teams) echo '<th class="smheading tooltip" align="center" width="40" title="Team Kills: Number of times a player in a team based game kills someone on their own team.">TK</th>';
+ echo '
+ <th class="smheading tooltip" align="center" width="55" title="Efficiency: A ratio that denotes the player\'s kill skill by comparing it with his overall performance. A perfect efficiency is equal to 1 (100%), anything less than 0.5 (50%) is below average. Formula: Kills / (Kills + Deaths + Suicides [+Team Kills])">Eff.</th>
+ <th class="smheading tooltip" align="center" width="55" title="Accuracy: Overall accuracy when using all weapons. Most accurate in insta but also very accurate in normal weapons.">Acc.</th>
+ <th class="smheading tooltip" align="center" width="50" title="Average Time to Live: The length of time a player is in a game in seconds divided by how many times he/she dies, thus giving an average time of how long he/she will live.">Avg TTL</th>
+ </tr>';
+ }
+
+ $eff = get_dp($r_players['eff']);
+ $acc = get_dp($r_players['accuracy']);
+ $ttl = GetMinutes($r_players['ttl']);
+ $kills = $r_players['frags'] + $r_players['suicides'];
+ $pname = $r_players['name'];
+
+ $totals['gamescore'] += $r_players['gamescore'];
+ if ($extra) $totals[$extra] += $r_players[$extra];
+ $totals['frags'] += $r_players['frags'];
+ $totals['kills'] += $kills;
+ $totals['deaths'] += $r_players['deaths'];
+ $totals['suicides'] += $r_players['suicides'];
+ $totals['teamkills'] += $r_players['teamkills'];
+ $totals['eff'] += $r_players['eff'];
+ $totals['acc'] += $r_players['accuracy'];
+ $totals['ttl'] += $r_players['ttl'];
+ $num++;
+
+ if ($r_players['banned'] == 'Y') {
+ $eff = '-';
+ $acc = '-';
+ $ttl = '-';
+ $kills = '-';
+ $r_players['gamescore'] = '-';
+ $r_players[$extra] = '-';
+ $r_players['frags'] = '-';
+ $r_players['deaths'] = '-';
+ $r_players['suicides'] = '-';
+ $r_players['teamkills'] = '-';
+ }
+
+ $class = ($num % 2) ? 'grey' : 'grey2';
+ echo '<tr class="clickableRow" href="./?p=matchp&amp;mid='.$mid.'&amp;pid='.$r_players['pid'].'">';
+ if ($r_players['banned'] != 'Y') {
+ echo '<td nowrap align="left"><a href="./?p=matchp&amp;mid='.$mid.'&amp;pid='.$r_players['pid'].'">'.FormatPlayerName($r_players['country'], $r_players['pid'], $r_players['name'], $gid, $gamename, true, $r_players['rank']).'</a></td>';
+ } else {
+ echo '<td nowrap align="left"><span style="text-decoration: line-through;">'.FormatPlayerName($r_players['country'], $r_players['pid'], $r_players['name'], $gid, $gamename, true, $r_players['rank']).'</span></td>';
+ }
+ echo '<td align="center">'.GetMinutes($r_players['gametime'] / TIMERATIO).'</td>';
+ echo '<td align="center">'.$r_players['gamescore'].'</td>';
+
+ if ($extra) echo '<td align="center">'.$r_players[$extra].'</td>';
+
+ echo '<td align="center">'.$r_players['frags'].'</td>';
+ echo '<td align="center">'.$kills.'</td>';
+ echo '<td align="center">'.$r_players['deaths'].'</td>';
+ echo '<td align="center">'.$r_players['suicides'].'</td>';
+
+ if ($teams) echo '<td align="center">'.$r_players['teamkills'].'</td>';
+
+ echo '<td align="center">'.$eff.'</td>';
+ echo '<td align="center">'.$acc.'</td>';
+ echo '<td align="center">'.$ttl.'</td>';
+ echo '</tr>';
+ }
+
+ teamstats_team_totals($totals, $num, $teams, $extra, $teamscore[$oldteam]);
+ echo '</tbody></table><br>';
}
function teamstats_init_totals(&$totals, &$num, $extra = null) {
- $totals['gamescore'] = 0;
- if ($extra) $totals[$extra] = 0;
- $totals['frags'] = 0;
- $totals['kills'] = 0;
- $totals['deaths'] = 0;
- $totals['suicides'] = 0;
- $totals['teamkills'] = 0;
- $totals['eff'] = 0;
- $totals['acc'] = 0;
- $totals['ttl'] = 0;
- $num = 0;
+ $totals['gamescore'] = 0;
+ if ($extra) $totals[$extra] = 0;
+ $totals['frags'] = 0;
+ $totals['kills'] = 0;
+ $totals['deaths'] = 0;
+ $totals['suicides'] = 0;
+ $totals['teamkills'] = 0;
+ $totals['eff'] = 0;
+ $totals['acc'] = 0;
+ $totals['ttl'] = 0;
+ $num = 0;
}
function teamstats_team_totals(&$totals, $num, $teams, $extra, $teamscore) {
- if ($num == 0) $num = 1;
- $eff = get_dp($totals['eff'] / $num);
- $acc = get_dp($totals['acc'] / $num);
- $ttl = GetMinutes($totals['ttl'] / $num);
-
- echo '<tr>';
- echo '<td nowrap class="totals" align="center">Totals</td>';
- echo '<td class="totals" align="center"></td>';
-
- if ($teams) {