feat: more defs

This commit is contained in:
TrèsAbhi committed 2023-12-12 13:40:58 -06:00
1 parent 2e2ab9b2d9
commit 66dbc5b2ed
10 files changed
+192 -73

No files matched your search

+1 -1
View File
@@ -5,5 +5,5 @@ export async function readXMLDVPL<Type>(file: string) {
const parser = new XMLParser();
const xml = await readStringDVPL(file);
return parser.parse(xml).root as Type;
return parser.parse(xml) as Type;
}
+5
View File
@@ -0,0 +1,5 @@
import { NATION_IDS } from '../../constants/nations';
export function toUniqueId(nation: string, id: number) {
return (id << 8) + (NATION_IDS[nation] << 4) + 1;
}