These are the docs for 13.7, an old version of SpatialOS. The docs for this version are frozen: we do not correct, update or republish them. 14.5 is the newest →

Entity interest

entity_interest is a required field in the bridge configuration section of a worker configuration file.

The entity interest field is about defining which entities a worker instance of this type gets component updates for.

If a worker instance is authoritative over an entity, it gets an update whenever that entity’s components change. But it also needs to know about the entities nearby.

By default, worker instances get component updates for all entities they’re authoritative over, as well as for all other entities in the same chunk (the grid squares of a SpatialOS world). But chunks are square, and so this doesn’t quite work.

You can use the entity interest field to set a radius (in world units, see note below). This is a radius around entities that a worker instance is authoritative over. If there’s another chunk with any point inside this radius, the worker instance will get component updates for entities inside that chunk.

For example, to make sure a worker instance gets updates from entities within 10 world units of any entity the worker instance has write access to, use the following entity_interest setting:

"entity_interest": {
    "range_entity_interest": {
        "radius": 10

Positions and distances are expressed in an arbitrary unit called “world unit”. It is up to the worker instances that run the simulation to interpret them consistently.

Search results

Was this page helpful?

Thanks for letting us know!

Thanks for your feedback

Need more help? Ask on the forums