Talos docs

script

Since 0.6
Plain text

Use it in a scene entity's components list as { "type": "script", … }. The contract writes the fields flat and refuses unknown keys.

Fields

FieldTypeRequiredDefaultAllowed valuesDescription
modulestringyes
propsobjectno

Rules that can refuse it

Example

From the contract's tested fixture fixtures/contract/full20/scene.json#door.

{
  "type": "script",
  "module": "sliding-door",
  "props": {
    "openOn": "hazard-reached",
    "speed": 1.5
  }
}