PlayAudioStreamForPlayer -
Ramin - 20.02.2016
Hi Thank You For Visiting
PHP код:
CMD:music(playerid, params[])
{
PlayAudioStreamForPlayer(playerid, "http://0up.ir/do.php?downf=clip3.mp3");
return 1;
}
My Problem Is When Finish Music Its Not REpeat
And Learn Me How I Can Start New Audio When Before Audio Finished
Please Help Thanks
Re: PlayAudioStreamForPlayer -
Karan007 - 20.02.2016
You should know when will this song finish. Take as an example, it will finish in 2 minutes. When the player do /music, set a timer for 2 minutes & when the music will finish, it will auto-restart.
Re: PlayAudioStreamForPlayer -
DyduShxD - 20.02.2016
Код:
CMD:music(playerid, params[])
{
SetTimer("SONGGGGG", 123000, true);
return 1;
}
CMD:stopmusic(playerid, params[])
{
StopAudioStreamForPlayer(playerid);
return 1;
}
forward SONGGGGG(playerid);
public SONGGGGG(playerid)
{
PlayAudioStreamForPlayer(playerid, "http://0up.ir/do.php?downf=clip3.mp3");
}
Re: PlayAudioStreamForPlayer -
Ramin - 20.02.2016
This Music Time is 2:11 2 Minute And 11 Seconds Please Show Me Timer For This Thanks For Helping
Re: PlayAudioStreamForPlayer -
DyduShxD - 20.02.2016
Just need to put time in miliseconds, for example: 3000(3 seconds), 120000(2 minutes)
Re: PlayAudioStreamForPlayer -
Ramin - 20.02.2016
Im Undrestand You Thank,s
]Rafaellos[ said to me You have to make the source repeating or calculate the seconds and create a timer of starting it again.
i dont know source repeat , but i need it
Thank You For Helping
Sry for My Bad English bros
Re: PlayAudioStreamForPlayer -
]Rafaellos[ - 20.02.2016
Next time use the correct section.
pawn Код:
CMD:music(playerid, params[])
{
playSong(playerid);
return 1;
}
forward playSong(playerid);
public playSong(playerid)
{
StopAudioStreamForPlayer(playerid);
PlayAudioStreamForPlayer(playerid, "http://0up.ir/do.php?downf=clip3.mp3");
SetTimerEx("playSong", 131000, true, "d", playerid);
return 1;
}