Unexpected chain reaction

Hello everyone,

I’m fairly new to UE4 and I don’t understand a chain reaction happening in one of my blueprints.


The first branch check if the player is overlapping an object, AND pressing the trigger button. The second branch check an Variable value (which i made 0 by default). If the value is 0, it sets it to 1. Then the next branch checks again the variable value, and play a sound if it is 1.

I Thought it would work as follow:

If i press the button once, the value of the variable change to 1. If i press it again, the sound play. But in pratice it plays already on first press!

Do you have any idea why it does that?

Thank you very much

Right Click on the first branch and ‘toggle breakpoint’. That should give you more info on what’s going on. Otherwise, post your variable details.

Thank you for your help Salm!

For an unkwown reason i reproduced the exactly same blueprint and now it works. It may be because of the variable default value, but i really thought I made it 0 !

Anyway thank you for the breakpoint tip it may prove very useful for troubleshooting.