Files
wanderer/assets/js/hooks/Mapper/components/map/helpers/isKnownSpace.ts
2024-09-29 21:47:35 +03:00

18 lines
493 B
TypeScript

import { SOLAR_SYSTEM_CLASS_IDS } from '@/hooks/Mapper/components/map/constants.ts';
export const isKnownSpace = (wormholeClassID: number) => {
switch (wormholeClassID) {
case SOLAR_SYSTEM_CLASS_IDS.hs:
case SOLAR_SYSTEM_CLASS_IDS.ls:
case SOLAR_SYSTEM_CLASS_IDS.ns:
case SOLAR_SYSTEM_CLASS_IDS.zarzakh:
return true;
}
return false;
};
export const isPossibleSpace = (spaces: number[], wormholeClassID: number) => {
return spaces.includes(wormholeClassID);
};