Product Chat / [SOLVED] Ambient object sound

Author
Message
MrManDude
4
Years of Service
User Offline
Joined: 14th Jan 2020
Location:
Posted: 14th Jan 2020 07:27
Hello there. My name is Eric and this is my first post. Like many posts I'm sure, this post is a plea for help.

I'm trying to get the sound of water dripping to come from a sink. I've got the sound in .wav format and I am trying to use the script that was posted on the thread about this subject:

https://www.youtube.com/watch?v=qCIwdbrURa0&feature=emb_logo

However, upon following the instructions and copying the script from the attachment on the thread, it doesn't seem to be working. So I am wondering, what is the most effective way to have an object make a looping noise that the community has been able to utilize? I don't mind using a different script if there is another one that is known to work with current versions of Windows and Gameguru.

Sorry if this question has been answered already, it's getting late and after being frustrated from not being able to make progress on this issue I am tired and hoping this thread will be more productive than I have been for the past hour.

Thanks!

The author of this post has marked a post as an answer.

Go to answer
PM
synchromesh
Forum Support
10
Years of Service
User Offline
Joined: 24th Jan 2014
Location:
Posted: 14th Jan 2020 11:26
Try this script …
Make sure you attach it to a Dynamic object.
The only person ever to get all his work done by "Friday" was Robinson Crusoe..

Attachments

Login to view attachments
PM
Tarkus1971
Audio Media Maker
9
Years of Service
User Offline
Joined: 24th Feb 2015
Location: England, UK
Posted: 14th Jan 2020 12:07
and make sure the sound you are using is mono for directional sound.
Aftershock Quad Core AMD FM2+ 3.5 GHz 8GB Motherboard and Processor, A7700k apu, Asus GT970 STRIX 4gb Nvidia gfx card.
King Korg Synth, Alesis SR18 Drum Machine, Akai MPX8 sample player, Roland Fantom XA Synth, Axus Digital AXK2 Digital Drum Kit, Novation Ultranova Synth, Waldorf Blofeld Synth, Roland D05 Synth Module, Bluedio Victory V Headphones, AKG K141 Studio Headphones, Lenovo Ideapad, with Windows 10 64bit, 8Gb Ram and AMD A10 7th Gen Graphics. Acer Swift i3 Laptop with Intel Optane memory, Intel 620UHD GPU, Windows 10 64bit.
AmenMoses
GameGuru Master
8
Years of Service
User Offline
Joined: 20th Feb 2016
Location: Portsmouth, England
Posted: 14th Jan 2020 21:23
https://forum.game-guru.com/thread/220877#msg2617569
Been there, done that, got all the T-Shirts!
PM
cybernescence
GameGuru Master
11
Years of Service
User Offline
Joined: 28th Jan 2013
Playing: Cogwheel Chronicles
Posted: 14th Jan 2020 22:10
That very informative thread is locked, so just re:

Quote: "
Ok, back to entity attached sounds, first thing to mention, and a personal bugbear of mine, is that even if you use a mono-WAV sound sample attached to an entity, once the sound sample starts to play its position is fixed, i.e. if the entity moves the sound does not move with it.
I originally considered this a bug myself and at one point added a PositionSound Lua command to get around it, the command works well but I haven't pushed it on GitHub yet because I would prefer to come up with a better solution."


I went to add this command for myself and discovered that LoopSound actually does this anyway, if you repeatedly call LoopSound on a moving entity (with a mono wav) the sound will follow the entity position (doesn't restart the sound as it checks to see if sound is already playing first, but re-positions in 3D space).

Cheers.



GPU: GeForce RTX 2070 SUPER PassMark: 14817
AmenMoses
GameGuru Master
8
Years of Service
User Offline
Joined: 20th Feb 2016
Location: Portsmouth, England
Posted: 15th Jan 2020 00:07
It makes sense for LoopSound because that would usually be something like an engine noise following a vehicle around but PlaySound is a bit trickier as in most cases you would want the sound to come from the place where it was triggered, i.e. like a collision noise of said vehicle (which wouldn't follow the vehicle IRL).

The PositionSound command I created was a really cool addition because it allowed you to position a sound explicitly, so for example a door slamming sound could be positioned correctly instead of coming from the doors origin (which is usually down at ground level near the hinged part of the door!).

Been there, done that, got all the T-Shirts!
PM
MrManDude
4
Years of Service
User Offline
Joined: 14th Jan 2020
Location:
Posted: 15th Jan 2020 02:12
Hmmmm I think that the sink object I was using isn't a dynamic object because I tested the realsound script on it and it didn't work but then tried it on a barrel (like in the video I referenced) and it did work. So that at least tells me what the issue is. I suppose my next quarry is how do I determine if an object is dynamic or not? Looking at both object properties, they look mostly the same.

For more information, the sink is from Classics\Modern Day 2
PM
Belidos
3D Media Maker
9
Years of Service
User Offline
Joined: 23rd Nov 2015
Playing: The Game
Posted: 15th Jan 2020 06:16
You change it in its properties,

Primary Desktop:
i7 7700,k NV1070 8GB, 16GB 3200mhz memory, 1x 2TB Hybrid, Win10.

Secondary Desktop:
i5 4760k, NV960 2GB, 16GB 2333mhz memory, 1x 2TB Hybrid, Win10.

Primary Laptop:
i5, NV1050 4GB, 8GB memory, 1x 1TB HDD, Win10.

Secondary Laptop:
i3, Intel 4000 series graphics, 6GB memory, 1x 500gb HDD, Win8.1.
synchromesh
Forum Support
10
Years of Service
User Offline
Joined: 24th Jan 2014
Location:
Posted: 15th Jan 2020 11:01 Edited at: 15th Jan 2020 11:05
This post has been marked by the post author as the answer.
Dynamic objects Highlight as green in the editor when the mouse touches it .. If its Static it shows as red.
So if you have a red static object you can select, extract and hit " Y " to make it green ( Dynamic )
Or as stated .. Select, Properties, Static Mode = No

Simply put the sink does not need to be Dynamic for this to work. You could simply add the script to a dynamic bar of soap or a bin on the floor. Anything near the sink will work just fine.
The only person ever to get all his work done by "Friday" was Robinson Crusoe..
PM
MrManDude
4
Years of Service
User Offline
Joined: 14th Jan 2020
Location:
Posted: 15th Jan 2020 19:05
That did it. Switched it to dynamic and now it works! Oh the simple things that stifle the inexperienced. Thank you all for your input. I very much appreciate it.
PM

Login to post a reply

Server time is: 2024-11-23 20:11:03
Your offset time is: 2024-11-23 20:11:03