From 84dd0735820b16b60f600284d35183d76547a71f Mon Sep 17 00:00:00 2001 From: Minteck Date: Wed, 10 Aug 2022 00:23:09 +0200 Subject: Stuff --- .idea/vcs.xml | 6 ++++++ assets/species/crystal.png | Bin 0 -> 2260 bytes assets/uploads/pt-frost.png | Bin 0 -> 7403 bytes includes/banner.php | 4 ++++ includes/score.php | 2 +- includes/system/species.php | 3 +++ 6 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 .idea/vcs.xml create mode 100644 assets/species/crystal.png create mode 100644 assets/uploads/pt-frost.png diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..94a25f7 --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/assets/species/crystal.png b/assets/species/crystal.png new file mode 100644 index 0000000..05287dd Binary files /dev/null and b/assets/species/crystal.png differ diff --git a/assets/uploads/pt-frost.png b/assets/uploads/pt-frost.png new file mode 100644 index 0000000..44c5149 Binary files /dev/null and b/assets/uploads/pt-frost.png differ diff --git a/includes/banner.php b/includes/banner.php index b5088df..8501a61 100644 --- a/includes/banner.php +++ b/includes/banner.php @@ -162,6 +162,10 @@ function getSubsystemFromMember(array $member) { echo "Alicorn"; break; + case "crystal": + echo "Crystal pony"; + break; + case "pegasus": echo "Pegasus"; break; diff --git a/includes/score.php b/includes/score.php index c3108f2..5367cd6 100644 --- a/includes/score.php +++ b/includes/score.php @@ -8,7 +8,7 @@ function calculateScore($metadata, $name) { $scoreMedian = $metadata["median"] !== false ? -50 : 0; $scoreProtector = $metadata["protector"] ? 1000 : 0; $scoreSharedMemory = $metadata["shared_memory"] === 0 ? 200 : ($metadata["shared_memory"] === 1 ? 50 : 0); - $scoreSpecies = (in_array("pegasus", $metadata["species"]) ? 100 : 0) + (in_array("unicorn", $metadata["species"]) ? 75 : 0) + (in_array("earth", $metadata["species"]) ? 50 : 0) + (in_array("alicorn", $metadata["species"]) ? 150 : 0) + (in_array("batpony", $metadata["species"]) ? 125 : 0); + $scoreSpecies = (in_array("pegasus", $metadata["species"]) ? 100 : 0) + (in_array("unicorn", $metadata["species"]) ? 75 : 0) + (in_array("earth", $metadata["species"]) ? 50 : 0) + (in_array("alicorn", $metadata["species"]) ? 150 : 0) + (in_array("batpony", $metadata["species"]) ? 125 : 0) + (in_array("crystal", $metadata["species"]) ? 125 : 0); $scoreName = strlen($name) * 5; $relations = (count($metadata["marefriends"]) * ($metadata["little"] ? 1 : 2)) + count($metadata["sisters"]); $scoreRelations = $relations * 50; diff --git a/includes/system/species.php b/includes/system/species.php index a2251d0..7747809 100644 --- a/includes/system/species.php +++ b/includes/system/species.php @@ -30,6 +30,7 @@ function species(array $members, string $id, string $name) { global $systemID; ? $unicorn = []; $alicorn = []; $batpony = []; + $crystal = []; foreach ($members as $member) { foreach ($member["_metadata"]["species"] as $species) { @@ -38,6 +39,7 @@ function species(array $members, string $id, string $name) { global $systemID; ? if ($species === "unicorn") $unicorn[] = $member; if ($species === "alicorn") $alicorn[] = $member; if ($species === "batpony") $batpony[] = $member; + if ($species === "crystal") $crystal[] = $member; } } @@ -48,6 +50,7 @@ function species(array $members, string $id, string $name) { global $systemID; ? + \ No newline at end of file -- cgit