Hello everyone,
I have been running into limitations while making a 2D bullet hell (shoot-em-up) game, featuring thousands of projectiles on the screen at once made with Paper2D sprites.
As you can imagine, this really pulverizes the Draw Call performance, and I have decided to try using Niagara to draw the bullet sprites alongside the bullet actors, since this seems to be the only way to draw multiple sprites in one draw call (if there is in fact another way, please let me know).
My plan is to create an emitter with an initial burst of 4000 bullet sprite particles (the max amount I plan to use), and have them start off invisible and lasting indefinitely. Every time an enemy bullet is fired, I want the bullet actor to select a particle by numerical index, make it visible, control its position, and choose what sprite to use through C++. If the actor is destroyed, it makes the particle invisible again and stops moving it.
My question is, is this possible?
And if so, how would I be able to go about doing this? It’s pretty rough finding the right methods to accomplish this. Is there a ‘GetEmitterParticleByIndex(int)’ method somewhere?
If I cannot get particles by index, can I instead just spawn a single particle from the bullet actor and keep a reference to it so it can be controlled?
Please let me know, as my game project hinges on this one issue. If this cannot be solved, I may have to switch to another engine, or god forbid make my own.
Thanks!
~Sol