Guest User

Sistema de celular que toca musica

a guest
Oct 30th, 2020
1,013
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.50 KB | None | 0 0
  1. /*
  2.  
  3. SISTEMA CELULAR
  4. FEITO POR: Buldog_Scripter
  5. */
  6.  
  7. // INCLUDES
  8. #include <a_samp>
  9.  
  10. // FS
  11. #define FILTERSCRIPT
  12. #if defined FILTERSCRIPT
  13.  
  14. // DIALOG
  15. #define celular 100
  16. #define RADIOS 5324
  17. #define URL 5325
  18.  
  19. public OnFilterScriptInit()
  20. {
  21. print("\n--------------------------------------");
  22. print(" SISTEMA CELULAR CARREGADO :)");
  23. print("--------------------------------------\n");
  24. return 1;
  25. }
  26.  
  27. public OnFilterScriptExit()
  28. {
  29. return 1;
  30. }
  31.  
  32. #else
  33. #endif
  34.  
  35. public OnPlayerConnect(playerid)
  36. {
  37. SendClientMessage(playerid, -1,"[!] Sistema de celular , by Buldog_Scripter");
  38. return 1;
  39. }
  40.  
  41. public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
  42. {
  43. if(dialogid == celular)
  44. {
  45. if(response)
  46. {
  47. if(listitem == 0)
  48. {
  49. SendClientMessage(playerid,VERMELHO,"INSTALANDO APLICATIVO.....");
  50. SendClientMessage(playerid,VERDE,"APLICATIVO INSTALADO COM SUCESSO");
  51. SendClientMessage(playerid,AMARELO,"PARA USAR DIGITE /ds [mensagem]" );
  52. }
  53. else if(listitem == 1)
  54. {
  55. SendClientMessage(playerid,VERMELHO,"INSTALANDO APLICATIVO.....");
  56. SendClientMessage(playerid,VERDE,"APLICATIVO INSTALADO COM SUCESSO");
  57. SendClientMessage(playerid,AMARELO,"PARA USAR DIGITE /musicas" );
  58. }
  59. else if(listitem == 2)
  60. {
  61. SendClientMessage(playerid,VERMELHO,"INSTALANDO APLICATIVO.....");
  62. SendClientMessage(playerid,VERDE,"APLICATIVO INSTALADO COM SUCESSO");
  63. SendClientMessage(playerid,AMARELO,"PARA USAR DIGITE /sms [ID] [mensagem]" );
  64. }
  65. else if(listitem == 3)
  66. {
  67. SendClientMessage(playerid,VERMELHO,"INSTALANDO APLICATIVO.....");
  68. SendClientMessage(playerid,VERDE,"APLICATIVO INSTALADO COM SUCESSO");
  69. SendClientMessage(playerid,AMARELO,"PARA USAR DIGITE /ligar [ID]" );
  70. }
  71. }
  72. }
  73. if(dialogid == RADIOS){
  74. if(response){
  75. switch(listitem){
  76. case 0:{
  77. PlayAudioStreamForPlayer(playerid,"http://listen.shoutcast.com:80/RadioHunter-TheHitzChannel");
  78. SendClientMessage(playerid,Amarelo,"[INFO: {00F5FF} Hunter selecionada!");
  79. SetPlayerAttachedObject(playerid,2226,5,0.394999,0.045000,0.027000,-25.299999,-101.699974);
  80. }
  81. case 1:{
  82. PlayAudioStreamForPlayer(playerid,"http://listen.shoutcast.com/jpfunkmusic");
  83. SetPlayerAttachedObject(playerid,2226,5,0.394999,0.045000,0.027000,-25.299999,-101.699974);
  84. SendClientMessage(playerid,Amarelo,"[INFO]: {00F5FF} Funk selecionada!");
  85. }
  86. case 2:{
  87. PlayAudioStreamForPlayer(playerid,"http://170.75.144.250:15672");
  88. SetPlayerAttachedObject(playerid,2226,5,0.394999,0.045000,0.027000,-25.299999,-101.699974);
  89. SendClientMessage(playerid,Amarelo,"[INFO]: {00F5FF} Sertanejo selecionada!");
  90. }
  91. case 3:{
  92. PlayAudioStreamForPlayer(playerid,"http://108.61.30.179:4010");
  93. SetPlayerAttachedObject(playerid,2226,5,0.394999,0.045000,0.027000,-25.299999,-101.699974);
  94. SendClientMessage(playerid,Amarelo,"[INFO]: {00F5FF} Hip Hop selecionada!");
  95. }
  96. case 4:{
  97. PlayAudioStreamForPlayer(playerid,"http://176.31.246.143:8300");
  98. SetPlayerAttachedObject(playerid,2226,5,0.394999,0.045000,0.027000,-25.299999,-101.699974);
  99. SendClientMessage(playerid,Amarelo,"[INFO]: {00F5FF} Reggae selecionada!");
  100. }
  101. case 5:{
  102. ShowPlayerDialog(playerid, URL, DIALOG_STYLE_INPUT, "Insira a URL", "Insira sua URL de um arquivo .MP3\nExemplo: {FF0000}http://sv12.onlinevideoconverter.com/download?file=j9a0h7a0d3e4g6e4", "Tocar", "Sair");
  103. }
  104. case 6:{
  105. StopAudioStreamForPlayer(playerid);
  106. SendClientMessage(playerid,Amarelo,"[INFO]: {00F5FF}Musica Desligada!{00F5FF}");
  107. }
  108. }
  109. }
  110. }
  111. if(dialogid == URL)
  112. {
  113. if(response){
  114. SendClientMessage(playerid, Amarelo, " via URL ligada com sucesso!");
  115. PlayAudioStreamForPlayer(playerid, inputtext);
  116. }
  117. return true;
  118. }
  119. return 1;
  120. }
  121. CMD:celular(playerid)
  122. {
  123. ShowPlayerDialog(playerid,celular,DIALOG_STYLE_LIST, "APLICATIVOS", " Discord \n Play Musicas \n Mensagens \n Telefone", "Selecionar", "Sair");
  124. return 1;
  125. }
  126. CMD:musicas(playerid)
  127. {
  128. SetPlayerAttachedObject( playerid, 0, 2226, 6, 0.398310, 0.000000, 0.071235, 0.000000, 259.946838, 0.000000, 1.000000, 1.000000, 1.000000 ); // LOW_HI_FI_3 - Radio de m??o
  129. ShowPlayerDialog(playerid,RADIOS,DIALOG_STYLE_LIST,"GOOGLE PLAY MUSICA","{00F5FF}Hunter\n{009ACD}Funk\n{FFD700} Sertanejo\n{CD00CD} Hip Hop\n{FF0000} Reggae\n{00688B}Youtube Mp3\n{EEE0E5}Desligar MP3","Selecionar","Cancelar");
  130. return 1;
  131. }
  132. CMD:ds(playerid, params[])
  133. {
  134. new Str[144], Name[MAX_PLAYER_NAME];
  135. GetPlayerName(playerid, Name, sizeof Name);
  136.  
  137. format(Str, sizeof Str, "{BDBDBD}[ DISCORD ] {FFFFFF}%s: {BDBDBD}%s", Name, params);
  138. SendClientMessageToAll(CINZA, Str);
  139. return true;
  140. }
  141.  
Add Comment
Please, Sign In to add comment