Guest User

SA-MP Youtube Include

a guest
Aug 20th, 2012
192
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 0.88 KB | None | 0 0
  1. //==============================================================================
  2. //                         Youtube Stream Function By Snakeman
  3. //          Youtube Includesi,Snakeman tarafından derlenmiştir
  4. //                     http://forum.sa-mp.com/member.php?u=79457
  5. //          http://www.gtaturk.com/forum/profile/?u=29759
  6. //                      native YoutubeStream(playerid,vlink[]);
  7. //                      native YoutubeStopStream(playerid);
  8. //==============================================================================
  9. #include <a_http>
  10. #pragma tabsize 0
  11. #define YoutubeStopStream(%1) StopAudioStreamForPlayer(%1)
  12. stock YoutubeStream(playerid, vlink[])
  13. {
  14.     new videoid[128], mp3link[128];
  15.     strmid(videoid,vlink,strfind(vlink,"v=")+2,strfind(vlink,"v=")+15);
  16.     format(mp3link,128,""http://element-samp.net/youtube.php?videoid=%s",videoid);
  17.     PlayAudioStreamForPlayer(playerid,mp3link);
  18. }
Advertisement
Add Comment
Please, Sign In to add comment