Schemas / Simulation
rig.sim.particle_emitter
v0.31.0 · draft 7 fields 3 required
Fields
| Field | Type | Meaning | |
|---|---|---|---|
rate |
float | required | Particles spawned per second |
lifetime |
float | required | Seconds each particle survives |
maxParticles |
int | required | Hard cap on live particles |
gravity |
vec3 | optional | Optional. Acceleration applied to every particle |
damping |
number0 – 1 | optional | Optional. 0-1, velocity lost per second |
startRgba |
rgba | optional | Optional. Colour at spawn |
endRgba |
rgba | optional | Optional. Colour at death; interpolated over the lifetime |
Particle spawn settings. Format when present.
Particles spawn at the entity's own position from rig.spatial.transform. There is no emitter shape - a volume or ring emitter is not portable, and a host that has one writes the settings it can and keeps the rest privately.
Live particles are never serialized. Reopening a document restarts the emitter empty rather than resuming mid-burst, so a screenshot of a running system will not reproduce exactly.
Seeds and randomness are not specified. Two hosts running the same emitter produce different particles on purpose; if you need a repeatable arrangement, author the entities instead.
JSON Schema
Resolves at https://rig.works/schemas/rig.sim.particle_emitter.schema.json —
raw file.
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://rig.works/schemas/rig.sim.particle_emitter.schema.json",
"title": "rig.sim.particle_emitter",
"type": "object",
"additionalProperties": false,
"properties": {
"rate": {
"$ref": "./_defs.schema.json#/$defs/float"
},
"lifetime": {
"$ref": "./_defs.schema.json#/$defs/float"
},
"maxParticles": {
"$ref": "./_defs.schema.json#/$defs/int"
},
"gravity": {
"$ref": "./_defs.schema.json#/$defs/vec3"
},
"damping": {
"type": "number",
"minimum": 0,
"maximum": 1
},
"startRgba": {
"$ref": "./_defs.schema.json#/$defs/rgba"
},
"endRgba": {
"$ref": "./_defs.schema.json#/$defs/rgba"
}
},
"required": [
"rate",
"lifetime",
"maxParticles"
]
}