World Utilities / Converters

Converters

Converters listen to one or more values and write a derived result into another value.

A converter sits between values. Whenever one of its inputs changes, it recomputes its result and writes it into a target value, which in turn notifies its own subscribers. Because the result is just another value, converters can be chained and their output can be used by anything that accepts a value: applicators, UI, other converters or your scripts.

[ Synchronized Boolean ] ─┐
  "owner enabled music"   ├─▶ [ Boolean Operation: AND ] ──▶ [ Local Boolean ] ──▶ [ Object Toggle ]
[ Persisted Boolean    ] ─┘                                     "music on"          Music Player
  "player wants music"

Most inputs offer three source types:

Type Reads from
STATIC a constant entered in the inspector
LOCAL a local value - persisted values work here too
SYNCHRONIZED a synchronized value

Write converter results into a local value whenever possible. Every client runs the converter itself, so a synchronized target would make every player fight over ownership of the same value.