Skip to content

Commit

Permalink
Server Info Graph Fixes
Browse files Browse the repository at this point in the history
Improved server info graph image a bit. It now has a header explaining what the graph is, and y scaling on the graph is better and more accurately described.
  • Loading branch information
tyger07 committed Mar 27, 2021
1 parent 7b6216b commit afc2697
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions common/server/players-by-date.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,16 +84,18 @@
{
imageline($base, $x_start, $day_average, $x_finish, $day_average, $orange);
}
imagestring($base, 2, $x_start, $height + 15 + $top_offset, $date, $yellow);
imagestring($base, 2, $x_start + 10, $height + 15 + $top_offset, $date, $yellow);
imageline($base, $x_finish, $height + $top_offset, $x_finish, $height + 10 + $top_offset, $light);
$last_average = $day_average;
$loop_count++;
}
imagestring($base, 2, 15, $height - ($y_max_display * $y_division) + $top_offset, $y_max_display, $yellow);
$middle = round(($y_max / 2), 0);
imagestring($base, 2, 15, $height - ($middle * $y_division) + $top_offset, $middle, $yellow);
imagestring($base, 2, 15, $height + $top_offset, "0", $yellow);
imageline($base, 40, $height + 10 + $top_offset, $width + 40, $height + 10 + $top_offset, $light);
imageline($base, 40, 10 + $top_offset, 40, $height + 10 + $top_offset, $light);
imageline($base, 40, $top_offset + 10, 50, $top_offset + 10, $light);
imageline($base, 40, $height + $top_offset, $width + 50, $height + $top_offset, $light);
imageline($base, 50, 10 + $top_offset, 50, $height + 10 + $top_offset, $light);
imagestring($base, 4, 90, 15, 'Average Players per Day on Days with Server Acitivity', $light);
}
else
Expand Down

0 comments on commit afc2697

Please sign in to comment.