@drincs/nqtr 0.3.7 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/RoomInterface-BRA386zn.d.mts +171 -0
- package/dist/RoomInterface-Cwm08AzD.d.ts +171 -0
- package/dist/{StageInterface-DX74DUxG.d.mts → StageInterface-LDgQToad.d.mts} +28 -14
- package/dist/{StageInterface-DX74DUxG.d.ts → StageInterface-LDgQToad.d.ts} +28 -14
- package/dist/classes/index.cjs +2 -0
- package/dist/classes/index.cjs.map +1 -0
- package/dist/classes/index.d.mts +508 -31
- package/dist/classes/index.d.ts +508 -31
- package/dist/classes/index.mjs +1 -1
- package/dist/classes/index.mjs.map +1 -1
- package/dist/decorators/index.cjs +2 -0
- package/dist/decorators/index.cjs.map +1 -0
- package/dist/decorators/index.d.mts +161 -9
- package/dist/decorators/index.d.ts +161 -9
- package/dist/decorators/index.mjs +1 -1
- package/dist/decorators/index.mjs.map +1 -1
- package/dist/index-B-x-OmU2.d.ts +186 -0
- package/dist/index-CJubtUni.d.mts +301 -0
- package/dist/index-Cq_kqDbo.d.ts +301 -0
- package/dist/index-k8ho_YWr.d.mts +186 -0
- package/dist/index.cjs +2 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.mts +16 -46
- package/dist/index.d.ts +16 -46
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/dist/interface/index.cjs +2 -0
- package/dist/{functions/index.js.map → interface/index.cjs.map} +1 -1
- package/dist/interface/index.d.mts +3 -14
- package/dist/interface/index.d.ts +3 -14
- package/dist/managers/index.cjs +2 -0
- package/dist/managers/index.cjs.map +1 -0
- package/dist/managers/index.d.mts +4 -17
- package/dist/managers/index.d.ts +4 -17
- package/dist/managers/index.mjs +1 -1
- package/dist/managers/index.mjs.map +1 -1
- package/dist/types/index.cjs +2 -0
- package/dist/{functions/index.mjs.map → types/index.cjs.map} +1 -1
- package/dist/types/index.d.mts +60 -4
- package/dist/types/index.d.ts +60 -4
- package/package.json +13 -5
- package/dist/RoomInterface-CdAM_q7P.d.ts +0 -83
- package/dist/RoomInterface-DURfkQ7u.d.mts +0 -83
- package/dist/classes/ActivityBaseModel.d.mts +0 -63
- package/dist/classes/ActivityBaseModel.d.ts +0 -63
- package/dist/classes/ActivityBaseModel.js +0 -2
- package/dist/classes/ActivityBaseModel.js.map +0 -1
- package/dist/classes/ActivityBaseModel.mjs +0 -2
- package/dist/classes/ActivityBaseModel.mjs.map +0 -1
- package/dist/classes/ActivityStoredClass.d.mts +0 -27
- package/dist/classes/ActivityStoredClass.d.ts +0 -27
- package/dist/classes/ActivityStoredClass.js +0 -2
- package/dist/classes/ActivityStoredClass.js.map +0 -1
- package/dist/classes/ActivityStoredClass.mjs +0 -2
- package/dist/classes/ActivityStoredClass.mjs.map +0 -1
- package/dist/classes/CommitmentBaseModel.d.mts +0 -65
- package/dist/classes/CommitmentBaseModel.d.ts +0 -65
- package/dist/classes/CommitmentBaseModel.js +0 -2
- package/dist/classes/CommitmentBaseModel.js.map +0 -1
- package/dist/classes/CommitmentBaseModel.mjs +0 -2
- package/dist/classes/CommitmentBaseModel.mjs.map +0 -1
- package/dist/classes/CommitmentStoredClass.d.mts +0 -31
- package/dist/classes/CommitmentStoredClass.d.ts +0 -31
- package/dist/classes/CommitmentStoredClass.js +0 -2
- package/dist/classes/CommitmentStoredClass.js.map +0 -1
- package/dist/classes/CommitmentStoredClass.mjs +0 -2
- package/dist/classes/CommitmentStoredClass.mjs.map +0 -1
- package/dist/classes/index.js +0 -2
- package/dist/classes/index.js.map +0 -1
- package/dist/classes/navigation/LocationBaseModel.d.mts +0 -54
- package/dist/classes/navigation/LocationBaseModel.d.ts +0 -54
- package/dist/classes/navigation/LocationBaseModel.js +0 -2
- package/dist/classes/navigation/LocationBaseModel.js.map +0 -1
- package/dist/classes/navigation/LocationBaseModel.mjs +0 -2
- package/dist/classes/navigation/LocationBaseModel.mjs.map +0 -1
- package/dist/classes/navigation/LocationStoredClass.d.mts +0 -23
- package/dist/classes/navigation/LocationStoredClass.d.ts +0 -23
- package/dist/classes/navigation/LocationStoredClass.js +0 -2
- package/dist/classes/navigation/LocationStoredClass.js.map +0 -1
- package/dist/classes/navigation/LocationStoredClass.mjs +0 -2
- package/dist/classes/navigation/LocationStoredClass.mjs.map +0 -1
- package/dist/classes/navigation/MapBaseModel.d.mts +0 -41
- package/dist/classes/navigation/MapBaseModel.d.ts +0 -41
- package/dist/classes/navigation/MapBaseModel.js +0 -2
- package/dist/classes/navigation/MapBaseModel.js.map +0 -1
- package/dist/classes/navigation/MapBaseModel.mjs +0 -2
- package/dist/classes/navigation/MapBaseModel.mjs.map +0 -1
- package/dist/classes/navigation/MapStoredClass.d.mts +0 -14
- package/dist/classes/navigation/MapStoredClass.d.ts +0 -14
- package/dist/classes/navigation/MapStoredClass.js +0 -2
- package/dist/classes/navigation/MapStoredClass.js.map +0 -1
- package/dist/classes/navigation/MapStoredClass.mjs +0 -2
- package/dist/classes/navigation/MapStoredClass.mjs.map +0 -1
- package/dist/classes/navigation/NavigationAbstractClass.d.mts +0 -48
- package/dist/classes/navigation/NavigationAbstractClass.d.ts +0 -48
- package/dist/classes/navigation/NavigationAbstractClass.js +0 -2
- package/dist/classes/navigation/NavigationAbstractClass.js.map +0 -1
- package/dist/classes/navigation/NavigationAbstractClass.mjs +0 -2
- package/dist/classes/navigation/NavigationAbstractClass.mjs.map +0 -1
- package/dist/classes/navigation/RoomBaseModel.d.mts +0 -67
- package/dist/classes/navigation/RoomBaseModel.d.ts +0 -67
- package/dist/classes/navigation/RoomBaseModel.js +0 -2
- package/dist/classes/navigation/RoomBaseModel.js.map +0 -1
- package/dist/classes/navigation/RoomBaseModel.mjs +0 -2
- package/dist/classes/navigation/RoomBaseModel.mjs.map +0 -1
- package/dist/classes/navigation/RoomStoredClass.d.mts +0 -24
- package/dist/classes/navigation/RoomStoredClass.d.ts +0 -24
- package/dist/classes/navigation/RoomStoredClass.js +0 -2
- package/dist/classes/navigation/RoomStoredClass.js.map +0 -1
- package/dist/classes/navigation/RoomStoredClass.mjs +0 -2
- package/dist/classes/navigation/RoomStoredClass.mjs.map +0 -1
- package/dist/classes/quest/QuestBaseModel.d.mts +0 -36
- package/dist/classes/quest/QuestBaseModel.d.ts +0 -36
- package/dist/classes/quest/QuestBaseModel.js +0 -2
- package/dist/classes/quest/QuestBaseModel.js.map +0 -1
- package/dist/classes/quest/QuestBaseModel.mjs +0 -2
- package/dist/classes/quest/QuestBaseModel.mjs.map +0 -1
- package/dist/classes/quest/QuestStoredClass.d.mts +0 -37
- package/dist/classes/quest/QuestStoredClass.d.ts +0 -37
- package/dist/classes/quest/QuestStoredClass.js +0 -2
- package/dist/classes/quest/QuestStoredClass.js.map +0 -1
- package/dist/classes/quest/QuestStoredClass.mjs +0 -2
- package/dist/classes/quest/QuestStoredClass.mjs.map +0 -1
- package/dist/classes/quest/StageBaseModel.d.mts +0 -50
- package/dist/classes/quest/StageBaseModel.d.ts +0 -50
- package/dist/classes/quest/StageBaseModel.js +0 -2
- package/dist/classes/quest/StageBaseModel.js.map +0 -1
- package/dist/classes/quest/StageBaseModel.mjs +0 -2
- package/dist/classes/quest/StageBaseModel.mjs.map +0 -1
- package/dist/classes/quest/StageStoredClass.d.mts +0 -46
- package/dist/classes/quest/StageStoredClass.d.ts +0 -46
- package/dist/classes/quest/StageStoredClass.js +0 -2
- package/dist/classes/quest/StageStoredClass.js.map +0 -1
- package/dist/classes/quest/StageStoredClass.mjs +0 -2
- package/dist/classes/quest/StageStoredClass.mjs.map +0 -1
- package/dist/constants.d.mts +0 -4
- package/dist/constants.d.ts +0 -4
- package/dist/constants.js +0 -2
- package/dist/constants.js.map +0 -1
- package/dist/constants.mjs +0 -2
- package/dist/constants.mjs.map +0 -1
- package/dist/decorators/ActivityDecorator.d.mts +0 -15
- package/dist/decorators/ActivityDecorator.d.ts +0 -15
- package/dist/decorators/ActivityDecorator.js +0 -2
- package/dist/decorators/ActivityDecorator.js.map +0 -1
- package/dist/decorators/ActivityDecorator.mjs +0 -2
- package/dist/decorators/ActivityDecorator.mjs.map +0 -1
- package/dist/decorators/CommitmentDecorator.d.mts +0 -27
- package/dist/decorators/CommitmentDecorator.d.ts +0 -27
- package/dist/decorators/CommitmentDecorator.js +0 -2
- package/dist/decorators/CommitmentDecorator.js.map +0 -1
- package/dist/decorators/CommitmentDecorator.mjs +0 -2
- package/dist/decorators/CommitmentDecorator.mjs.map +0 -1
- package/dist/decorators/QuestDecorator.d.mts +0 -22
- package/dist/decorators/QuestDecorator.d.ts +0 -22
- package/dist/decorators/QuestDecorator.js +0 -2
- package/dist/decorators/QuestDecorator.js.map +0 -1
- package/dist/decorators/QuestDecorator.mjs +0 -2
- package/dist/decorators/QuestDecorator.mjs.map +0 -1
- package/dist/decorators/RoomDecorator.d.mts +0 -28
- package/dist/decorators/RoomDecorator.d.ts +0 -28
- package/dist/decorators/RoomDecorator.js +0 -2
- package/dist/decorators/RoomDecorator.js.map +0 -1
- package/dist/decorators/RoomDecorator.mjs +0 -2
- package/dist/decorators/RoomDecorator.mjs.map +0 -1
- package/dist/decorators/index.js +0 -2
- package/dist/decorators/index.js.map +0 -1
- package/dist/functions/index.d.mts +0 -2
- package/dist/functions/index.d.ts +0 -2
- package/dist/functions/index.js +0 -2
- package/dist/functions/index.mjs +0 -2
- package/dist/index.js +0 -2
- package/dist/index.js.map +0 -1
- package/dist/interface/ActivityInterface.d.mts +0 -40
- package/dist/interface/ActivityInterface.d.ts +0 -40
- package/dist/interface/ActivityInterface.js +0 -2
- package/dist/interface/ActivityInterface.js.map +0 -1
- package/dist/interface/ActivityInterface.mjs +0 -2
- package/dist/interface/ActivityInterface.mjs.map +0 -1
- package/dist/interface/ActivityProps.d.mts +0 -48
- package/dist/interface/ActivityProps.d.ts +0 -48
- package/dist/interface/ActivityProps.js +0 -2
- package/dist/interface/ActivityProps.js.map +0 -1
- package/dist/interface/ActivityProps.mjs +0 -2
- package/dist/interface/ActivityProps.mjs.map +0 -1
- package/dist/interface/CommitmentInterface.d.mts +0 -6
- package/dist/interface/CommitmentInterface.d.ts +0 -6
- package/dist/interface/CommitmentInterface.js +0 -2
- package/dist/interface/CommitmentInterface.js.map +0 -1
- package/dist/interface/CommitmentInterface.mjs +0 -2
- package/dist/interface/CommitmentInterface.mjs.map +0 -1
- package/dist/interface/CommitmentProps.d.mts +0 -79
- package/dist/interface/CommitmentProps.d.ts +0 -79
- package/dist/interface/CommitmentProps.js +0 -2
- package/dist/interface/CommitmentProps.js.map +0 -1
- package/dist/interface/CommitmentProps.mjs +0 -2
- package/dist/interface/CommitmentProps.mjs.map +0 -1
- package/dist/interface/index.js +0 -2
- package/dist/interface/index.js.map +0 -1
- package/dist/interface/navigation/LocationBaseModelProps.d.mts +0 -32
- package/dist/interface/navigation/LocationBaseModelProps.d.ts +0 -32
- package/dist/interface/navigation/LocationBaseModelProps.js +0 -2
- package/dist/interface/navigation/LocationBaseModelProps.js.map +0 -1
- package/dist/interface/navigation/LocationBaseModelProps.mjs +0 -2
- package/dist/interface/navigation/LocationBaseModelProps.mjs.map +0 -1
- package/dist/interface/navigation/LocationInterface.d.mts +0 -6
- package/dist/interface/navigation/LocationInterface.d.ts +0 -6
- package/dist/interface/navigation/LocationInterface.js +0 -2
- package/dist/interface/navigation/LocationInterface.js.map +0 -1
- package/dist/interface/navigation/LocationInterface.mjs +0 -2
- package/dist/interface/navigation/LocationInterface.mjs.map +0 -1
- package/dist/interface/navigation/MapBaseModelProps.d.mts +0 -22
- package/dist/interface/navigation/MapBaseModelProps.d.ts +0 -22
- package/dist/interface/navigation/MapBaseModelProps.js +0 -2
- package/dist/interface/navigation/MapBaseModelProps.js.map +0 -1
- package/dist/interface/navigation/MapBaseModelProps.mjs +0 -2
- package/dist/interface/navigation/MapBaseModelProps.mjs.map +0 -1
- package/dist/interface/navigation/MapInterface.d.mts +0 -6
- package/dist/interface/navigation/MapInterface.d.ts +0 -6
- package/dist/interface/navigation/MapInterface.js +0 -2
- package/dist/interface/navigation/MapInterface.js.map +0 -1
- package/dist/interface/navigation/MapInterface.mjs +0 -2
- package/dist/interface/navigation/MapInterface.mjs.map +0 -1
- package/dist/interface/navigation/NavigationAbstractClass.d.mts +0 -54
- package/dist/interface/navigation/NavigationAbstractClass.d.ts +0 -54
- package/dist/interface/navigation/NavigationAbstractClass.js +0 -2
- package/dist/interface/navigation/NavigationAbstractClass.js.map +0 -1
- package/dist/interface/navigation/NavigationAbstractClass.mjs +0 -2
- package/dist/interface/navigation/NavigationAbstractClass.mjs.map +0 -1
- package/dist/interface/navigation/RoomBaseModelProps.d.mts +0 -37
- package/dist/interface/navigation/RoomBaseModelProps.d.ts +0 -37
- package/dist/interface/navigation/RoomBaseModelProps.js +0 -2
- package/dist/interface/navigation/RoomBaseModelProps.js.map +0 -1
- package/dist/interface/navigation/RoomBaseModelProps.mjs +0 -2
- package/dist/interface/navigation/RoomBaseModelProps.mjs.map +0 -1
- package/dist/interface/navigation/RoomInterface.d.mts +0 -6
- package/dist/interface/navigation/RoomInterface.d.ts +0 -6
- package/dist/interface/navigation/RoomInterface.js +0 -2
- package/dist/interface/navigation/RoomInterface.js.map +0 -1
- package/dist/interface/navigation/RoomInterface.mjs +0 -2
- package/dist/interface/navigation/RoomInterface.mjs.map +0 -1
- package/dist/interface/quest/QuestInterface.d.mts +0 -2
- package/dist/interface/quest/QuestInterface.d.ts +0 -2
- package/dist/interface/quest/QuestInterface.js +0 -2
- package/dist/interface/quest/QuestInterface.js.map +0 -1
- package/dist/interface/quest/QuestInterface.mjs +0 -2
- package/dist/interface/quest/QuestInterface.mjs.map +0 -1
- package/dist/interface/quest/QuestProps.d.mts +0 -39
- package/dist/interface/quest/QuestProps.d.ts +0 -39
- package/dist/interface/quest/QuestProps.js +0 -2
- package/dist/interface/quest/QuestProps.js.map +0 -1
- package/dist/interface/quest/QuestProps.mjs +0 -2
- package/dist/interface/quest/QuestProps.mjs.map +0 -1
- package/dist/interface/quest/StageFlags.d.mts +0 -12
- package/dist/interface/quest/StageFlags.d.ts +0 -12
- package/dist/interface/quest/StageFlags.js +0 -2
- package/dist/interface/quest/StageFlags.js.map +0 -1
- package/dist/interface/quest/StageFlags.mjs +0 -2
- package/dist/interface/quest/StageFlags.mjs.map +0 -1
- package/dist/interface/quest/StageInterface.d.mts +0 -2
- package/dist/interface/quest/StageInterface.d.ts +0 -2
- package/dist/interface/quest/StageInterface.js +0 -2
- package/dist/interface/quest/StageInterface.js.map +0 -1
- package/dist/interface/quest/StageInterface.mjs +0 -2
- package/dist/interface/quest/StageInterface.mjs.map +0 -1
- package/dist/interface/quest/StageProps.d.mts +0 -60
- package/dist/interface/quest/StageProps.d.ts +0 -60
- package/dist/interface/quest/StageProps.js +0 -2
- package/dist/interface/quest/StageProps.js.map +0 -1
- package/dist/interface/quest/StageProps.mjs +0 -2
- package/dist/interface/quest/StageProps.mjs.map +0 -1
- package/dist/managers/NavigatorManager.d.mts +0 -22
- package/dist/managers/NavigatorManager.d.ts +0 -22
- package/dist/managers/NavigatorManager.js +0 -2
- package/dist/managers/NavigatorManager.js.map +0 -1
- package/dist/managers/NavigatorManager.mjs +0 -2
- package/dist/managers/NavigatorManager.mjs.map +0 -1
- package/dist/managers/QuestManager.d.mts +0 -17
- package/dist/managers/QuestManager.d.ts +0 -17
- package/dist/managers/QuestManager.js +0 -2
- package/dist/managers/QuestManager.js.map +0 -1
- package/dist/managers/QuestManager.mjs +0 -2
- package/dist/managers/QuestManager.mjs.map +0 -1
- package/dist/managers/RoutineManager.d.mts +0 -59
- package/dist/managers/RoutineManager.d.ts +0 -59
- package/dist/managers/RoutineManager.js +0 -2
- package/dist/managers/RoutineManager.js.map +0 -1
- package/dist/managers/RoutineManager.mjs +0 -2
- package/dist/managers/RoutineManager.mjs.map +0 -1
- package/dist/managers/TimeManager.d.mts +0 -74
- package/dist/managers/TimeManager.d.ts +0 -74
- package/dist/managers/TimeManager.js +0 -2
- package/dist/managers/TimeManager.js.map +0 -1
- package/dist/managers/TimeManager.mjs +0 -2
- package/dist/managers/TimeManager.mjs.map +0 -1
- package/dist/managers/TimeManagerSettings.d.mts +0 -13
- package/dist/managers/TimeManagerSettings.d.ts +0 -13
- package/dist/managers/TimeManagerSettings.js +0 -2
- package/dist/managers/TimeManagerSettings.js.map +0 -1
- package/dist/managers/TimeManagerSettings.mjs +0 -2
- package/dist/managers/TimeManagerSettings.mjs.map +0 -1
- package/dist/managers/index.js +0 -2
- package/dist/managers/index.js.map +0 -1
- package/dist/nqtr.d.d.mts +0 -195
- package/dist/nqtr.d.d.ts +0 -195
- package/dist/nqtr.d.js +0 -2
- package/dist/nqtr.d.js.map +0 -1
- package/dist/nqtr.d.mjs +0 -2
- package/dist/nqtr.d.mjs.map +0 -1
- package/dist/types/ExecutionType.d.mts +0 -3
- package/dist/types/ExecutionType.d.ts +0 -3
- package/dist/types/ExecutionType.js +0 -2
- package/dist/types/ExecutionType.js.map +0 -1
- package/dist/types/ExecutionType.mjs +0 -2
- package/dist/types/ExecutionType.mjs.map +0 -1
- package/dist/types/OnRunEvent.d.mts +0 -9
- package/dist/types/OnRunEvent.d.ts +0 -9
- package/dist/types/OnRunEvent.js +0 -2
- package/dist/types/OnRunEvent.js.map +0 -1
- package/dist/types/OnRunEvent.mjs +0 -2
- package/dist/types/OnRunEvent.mjs.map +0 -1
- package/dist/types/QuestsRequired.d.mts +0 -2
- package/dist/types/QuestsRequired.d.ts +0 -2
- package/dist/types/QuestsRequired.js +0 -2
- package/dist/types/QuestsRequired.js.map +0 -1
- package/dist/types/QuestsRequired.mjs +0 -2
- package/dist/types/QuestsRequired.mjs.map +0 -1
- package/dist/types/TimeDataType.d.mts +0 -6
- package/dist/types/TimeDataType.d.ts +0 -6
- package/dist/types/TimeDataType.js +0 -2
- package/dist/types/TimeDataType.js.map +0 -1
- package/dist/types/TimeDataType.mjs +0 -2
- package/dist/types/TimeDataType.mjs.map +0 -1
- package/dist/types/TimeSettings.d.mts +0 -58
- package/dist/types/TimeSettings.d.ts +0 -58
- package/dist/types/TimeSettings.js +0 -2
- package/dist/types/TimeSettings.js.map +0 -1
- package/dist/types/TimeSettings.mjs +0 -2
- package/dist/types/TimeSettings.mjs.map +0 -1
- package/dist/types/index.js +0 -2
- package/dist/types/index.js.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/utils/log-utility.ts","../../src/decorators/RegisteredActivities.ts","../../src/decorators/RegisteredCommitments.ts","../../src/decorators/RegisteredLocations.ts","../../src/decorators/RegisteredMaps.ts","../../src/decorators/RegisteredQuests.ts","../../src/decorators/RegisteredRooms.ts"],"names":["logger","message","optionalParams","registeredActivities","CachedMap","RegisteredActivities","add","activities","activity","get","id","e","values","has","RegisteredActivities_default","registeredCommitments","RegisteredCommitments","commitments","commitment","RegisteredCommitments_default","registeredLocations","RegisteredLocations","location","c","RegisteredLocations_default","registeredMaps","RegisteredMaps","map","RegisteredMaps_default","registeredQuests","RegisteredQuest","quests","quest","RegisteredQuests_default","registeredRooms","RegisteredRooms","room","RegisteredRooms_default"],"mappings":"mDAAO,IAAUA,OACAA,CAAAA,CAAA,GAAA,CAAM,CAACC,CAAAA,CAAAA,GAAkBC,CAAAA,GAA0B,QAAQ,GAAA,CAAI,CAAA,OAAA,EAAUD,CAAO,CAAA,CAAA,CAAI,GAAGC,CAAc,CAAA,CACrGF,CAAAA,CAAA,IAAA,CAAO,CAACC,CAAAA,CAAAA,GAAkBC,CAAAA,GACnC,QAAQ,IAAA,CAAK,CAAA,OAAA,EAAUD,CAAO,CAAA,CAAA,CAAI,GAAGC,CAAc,CAAA,CAC1CF,CAAAA,CAAA,KAAA,CAAQ,CAACC,CAAAA,CAAAA,GAAkBC,CAAAA,GACpC,QAAQ,KAAA,CAAM,CAAA,OAAA,EAAUD,CAAO,CAAA,CAAA,CAAI,GAAGC,CAAc,CAAA,CAC3CF,CAAAA,CAAA,IAAA,CAAO,CAACC,CAAAA,CAAAA,GAAkBC,CAAAA,GACnC,QAAQ,IAAA,CAAK,CAAA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namespace logger {\n export const log = (message?: any, ...optionalParams: any[]) => console.log(`[NQTR] ${message}`, ...optionalParams);\n export const warn = (message?: any, ...optionalParams: any[]) =>\n console.warn(`[NQTR] ${message}`, ...optionalParams);\n export const error = (message?: any, ...optionalParams: any[]) =>\n console.error(`[NQTR] ${message}`, ...optionalParams);\n export const info = (message?: any, ...optionalParams: any[]) =>\n console.info(`[NQTR] ${message}`, ...optionalParams);\n}\n","import { CachedMap } from \"@drincs/pixi-vn\";\nimport { ActivityInterface } from \"../interface\";\nimport { logger } from \"../utils/log-utility\";\n\n/**\n * A Map that contains all activities registered and available to be used.\n * The key is the id of the activity and the value is the activity itself.\n */\nconst registeredActivities = new CachedMap<string, ActivityInterface>({ cacheSize: 20 });\n\nnamespace RegisteredActivities {\n /**\n * Save an activity in the registered activities. If the activity already exists, it will be overwritten.\n * @param activity The activity to save.\n * @returns\n */\n export function add(activities: ActivityInterface | ActivityInterface[]) {\n if (Array.isArray(activities)) {\n activities.forEach((activity) => RegisteredActivities.add(activity));\n return;\n }\n registeredActivities.set(activities.id, activities);\n }\n\n /**\n * Get an activity by its id.\n * @param id The id of the activity.\n * @returns The activity or undefined if not found.\n */\n export function get(id: string): ActivityInterface | undefined {\n try {\n let activity = registeredActivities.get(id);\n if (!activity) {\n console.warn(`[NQTR] Activity ${id} not found, you should register it first`);\n return;\n }\n return activity;\n } catch (e) {\n logger.error(`Error while getting Activity ${id}`, e);\n return;\n }\n }\n\n /**\n * Get a list of all activities registered.\n * @returns An array of activities.\n */\n export function values(): ActivityInterface[] {\n return Array.from(registeredActivities.values());\n }\n\n /**\n * Check if an activity is registered.\n * @param id The id of the activity.\n * @returns True if the activity is registered, false otherwise.\n */\n export function has(id: string): boolean {\n return registeredActivities.has(id);\n }\n}\nexport default RegisteredActivities;\n","import { CachedMap } from \"@drincs/pixi-vn\";\nimport { CommitmentInterface } from \"../interface\";\nimport { logger } from \"../utils/log-utility\";\n\n/**\n * A Map that contains all commitments registered and available to be used.\n * The key is the id of the commitment and the value is the commitment itself.\n */\nexport const registeredCommitments = new CachedMap<string, CommitmentInterface>({ cacheSize: 20 });\nexport const fixedCommitments = new CachedMap<string, CommitmentInterface>({ cacheSize: 20 });\n\nnamespace RegisteredCommitments {\n /**\n * Save a commitment in the registered commitments. If the commitment already exists, it will be overwritten.\n * @param commitment The commitment to save.\n * @returns\n */\n export function add(commitments: CommitmentInterface | CommitmentInterface[]) {\n if (Array.isArray(commitments)) {\n commitments.forEach((commitment) => RegisteredCommitments.add(commitment));\n return;\n }\n console.warn(`[NQTR] Registering commitment ${commitments.id}`, commitments);\n registeredCommitments.set(commitments.id, commitments);\n }\n /**\n * Get a commitment by its id.\n * @param id The id of the commitment.\n * @returns The commitment or undefined if not found.\n */\n export function get(id: string): CommitmentInterface | undefined {\n try {\n let commitment = registeredCommitments.get(id);\n if (!commitment) {\n console.warn(`[NQTR] Commitment ${id} not found, you should register it first`);\n return;\n }\n return commitment;\n } catch (e) {\n logger.error(`Error while getting Commitment ${id}`, e);\n return;\n }\n }\n /**\n * Get a list of all commitments registered.\n * @returns An array of commitments.\n */\n export function values(): CommitmentInterface[] {\n return Array.from(registeredCommitments.values());\n }\n /**\n * Check if a commitment is registered.\n * @param id The id of the commitment.\n * @returns True if the commitment is registered, false otherwise.\n */\n export function has(id: string): boolean {\n return registeredCommitments.has(id);\n }\n}\nexport default RegisteredCommitments;\n","import { CachedMap } from \"@drincs/pixi-vn\";\nimport { LocationInterface } from \"../interface\";\nimport { logger } from \"../utils/log-utility\";\n\n/**\n * A Map that contains all locations registered and available to be used.\n * The key is the id of the location and the value is the location itself.\n */\nconst registeredLocations = new CachedMap<string, LocationInterface>({ cacheSize: 20 });\n\nnamespace RegisteredLocations {\n /**\n * Save a location in the registered locations. If the location already exists, it will be overwritten.\n * @param location The location to save.\n * @returns\n */\n export function add(location: LocationInterface | LocationInterface[]) {\n if (Array.isArray(location)) {\n location.forEach((c) => add(c));\n return;\n }\n if (registeredLocations.has(location.id)) {\n console.warn(`[NQTR] Location id ${location.id} already exists, it will be overwritten`);\n }\n registeredLocations.set(location.id, location);\n }\n\n /**\n * Get a location by its id.\n * @param id The id of the location.\n * @returns The location or undefined if not found.\n */\n export function get(id: string): LocationInterface | undefined {\n try {\n let location = registeredLocations.get(id);\n if (!location) {\n console.warn(`[NQTR] Location ${id} not found, you should register it first`);\n return;\n }\n return location;\n } catch (e) {\n logger.error(`Error while getting Location ${id}`, e);\n return;\n }\n }\n\n /**\n * Get a list of all locations registered.\n * @returns An array of locations.\n */\n export function values(): LocationInterface[] {\n return Array.from(registeredLocations.values());\n }\n\n /**\n * Check if a location is registered.\n * @param id The id of the location.\n * @returns True if the location is registered, false otherwise.\n */\n export function has(id: string): boolean {\n return registeredLocations.has(id);\n }\n}\nexport default RegisteredLocations;\n","import { CachedMap } from \"@drincs/pixi-vn\";\nimport { MapInterface } from \"../interface\";\nimport { logger } from \"../utils/log-utility\";\n\n/**\n * A Map that contains all maps registered and available to be used.\n * The key is the id of the map and the value is the map itself.\n */\nconst registeredMaps = new CachedMap<string, MapInterface>({ cacheSize: 20 });\n\nnamespace RegisteredMaps {\n /**\n * Save a map in the registered maps. If the map already exists, it will be overwritten.\n * @param map The map to save.\n * @returns\n */\n export function add(map: MapInterface | MapInterface[]) {\n if (Array.isArray(map)) {\n map.forEach((c) => add(c));\n return;\n }\n if (registeredMaps.has(map.id)) {\n console.warn(`[NQTR] Map id ${map.id} already exists, it will be overwritten`);\n }\n registeredMaps.set(map.id, map);\n }\n\n /**\n * Get a map by its id.\n * @param id The id of the map.\n * @returns The map or undefined if not found.\n */\n export function get(id: string): MapInterface | undefined {\n try {\n let map = registeredMaps.get(id);\n if (!map) {\n console.warn(`[NQTR] Map ${id} not found, you should register it first`);\n return;\n }\n return map;\n } catch (e) {\n logger.error(`Error while getting Map ${id}`, e);\n return;\n }\n }\n\n /**\n * Get a list of all maps registered.\n * @returns An array of maps.\n */\n export function values(): MapInterface[] {\n return Array.from(registeredMaps.values());\n }\n\n /**\n * Check if a map is registered.\n * @param id The id of the map.\n * @returns True if the map is registered, false otherwise.\n */\n export function has(id: string): boolean {\n return registeredMaps.has(id);\n }\n}\nexport default RegisteredMaps;\n","import { CachedMap } from \"@drincs/pixi-vn\";\nimport { QuestInterface } from \"../interface\";\nimport { logger } from \"../utils/log-utility\";\n\n/**\n * A Map that contains all quests registered and available to be used.\n * The key is the id of the quest and the value is the quest itself.\n */\nconst registeredQuests = new CachedMap<string, QuestInterface>({ cacheSize: 5 });\n\nnamespace RegisteredQuest {\n /**\n * Save a quest in the registered quests. If the quest already exists, it will be overwritten.\n * @param quest The quest to save.\n * @returns\n */\n export function add(quests: QuestInterface | QuestInterface[]) {\n if (Array.isArray(quests)) {\n quests.forEach((quest) => RegisteredQuest.add(quest));\n return;\n }\n registeredQuests.set(quests.id, quests);\n }\n /**\n * Get a quest by its id.\n * @param id The id of the quest.\n * @returns The quest or undefined if not found.\n */\n export function get(id: string): QuestInterface | undefined {\n try {\n let quest = registeredQuests.get(id);\n if (!quest) {\n console.warn(`[NQTR] Quest ${id} not found, you should register it first`);\n return;\n }\n return quest;\n } catch (e) {\n logger.error(`Error while getting Quest ${id}`, e);\n return;\n }\n }\n /**\n * Get a list of all quests registered.\n * @returns An array of quests.\n */\n export function values(): QuestInterface[] {\n return Array.from(registeredQuests.values());\n }\n /**\n * Check if a quest is registered.\n * @param id The id of the quest.\n * @returns True if the quest is registered, false otherwise.\n */\n export function has(id: string): boolean {\n return registeredQuests.has(id);\n }\n}\nexport default RegisteredQuest;\n","import { CachedMap } from \"@drincs/pixi-vn\";\nimport { RoomInterface } from \"../interface\";\nimport { logger } from \"../utils/log-utility\";\nimport RegisteredLocations from \"./RegisteredLocations\";\nimport RegisteredMaps from \"./RegisteredMaps\";\n\n/**\n * A Map that contains all rooms registered and available to be used.\n * The key is the id of the room and the value is the room itself.\n */\nconst registeredRooms = new CachedMap<string, RoomInterface>({ cacheSize: 20 });\n\nnamespace RegisteredRooms {\n /**\n * Save a room in the registered rooms, and their location and map if they are not already registered.\n * If the room already exists, it will be overwritten.\n * @param room The room to save.\n * @returns\n */\n export function add(room: RoomInterface | RoomInterface[]) {\n if (Array.isArray(room)) {\n room.forEach((c) => add(c));\n return;\n }\n registeredRooms.set(room.id, room);\n let location = room.location;\n RegisteredLocations.add(location);\n let map = location?.map;\n if (map) {\n RegisteredMaps.add(map);\n }\n }\n\n /**\n * Get a room by its id.\n * @param id The id of the room.\n * @returns The room or undefined if not found.\n */\n export function get(id: string): RoomInterface | undefined {\n try {\n let room = registeredRooms.get(id);\n if (!room) {\n console.warn(`[NQTR] Room ${id} not found, you should register it first`);\n return;\n }\n return room;\n } catch (e) {\n logger.error(`Error while getting Room ${id}`, e);\n return;\n }\n }\n\n /**\n * Get a list of all rooms registered.\n * @returns An array of rooms.\n */\n export function values(): RoomInterface[] {\n return Array.from(registeredRooms.values());\n }\n\n /**\n * Check if a room is registered.\n * @param id The id of the room.\n * @returns True if the room is registered, false otherwise.\n */\n export function has(id: string): boolean {\n return registeredRooms.has(id);\n }\n}\nexport default RegisteredRooms;\n"]}
|
|
@@ -1,11 +1,163 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
export { saveQuest } from './QuestDecorator.mjs';
|
|
4
|
-
export { saveRoom } from './RoomDecorator.mjs';
|
|
5
|
-
import '../interface/ActivityInterface.mjs';
|
|
1
|
+
import { A as ActivityInterface, C as CommitmentInterface, L as LocationInterface, M as MapInterface, R as RoomInterface } from '../RoomInterface-BRA386zn.mjs';
|
|
2
|
+
import { Q as QuestInterface } from '../StageInterface-LDgQToad.mjs';
|
|
6
3
|
import '@drincs/nqtr';
|
|
7
|
-
import '../RoomInterface-DURfkQ7u.mjs';
|
|
8
4
|
import '@drincs/pixi-vn';
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
5
|
+
|
|
6
|
+
declare namespace RegisteredActivities {
|
|
7
|
+
/**
|
|
8
|
+
* Save an activity in the registered activities. If the activity already exists, it will be overwritten.
|
|
9
|
+
* @param activity The activity to save.
|
|
10
|
+
* @returns
|
|
11
|
+
*/
|
|
12
|
+
function add(activities: ActivityInterface | ActivityInterface[]): void;
|
|
13
|
+
/**
|
|
14
|
+
* Get an activity by its id.
|
|
15
|
+
* @param id The id of the activity.
|
|
16
|
+
* @returns The activity or undefined if not found.
|
|
17
|
+
*/
|
|
18
|
+
function get(id: string): ActivityInterface | undefined;
|
|
19
|
+
/**
|
|
20
|
+
* Get a list of all activities registered.
|
|
21
|
+
* @returns An array of activities.
|
|
22
|
+
*/
|
|
23
|
+
function values(): ActivityInterface[];
|
|
24
|
+
/**
|
|
25
|
+
* Check if an activity is registered.
|
|
26
|
+
* @param id The id of the activity.
|
|
27
|
+
* @returns True if the activity is registered, false otherwise.
|
|
28
|
+
*/
|
|
29
|
+
function has(id: string): boolean;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
declare namespace RegisteredCommitments {
|
|
33
|
+
/**
|
|
34
|
+
* Save a commitment in the registered commitments. If the commitment already exists, it will be overwritten.
|
|
35
|
+
* @param commitment The commitment to save.
|
|
36
|
+
* @returns
|
|
37
|
+
*/
|
|
38
|
+
function add(commitments: CommitmentInterface | CommitmentInterface[]): void;
|
|
39
|
+
/**
|
|
40
|
+
* Get a commitment by its id.
|
|
41
|
+
* @param id The id of the commitment.
|
|
42
|
+
* @returns The commitment or undefined if not found.
|
|
43
|
+
*/
|
|
44
|
+
function get(id: string): CommitmentInterface | undefined;
|
|
45
|
+
/**
|
|
46
|
+
* Get a list of all commitments registered.
|
|
47
|
+
* @returns An array of commitments.
|
|
48
|
+
*/
|
|
49
|
+
function values(): CommitmentInterface[];
|
|
50
|
+
/**
|
|
51
|
+
* Check if a commitment is registered.
|
|
52
|
+
* @param id The id of the commitment.
|
|
53
|
+
* @returns True if the commitment is registered, false otherwise.
|
|
54
|
+
*/
|
|
55
|
+
function has(id: string): boolean;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
declare namespace RegisteredLocations {
|
|
59
|
+
/**
|
|
60
|
+
* Save a location in the registered locations. If the location already exists, it will be overwritten.
|
|
61
|
+
* @param location The location to save.
|
|
62
|
+
* @returns
|
|
63
|
+
*/
|
|
64
|
+
function add(location: LocationInterface | LocationInterface[]): void;
|
|
65
|
+
/**
|
|
66
|
+
* Get a location by its id.
|
|
67
|
+
* @param id The id of the location.
|
|
68
|
+
* @returns The location or undefined if not found.
|
|
69
|
+
*/
|
|
70
|
+
function get(id: string): LocationInterface | undefined;
|
|
71
|
+
/**
|
|
72
|
+
* Get a list of all locations registered.
|
|
73
|
+
* @returns An array of locations.
|
|
74
|
+
*/
|
|
75
|
+
function values(): LocationInterface[];
|
|
76
|
+
/**
|
|
77
|
+
* Check if a location is registered.
|
|
78
|
+
* @param id The id of the location.
|
|
79
|
+
* @returns True if the location is registered, false otherwise.
|
|
80
|
+
*/
|
|
81
|
+
function has(id: string): boolean;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
declare namespace RegisteredMaps {
|
|
85
|
+
/**
|
|
86
|
+
* Save a map in the registered maps. If the map already exists, it will be overwritten.
|
|
87
|
+
* @param map The map to save.
|
|
88
|
+
* @returns
|
|
89
|
+
*/
|
|
90
|
+
function add(map: MapInterface | MapInterface[]): void;
|
|
91
|
+
/**
|
|
92
|
+
* Get a map by its id.
|
|
93
|
+
* @param id The id of the map.
|
|
94
|
+
* @returns The map or undefined if not found.
|
|
95
|
+
*/
|
|
96
|
+
function get(id: string): MapInterface | undefined;
|
|
97
|
+
/**
|
|
98
|
+
* Get a list of all maps registered.
|
|
99
|
+
* @returns An array of maps.
|
|
100
|
+
*/
|
|
101
|
+
function values(): MapInterface[];
|
|
102
|
+
/**
|
|
103
|
+
* Check if a map is registered.
|
|
104
|
+
* @param id The id of the map.
|
|
105
|
+
* @returns True if the map is registered, false otherwise.
|
|
106
|
+
*/
|
|
107
|
+
function has(id: string): boolean;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
declare namespace RegisteredQuest {
|
|
111
|
+
/**
|
|
112
|
+
* Save a quest in the registered quests. If the quest already exists, it will be overwritten.
|
|
113
|
+
* @param quest The quest to save.
|
|
114
|
+
* @returns
|
|
115
|
+
*/
|
|
116
|
+
function add(quests: QuestInterface | QuestInterface[]): void;
|
|
117
|
+
/**
|
|
118
|
+
* Get a quest by its id.
|
|
119
|
+
* @param id The id of the quest.
|
|
120
|
+
* @returns The quest or undefined if not found.
|
|
121
|
+
*/
|
|
122
|
+
function get(id: string): QuestInterface | undefined;
|
|
123
|
+
/**
|
|
124
|
+
* Get a list of all quests registered.
|
|
125
|
+
* @returns An array of quests.
|
|
126
|
+
*/
|
|
127
|
+
function values(): QuestInterface[];
|
|
128
|
+
/**
|
|
129
|
+
* Check if a quest is registered.
|
|
130
|
+
* @param id The id of the quest.
|
|
131
|
+
* @returns True if the quest is registered, false otherwise.
|
|
132
|
+
*/
|
|
133
|
+
function has(id: string): boolean;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
declare namespace RegisteredRooms {
|
|
137
|
+
/**
|
|
138
|
+
* Save a room in the registered rooms, and their location and map if they are not already registered.
|
|
139
|
+
* If the room already exists, it will be overwritten.
|
|
140
|
+
* @param room The room to save.
|
|
141
|
+
* @returns
|
|
142
|
+
*/
|
|
143
|
+
function add(room: RoomInterface | RoomInterface[]): void;
|
|
144
|
+
/**
|
|
145
|
+
* Get a room by its id.
|
|
146
|
+
* @param id The id of the room.
|
|
147
|
+
* @returns The room or undefined if not found.
|
|
148
|
+
*/
|
|
149
|
+
function get(id: string): RoomInterface | undefined;
|
|
150
|
+
/**
|
|
151
|
+
* Get a list of all rooms registered.
|
|
152
|
+
* @returns An array of rooms.
|
|
153
|
+
*/
|
|
154
|
+
function values(): RoomInterface[];
|
|
155
|
+
/**
|
|
156
|
+
* Check if a room is registered.
|
|
157
|
+
* @param id The id of the room.
|
|
158
|
+
* @returns True if the room is registered, false otherwise.
|
|
159
|
+
*/
|
|
160
|
+
function has(id: string): boolean;
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
export { RegisteredActivities, RegisteredCommitments, RegisteredLocations, RegisteredMaps, RegisteredQuest as RegisteredQuests, RegisteredRooms };
|
|
@@ -1,11 +1,163 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
export { saveQuest } from './QuestDecorator.js';
|
|
4
|
-
export { saveRoom } from './RoomDecorator.js';
|
|
5
|
-
import '../interface/ActivityInterface.js';
|
|
1
|
+
import { A as ActivityInterface, C as CommitmentInterface, L as LocationInterface, M as MapInterface, R as RoomInterface } from '../RoomInterface-Cwm08AzD.js';
|
|
2
|
+
import { Q as QuestInterface } from '../StageInterface-LDgQToad.js';
|
|
6
3
|
import '@drincs/nqtr';
|
|
7
|
-
import '../RoomInterface-CdAM_q7P.js';
|
|
8
4
|
import '@drincs/pixi-vn';
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
5
|
+
|
|
6
|
+
declare namespace RegisteredActivities {
|
|
7
|
+
/**
|
|
8
|
+
* Save an activity in the registered activities. If the activity already exists, it will be overwritten.
|
|
9
|
+
* @param activity The activity to save.
|
|
10
|
+
* @returns
|
|
11
|
+
*/
|
|
12
|
+
function add(activities: ActivityInterface | ActivityInterface[]): void;
|
|
13
|
+
/**
|
|
14
|
+
* Get an activity by its id.
|
|
15
|
+
* @param id The id of the activity.
|
|
16
|
+
* @returns The activity or undefined if not found.
|
|
17
|
+
*/
|
|
18
|
+
function get(id: string): ActivityInterface | undefined;
|
|
19
|
+
/**
|
|
20
|
+
* Get a list of all activities registered.
|
|
21
|
+
* @returns An array of activities.
|
|
22
|
+
*/
|
|
23
|
+
function values(): ActivityInterface[];
|
|
24
|
+
/**
|
|
25
|
+
* Check if an activity is registered.
|
|
26
|
+
* @param id The id of the activity.
|
|
27
|
+
* @returns True if the activity is registered, false otherwise.
|
|
28
|
+
*/
|
|
29
|
+
function has(id: string): boolean;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
declare namespace RegisteredCommitments {
|
|
33
|
+
/**
|
|
34
|
+
* Save a commitment in the registered commitments. If the commitment already exists, it will be overwritten.
|
|
35
|
+
* @param commitment The commitment to save.
|
|
36
|
+
* @returns
|
|
37
|
+
*/
|
|
38
|
+
function add(commitments: CommitmentInterface | CommitmentInterface[]): void;
|
|
39
|
+
/**
|
|
40
|
+
* Get a commitment by its id.
|
|
41
|
+
* @param id The id of the commitment.
|
|
42
|
+
* @returns The commitment or undefined if not found.
|
|
43
|
+
*/
|
|
44
|
+
function get(id: string): CommitmentInterface | undefined;
|
|
45
|
+
/**
|
|
46
|
+
* Get a list of all commitments registered.
|
|
47
|
+
* @returns An array of commitments.
|
|
48
|
+
*/
|
|
49
|
+
function values(): CommitmentInterface[];
|
|
50
|
+
/**
|
|
51
|
+
* Check if a commitment is registered.
|
|
52
|
+
* @param id The id of the commitment.
|
|
53
|
+
* @returns True if the commitment is registered, false otherwise.
|
|
54
|
+
*/
|
|
55
|
+
function has(id: string): boolean;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
declare namespace RegisteredLocations {
|
|
59
|
+
/**
|
|
60
|
+
* Save a location in the registered locations. If the location already exists, it will be overwritten.
|
|
61
|
+
* @param location The location to save.
|
|
62
|
+
* @returns
|
|
63
|
+
*/
|
|
64
|
+
function add(location: LocationInterface | LocationInterface[]): void;
|
|
65
|
+
/**
|
|
66
|
+
* Get a location by its id.
|
|
67
|
+
* @param id The id of the location.
|
|
68
|
+
* @returns The location or undefined if not found.
|
|
69
|
+
*/
|
|
70
|
+
function get(id: string): LocationInterface | undefined;
|
|
71
|
+
/**
|
|
72
|
+
* Get a list of all locations registered.
|
|
73
|
+
* @returns An array of locations.
|
|
74
|
+
*/
|
|
75
|
+
function values(): LocationInterface[];
|
|
76
|
+
/**
|
|
77
|
+
* Check if a location is registered.
|
|
78
|
+
* @param id The id of the location.
|
|
79
|
+
* @returns True if the location is registered, false otherwise.
|
|
80
|
+
*/
|
|
81
|
+
function has(id: string): boolean;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
declare namespace RegisteredMaps {
|
|
85
|
+
/**
|
|
86
|
+
* Save a map in the registered maps. If the map already exists, it will be overwritten.
|
|
87
|
+
* @param map The map to save.
|
|
88
|
+
* @returns
|
|
89
|
+
*/
|
|
90
|
+
function add(map: MapInterface | MapInterface[]): void;
|
|
91
|
+
/**
|
|
92
|
+
* Get a map by its id.
|
|
93
|
+
* @param id The id of the map.
|
|
94
|
+
* @returns The map or undefined if not found.
|
|
95
|
+
*/
|
|
96
|
+
function get(id: string): MapInterface | undefined;
|
|
97
|
+
/**
|
|
98
|
+
* Get a list of all maps registered.
|
|
99
|
+
* @returns An array of maps.
|
|
100
|
+
*/
|
|
101
|
+
function values(): MapInterface[];
|
|
102
|
+
/**
|
|
103
|
+
* Check if a map is registered.
|
|
104
|
+
* @param id The id of the map.
|
|
105
|
+
* @returns True if the map is registered, false otherwise.
|
|
106
|
+
*/
|
|
107
|
+
function has(id: string): boolean;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
declare namespace RegisteredQuest {
|
|
111
|
+
/**
|
|
112
|
+
* Save a quest in the registered quests. If the quest already exists, it will be overwritten.
|
|
113
|
+
* @param quest The quest to save.
|
|
114
|
+
* @returns
|
|
115
|
+
*/
|
|
116
|
+
function add(quests: QuestInterface | QuestInterface[]): void;
|
|
117
|
+
/**
|
|
118
|
+
* Get a quest by its id.
|
|
119
|
+
* @param id The id of the quest.
|
|
120
|
+
* @returns The quest or undefined if not found.
|
|
121
|
+
*/
|
|
122
|
+
function get(id: string): QuestInterface | undefined;
|
|
123
|
+
/**
|
|
124
|
+
* Get a list of all quests registered.
|
|
125
|
+
* @returns An array of quests.
|
|
126
|
+
*/
|
|
127
|
+
function values(): QuestInterface[];
|
|
128
|
+
/**
|
|
129
|
+
* Check if a quest is registered.
|
|
130
|
+
* @param id The id of the quest.
|
|
131
|
+
* @returns True if the quest is registered, false otherwise.
|
|
132
|
+
*/
|
|
133
|
+
function has(id: string): boolean;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
declare namespace RegisteredRooms {
|
|
137
|
+
/**
|
|
138
|
+
* Save a room in the registered rooms, and their location and map if they are not already registered.
|
|
139
|
+
* If the room already exists, it will be overwritten.
|
|
140
|
+
* @param room The room to save.
|
|
141
|
+
* @returns
|
|
142
|
+
*/
|
|
143
|
+
function add(room: RoomInterface | RoomInterface[]): void;
|
|
144
|
+
/**
|
|
145
|
+
* Get a room by its id.
|
|
146
|
+
* @param id The id of the room.
|
|
147
|
+
* @returns The room or undefined if not found.
|
|
148
|
+
*/
|
|
149
|
+
function get(id: string): RoomInterface | undefined;
|
|
150
|
+
/**
|
|
151
|
+
* Get a list of all rooms registered.
|
|
152
|
+
* @returns An array of rooms.
|
|
153
|
+
*/
|
|
154
|
+
function values(): RoomInterface[];
|
|
155
|
+
/**
|
|
156
|
+
* Check if a room is registered.
|
|
157
|
+
* @param id The id of the room.
|
|
158
|
+
* @returns True if the room is registered, false otherwise.
|
|
159
|
+
*/
|
|
160
|
+
function has(id: string): boolean;
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
export { RegisteredActivities, RegisteredCommitments, RegisteredLocations, RegisteredMaps, RegisteredQuest as RegisteredQuests, RegisteredRooms };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
var r={};function
|
|
1
|
+
import {CachedMap}from'@drincs/pixi-vn';var o;(t=>(t.log=(e,...r)=>console.log(`[NQTR] ${e}`,...r),t.warn=(e,...r)=>console.warn(`[NQTR] ${e}`,...r),t.error=(e,...r)=>console.error(`[NQTR] ${e}`,...r),t.info=(e,...r)=>console.info(`[NQTR] ${e}`,...r)))(o||={});var u=new CachedMap({cacheSize:20}),y;(t=>{function n(e){if(Array.isArray(e)){e.forEach(r=>t.add(r));return}u.set(e.id,e);}t.add=n;function a(e){try{let r=u.get(e);if(!r){console.warn(`[NQTR] Activity ${e} not found, you should register it first`);return}return r}catch(r){o.error(`Error while getting Activity ${e}`,r);return}}t.get=a;function i(){return Array.from(u.values())}t.values=i;function f(e){return u.has(e)}t.has=f;})(y||={});var C=y;var m=new CachedMap({cacheSize:20});new CachedMap({cacheSize:20});var I;(t=>{function n(e){if(Array.isArray(e)){e.forEach(r=>t.add(r));return}console.warn(`[NQTR] Registering commitment ${e.id}`,e),m.set(e.id,e);}t.add=n;function a(e){try{let r=m.get(e);if(!r){console.warn(`[NQTR] Commitment ${e} not found, you should register it first`);return}return r}catch(r){o.error(`Error while getting Commitment ${e}`,r);return}}t.get=a;function i(){return Array.from(m.values())}t.values=i;function f(e){return m.has(e)}t.has=f;})(I||={});var M=I;var c=new CachedMap({cacheSize:20}),R;(t=>{function n(e){if(Array.isArray(e)){e.forEach(r=>n(r));return}c.has(e.id)&&console.warn(`[NQTR] Location id ${e.id} already exists, it will be overwritten`),c.set(e.id,e);}t.add=n;function a(e){try{let r=c.get(e);if(!r){console.warn(`[NQTR] Location ${e} not found, you should register it first`);return}return r}catch(r){o.error(`Error while getting Location ${e}`,r);return}}t.get=a;function i(){return Array.from(c.values())}t.values=i;function f(e){return c.has(e)}t.has=f;})(R||={});var g=R;var s=new CachedMap({cacheSize:20}),w;(t=>{function n(e){if(Array.isArray(e)){e.forEach(r=>n(r));return}s.has(e.id)&&console.warn(`[NQTR] Map id ${e.id} already exists, it will be overwritten`),s.set(e.id,e);}t.add=n;function a(e){try{let r=s.get(e);if(!r){console.warn(`[NQTR] Map ${e} not found, you should register it first`);return}return r}catch(r){o.error(`Error while getting Map ${e}`,r);return}}t.get=a;function i(){return Array.from(s.values())}t.values=i;function f(e){return s.has(e)}t.has=f;})(w||={});var l=w;var p=new CachedMap({cacheSize:5}),A;(t=>{function n(e){if(Array.isArray(e)){e.forEach(r=>t.add(r));return}p.set(e.id,e);}t.add=n;function a(e){try{let r=p.get(e);if(!r){console.warn(`[NQTR] Quest ${e} not found, you should register it first`);return}return r}catch(r){o.error(`Error while getting Quest ${e}`,r);return}}t.get=a;function i(){return Array.from(p.values())}t.values=i;function f(e){return p.has(e)}t.has=f;})(A||={});var L=A;var d=new CachedMap({cacheSize:20}),Q;(t=>{function n(e){if(Array.isArray(e)){e.forEach(v=>n(v));return}d.set(e.id,e);let r=e.location;g.add(r);let h=r?.map;h&&l.add(h);}t.add=n;function a(e){try{let r=d.get(e);if(!r){console.warn(`[NQTR] Room ${e} not found, you should register it first`);return}return r}catch(r){o.error(`Error while getting Room ${e}`,r);return}}t.get=a;function i(){return Array.from(d.values())}t.values=i;function f(e){return d.has(e)}t.has=f;})(Q||={});var z=Q;export{C as RegisteredActivities,M as RegisteredCommitments,g as RegisteredLocations,l as RegisteredMaps,L as RegisteredQuests,z as RegisteredRooms};//# sourceMappingURL=index.mjs.map
|
|
2
2
|
//# sourceMappingURL=index.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/decorators/ActivityDecorator.ts","../../src/decorators/CommitmentDecorator.ts","../../src/decorators/QuestDecorator.ts","../../src/decorators/RoomDecorator.ts"],"names":["registeredActivities","saveActivity","activities","activity","getActivityById","id","e","registeredCommitments","saveCommitment","commitment","c","registeredQuests","saveQuest","quest","registeredRooms","saveRoom","room"],"mappings":"AAEO,IAAMA,CAAAA,CAA4D,EAElE,CAAA,SAASC,EAAaC,CAAqD,CAAA,CAC9E,GAAI,KAAM,CAAA,OAAA,CAAQA,CAAU,CAAG,CAAA,CAC3BA,EAAW,OAAQC,CAAAA,CAAAA,EAAY,CAC3BH,CAAqBG,CAAAA,CAAAA,CAAS,EAAE,CAAIA,CAAAA,EACxC,CAAC,CACD,CAAA,MACJ,CACAH,CAAqBE,CAAAA,CAAAA,CAAW,EAAE,CAAIA,CAAAA,EAC1C,CAOO,SAASE,CAAAA,CAAgBC,EAA2C,CACvE,GAAI,CACA,IAAIF,CAAAA,CAAWH,EAAqBK,CAAE,CAAA,CACtC,GAAI,CAACF,CAAAA,CAAU,CACX,OAAQ,CAAA,KAAA,CAAM,mBAAmBE,CAAE,CAAA,UAAA,CAAY,EAC/C,MACJ,CACA,OAAOF,CACX,CAA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"index.mjs","sourcesContent":["import { ActivityInterface } from \"../interface\"\n\nexport const registeredActivities: { [id: string]: ActivityInterface } = {}\n\nexport function saveActivity(activities: ActivityInterface | ActivityInterface[]) {\n if (Array.isArray(activities)) {\n activities.forEach(activity => {\n registeredActivities[activity.id] = activity\n })\n return\n }\n registeredActivities[activities.id] = activities\n}\n\n/**\n * Get an activity by its id.\n * @param id The id of the activity.\n * @returns The activity or undefined if not found.\n */\nexport function getActivityById(id: string): ActivityInterface | undefined {\n try {\n let activity = registeredActivities[id]\n if (!activity) {\n console.error(`[NQTR] Activity ${id} not found`)\n return\n }\n return activity\n }\n catch (e) {\n console.error(`[NQTR] Error while getting Activity ${id}`, e)\n return\n }\n}\n","import { CommitmentInterface } from \"../interface\";\n\nexport const registeredCommitments: { [id: string]: CommitmentInterface } = {};\nexport const fixedCommitments: { [id: string]: CommitmentInterface } = {};\n\n/**\n * Save a commitment in the registered commitments. If the commitment already exists, it will be overwritten.\n * @param commitment The commitment or commitments to save.\n * @returns\n */\nexport function saveCommitment(commitment: CommitmentInterface | CommitmentInterface[]) {\n\tif (Array.isArray(commitment)) {\n\t\tcommitment.forEach((c) => saveCommitment(c));\n\t\treturn;\n\t}\n\tif (registeredCommitments[commitment.id]) {\n\t\tconsole.warn(`[NQTR] Commitment id ${commitment.id} already exists, it will be overwritten`);\n\t}\n\tregisteredCommitments[commitment.id] = commitment;\n}\n\n/**\n * Get a commitment by its id.\n * @param id The id of the commitment.\n * @returns The commitment or undefined if not found.\n */\nexport function getCommitmentById(id: string): CommitmentInterface | undefined {\n\ttry {\n\t\tlet commitment = registeredCommitments[id];\n\t\tif (!commitment) {\n\t\t\tconsole.error(`[NQTR] Commitment ${id} not found`);\n\t\t\treturn;\n\t\t}\n\t\treturn commitment;\n\t} catch (e) {\n\t\tconsole.error(`[NQTR] Error while getting Commitment ${id}`, e);\n\t\treturn;\n\t}\n}\n","import { QuestInterface } from \"../interface\";\n\nexport const registeredQuests: { [id: string]: QuestInterface } = {};\n\n/**\n * Save a quest in the registered quests. If the quest already exists, it will be overwritten.\n * @param id The id of the quest, it must be unique\n * @param stages The stages of the quest\n * @param props The quest properties\n * @returns The created quest\n */\nexport function saveQuest(quest: QuestInterface | QuestInterface[]) {\n\tif (Array.isArray(quest)) {\n\t\tquest.forEach((c) => saveQuest(c));\n\t\treturn;\n\t}\n\tif (registeredQuests[quest.id]) {\n\t\tconsole.warn(`[NQTR] Quest id ${quest.id} already exists, it will be overwritten`);\n\t}\n\tregisteredQuests[quest.id] = quest;\n}\n\n/**\n * Get a quest by its id.\n * @param id The id of the quest.\n * @returns The quest or undefined if not found.\n */\nexport function getQuestById(id: string): QuestInterface | undefined {\n\ttry {\n\t\tlet quest = registeredQuests[id];\n\t\tif (!quest) {\n\t\t\tconsole.error(`[NQTR] Quest ${id} not found`);\n\t\t\treturn;\n\t\t}\n\t\treturn quest;\n\t} catch (e) {\n\t\tconsole.error(`[NQTR] Error while getting Quest ${id}`, e);\n\t\treturn;\n\t}\n}\n","import { RoomInterface } from \"../interface\";\n\nexport const registeredRooms: { [id: string]: RoomInterface } = {};\n\n/**\n * Save a room in the registered rooms. If the room already exists, it will be overwritten.\n * @param room The room to save.\n * @returns\n * @example\n * ```ts\n * saveRoom([mcRoom, aliceRoom, annRoom, bathroom, lounge, terrace, gymRoom]);\n * ```\n */\nexport function saveRoom(room: RoomInterface | RoomInterface[]) {\n\tif (Array.isArray(room)) {\n\t\troom.forEach((c) => saveRoom(c));\n\t\treturn;\n\t}\n\tif (registeredRooms[room.id]) {\n\t\tconsole.warn(`[NQTR] Room id ${room.id} already exists, it will be overwritten`);\n\t}\n\tregisteredRooms[room.id] = room;\n}\n\n/**\n * Get a room by its id.\n * @param id The id of the room.\n * @returns The room or undefined if not found.\n */\nexport function getRoomById(id: string): RoomInterface | undefined {\n\ttry {\n\t\tlet room = registeredRooms[id];\n\t\tif (!room) {\n\t\t\tconsole.error(`[NQTR] Room ${id} not found`);\n\t\t\treturn;\n\t\t}\n\t\treturn room;\n\t} catch (e) {\n\t\tconsole.error(`[NQTR] Error while getting Room ${id}`, e);\n\t\treturn;\n\t}\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["../../src/utils/log-utility.ts","../../src/decorators/RegisteredActivities.ts","../../src/decorators/RegisteredCommitments.ts","../../src/decorators/RegisteredLocations.ts","../../src/decorators/RegisteredMaps.ts","../../src/decorators/RegisteredQuests.ts","../../src/decorators/RegisteredRooms.ts"],"names":["logger","message","optionalParams","registeredActivities","CachedMap","RegisteredActivities","add","activities","activity","get","id","e","values","has","RegisteredActivities_default","registeredCommitments","RegisteredCommitments","commitments","commitment","RegisteredCommitments_default","registeredLocations","RegisteredLocations","location","c","RegisteredLocations_default","registeredMaps","RegisteredMaps","map","RegisteredMaps_default","registeredQuests","RegisteredQuest","quests","quest","RegisteredQuests_default","registeredRooms","RegisteredRooms","room","RegisteredRooms_default"],"mappings":"wCAAO,IAAUA,OACAA,CAAAA,CAAA,GAAA,CAAM,CAACC,CAAAA,CAAAA,GAAkBC,CAAAA,GAA0B,QAAQ,GAAA,CAAI,CAAA,OAAA,EAAUD,CAAO,CAAA,CAAA,CAAI,GAAGC,CAAc,CAAA,CACrGF,CAAAA,CAAA,IAAA,CAAO,CAACC,CAAAA,CAAAA,GAAkBC,CAAAA,GACnC,QAAQ,IAAA,CAAK,CAAA,OAAA,EAAUD,CAAO,CAAA,CAAA,CAAI,GAAGC,CAAc,CAAA,CAC1CF,CAAAA,CAAA,KAAA,CAAQ,CAACC,CAAAA,CAAAA,GAAkBC,CAAAA,GACpC,QAAQ,KAAA,CAAM,CAAA,OAAA,EAAUD,CAAO,CAAA,CAAA,CAAI,GAAGC,CAAc,CAAA,CAC3CF,CAAAA,CAAA,IAAA,CAAO,CAACC,CAAAA,CAAAA,GAAkBC,CAAAA,GACnC,QAAQ,IAAA,CAAK,CAAA,OAAA,EAAUD,CAAO,CAAA,CAAA,CAAI,GAAGC,CAAc,CAAA,CAAA,EAP1CF,CAAAA,GAAA,EAAA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G,CACrBA,CAAAA,CAAK,OAAA,CAASb,CAAAA,EAAMjB,CAAAA,CAAIiB,CAAC,CAAC,EAC1B,MACJ,CACAW,EAAgB,GAAA,CAAIE,CAAAA,CAAK,GAAIA,CAAI,CAAA,CACjC,IAAId,CAAAA,CAAWc,CAAAA,CAAK,QAAA,CACpBZ,EAAoB,GAAA,CAAIF,CAAQ,EAChC,IAAIK,CAAAA,CAAML,GAAU,GAAA,CAChBK,CAAAA,EACAC,CAAAA,CAAe,GAAA,CAAID,CAAG,EAE9B,CAZOQ,CAAAA,CAAS,GAAA,CAAA7B,EAmBT,SAASG,CAAAA,CAAIC,EAAuC,CACvD,GAAI,CACA,IAAI0B,CAAAA,CAAOF,CAAAA,CAAgB,IAAIxB,CAAE,CAAA,CACjC,GAAI,CAAC0B,CAAAA,CAAM,CACP,OAAA,CAAQ,IAAA,CAAK,CAAA,YAAA,EAAe1B,CAAE,CAAA,wCAAA,CAA0C,CAAA,CACxE,MACJ,CACA,OAAO0B,CACX,CAAA,MAASzB,CAAAA,CAAG,CACRX,CAAAA,CAAO,KAAA,CAAM,CAAA,yBAAA,EAA4BU,CAAE,CAAA,CAAA,CAAIC,CAAC,EAChD,MACJ,CACJ,CAZOwB,CAAAA,CAAS,GAAA,CAAA1B,EAkBT,SAASG,CAAAA,EAA0B,CACtC,OAAO,KAAA,CAAM,IAAA,CAAKsB,EAAgB,MAAA,EAAQ,CAC9C,CAFOC,CAAAA,CAAS,OAAAvB,CAAAA,CAST,SAASC,CAAAA,CAAIH,CAAAA,CAAqB,CACrC,OAAOwB,EAAgB,GAAA,CAAIxB,CAAE,CACjC,CAFOyB,CAAAA,CAAS,IAAAtB,EAAAA,CAAAA,EArDVsB,CAAAA,GAAA,EAAA,CAAA,CAyDV,IAAOE,CAAAA,CAAQF","file":"index.mjs","sourcesContent":["export namespace logger {\n export const log = (message?: any, ...optionalParams: any[]) => console.log(`[NQTR] ${message}`, ...optionalParams);\n export const warn = (message?: any, ...optionalParams: any[]) =>\n console.warn(`[NQTR] ${message}`, ...optionalParams);\n export const error = (message?: any, ...optionalParams: any[]) =>\n console.error(`[NQTR] ${message}`, ...optionalParams);\n export const info = (message?: any, ...optionalParams: any[]) =>\n console.info(`[NQTR] ${message}`, ...optionalParams);\n}\n","import { CachedMap } from \"@drincs/pixi-vn\";\nimport { ActivityInterface } from \"../interface\";\nimport { logger } from \"../utils/log-utility\";\n\n/**\n * A Map that contains all activities registered and available to be used.\n * The key is the id of the activity and the value is the activity itself.\n */\nconst registeredActivities = new CachedMap<string, ActivityInterface>({ cacheSize: 20 });\n\nnamespace RegisteredActivities {\n /**\n * Save an activity in the registered activities. If the activity already exists, it will be overwritten.\n * @param activity The activity to save.\n * @returns\n */\n export function add(activities: ActivityInterface | ActivityInterface[]) {\n if (Array.isArray(activities)) {\n activities.forEach((activity) => RegisteredActivities.add(activity));\n return;\n }\n registeredActivities.set(activities.id, activities);\n }\n\n /**\n * Get an activity by its id.\n * @param id The id of the activity.\n * @returns The activity or undefined if not found.\n */\n export function get(id: string): ActivityInterface | undefined {\n try {\n let activity = registeredActivities.get(id);\n if (!activity) {\n console.warn(`[NQTR] Activity ${id} not found, you should register it first`);\n return;\n }\n return activity;\n } catch (e) {\n logger.error(`Error while getting Activity ${id}`, e);\n return;\n }\n }\n\n /**\n * Get a list of all activities registered.\n * @returns An array of activities.\n */\n export function values(): ActivityInterface[] {\n return Array.from(registeredActivities.values());\n }\n\n /**\n * Check if an activity is registered.\n * @param id The id of the activity.\n * @returns True if the activity is registered, false otherwise.\n */\n export function has(id: string): boolean {\n return registeredActivities.has(id);\n }\n}\nexport default RegisteredActivities;\n","import { CachedMap } from \"@drincs/pixi-vn\";\nimport { CommitmentInterface } from \"../interface\";\nimport { logger } from \"../utils/log-utility\";\n\n/**\n * A Map that contains all commitments registered and available to be used.\n * The key is the id of the commitment and the value is the commitment itself.\n */\nexport const registeredCommitments = new CachedMap<string, CommitmentInterface>({ cacheSize: 20 });\nexport const fixedCommitments = new CachedMap<string, CommitmentInterface>({ cacheSize: 20 });\n\nnamespace RegisteredCommitments {\n /**\n * Save a commitment in the registered commitments. If the commitment already exists, it will be overwritten.\n * @param commitment The commitment to save.\n * @returns\n */\n export function add(commitments: CommitmentInterface | CommitmentInterface[]) {\n if (Array.isArray(commitments)) {\n commitments.forEach((commitment) => RegisteredCommitments.add(commitment));\n return;\n }\n console.warn(`[NQTR] Registering commitment ${commitments.id}`, commitments);\n registeredCommitments.set(commitments.id, commitments);\n }\n /**\n * Get a commitment by its id.\n * @param id The id of the commitment.\n * @returns The commitment or undefined if not found.\n */\n export function get(id: string): CommitmentInterface | undefined {\n try {\n let commitment = registeredCommitments.get(id);\n if (!commitment) {\n console.warn(`[NQTR] Commitment ${id} not found, you should register it first`);\n return;\n }\n return commitment;\n } catch (e) {\n logger.error(`Error while getting Commitment ${id}`, e);\n return;\n }\n }\n /**\n * Get a list of all commitments registered.\n * @returns An array of commitments.\n */\n export function values(): CommitmentInterface[] {\n return Array.from(registeredCommitments.values());\n }\n /**\n * Check if a commitment is registered.\n * @param id The id of the commitment.\n * @returns True if the commitment is registered, false otherwise.\n */\n export function has(id: string): boolean {\n return registeredCommitments.has(id);\n }\n}\nexport default RegisteredCommitments;\n","import { CachedMap } from \"@drincs/pixi-vn\";\nimport { LocationInterface } from \"../interface\";\nimport { logger } from \"../utils/log-utility\";\n\n/**\n * A Map that contains all locations registered and available to be used.\n * The key is the id of the location and the value is the location itself.\n */\nconst registeredLocations = new CachedMap<string, LocationInterface>({ cacheSize: 20 });\n\nnamespace RegisteredLocations {\n /**\n * Save a location in the registered locations. If the location already exists, it will be overwritten.\n * @param location The location to save.\n * @returns\n */\n export function add(location: LocationInterface | LocationInterface[]) {\n if (Array.isArray(location)) {\n location.forEach((c) => add(c));\n return;\n }\n if (registeredLocations.has(location.id)) {\n console.warn(`[NQTR] Location id ${location.id} already exists, it will be overwritten`);\n }\n registeredLocations.set(location.id, location);\n }\n\n /**\n * Get a location by its id.\n * @param id The id of the location.\n * @returns The location or undefined if not found.\n */\n export function get(id: string): LocationInterface | undefined {\n try {\n let location = registeredLocations.get(id);\n if (!location) {\n console.warn(`[NQTR] Location ${id} not found, you should register it first`);\n return;\n }\n return location;\n } catch (e) {\n logger.error(`Error while getting Location ${id}`, e);\n return;\n }\n }\n\n /**\n * Get a list of all locations registered.\n * @returns An array of locations.\n */\n export function values(): LocationInterface[] {\n return Array.from(registeredLocations.values());\n }\n\n /**\n * Check if a location is registered.\n * @param id The id of the location.\n * @returns True if the location is registered, false otherwise.\n */\n export function has(id: string): boolean {\n return registeredLocations.has(id);\n }\n}\nexport default RegisteredLocations;\n","import { CachedMap } from \"@drincs/pixi-vn\";\nimport { MapInterface } from \"../interface\";\nimport { logger } from \"../utils/log-utility\";\n\n/**\n * A Map that contains all maps registered and available to be used.\n * The key is the id of the map and the value is the map itself.\n */\nconst registeredMaps = new CachedMap<string, MapInterface>({ cacheSize: 20 });\n\nnamespace RegisteredMaps {\n /**\n * Save a map in the registered maps. If the map already exists, it will be overwritten.\n * @param map The map to save.\n * @returns\n */\n export function add(map: MapInterface | MapInterface[]) {\n if (Array.isArray(map)) {\n map.forEach((c) => add(c));\n return;\n }\n if (registeredMaps.has(map.id)) {\n console.warn(`[NQTR] Map id ${map.id} already exists, it will be overwritten`);\n }\n registeredMaps.set(map.id, map);\n }\n\n /**\n * Get a map by its id.\n * @param id The id of the map.\n * @returns The map or undefined if not found.\n */\n export function get(id: string): MapInterface | undefined {\n try {\n let map = registeredMaps.get(id);\n if (!map) {\n console.warn(`[NQTR] Map ${id} not found, you should register it first`);\n return;\n }\n return map;\n } catch (e) {\n logger.error(`Error while getting Map ${id}`, e);\n return;\n }\n }\n\n /**\n * Get a list of all maps registered.\n * @returns An array of maps.\n */\n export function values(): MapInterface[] {\n return Array.from(registeredMaps.values());\n }\n\n /**\n * Check if a map is registered.\n * @param id The id of the map.\n * @returns True if the map is registered, false otherwise.\n */\n export function has(id: string): boolean {\n return registeredMaps.has(id);\n }\n}\nexport default RegisteredMaps;\n","import { CachedMap } from \"@drincs/pixi-vn\";\nimport { QuestInterface } from \"../interface\";\nimport { logger } from \"../utils/log-utility\";\n\n/**\n * A Map that contains all quests registered and available to be used.\n * The key is the id of the quest and the value is the quest itself.\n */\nconst registeredQuests = new CachedMap<string, QuestInterface>({ cacheSize: 5 });\n\nnamespace RegisteredQuest {\n /**\n * Save a quest in the registered quests. If the quest already exists, it will be overwritten.\n * @param quest The quest to save.\n * @returns\n */\n export function add(quests: QuestInterface | QuestInterface[]) {\n if (Array.isArray(quests)) {\n quests.forEach((quest) => RegisteredQuest.add(quest));\n return;\n }\n registeredQuests.set(quests.id, quests);\n }\n /**\n * Get a quest by its id.\n * @param id The id of the quest.\n * @returns The quest or undefined if not found.\n */\n export function get(id: string): QuestInterface | undefined {\n try {\n let quest = registeredQuests.get(id);\n if (!quest) {\n console.warn(`[NQTR] Quest ${id} not found, you should register it first`);\n return;\n }\n return quest;\n } catch (e) {\n logger.error(`Error while getting Quest ${id}`, e);\n return;\n }\n }\n /**\n * Get a list of all quests registered.\n * @returns An array of quests.\n */\n export function values(): QuestInterface[] {\n return Array.from(registeredQuests.values());\n }\n /**\n * Check if a quest is registered.\n * @param id The id of the quest.\n * @returns True if the quest is registered, false otherwise.\n */\n export function has(id: string): boolean {\n return registeredQuests.has(id);\n }\n}\nexport default RegisteredQuest;\n","import { CachedMap } from \"@drincs/pixi-vn\";\nimport { RoomInterface } from \"../interface\";\nimport { logger } from \"../utils/log-utility\";\nimport RegisteredLocations from \"./RegisteredLocations\";\nimport RegisteredMaps from \"./RegisteredMaps\";\n\n/**\n * A Map that contains all rooms registered and available to be used.\n * The key is the id of the room and the value is the room itself.\n */\nconst registeredRooms = new CachedMap<string, RoomInterface>({ cacheSize: 20 });\n\nnamespace RegisteredRooms {\n /**\n * Save a room in the registered rooms, and their location and map if they are not already registered.\n * If the room already exists, it will be overwritten.\n * @param room The room to save.\n * @returns\n */\n export function add(room: RoomInterface | RoomInterface[]) {\n if (Array.isArray(room)) {\n room.forEach((c) => add(c));\n return;\n }\n registeredRooms.set(room.id, room);\n let location = room.location;\n RegisteredLocations.add(location);\n let map = location?.map;\n if (map) {\n RegisteredMaps.add(map);\n }\n }\n\n /**\n * Get a room by its id.\n * @param id The id of the room.\n * @returns The room or undefined if not found.\n */\n export function get(id: string): RoomInterface | undefined {\n try {\n let room = registeredRooms.get(id);\n if (!room) {\n console.warn(`[NQTR] Room ${id} not found, you should register it first`);\n return;\n }\n return room;\n } catch (e) {\n logger.error(`Error while getting Room ${id}`, e);\n return;\n }\n }\n\n /**\n * Get a list of all rooms registered.\n * @returns An array of rooms.\n */\n export function values(): RoomInterface[] {\n return Array.from(registeredRooms.values());\n }\n\n /**\n * Check if a room is registered.\n * @param id The id of the room.\n * @returns True if the room is registered, false otherwise.\n */\n export function has(id: string): boolean {\n return registeredRooms.has(id);\n }\n}\nexport default RegisteredRooms;\n"]}
|