Made enum that describes different mod loaders

This commit is contained in:
Kir_Antipov 2021-12-07 21:32:27 +03:00
parent 184c337d90
commit 59f286e65e

View file

@ -0,0 +1,16 @@
enum ModLoaderType {
Fabric = 1,
Forge,
}
namespace ModLoaderType {
export function getValues(): ModLoaderType[] {
return <ModLoaderType[]>Object.values(ModLoaderType).filter(x => typeof x === "number");
}
export function toString(target: ModLoaderType): string {
return ModLoaderType[target] ?? target.toString();
}
}
export default ModLoaderType;