Skip to content

Commit

Permalink
Profile Viewer: Improve accolade stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
Sainan committed Dec 19, 2024
1 parent 56b1ffe commit 0efe2fc
Showing 1 changed file with 22 additions and 14 deletions.
36 changes: 22 additions & 14 deletions profile.php
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,7 @@
this.select();
};*/

const guideTiers = [0, "Junior Guide of the Lotus", "Senior Guide of the Lotus"];
const founderTiers = [0, "Disciple", "Hunter", "Master", "Grand Master"];
const clanTiers = [0, "Ghost", "Shadow", "Storm", "Mountain", "Moon"];
const syndicateTags = [
Expand Down Expand Up @@ -537,21 +538,28 @@ function renderProfile()
{
accolades.push("Staff");
}
if (profile.Results[0].Moderator)
{
accolades.push("Moderator");
}
if (profile.Results[0].Partner)
{
accolades.push("Partner");
}
if (profile.Results[0].Founder)
{
accolades.push("Founder (" + founderTiers[profile.Results[0].Founder] + ")");
}
if (profile.Results[0].Accolades?.Heirloom)
else
{
accolades.push("Heirloom");
if (profile.Results[0].Moderator)
{
accolades.push("Moderator");
}
if (profile.Results[0].Partner)
{
accolades.push("Partner");
}
if (profile.Results[0].Guide)
{
accolades.push(guideTiers[profile.Results[0].Guide]);
}
if (profile.Results[0].Founder)
{
accolades.push("Founder (" + founderTiers[profile.Results[0].Founder] + ")");
}
if (profile.Results[0].Accolades?.Heirloom)
{
accolades.push("Heirloom");
}
}
if (accolades.length != 0)
{
Expand Down

0 comments on commit 0efe2fc

Please sign in to comment.