fix eslint

This commit is contained in:
dutlist 2024-06-26 01:33:51 +02:00 committed by AMelonInsideLemon
parent 6a9e56d802
commit 1728828fb3

View File

@ -36,7 +36,6 @@ import {
normalCircutRotations, normalCircutRotations,
hardCircutRotations hardCircutRotations
} from "@/src/constants/worldStateConstants"; } from "@/src/constants/worldStateConstants";
import { config } from "./configService";
export const createWorldState = async () => { export const createWorldState = async () => {
const worldState = new WorldState(); const worldState = new WorldState();
@ -661,7 +660,7 @@ const updateNigthWave = async () => {
else if (challenge.Challenge.startsWith("/Lotus/Types/Challenges/Seasons/WeeklyHard/")) weeklyHardCount++; else if (challenge.Challenge.startsWith("/Lotus/Types/Challenges/Seasons/WeeklyHard/")) weeklyHardCount++;
}); });
const addChallenges = async (count: number, limit: number, intervalStart: number, intervalEnd: number, challengesArray: string[], isDaily = false) => { const addChallenges = (count: number, limit: number, intervalStart: number, intervalEnd: number, challengesArray: string[], isDaily = false) => {
while (count < limit) { while (count < limit) {
challengesArray = challengesArray.filter(challenge => !usedChallenges.includes(challenge)) challengesArray = challengesArray.filter(challenge => !usedChallenges.includes(challenge))
const uniqueName = challengesArray[Math.floor(Math.random() * challengesArray.length)] const uniqueName = challengesArray[Math.floor(Math.random() * challengesArray.length)]
@ -680,9 +679,9 @@ const updateNigthWave = async () => {
} }
}; };
await addChallenges(dailyCount, 3, oneDayIntervalStart, oneDayIntervalEnd, dailyChallenges, true); addChallenges(dailyCount, 3, oneDayIntervalStart, oneDayIntervalEnd, dailyChallenges, true);
await addChallenges(weeklyCount, 5, oneWeekIntervalStart, oneWeekIntervalEnd, weeklyChallenges); addChallenges(weeklyCount, 5, oneWeekIntervalStart, oneWeekIntervalEnd, weeklyChallenges);
await addChallenges(weeklyHardCount, 2, oneWeekIntervalStart, oneWeekIntervalEnd, weeklyHardChallenges); addChallenges(weeklyHardCount, 2, oneWeekIntervalStart, oneWeekIntervalEnd, weeklyHardChallenges);
season = { season = {
Activation: season.Activation || 1715796000000, Activation: season.Activation || 1715796000000,