Vfx graph question

General discussion about the media server. Feature requests. Hints, tips and tricks.
Post Reply
Savita8127
Posts: 1
Joined: Fri Nov 22, 2019 7:24 am
AV Hardware: UPnP clients
Contact:

Vfx graph question

Post by Savita8127 » Fri Nov 22, 2019 7:31 am

"Does vfx graph have analogue of rate over distance?
I've found something called ""Spawn over distance"", but it seems not working."

Vikrant2345
Posts: 1
Joined: Tue Nov 26, 2019 9:31 am
AV Hardware: UPnP clients

Re: Vfx graph question

Post by Vikrant2345 » Tue Nov 26, 2019 9:34 am

Hello!

Indeed the spawn over distance is your way to go if you need to spawn based on a moving position. Although it does not seem to work at first it needs to record a moving position every frame to compute the amount of particles to spawn: For instance the world position of the game object that holds the component.

The reason about this behavior is you do not necessarily need to use the owner position (for instance you would probably want to spawn based on a procedurally animated position)

Basically it expects a value that changes every frame to perform the computation. So providing the 0,0,0 local position every frame does not do much, but instead using a Change Space to convert the value into world space will do what you expect.

Also, this node does set two SpawnEvent attributes : position and old position, really useful if you need to distribute the particles in between the position and the previous position.

Post Reply