PendingSound - "A simple utility resource to allow you to play sounds to your clients."

So how is this working ? Sorry i’m a noob, how do you use it ? The same way as we did with interact sound ? Looks like from what i’m seeing in the export

this is amazing work!

Preview Video

i was able to get my siren working!

would there be a way in the future to stream a mp3 url instead of a local sound?

InteractSound and my resource is very similar.

The difference between the two is that InteractSound - as far as I am aware requires any sounds that you play locally to be put in the InteractSound resource.

My resource on the other hand allows you to put the files in the resource that you are calling it from. When I remove the resource that calls for the sound to play from my server I won’t have to go around removing the files in InteractSound and all of my project files are in the resource itself.

Edit : the specifics of how to call sounds to play are in the README.md

1 Like

Version 1.2 - Playing sounds through URL

Thanks again! Awesome work :slight_smile:

Can you please also install an export for the volume adjustment because your script is great and I want to use it properly, but I’m missing the one function to set the volume

I think you were meaning to be over on this thread PendingSound - "A simple utility resource to allow you to play sounds to your clients." - #10 by OKCRP

See the README.md - you control the volume of each sound separately.

Yes, you can set it once, that’s true, the export should be used so that you can change the volume dynamically the closer you get to it

nice work bro

Ah. Now I understand. That’s something that I’ll work on playing a sound in a specific location.

So, i’ve tried this one to see how it works. Can’t figure it out why it’s not working for me. I followed the examples from readme. Still no sound and on top of that i get other errors in my resource after adding the export. I’m doing something wrong for sure but i’ll stick with interact-sound for now.

If this will be updated in feature to have dynamic volume and play sounds from coords etc maybe I’ll replace the interact-sound. Adding the sound files in diff resources seems to be just a prefered option for many.

Using the export :

fxmanifest inside my script:

And the Error in game:

I would appreciate some help on this.

You’ll need to change your argument from "belle.ogg" to "sound/belle.ogg".

Essentially, you need to have whatever you put in the files argument of your __resource.lua

Did that, still the same error.

Could you send your resource’s file structure please.

I looked at your code: issue should be fixed - see your direct messages.

For anyone else that may be struggling with the resource - it was due to a mismatch of naming between “sounds/belle.ogg” and the actual file name “sounds/belle.ogg.ogg”

Thank you much for willing to help and for your effort bro, it’s working now. I will follow this as a template for the rest of the things i have in place with sound.

Another small question. Do you know a way that could work with distance ? Because that’s whay i’m trying to achieve, to play something at a specific location and that can be heard only if you are in the range.
Thank you again for everything ! I really appreciate it !

I saw that in your source code. I’m actively working on that.

Sounds based on co-ordinates.

Uses a form of the inverse square law to lower the volume of the sound when moving away from the sound.

I’ve managed that it works great could send the files once but if you use it make a note that I had contributed

1 Like

I’m not entirely sure what you mean by this - but if you want to contribute to the project please do so via Github - it should credit you automatically if it’s used in the project!