Thrazamund
Guest
Posts: 0
|
Post by Thrazamund on Aug 22, 2023 18:12:44 GMT
Hello, my game has large levels with multiple sections. Each level section I have a different drone sound(2d) I want to played. I've tried using the playlist but is this really the best approach? For instance if you walk through the hallway I want a certain drone to be played but if you walk into the computer room I want a different drone to be played with the ability to go back to the hallway drone if the player walks back. Seems like the Playlist is just setup for a linear or randomized order of sounds and not sounds based on area. Also, a side question my editor hitches when using MasterAudio.Play(hallwaySound) in code mid level is there a reason for this? Thanks.
|
|
|
Post by DarkTonic Dev on Aug 23, 2023 12:10:41 GMT
If there are predicable enter and exit triggers you can place, then you can play it with Event Sounds script, using those MonoBehavior events (Trigger Enter, Trigger Exit to stop).
Code hitches? What do you mean? Is that a Resource file sound?
|
|
Thrazamund
Guest
Posts: 0
|
Post by Thrazamund on Aug 23, 2023 13:53:40 GMT
Ok, I'm trying it with event sounds. Thanks.
Both in code and with event sounds when I play a new track I get a second or two hitch in my editor when the selected drone starts playing.
|
|
|
Post by DarkTonic Dev on Aug 23, 2023 13:55:04 GMT
Ok, what's the Audio Import settings for that Audio clip? Do you have decompress on load set? Screenshot is fine.
Also, you have configured it in Master Audio which audio origin? Clip, Addressable, Resource file?
|
|