| Blockland Forums > Modification Help |
| Randomly playing sounds |
| (1/1) |
| VerticalHorizon:
Is it possible to have a sound play randomly instead of just having the loop play back to back? I want to have an ambient pack with for example a seagull sound that just plays randomly (Not just squee,squee,squee over and over again.) |
| -Koden-:
You can do this manually by making tons of functions each with a different schedule to the next one. |
| Zor:
--- Quote from: -Koden- on July 15, 2007, 12:47:25 PM ---You can do this manually by making tons of functions each with a different schedule to the next one. --- End quote --- actually you could just do --- Code: ---schedule(getRandom(1000,20000),0,functionThatPlaysYourSound); --- End code --- and it would play the sound randomly at 1 to 20 second intervals. change the values in getRandom to change the possible intervals. |
| Reactor Worker:
your gonna want to have more than one 'sqauk'. even if it is random, needs pitch and tone changes. Lets here angry seagull, happy seagull, and my favourite; severly bloated seagull (Think of a really fat seagull which can't fly and must instead roll to get where its going). I hope your going to include other cool ambients like: Road/street noises, Soccer/footbal game noises (fans cheering) and maybe a space ambience (really should be silent but you could go with the typical electronic sounds). |
| Navigation |
| Message Index |