UNPKG

@skullandbonestools/snbdata

Version:

Inofficial data package for the Skull and Bones game by Ubisoft.

21 lines 646 B
import eventsData from '../../data/events.json'; import { Seasons } from './seasons'; export class Event { constructor(id, seasons) { this.id = id; this.seasons = seasons; } static loadEvents() { const events = {}; for (const [key, value] of Object.entries(eventsData)) { const seasons = value.seasons.map((_season) => { const season = _season; return Seasons[season]; }); events[key] = new Event(value.id, seasons); } return events; } } export const Events = Event.loadEvents(); //# sourceMappingURL=events.js.map