Language:
Page Info
Tags:
Skill Level:
Engine Version:

Create a Sprite Based Effect with Niagara

Choose your OS:
Prerequisite Topics

This page assumes you have prior knowledge of the following topics. Please read them before proceeding.

One of the most used visual effects techniques is to render Texture and Materials to a 2D camera facing planes, called sprites. In the following How-To, we will take a look setting up a Niagara Emitter to work with sprites so that when the effect is placed in a level, it will work and be displayed correctly.

Sprite_Banner_01.png

Prerequisite Steps: This How-To uses�the M_smoke_subUV Material, which�can be found with the Starter Content. If you have not done so already, make sure that this Material or the Starter Content has been added to your project.

Steps

  1. First, we will need to create a Niagara Emitter by right-clicking in the Content Browser, and from the displayed menu select FX > Niagara Emitter.�
    SE_01.png

  2. Name the newly created Niagara Emitter FX_Smoke and then double-click it to open it.�
    SE_02.png

  3. With the Niagara Editor now open, go to the Selected Emitter panel and locate the Render section.

  4. Expand the Sprite Rendering section and set the following properties with the following values.
    CreateSpriteBasedEffect_Steps_Step4-SpriteRender.png

    Property Name

    Value

    Material

    M_smoke_subUV

    Sub Image Size

    X: 8.0, Y: 8.0

    Sub UV Blending Enabled

    Checked

  5. Collapse the Render section, then locate and expand the Emitter Update section.

  6. In the Spawn Rate section, change the Spawn Rate to a value of 50.0.
    CreateSpriteBasedEffect_Steps_Step6-EmitterUpdate.png

  7. Collapse the Emitter Update section, then locate and expand the Add Velocity section.�

  8. Set the Minimum and Maximum velocity to the following values.
    CreateSpriteBasedEffect_Steps_Step8-AddVelocityMinMax.png

    Property Name

    Value

    Minimum

    X: 0.0, Y: 0.0, Z: 50.0

    Maximum

    X: 0.0, Y: 0.0, Z: 200.0

  9. Locate the Sphere Location section.

  10. Set the Sphere Radius value to 64.0. Click the white arrow to expand the section, and make sure that the Surface Only box has been checked.
    CreateSpriteBasedEffect_Steps_Step10-SphereRadius.png

  11. Locate the Set Variables section.

  12. Expand the Particles.Lifetime variable.�This displays the Minimum and Maximum�fields.

  13. Set the Minimum and Maximum lifetime fields to the following values.
    CreateSpriteBasedEffect_Steps_Step13-ParticlesLifetimeMinMax.png

    Property Name

    Value

    Minimum

    2.0

    Maximum

    3.0

  14. Expand the Particles.SpriteSize variable to display the Minimum and Maximum fields.

  15. Set the Minimum and Maximum fields to the following values.
    CreateSpriteBasedEffect_Steps_Step15-ParticlesSpriteSizeMinMax.png

    Property Name

    Value

    Minimum

    X: 200.0, Y: 200.0

    Maximum

    X: 700.0, Y: 700.0

  16. Collapse the Particle Spawn section, then locate and expand the Particle Update section.�

  17. Locate the Acceleration Force section. Set the Z value to 500.
    CreateSpriteBasedEffect_Steps_Step17_AccelerationForce.png

    If your particle flow is going up and then down (like a fountain), make sure your Z value is positive and not negative. Positive goes up, negative goes down.

  18. Click the Plus sign icon (+) next to Particle Update to display a list of options. Select Set Specific Parameters > Particles.SubImageIndex. �This adds a Set Variables section for Particles.SubImageIndex.

  19. In the Particles.SubImageIndex section, click the white triangle next to Particle.SubImageIndex to display a list of options. Select Dynamic Inputs > Float From Curve.
    CreateSpriteBasedEffect_Steps_Step19-ParticlesSubImageIndexFloatCurve.png

  20. In the Curve input window, click the first key on the left side of the curve. For this key, set its Time and Value to 0.0.
    CreateSpriteBasedEffect_Steps_Step20-FloatCurveFirstKey.png

  21. Click the second key on the right side of the curve, and make sure that its Time is set to 1.0�and the Value is set to 0.64**.
    CreateSpriteBasedEffect_Steps_Step21-FloatCurveSecondKey.png

  22. In the Particles.SubImageIndex variable, press the small white triangle next to CurveIndex to display a list of options. Select Link Inputs > Particle Attributes > Normalized Age.
    CreateSpriteBasedEffect_Steps_Step22-CurveIndexNormalizedAge.png

  23. Then click the Compile, Apply and Save buttons to apply and save the changes, and close the FX_Smoke Niagara Emitter.
    SE_15.png

  24. Now over in the Content Browser, right-click and select FX > Niagara System. Name the new Niagara System Smoke.
    SE_16.png

  25. Double-click the Smoke Niagara System to open it, and drag the FX_Smoke emitter from the Content Browser to the Timeline.
    SE_17.png

  26. Click the Compile and Save buttons to apply and save your changes, then close the Smoke Niagara System. In the Content Browser, drag the Smoke Niagara System into the level viewport.

End Result

When complete, you will have a Niagara System playing the Niagara Emitter when you place the Niagara System in a level (like in the following video).

Tags