Audio help
#4

Код:
if(IsPlayerInRangeOfPoint(playerid, putradiushere, coordx, coordy, coordz) && AudioStreamOn[playerid] == 0) 
{
	PlayAudioStreamForPlayer(playerid, "audiostreamurlhere");
	AudioStreamOn[playerid] = 1;			
}
// This somewhere into your gamemode.

new AudioStreamOn[MAX_PLAYERS];


and something like AudioStreamOn[playerid] = 0; OnPlayerConnect, to reset the value for joining players.



EDIT: You should put the InRange check into a 1-2 second timer, OnPlayerUpdate isn't really needed here. (OnPlayerInteriorChange might be good though)
Reply


Messages In This Thread
Audio help - by [SRB]Genius - 25.05.2012, 18:20
Re: Audio help - by HighPitchedVoice - 25.05.2012, 18:24
Re: Audio help - by [SRB]Genius - 25.05.2012, 18:35
AW: Audio help - by EthanR - 25.05.2012, 19:24
Re: Audio help - by [SRB]Genius - 26.05.2012, 08:38
Re: Audio help - by Kitten - 26.05.2012, 08:56

Forum Jump:


Users browsing this thread: 1 Guest(s)