ParticleModule class abstract Particles

A unit of per-particle behaviour layered onto a system's simulation.

Modules run in two phases, in list order: spawn is called once for each newly created particle (to set birth state a shape or the main config does not), and update is called once per simulation step over all live particles (to apply forces or evaluate over-life properties). Both default to no-ops so a module implements only the phase it needs. A module touches only the storage columns it documents.

Implementers

Constructors

ParticleModule()
Creates a particle module.
const

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
spawn(ParticleStorage storage, int index) → void
Initializes the freshly spawned particle at index.
toString() String
A string representation of this object.
inherited
update(ParticleStorage storage, double dt) → void
Advances every live particle by dt seconds.

Operators

operator ==(Object other) bool
The equality operator.
inherited