Jump to content

Setting pitch or volume of a sound from a client won't take effect on other clients


Razer

Recommended Posts

    • Version?
    • Singleplayer/Multiplayer? 
    • Host or dedicated? 
    • Mods? 
    • Reproduction steps:

    • 41.65
    • Multiplayer.
    • Dedicated.
    • Yes.
    • Reproduction steps:
       1. Write a lua script or something that make player emit custom sound (Code example: soundID = getPlayer():playSound(soundName) )
       2. In the script in step 1, write a code to set volume and pitch for the sound id returned. (Code example: getPlayer():getEmitter():setPitch(soundID, 2)
       3. Start a server, joined with 2 clients as 2 players. Get the 2 players together, so they can here sound emitted from each other.
       4. Mute one of the clients as clientA, and make the clientA emit a sound by calling the script above. Then you should hear a sound with unchanged pitch and volume received by the other client as clientB. Similarly, unmute the clientA and mute clientB, emit sound from clientA again, then you should hear a sound set with intended pitch and volume.

The conlusion could be that when playing a sound from one client, the instruction DOES pass through network to other clients, so all the clients can hear the sound. However,  when setting the pitch and volume of the sound, they DO NOT pass to other clients. Therefore, the client which emits the sound can locally hear intended tuned sound, but clients from the othersides of the network only hear the original sound.

Although this problem seems trivial, but I really hope the devs can look into it, thanks!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...