fix: only emit notif if popn class is GOD

This commit is contained in:
zkldi
2022-05-25 15:08:59 +01:00
parent b77950e2b5
commit 7deca34d86
2 changed files with 17 additions and 3 deletions
+11
View File
@@ -40,3 +40,14 @@ export enum SDVX_VF_CLASSES {
IMPERIAL_III,
IMPERIAL_IV,
}
export enum POPN_CLASSES {
KITTY,
GRADE_SCHOOL,
DELINQUENT,
DETECTIVE,
IDOL,
GENERAL,
HERMIT,
GOD,
}
+6 -3
View File
@@ -3,7 +3,7 @@ import { AllClassSets } from "tachi-common/js/game-classes";
import { BotConfig } from "../config";
import { client } from "../main";
import { GetUGPTStats, GetUserInfo } from "../utils/apiRequests";
import { SDVX_VF_CLASSES } from "../utils/constants";
import { POPN_CLASSES, SDVX_VF_CLASSES } from "../utils/constants";
import { CreateEmbed } from "../utils/embeds";
import { PrependTachiUrl } from "../utils/fetchTachi";
import logger from "../utils/logger";
@@ -92,6 +92,11 @@ function ShouldRenderUpdate(
SDVX_VF_CLASSES.IMPERIAL_III,
SDVX_VF_CLASSES.IMPERIAL_IV,
].includes(classValue);
} else if (game === "popn" && classSet === "class") {
return [
// All of the other classes in pop'n can be trivially blitzed through.
POPN_CLASSES.GOD,
];
}
return true;
@@ -112,8 +117,6 @@ function GetMinimumScores(game: Game, playtype: Playtype, classSet: AllClassSets
return 20;
} else if (game === "iidx") {
return 20;
} else if (game === "popn") {
return 20;
}
return null;