Mod

Mod

new Mod(dataopt)

Source:
Example
// create a Mod
const { Mod } = require('lucid-dream');
const mod = new Mod({ name: 'My Mod', author: 'BSAC' });
Parameters:
Name Type Attributes Default Description
data Object <optional>
{}

An object containing the attributes of the Mod

Properties
Name Type Attributes Default Description
name String <optional>
'Lucid Dream Default'

The name of the Mod

version String <optional>
'0.0.1'

The version of the Mod (X.Y.Z)

author String <optional>
'Lucid Dream Author'

The author of the Mod

dependencies Array <optional>
[ { name: 'Everest', version: '1.0.0' } ]

An Array containing the dependencies of the Mod

chapters Array <optional>
[]

An Array of Chapter instances

dialog Dialog <optional>
new Dialog()

An instance of Dialog

Methods

(async) package(outputDir) → {null}

Source:

Package the Mod to a format loadable by Celeste

Example
// package a Mod to the `output` directory
const { Mod } = require('lucid-dream');
const mod = new Mod({ name: 'Packaged Mod', author: 'iamdadbod' });
// make any additional changes to the Mod
await mod.package('output');
Parameters:
Name Type Description
outputDir String

The directory to which to place the packaged Mod

Returns:
Type
null