mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-15 16:44:36 +00:00
Merge pull request #869 from Azaezel/alpha401/audioFIxes
soundasset sourcegroup fallback
This commit is contained in:
commit
7f598e18fc
4 changed files with 13 additions and 3 deletions
|
|
@ -225,6 +225,8 @@ bool SoundAsset::loadSound()
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{// = new SFXProfile(mProfileDesc, mSoundFile, mPreload);
|
{// = new SFXProfile(mProfileDesc, mSoundFile, mPreload);
|
||||||
|
if (mProfileDesc.mSourceGroup == NULL)
|
||||||
|
mProfileDesc.mSourceGroup = dynamic_cast<SFXSource*>(Sim::findObject("AudioChannelMaster"));
|
||||||
mSFXProfile.setDescription(&mProfileDesc);
|
mSFXProfile.setDescription(&mProfileDesc);
|
||||||
mSFXProfile.setSoundFileName(mSoundPath);
|
mSFXProfile.setSoundFileName(mSoundPath);
|
||||||
mSFXProfile.setPreload(mPreload);
|
mSFXProfile.setPreload(mPreload);
|
||||||
|
|
|
||||||
|
|
@ -30,7 +30,7 @@ function UI::initClient(%this)
|
||||||
{
|
{
|
||||||
//Load UI stuff
|
//Load UI stuff
|
||||||
//we need to load this because some of the menu profiles use the sounds here
|
//we need to load this because some of the menu profiles use the sounds here
|
||||||
//%this.queueExec("./datablocks/guiSounds");
|
%this.queueExec("./datablocks/guiSounds");
|
||||||
|
|
||||||
//Profiles
|
//Profiles
|
||||||
%this.queueExec("./scripts/profiles");
|
%this.queueExec("./scripts/profiles");
|
||||||
|
|
|
||||||
|
|
@ -1 +1,4 @@
|
||||||
<SoundAsset canSave="true" canSaveDynamicFields="true" AssetName="buttonClick" soundFile="@assetFile=buttonClick.wav" PitchAdjust="1" VolumeAdjust="1" is3D="false" isLooping="false" isStreaming="false" useHardware="false" minDistance="1" maxDistance="100" coneInsideAngle="360" coneOutsideAngle="360" coneOutsideVolume="1" rolloffFactor="-1" scatterDistance="0 0 0"/>
|
<SoundAsset
|
||||||
|
AssetName="buttonClick"
|
||||||
|
soundFile="@assetFile=buttonClick.wav"
|
||||||
|
sourceGroup="AudioChannelGui"/>
|
||||||
|
|
|
||||||
|
|
@ -1 +1,6 @@
|
||||||
<SoundAsset canSave="true" canSaveDynamicFields="true" AssetName="buttonHover" soundFile="@assetFile=buttonHover.wav" PitchAdjust="1" VolumeAdjust="1" is3D="false" isLooping="false" isStreaming="false" useHardware="true" minDistance="1" maxDistance="120" coneInsideAngle="360" coneOutsideAngle="360" coneOutsideVolume="1" rolloffFactor="-1" scatterDistance="0 0 0"/>
|
<SoundAsset
|
||||||
|
AssetName="buttonHover"
|
||||||
|
soundFile="@assetFile=buttonHover.wav"
|
||||||
|
useHardware="true"
|
||||||
|
maxDistance="120"
|
||||||
|
sourceGroup="AudioChannelGui"/>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue