Had a search but can’t seem to find whether anyone’s talked about creating a GTA style radio system before. I’m pretty new to the event system and that’s pretty much all we’re using here right now but am I right in thinking that to be able to play from a specific point in a song is not possible with an event? I noticed the possibility of creating a ‘start from’ effect, though that can only be a maximum of 60 seconds, whereas when you change to a radio station the system could decide that a song needs to play from any position. I’m just coming onto this project and there is already a basic radio system in place purely using events and I think there are a lot of events set up for the songs so that’s the main reason it’d be nice to continue using them.
Not using events should be fairly easy though, using setPosition as you switch to a new channel or get into a car to move the playback to where the system decides, possibly using some static/tuning sound effects to hide any delay in setPosition working on a stream. Simpler still is to keep all the channels playing and mute those that aren’t being listened to, though I think we want to avoid this if at all possible at the moment.
Kinda realised I’m mixing the concepts of FMODs channels and my own idea of a radio channel, hope it’s not too confusing 😉
- identitycrisisuk asked 11 years ago
From how I understand the radio system in the GTA series, all the stations were rather long (40min – 1hr) compressed sound files that get streamed.
When the game started a random position was chosen in the streams and the game kept updating the position in all the streams but only playing the currently selected stream, and looping each stream back to the start when the end of the stream is reached.
When you get killed/arrested and respawn, the positions in the stream are randomized and start updating from the new positions.
That is a rather simple way of handling a static radio station which could be very easily implemented with the basic FMOD API by calculating the length of the sound files used, start maintaining a position in the files in your game loop, then when the player gets in a vehicle/swaps station load the stream, set the position to the one you have been maintaining, then let it play. When the user swaps station/gets out of the vehicle get a copy of the current position and start updating it yourself again, and either stop the stream or switch to the new one.
Personally, I think while the GTA stations were extremely good in their production and music choice, they do have one rather big problem. They get to be repetitive. With me (big GTA fan!) it got to the point where I always used the MP3 player instead of the game tracks since you could, just by hearing the song on the station, pick all the songs to come after it.
My idea on in-game radio stations is this.. Real radio stations have a playlist they play from, the DJ’s choose the tracks in the list or they let listeners call in a request a song that gets added to the list. There are also the commercials between groups of songs (like the ’10 in a row, commercial free’ on the local station I listen to at work) as well as the DJ usually carrying on with something.
I would implement a station based on that like this…
Create a base directory for the station, with subdirectories for music, jingles, DJ chatter, and news reports.
Fill the directories with whatever music and other media you like.
In the game, have your radio system generate a random list of upcoming music, then when the music is over, play a few jingles, some DJ chatter, a few more jingles then back to music again.
If you wanted you could use any order for music/jingles/DJ chater, but usually it would be an idea to stick to an authentic system used by stations (like the 10-in-a-row used near me).
To make it interesting, have news reports recorded based off major objectives in the game that the user must complete, then after the objective is completed, schedule the music to stop, the DJ to do some minor stuff and announce the news will follow shortly, play a couple of jingles then start the news report.
Hope this gives you some ideas.
Good point, hadn’t really thought about randomness yet, we already have the idea of random chatter and stuff and it’s mostly not going to be english so it doesn’t have to fit in or anything. Definately like the idea of a few songs in a row, with the design as it stands being for random chatter after each song it could well get annoying.
From a technical standpoint it’s definately going to have to revolve around the more low level fmod API though yeah? The events one would only work if we kept every station playing in the background – surprised at how often people seem to have used this method rather than stopping and starting though.
- identitycrisisuk answered 11 years ago
If you wanted randomness then the event system would be pretty much ruled out. I don’t think that the API is all that hard to manage either (one of the reasons I love FMOD, easy but powerful API)
I also had the thought too that it would be very easy to slot user-tracks into the radio system if you wanted to provide the ability. Also to make things a little more authentic in that respect, radio stations play a quick sound-bite over the song’s intro, identifying the station on songs that are new, popular or requests so that the start of the song is messed up for people recording it.
Please login first to submit.