Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 1 Vote(s) - 4 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Playing Sounds Randomly through a whole map.
Adny Offline
Posting Freak

Posts: 1,766
Threads: 6
Joined: Mar 2012
Reputation: 173
#2
RE: Playing Sounds Randomly through a whole map.

To set up a basic repeating timer (with random times), it will look something like this:

Spoiler below!


void OnStart()
{
AddTimer("", RandFloat(25.0f, 60.0f), "ambience");
}

void ambience(string &in asTimer)
{
AddTimer("", RandFloat(25.0f, 60.0f), "ambience");
}


Getting the different sounds to play is a bit trickier though. Can't think of a solution off the top of my head atm, I'll post back later if I think of something. Good luck with the rest Big Grin

I rate it 3 memes.
03-01-2013, 08:53 PM
Find


Messages In This Thread
RE: Playing Sounds Randomly through a whole map. - by Adny - 03-01-2013, 08:53 PM



Users browsing this thread: 1 Guest(s)