commit
cd0e8cf82f
2 changed files with 30 additions and 6 deletions
|
|
@ -101,7 +101,8 @@ error_reporting(E_ALL);
|
||||||
<td>$matches</td>
|
<td>$matches</td>
|
||||||
<td>$wins</td>
|
<td>$wins</td>
|
||||||
<td>$deaths</td>
|
<td>$deaths</td>
|
||||||
<td>$change <img src='$imagePath' alt='Change Indicator' style='vertical-align: right;' width='25' height='25'/> </td>
|
<td style='line-height: 17px;'><img src='$imagePath' alt='Change Indicator' style='vertical-align: middle;' width='17' height='17'/> $change </td>
|
||||||
|
|
||||||
|
|
||||||
</tr>";
|
</tr>";
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -120,10 +120,12 @@ foreach ($player in $all_player_matches.playername) {
|
||||||
$player_wins = ($all_player_matches | where-object { $_.playername -eq $player } | ForEach-Object { $_.player_matches } | where-object { $_.stats.winPlace -eq 1 }).count
|
$player_wins = ($all_player_matches | where-object { $_.playername -eq $player } | ForEach-Object { $_.player_matches } | where-object { $_.stats.winPlace -eq 1 }).count
|
||||||
$winratio = ($player_wins / $player_matches) * 100
|
$winratio = ($player_wins / $player_matches) * 100
|
||||||
$winratio_old = (($oldstats.all | Where-Object { $_.playername -eq $player }).winratio)
|
$winratio_old = (($oldstats.all | Where-Object { $_.playername -eq $player }).winratio)
|
||||||
|
$change = get-change -winratio_old $winratio_old -winratio $winratio
|
||||||
|
write-output 'all'
|
||||||
write-output "Calculating for player $player"
|
write-output "Calculating for player $player"
|
||||||
write-output "new winratio $winratio"
|
write-output "new winratio $winratio"
|
||||||
write-output "Old winratio $winratio_old"
|
write-output "Old winratio $winratio_old"
|
||||||
|
write-output $change
|
||||||
|
|
||||||
|
|
||||||
$playerstats_all += [PSCustomObject]@{
|
$playerstats_all += [PSCustomObject]@{
|
||||||
|
|
@ -136,7 +138,7 @@ foreach ($player in $all_player_matches.playername) {
|
||||||
KD_ALL = $kills / $deaths
|
KD_ALL = $kills / $deaths
|
||||||
winratio = $winratio
|
winratio = $winratio
|
||||||
wins = $player_wins
|
wins = $player_wins
|
||||||
change = get-change -winratio_old $winratio_old -winratio $winratio
|
change = $change
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -154,6 +156,13 @@ foreach ($player in $all_player_matches.playername) {
|
||||||
$player_wins = ($all_player_matches | where-object { $_.playername -eq $player } | ForEach-Object { $_.player_matches } | where-object { $_.stats.winPlace -eq 1 } | Where-Object { $_.matchType -eq 'event' -and $_.gameMode -eq 'ibr' }).count
|
$player_wins = ($all_player_matches | where-object { $_.playername -eq $player } | ForEach-Object { $_.player_matches } | where-object { $_.stats.winPlace -eq 1 } | Where-Object { $_.matchType -eq 'event' -and $_.gameMode -eq 'ibr' }).count
|
||||||
$winratio = ($player_wins / $player_matches) * 100
|
$winratio = ($player_wins / $player_matches) * 100
|
||||||
$winratio_old = (($oldstats.all | Where-Object { $_.playername -eq $player }).winratio)
|
$winratio_old = (($oldstats.all | Where-Object { $_.playername -eq $player }).winratio)
|
||||||
|
$change = get-change -winratio_old $winratio_old -winratio $winratio
|
||||||
|
|
||||||
|
write-output 'event'
|
||||||
|
write-output "Calculating for player $player"
|
||||||
|
write-output "new winratio $winratio"
|
||||||
|
write-output "Old winratio $winratio_old"
|
||||||
|
write-output $change
|
||||||
|
|
||||||
$playerstats_event_ibr += [PSCustomObject]@{
|
$playerstats_event_ibr += [PSCustomObject]@{
|
||||||
playername = $player
|
playername = $player
|
||||||
|
|
@ -165,7 +174,7 @@ foreach ($player in $all_player_matches.playername) {
|
||||||
KD_ALL = $kills / $deaths
|
KD_ALL = $kills / $deaths
|
||||||
winratio = ($player_wins / $player_matches) * 100
|
winratio = ($player_wins / $player_matches) * 100
|
||||||
wins = $player_wins
|
wins = $player_wins
|
||||||
change = get-change -winratio_old $winratio_old -winratio $winratio
|
change = $change
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$playerstats_event_ibr = $playerstats_event_ibr | Sort-Object winratio -Descending
|
$playerstats_event_ibr = $playerstats_event_ibr | Sort-Object winratio -Descending
|
||||||
|
|
@ -181,6 +190,14 @@ foreach ($player in $all_player_matches.playername) {
|
||||||
$player_wins = ($all_player_matches | where-object { $_.playername -eq $player } | ForEach-Object { $_.player_matches } | where-object { $_.stats.winPlace -eq 1 } | Where-Object { $_.matchType -eq 'airoyale' }).count
|
$player_wins = ($all_player_matches | where-object { $_.playername -eq $player } | ForEach-Object { $_.player_matches } | where-object { $_.stats.winPlace -eq 1 } | Where-Object { $_.matchType -eq 'airoyale' }).count
|
||||||
$winratio = ($player_wins / $player_matches) * 100
|
$winratio = ($player_wins / $player_matches) * 100
|
||||||
$winratio_old = (($oldstats.all | Where-Object { $_.playername -eq $player }).winratio)
|
$winratio_old = (($oldstats.all | Where-Object { $_.playername -eq $player }).winratio)
|
||||||
|
$change = get-change -winratio_old $winratio_old -winratio $winratio
|
||||||
|
|
||||||
|
write-output 'airoyale'
|
||||||
|
write-output "Calculating for player $player"
|
||||||
|
write-output "new winratio $winratio"
|
||||||
|
write-output "Old winratio $winratio_old"
|
||||||
|
write-output $change
|
||||||
|
|
||||||
|
|
||||||
$playerstats_airoyale += [PSCustomObject]@{
|
$playerstats_airoyale += [PSCustomObject]@{
|
||||||
playername = $player
|
playername = $player
|
||||||
|
|
@ -192,7 +209,7 @@ foreach ($player in $all_player_matches.playername) {
|
||||||
KD_ALL = $kills / $deaths
|
KD_ALL = $kills / $deaths
|
||||||
winratio = ($player_wins / $player_matches) * 100
|
winratio = ($player_wins / $player_matches) * 100
|
||||||
wins = $player_wins
|
wins = $player_wins
|
||||||
change = get-change -winratio_old $winratio_old -winratio $winratio
|
change = $change
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$playerstats_airoyale = $playerstats_airoyale | Sort-Object winratio -Descending
|
$playerstats_airoyale = $playerstats_airoyale | Sort-Object winratio -Descending
|
||||||
|
|
@ -207,6 +224,12 @@ foreach ($player in $all_player_matches.playername) {
|
||||||
$player_wins = ($all_player_matches | where-object { $_.playername -eq $player } | ForEach-Object { $_.player_matches } | where-object { $_.stats.winPlace -eq 1 } | Where-Object { $_.matchType -eq 'official' }).count
|
$player_wins = ($all_player_matches | where-object { $_.playername -eq $player } | ForEach-Object { $_.player_matches } | where-object { $_.stats.winPlace -eq 1 } | Where-Object { $_.matchType -eq 'official' }).count
|
||||||
$winratio = ($player_wins / $player_matches) * 100
|
$winratio = ($player_wins / $player_matches) * 100
|
||||||
$winratio_old = (($oldstats.all | Where-Object { $_.playername -eq $player }).winratio)
|
$winratio_old = (($oldstats.all | Where-Object { $_.playername -eq $player }).winratio)
|
||||||
|
$change = get-change -winratio_old $winratio_old -winratio $winratio
|
||||||
|
write-output 'official'
|
||||||
|
write-output "Calculating for player $player"
|
||||||
|
write-output "new winratio $winratio"
|
||||||
|
write-output "Old winratio $winratio_old"
|
||||||
|
write-output $change
|
||||||
|
|
||||||
$playerstats_official += [PSCustomObject]@{
|
$playerstats_official += [PSCustomObject]@{
|
||||||
playername = $player
|
playername = $player
|
||||||
|
|
@ -218,7 +241,7 @@ foreach ($player in $all_player_matches.playername) {
|
||||||
KD_ALL = $kills / $deaths
|
KD_ALL = $kills / $deaths
|
||||||
winratio = ($player_wins / $player_matches) * 100
|
winratio = ($player_wins / $player_matches) * 100
|
||||||
wins = $player_wins
|
wins = $player_wins
|
||||||
change = get-change -winratio_old $winratio_old -winratio $winratio
|
change = $change
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$playerstats_official = $playerstats_official | Sort-Object winratio -Descending
|
$playerstats_official = $playerstats_official | Sort-Object winratio -Descending
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue