How do I play audio at object

0 favourites
From the Asset Store
112 High-Quality destruction sounds for videogames
  • I have been using "regular" audio in my game. But now I need a sound that makes it at an object. So the closer I get to the object the harder it sounds.

    The object is a cannon who fires a bullet. sound is "poof"(for example) So I want that when I am standing next to the cannon poof is louder then when I am further away from it. I also have multiple cannons.

    So i use the action: Play at object.

    Then I get some options I dont fully understand

    Inner angle:

    outer Angle:

    Outer gain:

    I triend all different kind of settings but none of them work.

    I tried looking for tutorials but can't find them about this specific subject.

    Can somebody please help me fix this problem. If you need any other information let me know. I rather not give my capx I hope you understand.

  • Inner angle and outer angle are to create a cone of sound. If you leave them at there original values, which ara inner:360 outer:360 gain:0, you create a circle of sound around the object instead of directional sound.

  • I still do not understand how it is to operate. i set values to 1000 and still audio not playing (?)

  • Thank you for your answer. I tried it however nothing changed. I still have that when I am far away from the object I hear it as loud as standing next to it. I tried different outer gain as well.

    So far it seems to do the same as action: play

  • Audio manuak

    I guess you should change listener z-height, roll-off and/or any other audio settings before noticing any effect.

  • I am making a platform game. Do you have any tips on how to do that with the sound.

  • So how do I make the sound right? I wish there was a tutorial about it.

  • First you should use the audio set listener object action, that will probably help a lot.

  • I set my player object as listener object I tried it on start of the alyout as well as on every tick

  • Did you have a look at the audio object properties and set them to the values you'd like?

  • Here's an example Capx

    While playing click with your mouse around the player to hear the effect.

    (further away softer (because of roll off factor))

  • Thank you very much I finally understood what I needed to do. The funniest thing was. At first it didn't work then I realised I was previewing IE and the other capx was in chrome. That did the trick.

    But without your help it wouldn't be working now


  • PS just saw you were dutch as well on your website;)

  • LittleStain thanks

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • So my next problem is that it does not work in cocoonjslauncher.

    Does anybody knows a solution or does this function not work on phones?

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)