re-add per page/leaderboard embed colors
All checks were successful
Deploy Backend / deploy (push) Successful in 3m31s
Deploy Website / deploy (push) Successful in 5m17s

This commit is contained in:
Lee
2024-10-16 07:31:52 +01:00
parent 7f42a27d8f
commit ff9408fb8c
12 changed files with 131 additions and 22 deletions

View File

@ -21,6 +21,10 @@ import { delay } from "@ssr/common/utils/utils";
import { connectScoreSaberWebSocket } from "@ssr/common/websocket/scoresaber-websocket";
import ImageController from "./controller/image.controller";
import ReplayController from "./controller/replay.controller";
// @ts-ignore
import { MessageBuilder, Webhook } from "discord-webhook-node";
import { formatPp } from "@ssr/common/utils/number-utils";
import { ScoreService } from "./service/score.service";
// Load .env file
dotenv.config({
@ -33,8 +37,9 @@ await mongoose.connect(Config.mongoUri!); // Connect to MongoDB
setLogLevel("DEBUG");
connectScoreSaberWebSocket({
onScore: async score => {
await PlayerService.trackScore(score);
onScore: async playerScore => {
await PlayerService.trackScore(playerScore);
await ScoreService.notifyNumberOne(playerScore);
},
});