From b8af8320b73228275af30c0476df57cc225081dd Mon Sep 17 00:00:00 2001 From: Richard Date: Fri, 5 Jul 2024 13:51:55 -0700 Subject: [PATCH] fix: prioritize score stat --- src/server/players/services/scoreboard.ts | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/server/players/services/scoreboard.ts b/src/server/players/services/scoreboard.ts index d0849f7..a3a97e8 100644 --- a/src/server/players/services/scoreboard.ts +++ b/src/server/players/services/scoreboard.ts @@ -13,13 +13,18 @@ export async function initScoreboardService() { knockouts.Name = "☠️ KOs"; knockouts.Parent = stats; + const cash = new Instance("IntValue"); + cash.Name = "💵 Cash"; + cash.Parent = stats; + const score = new Instance("IntValue"); score.Name = "💯 Score"; score.Parent = stats; - const cash = new Instance("IntValue"); - cash.Name = "💵 Cash"; - cash.Parent = stats; + const isPrimary = new Instance("BoolValue"); + isPrimary.Name = "IsPrimary"; + isPrimary.Value = true; + isPrimary.Parent = score; const unsubscribeFromSnake = store.subscribe(selectSnakeById(player.Name), (snake) => { score.Value = snake ? snake.score : 0;