Hello. I have this shell ejection UTParticleSystemComponent on my weapons that spit out shell casings when the weapon is fired. The casings land on the ground but disappear when the weapon is put away. How would you make them persistent and not disappear when the weapon is put away? I can't use the emitter pool since I need to be able to change the FOV the particle system is rendered with.
Announcement
Collapse
No announcement yet.
Persistent particle system component on a weapon?
Collapse
X
-
Lifespan is under the required part of the particle module. Set it to 0. Set lifetime to 0 as well.
http://udn.epicgames.com/Three/Parti...uired%20Module
Comment
-
The thing is, once you un-equip a weapon with the default inventory system, it stops existing, it cannot do anything anymore.
What you need to do is work around that somehow, for instance managing the particle system component in your pawn class instead. Of course, managing weapon stuff in the pawn class is sub-optimal, but it works.
Comment
-
Actually, I don't think it stops existing, as one of the performance workarounds that I've done to the default weapon system is to completely shut them down when they are not in use (some of you might be surprised by how much CPU time a weapon that isn't in use can take up). However, the mesh is detached, which probably causes anything that is attached to it to become inactive, or dead, or whatever. If the attached emitter comes back to life when you bring it back up, it's probably something like that. Having tons and tons of extra particles hanging out though is probably far more concerning for performance reasons than a few ticks spent doing nothing on a dead weapon
it does sound like you may want to have the particlesystemcomponent as part of the pawn, if you need these to persist for significantly longer periods, though. Or *shudder* make their results seperate actors.
Comment
Comment