data/io_signatures/
An I/O signature: the named outputs a component kind fires and the inputs it accepts, each with a value type, so encounter templates link entities and the links are checked when they load (the ports exist and the value converts). A content input grants or revokes a tag, applies an effect or relays to one of the entity’s own outputs. The engine declares the signatures of its own components (manifold:io/…), and every entity has the User signature (FireUser1 to FireUser4, OnUser1 to OnUser4). One signature per component. Loaded by the server only.
| Registry | manifold-ai:io-signature |
| Files | data/io_signatures/*.ron, *.update.ron, *.final.ron |
| Sides | server: only the server loads it |
| Reads | nothing |
| Contract | Population, data stage |
Entry
A record, written IoSignature(..); the name before the parentheses is optional.
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
id | string | yes | The signature’s key, <mod-id>:<name>. | |
component | string | yes | The component key it describes ("mymod:door"). | |
outputs | list of (string, IoType) | no | none | The outputs, ("<Name>", <type>): names are letters, digits and _. |
inputs | list of (string, IoType, InputHandler) | no | none | The inputs, ("<Name>", <type>, <handler>). |
Example
No bundled file declares one yet. From the reference’s test fixture, crates/manifold-server-state/tests/data-reference-fixture/data/io_signatures/door.ron, which the data stage loads in its tests:
IoSignature(id: "dataref-fixture:io/door", component: "dataref-fixture:door")
Types
IoType
A port’s value type. An Int reaches a Fixed input, an Entity a Bool input, and anything an input that takes None.
| Variant | Written | Description |
|---|---|---|
None | None | No value. |
Bool | Bool | true or false. |
Int | Int | A whole number. |
Fixed | Fixed | A number, kept in thousandths. |
Entity | Entity | An entity. |
Tag | Tag | A tag. |
Text | Text | Text of at most 64 bytes. |
InputHandler
What an input does.
| Variant | Written | Description |
|---|---|---|
Native | Native | The engine’s own handling: only for the engine’s components. |
SetTag | SetTag(tag: .., value: ..) | Grants (value: true) or revokes the tag on the target. |
Effect | Effect(string) | Applies the effect (manifold:effect key) to the target, from the activator. An unknown key fails the data stage (DATA010). |
Output | Output(string) | Fires one of the target’s own outputs with the value, which must be declared in outputs. |
SetTag fields:
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
tag | string | yes | The tag (manifold:tag key). An unknown key fails the data stage (DATA010). | |
value | bool | no | true | Grant or revoke. |