Files
zkldi_Tachi/client/src/components/util/useBucket.tsx
T
2023-01-19 16:39:42 +00:00

15 lines
423 B
TypeScript

import { Game, GetGamePTConfig, Playtype } from "tachi-common";
import useLUGPTSettings from "./useLUGPTSettings";
export function useBucket(game: Game, playtype: Playtype) {
const { settings } = useLUGPTSettings();
if (!settings?.preferences.preferredDefaultEnum) {
const gptConfig = GetGamePTConfig(game, playtype);
return gptConfig.preferredDefaultEnum;
}
return settings.preferences.preferredDefaultEnum;
}