How to make particles emit themselves facing the direction of the emitter?

When the particle quads come out of the emitter I want them to take their face/angle from the nature of the emitter, which is on an object in my scene that both moves and rotates. I can get the particle quads to emit from wherever the emitter is, but they will not cooperate with regards ONLY facing the direction they're coming off of the emitter at release. The emitter is attached to the object.

The quads either turn to face the camera, or, if using horizontal or vertical modes, they lay flat on that axis.

Is it possible to make them emit from the angle of the emitter, regardless of what that angle is? How?

I am not entirely sure what you mean when you say you want particles to face the direction they are coming off from. Either you want what you say, and want the particle geometrical face to point in the same direction they are traveling in for some special purpose. I also guess you could mean that you want the particles stretched into the direction they are traveling (to make arcs etc). Third, your particles doesn't move in the general direction you were hoping for.

  • For the former behavior I have no answer for. I don't think you can control which directions the billboards should face in greater detail.

  • For the second you can check the settings on your particle renderer.

Distorting particles

By default particles are rendered billboarded. That is simple square sprites. This is good for smoke and explosions and most other particle effects.

Particles can be made to either stretch with the velocity. This is useful for sparks, lightning or laser beams. Length Scale and Velocity Scale affects how long the stretched particle will be.

There should be a checkbox named "Stretched", that allows particles to strech out in the direction they travel. You can also apply camera velocity scale to stretch the particles based on camera velocity. See also Length scale and Velocity scale that affect how the streched effect behave.

  • If you are having problems with particles not emitting in the general direction you want, you are probably using world space settings instead of local space settings. These are configurable on your particle emitter.

I have the same issue. Basically I’m trying to create a star and would like the flames to emit from center but be rotated towards center. Seems like an obvious thing to me honestly.

use transform.LookAt

I had the same problem, but what I did was I created 10 different sprites as my particles, and equipped each of them with a script so every second one of the sprites would get teleported to the game object so it had the same rotation and position.

50246-hiearchy2.png

First I grouped all of my Trail Particle sprites and my Main Game Object together as children under one main parent.

Then I created a script that invokes a function to teleport each of the Trail Particles to the Main Game Object’s position and rotation using two float variables; “base” and “timeBeforeTeleportation”

InvokeRepeating ("Trail", base , timeBeforeTeleportation);

I made it so “base” = “timeBeforeTeleportation” / numberOfTrailParticles * trailParticleNumber

function Trail () {
    transform.position = mainGameObject.position;
    transform.rotation = mainGameObject.rotation;
    }

As you can see, the rest of my invoke statement is fairly simple. All it does is set each of the Trail Particles’ Transforms to have the same position and rotation as the Main GameObject. Finally all I did was add an opacity argument so they would slowly become transparent and then reset it every time they got teleported. It helps blend them better.

I realize you posted this question all the way in 2010, but I figured there was still a possibility of me helping you. :slight_smile:

Here is some example code on how to set the particle’s orientation: