PlayAudioStreamForPlayer
#1

PlayAudioStreamForPlayer - how to include a person who has just come?
Reply
#2

Under your register code
pawn Код:
PlayerAudioStreamForPlayer(playerid,link);
when he spawns
pawn Код:
StopAudioStreamForPlayer(playerid);
Reply
#3

Oh, I did not say so.
How to start playing music to the player who just came to me?
Reply
#4

Oh under onplayerupdate ( i think this will work)
pawn Код:
New name[MAX_PLAYER_NAME];
if(strcmp,name,"Dima",true,10)
{
        for(new i=0; i<MAX_PLAYERS; i++)
        {
                GetPlayerPos(name,X,Y,Z);
                if(IsPlayerInRangeOfPoint(i, 10, X,Y,Z))
                {
                          PlayerAudiostream...
                }
        }
        return 1;
}
im not sure if it will work, try it
Reply
#5

Quote:
Originally Posted by Tanush123
Посмотреть сообщение
Oh under onplayerupdate ( i think this will work)
pawn Код:
New name[MAX_PLAYER_NAME];
if(strcmp,name,"Dima",true,10)
{
        for(new i=0; i<MAX_PLAYERS; i++)
        {
                GetPlayerPos(name,X,Y,Z);
                if(IsPlayerInRangeOfPoint(i, 10, X,Y,Z))
                {
                          PlayerAudiostream...
                }
        }
        return 1;
}
im not sure if it will work, try it
Have you seen a boombox on LSRP? Here's how they do so?
Reply
#6

On LSRP function PlayAudioStreamForPlayer as was done?No one knows?
Reply
#7

I'll ask again, no one knows how to do it:
1.That when I went into the distance, for example 50 meters, then occurred StopAudioStreamForPlayer.
2.That when I was not even close, I go and I automatically PlayerAudioStreamForPlayer.

If you can help, I'd be very grateful.
Thanks in advance.
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)