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"

Panting sounds while sprinting

I want my player character to make panting sounds (which I've recorded) while sprinting, and then catch his breath upon stopping. I can't seem to get it to work. So far all I can get it to do is automatically play both sounds when the shift key is pressed, regardless of whether I'm moving. I also don't know how to make the initial panting sound stop when the shift key is released.

EDIT: Forgot to mention, my game is in first person.

Screenshot: alt text

Product Version: Not Selected
sprintblueprint.jpg (221.6 kB)
more ▼

asked Mar 27 '15 at 03:10 AM in Blueprint Scripting

avatar image

23 3 5 9

avatar image unit23 Mar 27 '15 at 03:34 AM

Basically I would add those sounds to your specific animation, i do this for footsteps, there is also a small tutorial on the forum about this, which uses notifies instead of sounds for triggering sounds depending on the ground material.

Because you need to add distance and speed (for the breath) you might use basic notifies on the animation (no sound).

Once you add a notify (new notify) to your animation it becomes available in the Blueprint editor as an event (Notify event)

Attached image shows sound notifies)

alt text

avatar image Aethryx Mar 27 '15 at 03:49 AM

That would be really helpful, but unfortunately I don't have any animations for my character at the moment, and I forgot to mention that my game is first person. I'll add those things in.

avatar image unit23 Mar 27 '15 at 04:07 AM

Well, i think ideally, without using animation notifies, you would create a "Sound Cue" add different sounds and add a random play node, then you load an Audio component on Input Sprint Key, and add a ">" node(attach your player speed variable), and click into the > node add a speed (for instance 25), then when triggered, load the audio component (Play audio node). Inside the audio component you can add the sound cue.

If you look into the example SHOOTER GAME (Launcher content), the player character there has such a sound cue.

avatar image Aethryx Mar 27 '15 at 06:37 AM

How would I load an audio component onto the sprint key? Also the > node doesn't connect to any play audio nodes because its output is boolean.

avatar image unit23 Mar 27 '15 at 11:08 AM

Look at the shooter game example. I'm back in about 10 hours.

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

0 answers: sort voted first
Be the first one to answer this question
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