Hi guys, I’m Ashif Ali, and you’re watching CGHOW. Today, I created a butterfly effect using Sprites in Niagara. The special part is that everything, including the animation, is done inside Niagara using alignment and facing in the Sprite system, without relying on a custom material for the animation. Let’s dive into this tutorial.
Step-by-Step Breakdown:
Material Setup:
Create Butterfly Material: Start by creating a material (named Butterfly).
Use Arrow Texture: Import the arrow texture and multiply it with the particle color.
Texture Adjustment: Adjust the texture’s color and invert the green channel to form the desired butterfly shape. Rotate the texture for correct orientation.
Niagara Setup:
Create Niagara Emitter: Set up a single particle emitter with a larger size and apply the arrow material to it.
Second Wing: Duplicate the first particle and apply a different color to simulate the second wing (e.g., green for the second wing).
Align Wings: Use custom alignment to orient both wings correctly, ensuring one wing faces the camera while the other aligns with the sprite’s facing direction.
Animation Setup:
Flapping Animation: To animate the butterfly flapping its wings, use a sine wave for the rotation of the wings.
Use Sine Wave: Adjust the sine wave value for flap speed.
Apply Different Speeds: Randomize the flap speed to make the animation more natural.
Velocity and Movement:
Add Velocity: To simulate butterfly movement, use the velocity line and link it to the facing angle.
Apply Curl Noise: Add curl noise to the velocity to make the butterfly fly around more randomly.
Texture Adjustment for Butterfly:
Replace Arrow with Butterfly Texture: Swap out the arrow texture for a butterfly texture and adjust the UV to display only half the butterfly at a time.
Fix Facing Issue: Invert the UV scale for one of the wings to ensure both wings face the correct direction.
Final Tweaks:
Randomize Speed and Colors: Add a random speed value to each butterfly to vary their flapping speed, and randomize the color if desired.
Finalize Butterfly Behavior: Increase the number of particles, adjust speeds, and finalize the flapping animation.
Conclusion:
So that’s how you can animate a butterfly effect using Sprites in Niagara. Thanks for watching, and keep learning. Bye!
Key Takeaways:
Used Sprite facing and alignment for butterfly wings.
No custom material for animation; the whole effect is done within Niagara.
Randomized butterfly speeds and animations for a natural feel.
Texture manipulation ensures the butterfly flaps realistically.
I am Ashif Ali, Real-Time VFX Artist, I make Unreal Engine Niagara Tutorial on this channel. I've made it my mission to share my knowledge and expertise with the world through my YouTube channel. So why not join me on this exciting adventure? Follow me on my social links, subscribe to my channel, and support my growth as a creator. Together, we can create amazing things and take our skills to new heights. And who knows, you might even get access to some of my exclusive files for free!