Play a sound then open/close a door but can spam the sound... help?

Hey guys i need youre help.
Im new with the unreal engine 4 and i did a door which i can close and open also i add the sound for opening and closing… my problem is then the door is one the open animation and the sound plays i can spam the sound
maybe you can help me :slight_smile:

Sorry for my bad english

Thats how it looks now.

Use a second boolean like “IsMoving”. Set it to true as soon as the door is either opening or closing and set it to false when the Animation Timeline is finished.
Then, after the Branch with DoorClosed, create a new branch on EACH (true and false) exec. Connect the “IsMoving” bool to it and use the “false” exec for the Play
Sound etc.

Okay i think im to stupid for this. So i need to wait for a YouTube tutorial or screenshot what helps me out

But thanks for trying :smiley:

Alternatively, go the sound asset and open it. There’s a setting for how many instances you want of the same sound, you can set that to one. If you have a sound wave you will have to right click and make it a sound cue, because I think you will only find the setting there.

Edit: No problem. Feel free to send me 5% from your next game. :smiley: I joke.

Thanks mate! that worked fine! :slight_smile:

Here is what i meant.

EDIT2: Ok now:

But the other might work too. I just don’t know if this would also limit another door to not fire the sound. So if 2 doors open at once you might only hear one with MaxL’s solution (or?).

eXi raised a valid point. I didn’t consider your game using more than one door, hahaha. The other solution posted is probably best. If you’re still against learning it then you can set it so that only one sound is active at time, but the old sound is killed and the new sound is played at the current location, the setting I’m referring to should be in the same place were you set it to one active sound.

For now i just use only 1 sound Door blueprint. I will see if i add other doors. But thanks for the helping! :slight_smile:

Use a do once node? ?

This is the solution I used for the interaction within my project.

I would use a ‘do once node’ and then set a delay equal to the length of the animation as the ‘reset’. This means as soon as the animation ends, the player can re-interact with the object again.

Got this working after seeing your blueprint. Works when you approach the door, and then when you leave it (it closes) then makes the closing sound.