# How do I spawn niagara particle(s) on triggered events, e.g. an OSC message, or button press?

**URL:** <https://forums.unrealengine.com/t/how-do-i-spawn-niagara-particle-s-on-triggered-events-e-g-an-osc-message-or-button-press/158185>\
**Category:** FX\
**Tags:** unreal-engine\
**Created:** [February 20, 2021, 3:56pm UTC](https://forums.unrealengine.com/t/how-do-i-spawn-niagara-particle-s-on-triggered-events-e-g-an-osc-message-or-button-press/158185 "2021-02-20T15:56:43Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![onar3d](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@onar3d](https://forums.unrealengine.com/u/onar3d)\
**Post date:** [February 20, 2021, 3:56pm UTC](https://forums.unrealengine.com/t/how-do-i-spawn-niagara-particle-s-on-triggered-events-e-g-an-osc-message-or-button-press/158185/1 "2021-02-20T15:56:43Z")

</div>

Hi!

I want to make it so that whenever an OSC message is received, I spawn one or more particles in a Niagara system. I was planning on at most using Blueprints for this, not C++ if I can avoid it.

I’ve found one way, by setting the probability to 0, and flipping it to 1 for a short while on receiving a message, but it’s not ideal, since it still needs to be at 1 for exactly one frame, or I will get either no particles triggered or too many, depending on how long I leave it flipped on to 1.

Is there a better way to achieve what I want, with more precision, so that each OSC message/keypress received is guaranteed to spawn n particles?

Thank you!

---

<div class="post-metadata">

**Author:** ![onar3d](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@onar3d](https://forums.unrealengine.com/u/onar3d)\
**Post date:** [February 21, 2021, 1:47pm UTC](https://forums.unrealengine.com/t/how-do-i-spawn-niagara-particle-s-on-triggered-events-e-g-an-osc-message-or-button-press/158185/2 "2021-02-21T13:47:37Z")

</div>

I’ve made some progress in my learning, and have come to the more explicit understanding that I need to map a “User Exposed” variable - float or bool - to an “Event Handler” which can spawn n variables in my particle system. Still unsure how those tow can be linked though.

When the variable changes it should somehow be interpreted as an event. Is that reasonable?

Edit:  
An RTFM link is definitely appreciated too 🙂 While experienced with graphics programming I am new to Unreal, so am not quite as good as I could be on finding information in the right places…

---

<div class="post-metadata">

**Author:** ![onar3d](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@onar3d](https://forums.unrealengine.com/u/onar3d)\
**Post date:** [April 3, 2021, 10:19am UTC](https://forums.unrealengine.com/t/how-do-i-spawn-niagara-particle-s-on-triggered-events-e-g-an-osc-message-or-button-press/158185/3 "2021-04-03T10:19:05Z")

</div>

As a step sideways, I learned that I can spawn “projectiles” on events, but I would still love for each projectile to be part of a Niagara system rather than essentially re-invent it…

Bumping this:

Any tips on how I can control the triggering of each particle spawn individually?
