Playing an ambient sound evenly all over a cell, how to?

Post » Sat Dec 10, 2011 5:00 am

I have made an interior cell and added a custom sound to a marker with max range of 255 in CS. Everything works fine, but you can only hear that sound when close to the marker ingame. I duplicated the marker all over the cell, so that it looks like a minefield now, but still there are sound gaps between the markers. Ain't there a way to have an ambient sound being played evenly all over a cell?
User avatar
Euan
 
Posts: 3376
Joined: Mon May 14, 2007 3:34 pm

Post » Sat Dec 10, 2011 3:34 pm

Is there an issue with looping sounds on the player itself ?
User avatar
JD FROM HELL
 
Posts: 3473
Joined: Thu Aug 24, 2006 1:54 am

Post » Sat Dec 10, 2011 2:09 am

Ain't there a way to have an ambient sound being played evenly all over a cell?
PlaySound
User avatar
Tanika O'Connell
 
Posts: 3412
Joined: Fri Jan 26, 2007 1:34 am

Post » Sat Dec 10, 2011 6:08 pm

Hmm, I just took a vanilla ambience script and copy/pasted in my soundfile. So what would I have to change about this script? Problem is, when I walk a few steps past the sound marker all is quiet again. I've already used about 100 of those markers in that cell and still I get no density.

begin Sound_rainforest_01

if ( CellChanged == 0 )
if ( GetSoundPlaying "pvt_rainforest_01" == 0 )
PlayLoopSound3DVP "pvt_rainforest_01", 1.0, 1.0
endif
endif

end

Sound_rainforest_01
User avatar
BEl J
 
Posts: 3397
Joined: Tue Feb 13, 2007 8:12 am

Post » Sat Dec 10, 2011 4:27 pm

The function "PlaySound" makes the sound come from the player, "PlayLoopSound3DVP" makes it come from what the script is attached to (your markers).

I don't know to what extent PlaySound can be used to loop a sound (you might have to script it so it restarts?),
but if you can call PlayLoopSound3DVP from the player that would probably solve your problem.
User avatar
Tom Flanagan
 
Posts: 3522
Joined: Sat Jul 21, 2007 1:51 am

Post » Sat Dec 10, 2011 3:43 am

if you need a loop you can try this way (just 1 activator should do)
begin Sound_rainforest_01if ( CellChanged == 0 )	if ( player->GetSoundPlaying "pvt_rainforest_01" == 0 )		player->PlayLoopSound3DVP "pvt_rainforest_01" 1.0 1.0	endifendifend
or this way
begin Sound_rainforest_01if ( CellChanged == 0 )	if ( player->GetSoundPlaying "pvt_rainforest_01" == 0 )		player->PlaySound3DVP "pvt_rainforest_01" 1.0 1.0	endifendifend
or this way if you don't need frequency/volume tuning
begin Sound_rainforest_01if ( CellChanged == 0 )	if ( player->GetSoundPlaying "pvt_rainforest_01" == 0 )		player->PlayLoopSound3D "pvt_rainforest_01"	endifendifend

User avatar
Tiffany Carter
 
Posts: 3454
Joined: Wed Jul 19, 2006 4:05 am

Post » Sat Dec 10, 2011 1:34 pm

Awesome, thx!!! :) Works flawless with first script, sound is even more intense than when coming from all those single markers. Will try other scripts as well. Guess I gonna copy that, before it get's lost here.
User avatar
Emilie Joseph
 
Posts: 3387
Joined: Thu Mar 15, 2007 6:28 am


Return to III - Morrowind