Builtin Library
README.md
Particles.spec
How the particle system reads an emitter spec. Each reader checks one field against the shapes it takes and raises a refusal naming the field and those shapes; level is how far out the refusal is reported, counted from the reader, so it lands on the call that wrote the value.
readRange(value, field, lo, hi, level)reads a number or{min, max}, andrangeArgs(min, max)packs the two arguments a range setter takes.readSize(value, fallbackSeq, level)reads a number,{min, max}, a NumberSequence or a keypoint list.asNumberSequence(value, fallback, field, level)andasColorSequence(value, fallback)read a curve.readBursts(bursts)normalizes a burst schedule;readDirection(dir)a direction.readNumber,readBoolean,readEnum,readVectorandreadTableread one value of their kind, andnameSet(names)builds the setreadEnumchecks against.
local Spec = require("@builtin::deprecated.deprecatedParticles.engine.spec")
local lo, hi = Spec.readRange({ 1, 3 }, "lifetime", 1, 1, 2)
print(lo, hi) -- 1 3