DOCS // pyrofx

Values over time

Any field marked animatable takes either a constant or keys over simulated seconds, such as fuel = [[0.0, 4.0], [0.5, 0.0]]. The value blends between keys with linear, smooth or step easing and holds outside them.

Contents4 sections
  1. Syntax
  2. Animatable fields
  3. Motion
  4. Questions

Syntax

values over time
fuel = 4.0                                        # constant
fuel = [[0.0, 4.0], [0.5, 0.0]]                   # keys: [seconds, value]
position_m = [[0, -3, 1, 0], [2, 3, 1, 0]]        # keys of a vector: [seconds, x, y, z]
fuel = { keys = [[0, 4], [0.5, 0]], ease = "smooth" }   # ease: linear (default), smooth or step
  • A key is [seconds, value], or [seconds, x, y, z] for a vector.
  • Values blend between keys and hold outside them. Times must rise.
  • ease is linear (the default), smooth or step.
  • The schema tool marks these fields "animatable": true.
  • As a set override: emitters.0.fuel=[[0,4],[0.5,0]].

Animatable fields

SectionFields
[[emitters]]position_m, size_m, thickness_m, rotation_deg, fuel, temperature_k, smoke, dust, velocity_mps, direction, spread_deg, jitter, lumpiness
[[forces]]position_m, size_m, rotation_deg, falloff, strength, direction, max_speed_mps
[[obstacles]]position_m, size_m, height_m, rotation_deg
[solver]buoyancy, burn_rate, ignition_k, flame_k, expansion and more

schema has the full list.

Motion

Key position_m to move an emitter or obstacle, rotation_deg to turn it. Moving solids push gas; spinning ones drag it.

Questions

How do I animate a pyrofx field over time?

Provide a list of pairs of time and value or time and XYZ coordinates for vectors.

What easing modes does pyrofx support for animated values?

Animated fields support linear, smooth or step easing, blending between keys and holding values outside them.

Which pyrofx sections support animatable fields?

Emitters, forces, obstacles and solver sections all include animatable fields marked in the schema.