Skip to content

Commit

Permalink
General
Browse files Browse the repository at this point in the history
Hide games/progress/etc on cheater profiles.
  • Loading branch information
Ragowit committed Mar 29, 2024
1 parent 8b648e6 commit 07a5649
Show file tree
Hide file tree
Showing 7 changed files with 43 additions and 17 deletions.
4 changes: 2 additions & 2 deletions wwwroot/about.php
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@
</td>
<td class="align-middle text-center">
<?php
if ($player["status"] == 3) {
if ($player["status"] == 1 || $player["status"] == 3) {
?>
N/A
<?php
Expand All @@ -175,7 +175,7 @@
</td>
<td class="align-middle text-center">
<?php
if ($player["status"] == 3) {
if ($player["status"] == 1 || $player["status"] == 3) {
?>
N/A
<?php
Expand Down
2 changes: 1 addition & 1 deletion wwwroot/games.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
$query->execute();
$playerStatus = $query->fetchColumn();

if ($playerStatus == 3) { // Private player
if ($playerStatus == 1 || $playerStatus == 3) { // Cheater or Private player
$player = "";
}
}
Expand Down
14 changes: 11 additions & 3 deletions wwwroot/player.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@

$metaData = new stdClass();
$metaData->title = $player["online_id"] ."'s Trophy Progress";
if ($player["status"] == 3) {
if ($player["status"] == 1) {
$metaData->description = "The player is flagged as a cheater.";
} elseif ($player["status"] == 3) {
$metaData->description = "The player is private.";
} else {
$metaData->description = "Level ". $player["level"] .".". $player["progress"] ." ~ ". $numberOfGames ." Unique Games ~ ". $player["platinum"] ." Unique Platinums";
Expand All @@ -36,7 +38,7 @@
$playerSearch = $_GET["search"] ?? "";
$sort = (!empty($_GET["sort"]) ? $_GET["sort"] : (!empty($_GET["search"]) ? "search" : "date"));

if ($player["status"] == 3) {
if ($player["status"] == 1 || $player["status"] == 3) {
$total_pages = 0;
} else {
$sql = "SELECT Count(*)
Expand Down Expand Up @@ -209,7 +211,13 @@

<tbody>
<?php
if ($player["status"] == 3) {
if ($player["status"] == 1) {
?>
<tr>
<td colspan="4" class="text-center"><h3>This player have some funny looking trophy data. This doesn't necessarily means cheating, but all data from this player will not be in any of the site statistics or leaderboards. <a href="https://github.com/Ragowit/psn100/issues?q=label%3Acheater+<?= $player["online_id"]; ?>+OR+<?= $player["account_id"]; ?>">Dispute</a>?</h3></td>
</tr>
<?php
} elseif ($player["status"] == 3) {
?>
<tr>
<td colspan="4" class="text-center"><h3>This player seems to have a <a class="link-underline link-underline-opacity-0 link-underline-opacity-100-hover" href="https://www.playstation.com/en-us/support/account/privacy-settings-psn/">private</a> profile.</h3></td>
Expand Down
10 changes: 8 additions & 2 deletions wwwroot/player_advisor.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

$sort = (!empty($_GET["sort"]) ? $_GET["sort"] : "date");

if ($player["status"] == 3) {
if ($player["status"] == 1 || $player["status"] == 3) {
$total_pages = 0;
} else {
$sql = "SELECT
Expand Down Expand Up @@ -171,7 +171,13 @@

<tbody>
<?php
if ($player["status"] == 3) {
if ($player["status"] == 1) {
?>
<tr>
<td colspan="5" class="text-center"><h3>This player have some funny looking trophy data. This doesn't necessarily means cheating, but all data from this player will not be in any of the site statistics or leaderboards. <a href="https://github.com/Ragowit/psn100/issues?q=label%3Acheater+<?= $player["online_id"]; ?>+OR+<?= $player["account_id"]; ?>">Dispute</a>?</h3></td>
</tr>
<?php
} elseif ($player["status"] == 3) {
?>
<tr>
<td colspan="5" class="text-center"><h3>This player seems to have a <a class="link-underline link-underline-opacity-0 link-underline-opacity-100-hover" href="https://www.playstation.com/en-us/support/account/privacy-settings-psn/">private</a> profile.</h3></td>
Expand Down
12 changes: 6 additions & 6 deletions wwwroot/player_header.php
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
<div class="hstack">
<div class="vstack">
<?php
if ($player["status"] == 3) {
if ($player["status"] == 1 || $player["status"] == 3) {
echo "N/A";
} else {
?>
Expand Down Expand Up @@ -116,7 +116,7 @@

<div class="text-center bg-dark-subtle p-3 rounded">
<?php
if ($player["status"] == 3) {
if ($player["status"] == 1 || $player["status"] == 3) {
echo "N/A";
} else {
?>
Expand Down Expand Up @@ -148,7 +148,7 @@
Games
<hr class="m-2">
<?php
if ($player["status"] == 3) {
if ($player["status"] == 1 || $player["status"] == 3) {
echo "N/A";
} else {
?>
Expand All @@ -162,7 +162,7 @@
100% Completion
<hr class="m-2">
<?php
if ($player["status"] == 3) {
if ($player["status"] == 1 || $player["status"] == 3) {
echo "N/A";
} else {
?>
Expand Down Expand Up @@ -286,7 +286,7 @@
Average Progress
<hr class="m-2">
<?php
if ($player["status"] == 3) {
if ($player["status"] == 1 || $player["status"] == 3) {
echo "N/A";
} else {
?>
Expand All @@ -300,7 +300,7 @@
Unearned Trophies
<hr class="m-2">
<?php
if ($player["status"] == 3) {
if ($player["status"] == 1 || $player["status"] == 3) {
echo "N/A";
} else {
?>
Expand Down
10 changes: 8 additions & 2 deletions wwwroot/player_log.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

$sort = (!empty($_GET["sort"]) ? $_GET["sort"] : "date");

if ($player["status"] == 3) {
if ($player["status"] == 1 || $player["status"] == 3) {
$total_pages = 0;
} else {
$sql = "SELECT COUNT(*) FROM trophy_earned te
Expand Down Expand Up @@ -169,7 +169,13 @@

<tbody>
<?php
if ($player["status"] == 3) {
if ($player["status"] == 1) {
?>
<tr>
<td colspan="5" class="text-center"><h3>This player have some funny looking trophy data. This doesn't necessarily means cheating, but all data from this player will not be in any of the site statistics or leaderboards. <a href="https://github.com/Ragowit/psn100/issues?q=label%3Acheater+<?= $player["online_id"]; ?>+OR+<?= $player["account_id"]; ?>">Dispute</a>?</h3></td>
</tr>
<?php
} elseif ($player["status"] == 3) {
?>
<tr>
<td colspan="5" class="text-center"><h3>This player seems to have a <a class="link-underline link-underline-opacity-0 link-underline-opacity-100-hover" href="https://www.playstation.com/en-us/support/account/privacy-settings-psn/">private</a> profile.</h3></td>
Expand Down
8 changes: 7 additions & 1 deletion wwwroot/player_random.php
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,13 @@

<div class="row">
<?php
if ($player["status"] == 3) {
if ($player["status"] == 1) {
?>
<div class="col-12 text-center">
<h3>This player have some funny looking trophy data. This doesn't necessarily means cheating, but all data from this player will not be in any of the site statistics or leaderboards. <a href="https://github.com/Ragowit/psn100/issues?q=label%3Acheater+<?= $player["online_id"]; ?>+OR+<?= $player["account_id"]; ?>">Dispute</a>?</h3>
</div>
<?php
} elseif ($player["status"] == 3) {
?>
<div class="col-12 text-center">
<h3>This player seems to have a <a class="link-underline link-underline-opacity-0 link-underline-opacity-100-hover" href="https://www.playstation.com/en-us/support/account/privacy-settings-psn/">private</a> profile.</h3>
Expand Down

0 comments on commit 07a5649

Please sign in to comment.