Texture Sheet Animation not working in Particle System
Hello, fellow Unity developers and everyone in general.
I've recently started a new project using the Unity's Particle System, but came across with a little problem. I'm currently struggling to create animated particles of bats that shoot towards my player. I've used the Particle System before to create normal particles with great success. But somehow I can't get the Texture Sheet Animation feature to work. I want my bats to animate and flap their wings as they move towards the screen, increasing in size until they disappear.
First I have created a 512x512 pixels PNG image with Alpha channel to work as an animated texture sheet, thus having a total of 2x2 sprites, each with 256x256 pixels.
I have then imported the texture to Unity using the Multiple Sprite Mode. I even used the Sprite Editor to draw rectangles around each sprite individually.
And finally used the texture image to create a particle Material, using Mobile/Particles/Alpha Blended as Shader type (I'm developing for Android).
I set the Texture Sheet Animation on the Particle System and used Whole Sheet and 2 x 2 Tiles settings. I've also set the Frame over Time to Curve, instead of Constant (default).
But I'm getting the whole sheet displaying with all the 4 sprites at once (even when I set max particles to 1) instead of a single animated sprite, as it was supposed.
Am I missing anything here?! Or is this possibly a bug? I've looked everywhere for answer and feel I've tried everything already and I can't come up with a solution. I've even tried to change the texture to Single Row with a 1024x256 4x1 sprite sheet. Would anyone kindly point me in a direction here?
Thanks in advance for your time and effort to help us all newbies around here.
The setting seems right. $$anonymous$$aybe you can recreate the issue in a much simpler scene with dummy texture (replace each bat sprite with just a number), export and upload it to somewhere like Google Drive and share for us to inspect.
Answer by prabubejoslamet · Jun 18, 2017 at 11:15 AM
@Balthazaar have you sliced the texture? Just in case you haven't, try this:
Select your image/texture from the Project window, and then navigate to its Inspector window.
Change to Sprite (2D and UI).
Change the to Multiple.
Click on Sprite Editor button to open the Sprite Editor window.
Inside the Sprite Editor window, at the top left just under the label, you'll see tool, click on it, and choose a method you suitable for your need, Slice and don't forget to hit Apply.
Answer by jarado9 · Jan 24, 2018 at 08:05 AM
Have you made a particle material and put your sprite sheet texture on that material, and then put the material in the Renderer - Material slot...
A bit late to post looking at time of post but hope it helps someone.
Your answer
Follow this Question
Related Questions
Change particles per burst from code 2 Answers
Are there any disadvantages to using the legacy Ellipsoid Particle System in Unity 5 over Shuriken. 0 Answers
Has anyone found a way to change Shuriken particles with c# while it is in transit. 1 Answer
Particle Effect does not trigger again when the character animation loops in game view 0 Answers
How do you get particles to follow along the terrain? 1 Answer