Can you make a particle emitter that emits inwards?

I'd like to make a particle emitter that will spawn particles at a given radius and have those particles travel in to the center. The effect should be that the particles are being sucked in to a central point, like you would see on a portal. I've been playing around with the particle emitters and I can't seem to find a good way to make this happen. Anyone know how?

For a sphere, set minEmmiterRange to around 0.9 (90%) and TangentVelocity.Z to negative. Adjust Energy so they die before they cross the center and move outwards again.

Only works if the emitter is round (MinEmitterRange only properly sets them on the edge if XYZ are all the same.)

Tangent velocity clearly has something to do with "speed based on spawn position," but darned if I can figure it out.

Default particle emitters use only one emitter point. You want to use a complete sphere as emitter point. This is very well possible to create, but doing this in Unity will need some scripting. Maybe you could inherit from the `ParticleEmitter` class?

There is also this piece of documentation about Ellipsoid Particle Emitters. But still, I think it will require some scripting, because not every particle emitted from the emitter has the same velocity. And also the force in the particle animator is different for each particle.

So concluding: It requires some inheritance or reuse of the ParticleEmitter and ParticleAnimator class. When a new particle has to be created:

  1. Determine the place on the sphere
  2. Determine the velocity (starting speed)
  3. Determine the force for this particle in the Animator
  4. Determine the energy for this particle (time until it will reach the end)

Alternative (easier?) solution

While creating this answer, I came at some other pages in unity as well.

  1. Create a Mesh Particle Emitter with a Sphere as mesh.
  2. Create a Particle Collider inside your vortex
  3. Let your particles die when they come into the particle collider.

The only thing is: what is the starting velocity? What is the force? So still, maybe some coding is needed to get this going in your way. Or check google for some unity particle effects. I'm pretty sure that someone has already done this.

Update

Come to think of it, the ellipsoid particle emitters have local velocity, so you could use that probably.

Use a mesh particle emitter and have the min/max normal velocities be negative. (Either that or have the surface normals of the mesh pointing inwards.)

You can also use any kind of ParticleEmitter and use the .particles array to get the current particles and even changed them or add new particles. Just create a new array and write it back to .particles. Take a look at the Particle class which represents a single particle.