show all modifiers now
This commit is contained in:
parent
d2be3d833b
commit
670f2047a0
@ -2,19 +2,18 @@
|
|||||||
* The score modifiers.
|
* The score modifiers.
|
||||||
*/
|
*/
|
||||||
export enum Modifier {
|
export enum Modifier {
|
||||||
DA = "Disappearing Arrows",
|
NF = "No Fail",
|
||||||
|
PM = "Pro Mode",
|
||||||
FS = "Faster Song",
|
FS = "Faster Song",
|
||||||
SF = "Super Fast Song",
|
SF = "Super Fast Song",
|
||||||
SS = "Slower Song",
|
SS = "Slower Song",
|
||||||
GN = "Ghost Notes",
|
GN = "Ghost Notes",
|
||||||
NA = "No Arrows",
|
DA = "Disappearing Arrows",
|
||||||
NO = "No Obstacles",
|
|
||||||
SA = "Strict Angles",
|
SA = "Strict Angles",
|
||||||
SC = "Small Notes",
|
SC = "Small Notes",
|
||||||
PM = "Pro Mode",
|
|
||||||
CS = "Fail on Saber Clash",
|
|
||||||
IF = "One Life",
|
IF = "One Life",
|
||||||
|
NO = "No Obstacles",
|
||||||
BE = "Battery Energy",
|
BE = "Battery Energy",
|
||||||
NF = "No Fail",
|
|
||||||
NB = "No Bombs",
|
NB = "No Bombs",
|
||||||
|
NA = "No Arrows",
|
||||||
}
|
}
|
||||||
|
@ -57,18 +57,35 @@ const badges: ScoreBadge[] = [
|
|||||||
}
|
}
|
||||||
|
|
||||||
const failed = score.modifiers.includes("No Fail" as Modifier);
|
const failed = score.modifiers.includes("No Fail" as Modifier);
|
||||||
|
const modCount = score.modifiers.length;
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<Tooltip
|
<Tooltip
|
||||||
display={
|
display={
|
||||||
|
<div className="flex flex-col gap-2">
|
||||||
<div>
|
<div>
|
||||||
<p>{accDetails}</p>
|
<p>{accDetails}</p>
|
||||||
{failed && <p className="text-red-500">Failed</p>}
|
{failed && <p className="text-red-500">Failed</p>}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
{modCount > 0 && (
|
||||||
|
<div>
|
||||||
|
<p className="font-semibold">Modifiers</p>
|
||||||
|
<p>{score.modifiers.join(", ")}</p>
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
|
</div>
|
||||||
}
|
}
|
||||||
>
|
>
|
||||||
<p className="cursor-default">
|
<p className="cursor-default">
|
||||||
{acc.toFixed(2)}% {failed && <span>NF</span>}
|
{acc.toFixed(2)}%
|
||||||
|
{modCount > 0
|
||||||
|
? ` ${Object.entries(Modifier)
|
||||||
|
.filter(mod => score.modifiers.includes(mod[1] as Modifier))
|
||||||
|
.map(mod => mod[0])
|
||||||
|
.splice(0, Object.entries(Modifier).length - 1)
|
||||||
|
.join("")}`
|
||||||
|
: ""}
|
||||||
</p>
|
</p>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
</>
|
</>
|
||||||
|
Reference in New Issue
Block a user