Guest User

Untitled

a guest
Jun 18th, 2018
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.20 KB | None | 0 0
  1. #include <a_samp>
  2. #include <core>
  3. #include <float>
  4.  
  5.  
  6. public OnPlayerConnect(playerid)
  7. {
  8. PlayAudioStreamForPlayer(playerid, 0, 0, 0, 0, 1112014848, 0);
  9. return 1;
  10. }
  11.  
  12. public OnPlayerSpawn(playerid)
  13. {
  14. StopAudioStreamForPlayer(playerid);
  15. return 1;
  16. }
  17.  
  18. public OnPlayerCommandText(playerid, cmdtext)
  19. {
  20. if(!strcmp(cmdtext, "/music", true))
  21. {
  22. return ShowPlayerDialog(playerid, 993, 2, 236, 312, 1612, 1644);
  23. }
  24. return 0;
  25. }
  26.  
  27. public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
  28. {
  29. PlayAudioStreamForPlayer(playerid, 1672, 0, 0, 0, 1112014848, 0);
  30. return 1;
  31. }
  32.  
  33. public OnPlayerExitVehicle(playerid, vehicleid)
  34. {
  35. StopAudioStreamForPlayer(playerid);
  36. return 1;
  37. }
  38.  
  39. public OnDialogResponse(arg0, arg1, arg2, arg3)
  40. {
  41. switch(arg1) {
  42. case 993:
  43. if(arg2)
  44. {
  45. switch(arg3) {
  46. case 0:
  47. StopAudioStreamForPlayer(arg0);
  48. PlayAudioStreamForPlayer(arg0, 1876, 0, 0, 0, 1112014848, 0);
  49. case 1:
  50. StopAudioStreamForPlayer(arg0);
  51. PlayAudioStreamForPlayer(arg0, 2084, 0, 0, 0, 1112014848, 0);
  52. case 2:
  53. StopAudioStreamForPlayer(arg0);
  54. PlayAudioStreamForPlayer(arg0, 2364, 0, 0, 0, 1112014848, 0);
  55. case 3:
  56. StopAudioStreamForPlayer(arg0);
  57. PlayAudioStreamForPlayer(arg0, 2632, 0, 0, 0, 1112014848, 0);
  58. case 4:
  59. StopAudioStreamForPlayer(arg0);
  60. PlayAudioStreamForPlayer(arg0, 2900, 0, 0, 0, 1112014848, 0);
  61. case 5:
  62. StopAudioStreamForPlayer(arg0);
  63. PlayAudioStreamForPlayer(arg0, 3228, 0, 0, 0, 1112014848, 0);
  64. case 6:
  65. StopAudioStreamForPlayer(arg0);
  66. PlayAudioStreamForPlayer(arg0, 3504, 0, 0, 0, 1112014848, 0);
  67. case 7:
  68. StopAudioStreamForPlayer(arg0);
  69. PlayAudioStreamForPlayer(arg0, 3832, 0, 0, 0, 1112014848, 0);
  70. case 8:
  71. StopAudioStreamForPlayer(arg0);
  72. PlayAudioStreamForPlayer(arg0, 4036, 0, 0, 0, 1112014848, 0);
  73. case 9:
  74. StopAudioStreamForPlayer(arg0);
  75. PlayAudioStreamForPlayer(arg0, 4240, 0, 0, 0, 1112014848, 0);
  76. case 10:
  77. StopAudioStreamForPlayer(arg0);
  78. PlayAudioStreamForPlayer(arg0, 4456, 0, 0, 0, 1112014848, 0);
  79. case 11:
  80. StopAudioStreamForPlayer(arg0);
  81. }
  82. }
  83. }
  84. return 1;
  85. }
Add Comment
Please, Sign In to add comment