Skip to content

Commit

Permalink
Ubers suspect test COIL
Browse files Browse the repository at this point in the history
  • Loading branch information
TheImmortal committed Jul 25, 2014
1 parent 380f245 commit 31a942b
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 8 deletions.
12 changes: 7 additions & 5 deletions js/client-chat.js
Original file line number Diff line number Diff line change
Expand Up @@ -596,14 +596,16 @@
buffer += '<em>'+Math.round(row.rpr)+'<small> &#177; '+Math.round(row.rprd)+'</small></em>';
}
var N=parseInt(row.w)+parseInt(row.l)+parseInt(row.t);
if (row.formatid === 'lcsuspecttest') {
buffer += '<td>'+Math.round(40.0*parseFloat(row.gxe)*Math.pow(2.0,-43.0/N),0)+'</td>';
} else if (row.formatid === 'oususpecttest') {
if (row.formatid === 'oususpecttest') {
buffer += '<td>'+Math.round(40.0*parseFloat(row.gxe)*Math.pow(2.0,-17.0/N),0)+'</td>';
} else if (row.formatid === 'smogondoublescurrent' || row.formatid === 'smogondoublessuspecttest') {
buffer += '<td>'+Math.round(40.0*parseFloat(row.gxe)*Math.pow(2.0,-15.0/N),0)+'</td>';
if (row.formatid === 'uberssuspecttest') {
buffer += '<td>'+Math.round(40.0*parseFloat(row.gxe)*Math.pow(2.0,-29.0/N),0)+'</td>';
} else if (row.formatid === 'rususpecttest') {
buffer += '<td>'+Math.round(40.0*parseFloat(row.gxe)*Math.pow(2.0,-20.0/N),0)+'</td>';
} else if (row.formatid === 'lcsuspecttest') {
buffer += '<td>'+Math.round(40.0*parseFloat(row.gxe)*Math.pow(2.0,-43.0/N),0)+'</td>';
} else if (row.formatid === 'smogondoublescurrent' || row.formatid === 'smogondoublessuspecttest') {
buffer += '<td>'+Math.round(40.0*parseFloat(row.gxe)*Math.pow(2.0,-15.0/N),0)+'</td>';
} else {
buffer += '<td>--</td>';
}
Expand Down
7 changes: 4 additions & 3 deletions ladder.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,11 @@
<td><?php echo $i; ?></td><td><?php echo htmlspecialchars($row['username']); ?></td><td><strong><?php echo round($row['acre']); ?></strong></td><td><?php echo number_format($row['gxe'],1); ?></td>
<td><?php echo '<em>'.round($row['rpr']).'<small> &#177; '.round($row['rprd']).'</small></em>'; /* if (floatval($row['rprd']) > 100) echo ' <small>(provisional)</small>'; */ ?></td>
<td>
<?php if ($row['formatid'] == 'lcsuspecttest') echo number_format($N ? 40*$row['gxe']*pow(2.0,-43.0/$N) : 0,1,'.','');
elseif ($row['formatid'] == 'oususpecttest') echo number_format($N ? 40*$row['gxe']*pow(2.0,-17.0/$N) : 0,1,'.','');
elseif ($row['formatid'] == 'smogondoublescurrent' || $row['formatid'] == 'smogondoublessuspecttest') echo number_format($N ? 40*$row['gxe']*pow(2.0,-15.0/$N) : 0,1,'.','');
<?php if ($row['formatid'] == 'oususpecttest') echo number_format($N ? 40*$row['gxe']*pow(2.0,-17.0/$N) : 0,1,'.','');
elseif ($row['formatid'] == 'uberssuspecttest') echo number_format($N ? 40*$row['gxe']*pow(2.0,-29.0/$N) : 0,1,'.','');
elseif ($row['formatid'] == 'rususpecttest') echo number_format($N ? 40*$row['gxe']*pow(2.0,-20.0/$N) : 0,1,'.','');
elseif ($row['formatid'] == 'lcsuspecttest') echo number_format($N ? 40*$row['gxe']*pow(2.0,-43.0/$N) : 0,1,'.','');
elseif ($row['formatid'] == 'smogondoublescurrent' || $row['formatid'] == 'smogondoublessuspecttest') echo number_format($N ? 40*$row['gxe']*pow(2.0,-15.0/$N) : 0,1,'.','');
else echo '--'; ?></td>
</tr>
<?php
Expand Down

0 comments on commit 31a942b

Please sign in to comment.