Making specific players hear specific sounds.

  • Two Factor Authentication is now available on BeyondUnreal Forums. To configure it, visit your Profile and look for the "Two Step Verification" option on the left side. We can send codes via email (may be slower) or you can set up any TOTP Authenticator app on your phone (Authy, Google Authenticator, etc) to deliver codes. It is highly recommended that you configure this to keep your account safe.

Techno JF

He Who Has Powerful Words
Here's the effect I'm going for. When a player touches a certain actor in a level, the player makes a sound that only he can hear. (I figure that the player actually needs to make the sound, because I don't want him to be able to move out of hearing range and miss the latter parts of the sound. I'm being cautious and saying that the sound can be as long as 5 seconds in duration.) Meanwhile, the touched object makes a different sound that everyone in hearing range except the touching player can hear.

Is there a way to prevent a sound played in the world from being heard by a specific player? I'm pretty sure that there's an easy way to do this, but I'm not at all versed in the ways of controlling sound with UScript.
 

Techno JF

He Who Has Powerful Words
Thanks for the heads-up about the ClientPlaySound function. I tracked it all back to the PlaySound function in the base Actor class. However, after taking a look at it, I think I'm going to have to do a little math with this function. (i.e. to simulate distance from the actor by lowering volume) I was hoping I could just use the engine's native functions for determining sound audibility, and then find a way to block the instigator of the sound from hearing it.