πŸŽ›οΈModule Configuration

To use a Module from the Model Registry, admins must specify which components of the module they need; they can also tweak exposed properties of modules.

Module Manifest vs. Module Configuration

Module Configuration is an override over a particular Manifest that only contains part of the Manifest that are relevant for a particular use case.

Let’s take a look on the Car Module: it contains two artifacts, a name and a preview:

assetId: asset.morpheusxr.car
name: Car
meta:
  preview: https://storage.googleapis.com/xmorpheus-public-assets/artifacts/previews/v2/car.png
contents:
  - artifact:
      id: car.ford
      data: data.uZ_dpln_mTUK3IGmeb46H.JOmjpVD5l-eEYrzAkvAUQ
  - artifact:
      id: car.bmw
      data: data.onveouruohpfpp9gfwpwi.orvouqv90ar9e0pf97vgr

Now, we want our users to be able to spawn Ford cars; also they should see them as β€˜Guest Car’ in their spawn menu. For this, we need a Config, which is in the same format, but significantly shorter.

assetId: asset.morpheusxr.car
name: Guest Car
contents:
  - artifact:
      id: car.ford

assetId in the Module Config points to the Manifest this Config intends to override, other Manifest properties, if present, override the corresponding properties of the Manifest.

contents part of the config declares which items will be used when the Config is taken into action (for example, when an artifact is spawn). Only those items that are mentioned explicitly will be used. Properties of sub-manifests can also be overriden in the same way. In the example above, they are not.

Once created, Module Configs should be uploaded to a Content Folder of a particular Place. More details on this in the Modules in Places section.

Examples of Configs

Trivial configuration: no overrides, just use the module

assetId: asset.morpheusxr.car

Use the cars module, but replace the 3D asset

END

Last updated