In theory, is this possible?
#1

I've thought of an idea for a server recently, that I think would improve RP servers, but I'm curious if it's even possible.

Alright, so I know SA has an object that is a stereo. So, in theory.

Would it be possible so that one could buy a stereo from a place like a general store, and by doing a command like /dropstereo it creates the object under them (Like when you drop other items). While the object is on the ground, one could use certain commands, to then play music, that people who have the audio plugin that are in the area, would be able to hear it in-game.

For example, lets say I buy a stereo from 24/7, I drop it on a rooftop at grove street and I start playing a song (Saliva - Click Click Boom). People in grove street would be able to hear it as long as they have the audio plugin and are in the close area. Obviously, if you were to go off to idlewood or jefferson, you likely wouldn't be able to hear it.

Is this possible?
Reply
#2

Yeah.. this can also be done with the PlayAudioSteamForPlayer natvie, though in the past I used incognitos audio plugin to make a car radio system where the volume would change depending on your distance to the "stereo" but that part is not possible with the native.
Reply
#3

It's not a major deal if the audio doesn't change volume based on distance I don't think. It would be pretty good for an RP server for gangs and what not.
Reply
#4

Indeed, this is possible. A way you could do this, is, well, as stated above, using PlayAudioStreamForPlayer. Then you could use OnPlayerUpdate to see if the player is in the current coordinates of the placed radio, and if so, play the radio stream that is currently playing in the radio.

Hope I described it well enough, good luck,
KurtBag.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)