|
|
@ -18,11 +18,14 @@ $latest_patch = json_decode(file_get_contents("https://ddragon.leagueoflegends.c |
|
|
|
echo "<h1>UEM LoL Elo-Challenge</h1>"; |
|
|
|
echo "<h1>UEM LoL Elo-Challenge</h1>"; |
|
|
|
echo "<div class='uem-logo-header'><img class='uem-logo' src='./../img/uem-logo.png' alt=''></div>"; |
|
|
|
echo "<div class='uem-logo-header'><img class='uem-logo' src='./../img/uem-logo.png' alt=''></div>"; |
|
|
|
echo "<div class='leaderboard'>"; |
|
|
|
echo "<div class='leaderboard'>"; |
|
|
|
echo "<canvas id=\"progress-chart-combined\" style=\"width:100%;max-width:700px\"></canvas>"; |
|
|
|
echo "<div class='combined-charts-buttons'> |
|
|
|
|
|
|
|
<button type='button' id='rank-graph' class='open-general-graph'>Rang-Vergleich</button> |
|
|
|
|
|
|
|
<button type='button' id='progress-graph' class='open-general-graph'>Fortschritt-Vergleich</button> |
|
|
|
|
|
|
|
</div>"; |
|
|
|
|
|
|
|
echo "<div class='graph-wrapper rank-graph closed'><canvas id=\"progress-chart-combined\" style=\"width:100%;max-width:700px\"></canvas></div>"; |
|
|
|
echo "<div class='leaderboard-list'>"; |
|
|
|
echo "<div class='leaderboard-list'>"; |
|
|
|
$placement_counter = 1; |
|
|
|
$placement_counter = 1; |
|
|
|
foreach ($tracker->getProgressions() as $puuid => $progress){ |
|
|
|
foreach ($tracker->getProgressions() as $puuid => $progress){ |
|
|
|
echo "<div class='leaderboard-element place-$placement_counter'>"; |
|
|
|
|
|
|
|
$entries = $tracker->entries[$puuid]; |
|
|
|
$entries = $tracker->entries[$puuid]; |
|
|
|
$account = $tracker->accounts[$puuid]; |
|
|
|
$account = $tracker->accounts[$puuid]; |
|
|
|
$start_elo = reset($entries); |
|
|
|
$start_elo = reset($entries); |
|
|
@ -38,6 +41,11 @@ foreach ($tracker->getProgressions() as $puuid => $progress){ |
|
|
|
$start_tier_ucfirst = ucfirst($start_tier_lowercase); |
|
|
|
$start_tier_ucfirst = ucfirst($start_tier_lowercase); |
|
|
|
$gained_lp_sign = ($progress > 0) ? " plus-lp" : (($progress < 0) ? " minus-lp" : "no-lp"); |
|
|
|
$gained_lp_sign = ($progress > 0) ? " plus-lp" : (($progress < 0) ? " minus-lp" : "no-lp"); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if ($start_elo) { |
|
|
|
|
|
|
|
echo "<button type='button' class='leaderboard-element place-$placement_counter closed'>"; |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
echo "<button type='button' class='leaderboard-element place-$placement_counter closed' disabled>"; |
|
|
|
|
|
|
|
} |
|
|
|
echo "<span class='placement'>$placement_counter.</span>"; |
|
|
|
echo "<span class='placement'>$placement_counter.</span>"; |
|
|
|
|
|
|
|
|
|
|
|
echo "<div class='player-info'> |
|
|
|
echo "<div class='player-info'> |
|
|
@ -60,9 +68,9 @@ foreach ($tracker->getProgressions() as $puuid => $progress){ |
|
|
|
<span class='rank-desc'><span class='rank-tier'>{$tier_ucfirst} {$current_elo->rank}</span> <br> <span class='rank-LP'>{$current_elo->points} LP</span></span> |
|
|
|
<span class='rank-desc'><span class='rank-tier'>{$tier_ucfirst} {$current_elo->rank}</span> <br> <span class='rank-LP'>{$current_elo->points} LP</span></span> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div>"; |
|
|
|
</div>"; |
|
|
|
echo "<canvas id=\"progress-chart-$puuid\" class='progress-chart' style=\"width:100%;max-width:700px\"></canvas>"; |
|
|
|
echo "<div class='graph-wrapper'><canvas id=\"progress-chart-$puuid\" class='progress-chart' style=\"width:100%;max-width:700px\"></canvas></div>"; |
|
|
|
} |
|
|
|
} |
|
|
|
echo "</div>"; |
|
|
|
echo "</button>"; |
|
|
|
$placement_counter++; |
|
|
|
$placement_counter++; |
|
|
|
} |
|
|
|
} |
|
|
|
echo "</div>"; |
|
|
|
echo "</div>"; |
|
|
|