PlayerPlaySound
#1

Oui mates, I wanted to know how to play a sound through "PlayerPlaySound" to players nearby the person who enters a CMD. Can you give me an example? Thank you fucking much <3.
Reply
#2

Quote:
Originally Posted by Clergy
Посмотреть сообщение
Oui mates, I wanted to know how to play a sound through "PlayerPlaySound" to players nearby the person who enters a CMD. Can you give me an example? Thank you fucking much <3.
https://sampwiki.blast.hk/wiki/PlayerPlaySound
Reply
#3

Quote:
Originally Posted by ForCop
Посмотреть сообщение
But that only plays it to the player, I want to it to play for the nearby players too!
Reply
#4

Quote:
Originally Posted by Clergy
Посмотреть сообщение
But that only plays it to the player, I want to it to play for the nearby players too!
Код:
CMD:sond(playerid, params[])
{
	new Float:x,Float:y,Float:z;
	GetPlayerPos(playerid, x, y, z);
	for(new i=0; i<MAX_PLAYERS; i++){
		if(!IsPlayerConnected(i)) continue;
		if(IsPlayerInRangeOfPoint(i, 10.0, x,y,z)){ //add radius
			PlayerPlaySound(i, 36401,0.0,0.0,0.0); // add id sond
		}
	}
	return true;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)