PlayAudioStreamForPlayer Help - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: PlayAudioStreamForPlayer Help (
/showthread.php?tid=465084)
PlayAudioStreamForPlayer Help -
iBeast - 20.09.2013
pawn Код:
CMD:smfa(playerid, params[])
{
foreach(Player, i)
{
if (PlayerInfo[playerid][Level] >= 4)
{
if(isnull(params)) return SendClientMessage(playerid, COLOR_WHITE, "USAGE: /smfa [Link]");
PlayAudioStreamForPlayer(i, params);
}
}
return 1;
}
when i use this command it sends clientmessagetoall that what link is being played...but i want that the link doesnt show up and rather just shows up to the admin who is streaming...
any kind of help would be much appreciated.
Re: PlayAudioStreamForPlayer Help -
jakejohnsonusa - 20.09.2013
This is a question we have all asked at some point. I spent like a ton of time trying to find a way.The answer is your sort of out of luck. The SA-MP developers scripted it to always do that, nothing in your scripting will work to remove it.
The only fix/workaround is clearing the chat directly after it sends the play audio command.
Re: PlayAudioStreamForPlayer Help -
xganyx - 21.09.2013
pawn Код:
CMD:smfa(playerid, params[])
{
if(PlayerInfo[playerid][Level] >= 4)
{
if(isnull(params)) return SendClientMessage(playerid, COLOR_WHITE, "USAGE: /smfa [Link]");
for(new i; i < MAX_PLAYERS; i++) // loop all the players
{
PlayAudioStreamForPlayer(i, params);
}
}
else return SendClientMessage(playerid,COLOR_RED,"You not hight enough level to use this command");
return 1;
}