Guest User

samp loading screen

a guest
Mar 5th, 2016
1,552
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.22 KB | None | 0 0
  1. /////SAMP loading screen by UltraScripter////////////////////////////
  2.  
  3. #include <a_samp>
  4.  
  5. new Text:LOADSCS[14];
  6. new Spawned[MAX_PLAYERS];
  7.  
  8. #if defined FILTERSCRIPT
  9.  
  10. #endif
  11.  
  12. public OnPlayerConnect(playerid)
  13. {
  14. LOADSCS[0] = TextDrawCreate(0.0, 0.0, "loadsc1:loadsc1");
  15. TextDrawFont(LOADSCS[0], 4);
  16. TextDrawUseBox(LOADSCS[0], 1);
  17. TextDrawTextSize(LOADSCS[0], 650.0, 470.0);
  18. LOADSCS[1] = TextDrawCreate(0.0, 0.0, "loadsc2:loadsc2");
  19. TextDrawFont(LOADSCS[1], 4);
  20. TextDrawUseBox(LOADSCS[1], 1);
  21. TextDrawTextSize(LOADSCS[1], 650.0, 470.0);
  22. LOADSCS[2] = TextDrawCreate(0.0, 0.0, "loadsc3:loadsc3");
  23. TextDrawFont(LOADSCS[2], 4);
  24. TextDrawUseBox(LOADSCS[2], 1);
  25. TextDrawTextSize(LOADSCS[2], 650.0, 470.0);
  26. LOADSCS[3] = TextDrawCreate(0.0, 0.0, "loadsc4:loadsc4");
  27. TextDrawFont(LOADSCS[3], 4);
  28. TextDrawUseBox(LOADSCS[3], 1);
  29. TextDrawTextSize(LOADSCS[3], 650.0, 470.0);
  30. LOADSCS[4] = TextDrawCreate(0.0, 0.0, "loadsc5:loadsc5");
  31. TextDrawFont(LOADSCS[4], 4);
  32. TextDrawUseBox(LOADSCS[4], 1);
  33. TextDrawTextSize(LOADSCS[4], 650.0, 470.0);
  34. LOADSCS[5] = TextDrawCreate(0.0, 0.0, "loadsc6:loadsc6");
  35. TextDrawFont(LOADSCS[5], 4);
  36. TextDrawUseBox(LOADSCS[5], 1);
  37. TextDrawTextSize(LOADSCS[5], 650.0, 470.0);
  38. LOADSCS[6] = TextDrawCreate(0.0, 0.0, "loadsc7:loadsc7");
  39. TextDrawFont(LOADSCS[6], 4);
  40. TextDrawUseBox(LOADSCS[6], 1);
  41. TextDrawTextSize(LOADSCS[6], 650.0, 470.0);
  42. LOADSCS[7] = TextDrawCreate(0.0, 0.0, "loadsc8:loadsc8");
  43. TextDrawFont(LOADSCS[7], 4);
  44. TextDrawUseBox(LOADSCS[7], 1);
  45. TextDrawTextSize(LOADSCS[7], 650.0, 470.0);
  46. LOADSCS[8] = TextDrawCreate(0.0, 0.0, "loadsc9:loadsc9");
  47. TextDrawFont(LOADSCS[8], 4);
  48. TextDrawUseBox(LOADSCS[8], 1);
  49. TextDrawTextSize(LOADSCS[8], 650.0, 470.0);
  50. LOADSCS[9] = TextDrawCreate(0.0, 0.0, "loadsc10:loadsc10");
  51. TextDrawFont(LOADSCS[9], 4);
  52. TextDrawUseBox(LOADSCS[9], 1);
  53. TextDrawTextSize(LOADSCS[9], 650.0, 470.0);
  54. LOADSCS[10] = TextDrawCreate(0.0, 0.0, "loadsc11:loadsc11");
  55. TextDrawFont(LOADSCS[10], 4);
  56. TextDrawUseBox(LOADSCS[10], 1);
  57. TextDrawTextSize(LOADSCS[10], 650.0, 470.0);
  58. LOADSCS[11] = TextDrawCreate(0.0, 0.0, "loadsc12:loadsc12");
  59. TextDrawFont(LOADSCS[11], 4);
  60. TextDrawUseBox(LOADSCS[11], 1);
  61. TextDrawTextSize(LOADSCS[11], 650.0, 470.0);
  62. LOADSCS[12] = TextDrawCreate(0.0, 0.0, "loadsc13:loadsc13");
  63. TextDrawFont(LOADSCS[12], 4);
  64. TextDrawUseBox(LOADSCS[12], 1);
  65. TextDrawTextSize(LOADSCS[12], 650.0, 470.0);
  66. LOADSCS[13] = TextDrawCreate(0.0, 0.0, "loadsc14:loadsc14");
  67. TextDrawFont(LOADSCS[13], 4);
  68. TextDrawUseBox(LOADSCS[13], 1);
  69. TextDrawTextSize(LOADSCS[13], 650.0, 470.0);
  70. Spawned[playerid] = 0;
  71. return 1;
  72. }
  73.  
  74. public OnPlayerDisconnect(playerid, reason)
  75. {
  76. Spawned[playerid] = 0;
  77. return 1;
  78. }
  79.  
  80. public OnPlayerSpawn(playerid)
  81. {
  82. if(Spawned[playerid] == 0)
  83. {
  84. PlayAudioStreamForPlayer(playerid, "https://dl.dropbox.com/s/otw0f6mk0w1ouha/GTA%20San%20Andreas%20Theme%20Song%20Full%20%21%20%21.mp3");
  85. SetPlayerHealth(playerid, 999999);
  86. TogglePlayerControllable(playerid, 0);
  87. SetTimerEx("LOADSCS1", 100, false, "i", playerid);
  88. Spawned[playerid] = 1;
  89. }
  90. else return 0;
  91. return 1;
  92. }
  93.  
  94. forward LOADSCS1(playerid);
  95.  
  96. public LOADSCS1(playerid)
  97. {
  98. TextDrawShowForPlayer(playerid, LOADSCS[0]);
  99. SetTimerEx("LOADSCS2", 3000, false, "i", playerid);
  100. return 1;
  101. }
  102.  
  103. forward LOADSCS2(playerid);
  104.  
  105. public LOADSCS2(playerid)
  106. {
  107. TextDrawDestroy(LOADSCS[0]);
  108. TextDrawShowForPlayer(playerid, LOADSCS[2]);
  109. SetTimerEx("LOADSCS3", 3000, false, "i", playerid);
  110. return 1;
  111. }
  112.  
  113. forward LOADSCS3(playerid);
  114.  
  115. public LOADSCS3(playerid)
  116. {
  117. TextDrawDestroy(LOADSCS[2]);
  118. TextDrawShowForPlayer(playerid, LOADSCS[3]);
  119. SetTimerEx("LOADSCS4", 3000, false, "i", playerid);
  120. return 1;
  121. }
  122.  
  123. forward LOADSCS4(playerid);
  124.  
  125. public LOADSCS4(playerid)
  126. {
  127. TextDrawDestroy(LOADSCS[3]);
  128. TextDrawShowForPlayer(playerid, LOADSCS[4]);
  129. SetTimerEx("LOADSCS5", 3000, false, "i", playerid);
  130. return 1;
  131. }
  132.  
  133. forward LOADSCS5(playerid);
  134.  
  135. public LOADSCS5(playerid)
  136. {
  137. TextDrawDestroy(LOADSCS[4]);
  138. TextDrawShowForPlayer(playerid, LOADSCS[5]);
  139. SetTimerEx("LOADSCS6", 3000, false, "i", playerid);
  140. return 1;
  141. }
  142.  
  143. forward LOADSCS6(playerid);
  144.  
  145. public LOADSCS6(playerid)
  146. {
  147. TextDrawDestroy(LOADSCS[5]);
  148. TextDrawShowForPlayer(playerid, LOADSCS[6]);
  149. SetTimerEx("LOADSCS7", 3000, false, "i", playerid);
  150. return 1;
  151. }
  152.  
  153. forward LOADSCS7(playerid);
  154.  
  155. public LOADSCS7(playerid)
  156. {
  157. TextDrawDestroy(LOADSCS[6]);
  158. TextDrawShowForPlayer(playerid, LOADSCS[1]);
  159. SetTimerEx("LOADSCS8", 3000, false, "i", playerid);
  160. return 1;
  161. }
  162.  
  163. forward LOADSCS8(playerid);
  164.  
  165. public LOADSCS8(playerid)
  166. {
  167. TextDrawDestroy(LOADSCS[1]);
  168. TextDrawShowForPlayer(playerid, LOADSCS[8]);
  169. SetTimerEx("LOADSCS9", 3000, false, "i", playerid);
  170. return 1;
  171. }
  172.  
  173. forward LOADSCS9(playerid);
  174.  
  175. public LOADSCS9(playerid)
  176. {
  177. TextDrawDestroy(LOADSCS[8]);
  178. TextDrawShowForPlayer(playerid, LOADSCS[9]);
  179. SetTimerEx("LOADSCS10", 3000, false, "i", playerid);
  180. return 1;
  181. }
  182.  
  183. forward LOADSCS10(playerid);
  184.  
  185. public LOADSCS10(playerid)
  186. {
  187. TextDrawDestroy(LOADSCS[9]);
  188. TextDrawShowForPlayer(playerid, LOADSCS[10]);
  189. SetTimerEx("LOADSCS11", 3000, false, "i", playerid);
  190. return 1;
  191. }
  192.  
  193. forward LOADSCS11(playerid);
  194.  
  195. public LOADSCS11(playerid)
  196. {
  197. TextDrawDestroy(LOADSCS[10]);
  198. TextDrawShowForPlayer(playerid, LOADSCS[11]);
  199. SetTimerEx("LOADSCS12", 3000, false, "i", playerid);
  200. return 1;
  201. }
  202.  
  203. forward LOADSCS12(playerid);
  204.  
  205. public LOADSCS12(playerid)
  206. {
  207. TextDrawDestroy(LOADSCS[11]);
  208. TextDrawShowForPlayer(playerid, LOADSCS[12]);
  209. SetTimerEx("LOADSCS13", 3000, false, "i", playerid);
  210. return 1;
  211. }
  212.  
  213. forward LOADSCS13(playerid);
  214.  
  215. public LOADSCS13(playerid)
  216. {
  217. TextDrawDestroy(LOADSCS[12]);
  218. TextDrawShowForPlayer(playerid, LOADSCS[13]);
  219. SetTimerEx("LOADSCS14", 3000, false, "i", playerid);
  220. return 1;
  221. }
  222.  
  223. forward LOADSCS14(playerid);
  224.  
  225. public LOADSCS14(playerid)
  226. {
  227. StopAudioStreamForPlayer(playerid);
  228. TextDrawDestroy(LOADSCS[13]);
  229. TogglePlayerControllable(playerid, 1);
  230. SetPlayerHealth(playerid, 100);
  231. return 1;
  232. }
  233.  
  234. /////SAMP loading screen by UltraScripter////////////////////////////
Advertisement
Add Comment
Please, Sign In to add comment