KNG

Custom Audio Sfx

Recommended Posts

Hello,

 

I've got some questions. After doing some research (Steam Dev Forums) I found out that you can indeed use custom audio in your map.

 

So I added my custom audio to \data\custom\sfx\myaudio.ogg

 

In the Editor I clicked -> Refresh Filesystem, then clicked Validate and Build -> Build Audiobank.

 

Custom Audio SFX .ogg was detected and successfully imported.

 

Now I find out that these "custom" audio files can not be played using the SoundEmitter Classes etc. But rather using the Trigger in a objects (asset) _FIELDS_ properties.

 

How do you set this _FIELDS_ trigger property up properly?

 

I added the custom_sfx.ogg into the execute field:

 

Question do you have to specify filetype like do you add: a) custom_sfx.ogg or just B) custom_sfx into the field?

How does the trigger property work anyway?

 

What does autoexecuteRange (default 2.5) do?

What is Trigger Distance?

 

Here is what I did. I added a cb_radio_a.msh and put the custom sounds in the trigger, which wouldnt work.

 

The only way of making this cb_radio_a.msh "interactable" for me was to add the PhysicalSwitchDl Class, link that on to a Sound Emitter, then use the Sound Emitter to play aSoundName (which apperantly can only play the default sound SFXs etc.)

 

TLDR;

 

How does the Trigger property exactly work?

How do you exactly play a custom SFX .ogg when i.E. interacting with some object (like pressing a button on a radio).

 

 

Share this post


Link to post
Share on other sites

The only custom sound i imported were used in dialogs and movies so i never tested in sound emitters?

 

For the radio that you can enable with a button

I saw that ingame also in harran the ride when you meat jade .

There ´s also a scene with the talkie walkie in harran the ride next to the shop.

 

Try to load this map in your devtools to see how the radio is made.

 

Now there ´s also radio dialog quest phase (

You can put custom audio instead of dialog

Also adding subtitles).

 

http://steamcommunity.com/workshop/discussions/-1/530649887197778610/?appid=239140#c530649887201999038

Share this post


Link to post
Share on other sites

The only custom sound i imported were used in dialogs and movies so i never tested in sound emitters?

 

For the radio that you can enable with a button

I saw that ingame also in harran the ride when you meat jade .

There ´s also a scene with the talkie walkie in harran the ride next to the shop.

 

Try to load this map in your devtools to see how the radio is made.

 

Now there ´s also radio dialog quest phase (

You can put custom audio instead of dialog

Also adding subtitles).

 

http://steamcommunity.com/workshop/discussions/-1/530649887197778610/?appid=239140#c530649887201999038

 

Hey Cr1m3,

 

this is good info, but not exactly what I'm looking for. I will probably use it anyway at some point.

 

Again my problem is the following:

 

I have a radio mesh placed on a table, changed it's class from ModelObject to PhysicalSwitchDl and linked the "switch" properties to a sound emitter that would right now play any sound that is in the sound emitter library (apperantly sound emitters DO NOT support custom audio sfx).

 

So far this works.

 

The end result ist a usable radio on the table where I can walk to and a "Turn On" Dialog option appears that, when used, will play the audio linked from the Sound Emitter.

 

Turning the radio off, will obviously also turn off the sound emitter. So this works great and is cool and all...

 

Now my question is.... How can I link / add / call a _CUSTOM_ audio sfx when turning on the radio.

 

Anyone?

Share this post


Link to post
Share on other sites

Sound emitters seems to pick sounds here:

C:\Program Files (x86)\Steam\steamapps\common\Dying Light\DW\Data     all_in_maps_3.csb

but not any custom map.

 

I found how it is loaded into the tools:

C:\Program Files (x86)\Steam\steamapps\common\Dying Light Developer Tools\DW\Data\Scripts\Audio

audiodata.scr

//////////////////////////////////////////////////////////////////
// DEAD WORLD PRE PRODUCTION /////////////////////////////////////
//////////////////////////////////////////////////////////////////
AudioProc("map_default")
{
    LoadAudioBanks("menu")
    LoadAudioBanks("music_1")
    LoadAudioBanks("music_2")
    LoadAudioBanks("music_3")
    LoadAudioBanks("all_in_maps_1")
    LoadAudioBanks("all_in_maps_2")
    LoadAudioBanks("all_in_maps_3")
    LoadAudioBanks("all_in_maps_persistant")
    LoadLocalisedAudioBank("all_quests_local")
    LoadLocalisedAudioBank("common_local_1")
    LoadLocalisedAudioBank("common_local_2")
}

AudioProc("chromed")
{
    CallProc("map_default")
}

I know it does not answer to your question but maybe adding the "workshop_audio.csb"

to it could enable custom sound into map soundemitter simple?

 

I mean by modifying the audiodata_workshop.scr by adding a callproc with workshop_audio.csb

!include("AudioScript.def")

AudioProc("CustomSoundRadio")
{
    CallProc("map_default")
}

or LoadAudioBanks.

 

I did not tested but...

Share this post


Link to post
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