new BundleManager(state)
Parameters:
| Name | Type | Description |
|---|---|---|
state |
GameState |
Methods
-
createCommand(commandPath, commandName, bundle) → {Command}
-
Parameters:
Name Type Description commandPathstring commandNamestring bundlestring Returns:
Command -
async loadArea(bundle, areaName, areaPath)
-
Parameters:
Name Type Description bundlestring areaNamestring areaPathstring -
async loadAreas(bundle)
-
Parameters:
Name Type Description bundlestring -
loadAttributes(bundle, attributesFile)
-
Load attribute definitions
Parameters:
Name Type Description bundlestring attributesFilestring -
loadBehaviors(bundle, behaviorsDir)
-
Parameters:
Name Type Description bundlestring behaviorsDirstring -
async loadBundle(bundle, bundlePath)
-
Parameters:
Name Type Description bundlestring Bundle name
bundlePathstring Path to bundle directory
-
async loadBundles()
-
Load in all bundles
-
loadChannels(bundle, channelsFile)
-
Parameters:
Name Type Description bundlestring channelsFilestring -
loadCommands(bundle, commandsDir)
-
Parameters:
Name Type Description bundlestring commandsDirstring -
loadEffects(bundle, effectsDir)
-
Parameters:
Name Type Description bundlestring effectsDirstring -
async loadEntities(bundle, areaName, type, factory) → {Array.<entityReference>}
-
Load an entity (item/npc/room) from file
Parameters:
Name Type Description bundlestring areaNamestring typestring factoryEntityFactory Returns:
Array.<entityReference> -
loadEntityScript(factory, entityRef, scriptPath)
-
Parameters:
Name Type Description factoryEntityFactory Instance of EntityFactory that the item/npc will be loaded into
entityRefEntityReference scriptPathstring -
async loadHelp(bundle, helpDir)
-
Parameters:
Name Type Description bundlestring helpDirstring -
loadInputEvents(bundle, inputEventsDir)
-
Parameters:
Name Type Description bundlestring inputEventsDirstring -
loadPlayerEvents(bundle, eventsFile)
-
Load/initialize player. See the Player Event guide
Parameters:
Name Type Description bundlestring eventsFilestring event js file to load
-
async loadQuests(areaName, questsFile) → {Promise.<Array.<entityReference>>}
-
Parameters:
Name Type Description areaNamestring questsFilestring Returns:
Promise.<Array.<entityReference>> -
loadServerEvents(bundle, serverEventsDir)
-
Parameters:
Name Type Description bundlestring serverEventsDirstring -
loadSkills(bundle, skillsDir)
-
Parameters:
Name Type Description bundlestring skillsDirstring