x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

New to UE4. How to use stop audio in this instance?

I am trying to learn UE4, just picked it up seriously recently. Below is a simple sound input on key down BP. However I want sound to stop immediately on key release. I am just not sure how to hook up stop sound however. When I google it, it seems people are setting the sound up as a component or something. Surely there is a way to just attach it to the sound cue that is being called? Thanks!

alt text

Product Version: UE 4.18
Tags:
simplefoot.png (148.7 kB)
more ▼

asked Nov 26 '17 at 06:10 AM in Blueprint Scripting

avatar image

zarsie
1 1 2 3

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

As you can see, Stop needs a reference, so instead of using PlaySoundAtLocation, use "SpawnSoundAtLocation" that node will return a reference to use in Stop

Also using it in tick event is quite unnecessary, there are input functions that will do the job You can either set up the input in your project setttings to use

alt text

alt text

alt text

alt text

Or use keyboard events

alt text

1.png (305.4 kB)
2.png (299.8 kB)
3.png (357.5 kB)
4.png (361.8 kB)
5.png (436.3 kB)
more ▼

answered Nov 26 '17 at 02:05 PM

avatar image

Daher
266 4 4 5

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question