ParticleSystemSet Uncaught Error: Invalid property (y) in property path (emitter.y) when using AbstractMesh as emitterNode

When creating a particlesystemset and setting emitternode to a Mesh, the following error is logged:
Uncaught Error: Invalid property (y) in property path (emitter.y)

(Babylon.js Playground)
as far as I can tell, everything “works” but the runtimeAnimation class seems to expect the emitter to have “y” property (which abstractMesh doesn’t have). Seems to be an incompatibility between what the runtimeanimation class assumes an emitter is.

private _preparePath(target: any, targetIndex = 0) {
        const targetPropertyPath = this._animation.targetPropertyPath;

        if (targetPropertyPath.length > 1) {
            let property = target;
            for (let index = 0; index < targetPropertyPath.length - 1; index++) {
                const name = targetPropertyPath[index];
                property = property[name];
                if (property === undefined) {
                    throw new Error(`Invalid property (${name}) in property path (${targetPropertyPath.join(".")})`);
                }
            }

            this._targetPath = targetPropertyPath[targetPropertyPath.length - 1];
            this._activeTargets[targetIndex] = property;
        } else {
            this._targetPath = targetPropertyPath[0];
            this._activeTargets[targetIndex] = target;
        }

        if (this._activeTargets[targetIndex][this._targetPath] === undefined) {
            throw new Error(`Invalid property (${this._targetPath}) in property path (${targetPropertyPath.join(".")})`);
        }
    }

In my case emitter is a Mesh, but the _preparePath method doesn’t account for the fact that an emitter that is a mesh won’t have a y property.

Note: there’s a different problem using a Vector3 as the emitter (won’t get this error logged) but the position is sometimes “waaay off”…haven’t been able to repro in a sandbox yet though.

The “plumeAnimation” animation was created to animate the “y” property of the emitting object. If you want to use a mesh instead, you must modify it to animate “position.y” instead: