Advertisement
Guest User

Untitled

a guest
May 20th, 2014
383
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.05 KB | None | 0 0
  1. /*
  2. _______
  3. | | | |__ __ __ _ _ __ __ _
  4. | |_| |\ \ /\ / // _` || `_ \ / _` |
  5. | _ | \ v V /| (_| || | | || (_| |
  6. |_| |_| \_/\_/ \__,_||_| |_| \__, |
  7. |___/
  8.  
  9. - Forum SA-MP profile: http://forum.sa-mp.com/member.php?u=207800
  10. */
  11. #include a_samp
  12.  
  13. /* Bag Pounds */
  14. #define BagPounds (5000)
  15. #define ikincielFiyat (2500)
  16.  
  17. #define DIALOG_DUBSTEP (15)
  18.  
  19. enum icerik
  20. {
  21. Bag,
  22. BagWear,
  23. Dinliyormu
  24. }
  25. new pInfo[MAX_PLAYERS][icerik];
  26. //------------------------------------------------------------------------------
  27.  
  28. public OnFilterScriptInit()
  29. {
  30. return print(" Dubstep Bag System Opened! - Hwang"), 1;
  31. }
  32.  
  33. public OnFilterScriptExit()
  34. {
  35. return print(" Dubstep Bag System Closed! - Hwang"), 1;
  36. }
  37.  
  38. public OnPlayerConnect(playerid)
  39. {
  40. return SendClientMessage(playerid,-1,"{FF00FF}System: {ffffff}Dubstep help command, type: /dubstephelp"), 1;
  41. }
  42.  
  43. public OnPlayerText(playerid, text[])
  44. {
  45. if(pInfo[playerid][Dinliyormu] == 1){
  46. new string[128],name[20];
  47. GetPlayerName(playerid, name, 20);
  48. format(string, sizeof(string), "{FF00FF}(Dubstep-Listener) {%06x}%s(%i): {ffffff}%s", GetPlayerColor(playerid) >>> 8, name,playerid, text);
  49. SendClientMessageToAll(playerid, string);
  50. return 0;
  51. } else {
  52. new string[128],name[20];
  53. GetPlayerName(playerid, name, 20);
  54. format(string, sizeof(string), "{%06x}%s(%i): {ffffff}%s", GetPlayerColor(playerid) >>> 8, name,playerid, text);
  55. SendClientMessageToAll(playerid, string);
  56. }
  57. return 1;
  58. }
  59.  
  60. public OnPlayerCommandText(playerid, cmdtext[])
  61. {
  62. if (strcmp("/buybag", cmdtext, true, 10) == 0)
  63. {
  64. if(pInfo[playerid][Bag] == 1) return SendClientMessage(playerid,-1,"{FF00FF}System: {ffffff}Zaten çantanız var!");
  65. if(GetPlayerMoney(playerid) < BagPounds) return SendClientMessage(playerid,-1,"{FF00FF}System: {ffffff}Çanta alabilmek için 5000$ gerekir!");
  66. GivePlayerMoney(playerid,-BagPounds);
  67. pInfo[playerid][Bag] = 1;
  68. SendClientMessage(playerid,-1,"{FF00FF}System: {ffffff}Bag bought!");
  69. return 1;
  70. }
  71. if (strcmp("/sellbag", cmdtext, true, 10) == 0)
  72. {
  73. if(pInfo[playerid][Bag] == 0) return SendClientMessage(playerid,-1,"{FF00FF}System: {ffffff}You do not have to buy bags!");
  74. GivePlayerMoney(playerid,ikincielFiyat);
  75. pInfo[playerid][Bag] = 0;
  76. return 1;
  77. }
  78. if (strcmp("/wearbag", cmdtext, true, 10) == 0)
  79. {
  80. if(pInfo[playerid][Bag] == 0) return SendClientMessage(playerid,-1,"{FF00FF}System: {ffffff}To wear your bag has to be!");
  81. pInfo[playerid][BagWear] = 1;
  82. SetPlayerAttachedObject(playerid, 3, 1210, 6, 0.230000, 0.100000, 0.000000, 2.000000, 270.000000, 0.000000);
  83. SendClientMessage(playerid,-1,"{FF00FF}System: {ffffff}Did you wear your bag, now {FF00FF}/dubstep {ffffff}you can open writing music!");
  84. return 1;
  85. }
  86. if (strcmp("/removebag", cmdtext, true, 10) == 0)
  87. {
  88. if(pInfo[playerid][Bag] == 0) return SendClientMessage(playerid,-1,"{FF00FF}System: {ffffff}Giyebilmek for çantanız Olması lazım!");
  89. pInfo[playerid][BagWear] = 0;
  90. RemovePlayerAttachedObject(playerid, 3);
  91. SendClientMessage(playerid,-1,"{FF00FF}System: {ffffff}Did you remove your bag.");
  92. return 1;
  93. }
  94. if (strcmp("/dubstep", cmdtext, true, 10) == 0)
  95. {
  96. if(pInfo[playerid][Bag] == 0) return SendClientMessage(playerid,-1,"{FF00FF}System: {ffffff}To listen to Dubstep bag has to be!");
  97. if(pInfo[playerid][BagWear] == 0) return SendClientMessage(playerid,-1,"{FF00FF}System: {ffffff}To use this, you must wear your bag!");
  98. pInfo[playerid][Dinliyormu] = 1;
  99. SetPlayerAttachedObject(playerid, 3, 1210, 6, 0.230000, 0.100000, 0.000000, 2.000000, 270.000000, 0.000000);
  100. ShowPlayerDialog(playerid,DIALOG_DUBSTEP,DIALOG_STYLE_LIST,"{FF00FF}Dubstep","{FF00FF}1) Skrillex - {ffffff}Bangarang\n{FF00FF}2) Skrillex - {ffffff}Make It Bun Dem\n{FF00FF}3) Skrillex - {ffffff}Kill everybody\n{FF00FF}4) Skrillex - {ffffff}First Of The Year\n{FF00FF}5) Skrillex - {ffffff}Ruffneck\n{FF00FF}6) Skrillex - {ffffff}Right IN\n7) {FF00FF}Dubstep durdur","Seç","Kapat");
  101. return 1;
  102. }
  103. if (strcmp("/dubstepyardim", cmdtext, true, 10) == 0)
  104. {
  105. new dY[512];
  106. strcat(dY, "{ff00FF}How can I listen to Dubstep?\n");
  107. strcat(dY, "{a9a9a9}/buybag = Buy Bag\n");
  108. strcat(dY, "{a9a9a9}/sellbag = Sell your bag.\n");
  109. strcat(dY, "{a9a9a9}/wearbag = Wear your bag.\n");
  110. strcat(dY, "{a9a9a9}/removebag = Remove your bag.");
  111. ShowPlayerDialog(playerid,1,DIALOG_STYLE_MSGBOX,"{FF00FF}Dubstep Help",dY,"Close","");
  112. return 1;
  113. }
  114. return 1;
  115. }
  116.  
  117.  
  118. public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
  119. {
  120. if(dialogid == DIALOG_DUBSTEP){
  121. if(response){
  122. if(listitem == 0){
  123. MuzikAc(playerid,"Skrillex","Bangarang","http://176.32.34.21/~mp3ler/data/Skrillex-feat-sirah---bangarang--dubstep-sector(-MP3Ler.Biz).mp3");
  124. }
  125. if(listitem == 1){
  126. MuzikAc(playerid,"Skrillex","Make It Bun dem","http://176.32.34.21/~mp3ler/data/Skrillex---damian-jr-gong-marley-make-it-bun-dem(-MP3Ler.Biz).mp3");
  127. }
  128. if(listitem == 2){
  129. MuzikAc(playerid,"Skrillex","Kill everybody","http://176.32.34.21/~mp3ler/data/Skrillex--kill-everybody(-MP3Ler.Biz).mp3");
  130. }
  131. if(listitem == 3){
  132. MuzikAc(playerid,"Skrillex","First Of The Year","http://176.32.34.21/~mp3ler/data/Skrillex-first-of-the-year(-MP3Ler.Biz).mp3");
  133. }
  134. if(listitem == 4){
  135. MuzikAc(playerid,"Skrillex","Ruffneck","http://176.32.34.21/~mp3ler/data/Skrillex-ruffneck-full-flex(-MP3Ler.Biz).mp3");
  136. }
  137. if(listitem == 5){
  138. MuzikAc(playerid,"Skrillex","Right IN","http://176.32.34.21/~mp3ler/data/Skrillex-right-in-original-mix(-MP3Ler.Biz).mp3");
  139. }
  140. if(listitem == 6){
  141. pInfo[playerid][Dinliyormu] = 0;
  142. StopAudioStreamForPlayer(playerid);
  143. SendClientMessage(playerid,-1,"{FF00FF}System: {ffffff}Dubstep closed.");
  144. }
  145. }
  146. }
  147. return 1;
  148. }
  149.  
  150. stock MuzikAc(playerid,sanatci[],muzikad[],link[])
  151. {
  152. new string[256];
  153. format(string,sizeof(string),"{ffffff}Musician: {FF00FF}%s {ffffff}- Dubstep: {FF00FF}%s",sanatci,muzikad);
  154. SendClientMessage(playerid,-1,string);
  155. PlayAudioStreamForPlayer(playerid,link);
  156. return 1;
  157. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement