Advertisement
Guest User

UPDATE

a guest
Dec 25th, 2017
125
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 24.88 KB | None | 0 0
  1. #include < a_samp >
  2. #include < zcmd >
  3.  
  4. #undef MAX_PLAYERS
  5. #define MAX_PLAYERS 50 // Prilagoditi
  6.  
  7. new PlayerText:GunTD[ MAX_PLAYERS ][ 15 ];
  8. new Stranica[ MAX_PLAYERS ];
  9.  
  10. public OnPlayerConnect(playerid)
  11. {
  12. GunTD[playerid][0] = CreatePlayerTextDraw(playerid, 200.058807, 153.250015, "LD_SPAC:white");
  13. PlayerTextDrawLetterSize(playerid, GunTD[playerid][0], 0.000000, 0.000000);
  14. PlayerTextDrawTextSize(playerid, GunTD[playerid][0], 238.000000, 128.000000);
  15. PlayerTextDrawAlignment(playerid, GunTD[playerid][0], 1);
  16. PlayerTextDrawColor(playerid, GunTD[playerid][0], -5963521);
  17. PlayerTextDrawSetShadow(playerid, GunTD[playerid][0], 0);
  18. PlayerTextDrawSetOutline(playerid, GunTD[playerid][0], 0);
  19. PlayerTextDrawBackgroundColor(playerid, GunTD[playerid][0], 255);
  20. PlayerTextDrawFont(playerid, GunTD[playerid][0], 4);
  21. PlayerTextDrawSetProportional(playerid, GunTD[playerid][0], 0);
  22. PlayerTextDrawSetShadow(playerid, GunTD[playerid][0], 0);
  23.  
  24. GunTD[playerid][1] = CreatePlayerTextDraw(playerid, 201.941131, 155.000000, "LD_SPAC:white");
  25. PlayerTextDrawLetterSize(playerid, GunTD[playerid][1], 0.000000, 0.000000);
  26. PlayerTextDrawTextSize(playerid, GunTD[playerid][1], 234.000000, 124.000000);
  27. PlayerTextDrawAlignment(playerid, GunTD[playerid][1], 1);
  28. PlayerTextDrawColor(playerid, GunTD[playerid][1], 255);
  29. PlayerTextDrawSetShadow(playerid, GunTD[playerid][1], 0);
  30. PlayerTextDrawSetOutline(playerid, GunTD[playerid][1], 0);
  31. PlayerTextDrawBackgroundColor(playerid, GunTD[playerid][1], 255);
  32. PlayerTextDrawFont(playerid, GunTD[playerid][1], 4);
  33. PlayerTextDrawSetProportional(playerid, GunTD[playerid][1], 0);
  34. PlayerTextDrawSetShadow(playerid, GunTD[playerid][1], 0);
  35.  
  36. GunTD[playerid][2] = CreatePlayerTextDraw(playerid, 249.941085, 148.583328, "ld_beat:chit");
  37. PlayerTextDrawLetterSize(playerid, GunTD[playerid][2], 0.000000, 0.000000);
  38. PlayerTextDrawTextSize(playerid, GunTD[playerid][2], 26.000000, 30.000000);
  39. PlayerTextDrawAlignment(playerid, GunTD[playerid][2], 1);
  40. PlayerTextDrawColor(playerid, GunTD[playerid][2], -5963521);
  41. PlayerTextDrawSetShadow(playerid, GunTD[playerid][2], 0);
  42. PlayerTextDrawSetOutline(playerid, GunTD[playerid][2], 0);
  43. PlayerTextDrawBackgroundColor(playerid, GunTD[playerid][2], 255);
  44. PlayerTextDrawFont(playerid, GunTD[playerid][2], 4);
  45. PlayerTextDrawSetProportional(playerid, GunTD[playerid][2], 0);
  46. PlayerTextDrawSetShadow(playerid, GunTD[playerid][2], 0);
  47.  
  48. GunTD[playerid][3] = CreatePlayerTextDraw(playerid, 201.470642, 154.416625, "LD_SPAC:white");
  49. PlayerTextDrawLetterSize(playerid, GunTD[playerid][3], 0.000000, 0.000000);
  50. PlayerTextDrawTextSize(playerid, GunTD[playerid][3], 62.000000, 19.000000);
  51. PlayerTextDrawAlignment(playerid, GunTD[playerid][3], 1);
  52. PlayerTextDrawColor(playerid, GunTD[playerid][3], -5963521);
  53. PlayerTextDrawSetShadow(playerid, GunTD[playerid][3], 0);
  54. PlayerTextDrawSetOutline(playerid, GunTD[playerid][3], 0);
  55. PlayerTextDrawBackgroundColor(playerid, GunTD[playerid][3], 255);
  56. PlayerTextDrawFont(playerid, GunTD[playerid][3], 4);
  57. PlayerTextDrawSetProportional(playerid, GunTD[playerid][3], 0);
  58. PlayerTextDrawSetShadow(playerid, GunTD[playerid][3], 0);
  59.  
  60. GunTD[playerid][4] = CreatePlayerTextDraw(playerid, 209.999984, 155.000015, "Deagle");
  61. PlayerTextDrawLetterSize(playerid, GunTD[playerid][4], 0.304941, 1.483333);
  62. PlayerTextDrawAlignment(playerid, GunTD[playerid][4], 1);
  63. PlayerTextDrawColor(playerid, GunTD[playerid][4], 255);
  64. PlayerTextDrawSetShadow(playerid, GunTD[playerid][4], 0);
  65. PlayerTextDrawSetOutline(playerid, GunTD[playerid][4], 0);
  66. PlayerTextDrawBackgroundColor(playerid, GunTD[playerid][4], 255);
  67. PlayerTextDrawFont(playerid, GunTD[playerid][4], 2);
  68. PlayerTextDrawSetProportional(playerid, GunTD[playerid][4], 1);
  69. PlayerTextDrawSetShadow(playerid, GunTD[playerid][4], 0);
  70.  
  71. GunTD[playerid][5] = CreatePlayerTextDraw(playerid, 364.294158, 147.999969, "ld_beat:chit");
  72. PlayerTextDrawLetterSize(playerid, GunTD[playerid][5], 0.000000, 0.000000);
  73. PlayerTextDrawTextSize(playerid, GunTD[playerid][5], 26.000000, 30.000000);
  74. PlayerTextDrawAlignment(playerid, GunTD[playerid][5], 1);
  75. PlayerTextDrawColor(playerid, GunTD[playerid][5], -5963521);
  76. PlayerTextDrawSetShadow(playerid, GunTD[playerid][5], 0);
  77. PlayerTextDrawSetOutline(playerid, GunTD[playerid][5], 0);
  78. PlayerTextDrawBackgroundColor(playerid, GunTD[playerid][5], 255);
  79. PlayerTextDrawFont(playerid, GunTD[playerid][5], 4);
  80. PlayerTextDrawSetProportional(playerid, GunTD[playerid][5], 0);
  81. PlayerTextDrawSetShadow(playerid, GunTD[playerid][5], 0);
  82.  
  83. GunTD[playerid][6] = CreatePlayerTextDraw(playerid, 375.588409, 153.833282, "LD_SPAC:white");
  84. PlayerTextDrawLetterSize(playerid, GunTD[playerid][6], 0.000000, 0.000000);
  85. PlayerTextDrawTextSize(playerid, GunTD[playerid][6], 62.000000, 19.000000);
  86. PlayerTextDrawAlignment(playerid, GunTD[playerid][6], 1);
  87. PlayerTextDrawColor(playerid, GunTD[playerid][6], -5963521);
  88. PlayerTextDrawSetShadow(playerid, GunTD[playerid][6], 0);
  89. PlayerTextDrawSetOutline(playerid, GunTD[playerid][6], 0);
  90. PlayerTextDrawBackgroundColor(playerid, GunTD[playerid][6], 255);
  91. PlayerTextDrawFont(playerid, GunTD[playerid][6], 4);
  92. PlayerTextDrawSetProportional(playerid, GunTD[playerid][6], 0);
  93. PlayerTextDrawSetShadow(playerid, GunTD[playerid][6], 0);
  94.  
  95. GunTD[playerid][7] = CreatePlayerTextDraw(playerid, 375.647125, 155.000015, "Cena:_5000$");
  96. PlayerTextDrawLetterSize(playerid, GunTD[playerid][7], 0.217411, 1.541666);
  97. PlayerTextDrawAlignment(playerid, GunTD[playerid][7], 1);
  98. PlayerTextDrawColor(playerid, GunTD[playerid][7], 255);
  99. PlayerTextDrawSetShadow(playerid, GunTD[playerid][7], 0);
  100. PlayerTextDrawSetOutline(playerid, GunTD[playerid][7], 0);
  101. PlayerTextDrawBackgroundColor(playerid, GunTD[playerid][7], 255);
  102. PlayerTextDrawFont(playerid, GunTD[playerid][7], 2);
  103. PlayerTextDrawSetProportional(playerid, GunTD[playerid][7], 1);
  104. PlayerTextDrawSetShadow(playerid, GunTD[playerid][7], 0);
  105.  
  106. GunTD[playerid][8] = CreatePlayerTextDraw(playerid, 219.823547, 139.833328, "");
  107. PlayerTextDrawLetterSize(playerid, GunTD[playerid][8], 0.000000, 0.000000);
  108. PlayerTextDrawTextSize(playerid, GunTD[playerid][8], 162.000000, 152.000000);
  109. PlayerTextDrawAlignment(playerid, GunTD[playerid][8], 1);
  110. PlayerTextDrawColor(playerid, GunTD[playerid][8], -1);
  111. PlayerTextDrawSetShadow(playerid, GunTD[playerid][8], 0);
  112. PlayerTextDrawSetOutline(playerid, GunTD[playerid][8], 0);
  113. PlayerTextDrawBackgroundColor(playerid, GunTD[playerid][8], 1090519040);
  114. PlayerTextDrawFont(playerid, GunTD[playerid][8], 5);
  115. PlayerTextDrawSetProportional(playerid, GunTD[playerid][8], 0);
  116. PlayerTextDrawSetShadow(playerid, GunTD[playerid][8], 0);
  117. PlayerTextDrawSetPreviewModel(playerid, GunTD[playerid][8], 355);
  118. PlayerTextDrawSetPreviewRot(playerid, GunTD[playerid][8], 0.000000, 0.000000, 180.000000, 3.000000);
  119.  
  120. GunTD[playerid][9] = CreatePlayerTextDraw(playerid, 236.764755, 206.916595, "ld_beat:left");
  121. PlayerTextDrawLetterSize(playerid, GunTD[playerid][9], 0.000000, 0.000000);
  122. PlayerTextDrawTextSize(playerid, GunTD[playerid][9], 18.000000, 13.000000);
  123. PlayerTextDrawAlignment(playerid, GunTD[playerid][9], 1);
  124. PlayerTextDrawColor(playerid, GunTD[playerid][9], -5963521);
  125. PlayerTextDrawSetShadow(playerid, GunTD[playerid][9], 0);
  126. PlayerTextDrawSetOutline(playerid, GunTD[playerid][9], 0);
  127. PlayerTextDrawBackgroundColor(playerid, GunTD[playerid][9], 255);
  128. PlayerTextDrawFont(playerid, GunTD[playerid][9], 4);
  129. PlayerTextDrawSetProportional(playerid, GunTD[playerid][9], 0);
  130. PlayerTextDrawSetShadow(playerid, GunTD[playerid][9], 0);
  131. PlayerTextDrawSetSelectable(playerid, GunTD[playerid][9], true);
  132.  
  133. GunTD[playerid][10] = CreatePlayerTextDraw(playerid, 382.646972, 206.916610, "ld_beat:right");
  134. PlayerTextDrawLetterSize(playerid, GunTD[playerid][10], 0.000000, 0.000000);
  135. PlayerTextDrawTextSize(playerid, GunTD[playerid][10], 18.000000, 13.000000);
  136. PlayerTextDrawAlignment(playerid, GunTD[playerid][10], 1);
  137. PlayerTextDrawColor(playerid, GunTD[playerid][10], -5963521);
  138. PlayerTextDrawSetShadow(playerid, GunTD[playerid][10], 0);
  139. PlayerTextDrawSetOutline(playerid, GunTD[playerid][10], 0);
  140. PlayerTextDrawBackgroundColor(playerid, GunTD[playerid][10], 255);
  141. PlayerTextDrawFont(playerid, GunTD[playerid][10], 4);
  142. PlayerTextDrawSetProportional(playerid, GunTD[playerid][10], 0);
  143. PlayerTextDrawSetShadow(playerid, GunTD[playerid][10], 0);
  144. PlayerTextDrawSetSelectable(playerid, GunTD[playerid][10], true);
  145.  
  146. GunTD[playerid][11] = CreatePlayerTextDraw(playerid, 262.647125, 255.916641, "ld_beat:chit");
  147. PlayerTextDrawLetterSize(playerid, GunTD[playerid][11], 0.000000, 0.000000);
  148. PlayerTextDrawTextSize(playerid, GunTD[playerid][11], 26.000000, 30.000000);
  149. PlayerTextDrawAlignment(playerid, GunTD[playerid][11], 1);
  150. PlayerTextDrawColor(playerid, GunTD[playerid][11], -5963521);
  151. PlayerTextDrawSetShadow(playerid, GunTD[playerid][11], 0);
  152. PlayerTextDrawSetOutline(playerid, GunTD[playerid][11], 0);
  153. PlayerTextDrawBackgroundColor(playerid, GunTD[playerid][11], 255);
  154. PlayerTextDrawFont(playerid, GunTD[playerid][11], 4);
  155. PlayerTextDrawSetProportional(playerid, GunTD[playerid][11], 0);
  156. PlayerTextDrawSetShadow(playerid, GunTD[playerid][11], 0);
  157.  
  158. GunTD[playerid][12] = CreatePlayerTextDraw(playerid, 343.588104, 255.916641, "ld_beat:chit");
  159. PlayerTextDrawLetterSize(playerid, GunTD[playerid][12], 0.000000, 0.000000);
  160. PlayerTextDrawTextSize(playerid, GunTD[playerid][12], 26.000000, 30.000000);
  161. PlayerTextDrawAlignment(playerid, GunTD[playerid][12], 1);
  162. PlayerTextDrawColor(playerid, GunTD[playerid][12], -5963521);
  163. PlayerTextDrawSetShadow(playerid, GunTD[playerid][12], 0);
  164. PlayerTextDrawSetOutline(playerid, GunTD[playerid][12], 0);
  165. PlayerTextDrawBackgroundColor(playerid, GunTD[playerid][12], 255);
  166. PlayerTextDrawFont(playerid, GunTD[playerid][12], 4);
  167. PlayerTextDrawSetProportional(playerid, GunTD[playerid][12], 0);
  168. PlayerTextDrawSetShadow(playerid, GunTD[playerid][12], 0);
  169.  
  170. GunTD[playerid][13] = CreatePlayerTextDraw(playerid, 274.411804, 261.166625, "LD_SPAC:white");
  171. PlayerTextDrawLetterSize(playerid, GunTD[playerid][13], 0.000000, 0.000000);
  172. PlayerTextDrawTextSize(playerid, GunTD[playerid][13], 83.000000, 19.000000);
  173. PlayerTextDrawAlignment(playerid, GunTD[playerid][13], 1);
  174. PlayerTextDrawColor(playerid, GunTD[playerid][13], -5963521);
  175. PlayerTextDrawSetShadow(playerid, GunTD[playerid][13], 0);
  176. PlayerTextDrawSetOutline(playerid, GunTD[playerid][13], 0);
  177. PlayerTextDrawBackgroundColor(playerid, GunTD[playerid][13], 255);
  178. PlayerTextDrawFont(playerid, GunTD[playerid][13], 4);
  179. PlayerTextDrawSetProportional(playerid, GunTD[playerid][13], 0);
  180. PlayerTextDrawSetShadow(playerid, GunTD[playerid][13], 0);
  181. PlayerTextDrawSetSelectable(playerid, GunTD[playerid][13], true);
  182.  
  183. GunTD[playerid][14] = CreatePlayerTextDraw(playerid, 287.646881, 263.500030, "]_KUPI_]");
  184. PlayerTextDrawLetterSize(playerid, GunTD[playerid][14], 0.304941, 1.483333);
  185. PlayerTextDrawAlignment(playerid, GunTD[playerid][14], 1);
  186. PlayerTextDrawColor(playerid, GunTD[playerid][14], 255);
  187. PlayerTextDrawSetShadow(playerid, GunTD[playerid][14], 0);
  188. PlayerTextDrawSetOutline(playerid, GunTD[playerid][14], 0);
  189. PlayerTextDrawBackgroundColor(playerid, GunTD[playerid][14], 255);
  190. PlayerTextDrawFont(playerid, GunTD[playerid][14], 2);
  191. PlayerTextDrawSetProportional(playerid, GunTD[playerid][14], 1);
  192. PlayerTextDrawSetShadow(playerid, GunTD[playerid][14], 0);
  193.  
  194. return 1;
  195. }
  196. public OnPlayerClickPlayerTextDraw(playerid, PlayerText:playertextid)
  197. {
  198. if(playertextid == GunTD[ playerid ][ 9 ])
  199. {
  200. if(Stranica[ playerid ] == 1)
  201. {
  202. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  203. Stranica[ playerid ] = 10;
  204. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 373);
  205. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  206. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "Armour");
  207. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_7000$");
  208. }
  209. else if(Stranica[ playerid ] == 2)
  210. {
  211. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  212. Stranica[ playerid ] = 1;
  213. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 348);
  214. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  215. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "Deagle");
  216. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_4000$");
  217. }
  218. else if(Stranica[ playerid ] == 3)
  219. {
  220. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  221. Stranica[ playerid ] = 2;
  222. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 346);
  223. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  224. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "9mm");
  225. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_2500$");
  226. }
  227. else if(Stranica[ playerid ] == 4)
  228. {
  229. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  230. Stranica[ playerid ] = 3;
  231. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 355);
  232. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  233. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "AK-47");
  234. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_5000$");
  235. }
  236. else if(Stranica[ playerid ] == 5)
  237. {
  238. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  239. Stranica[ playerid ] = 4;
  240. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 356);
  241. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  242. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "M4");
  243. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_5000$");
  244. }
  245. else if(Stranica[ playerid ] == 6)
  246. {
  247. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  248. Stranica[ playerid ] = 5;
  249. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 353);
  250. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  251. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "M5");
  252. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_4500$");
  253. }
  254. else if(Stranica[ playerid ] == 7)
  255. {
  256. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  257. Stranica[ playerid ] = 6;
  258. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 352);
  259. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  260. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "Uzi");
  261. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_4000$");
  262. }
  263. else if(Stranica[ playerid ] == 8)
  264. {
  265. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  266. Stranica[ playerid ] = 7;
  267. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 372);
  268. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  269. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "Tec-9");
  270. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_4000$");
  271. }
  272. else if(Stranica[ playerid ] == 9)
  273. {
  274. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  275. Stranica[ playerid ] = 8;
  276. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 349);
  277. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  278. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "Shotgun");
  279. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_5000$");
  280. }
  281. else if(Stranica[ playerid ] == 10)
  282. {
  283. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  284. Stranica[ playerid ] = 9;
  285. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 358);
  286. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  287. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "Sniper");
  288. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_8500$");
  289. }
  290. }
  291. else if(playertextid == GunTD[ playerid ][ 10 ])
  292. {
  293. if(Stranica[ playerid ] == 1)
  294. {
  295. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  296. Stranica[ playerid ] = 2;
  297. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 346);
  298. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  299. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "9mm");
  300. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_2500$");
  301. }
  302. else if(Stranica[ playerid ] == 2)
  303. {
  304. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  305. Stranica[ playerid ] = 3;
  306. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 355);
  307. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  308. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "AK-47");
  309. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_5000$");
  310. }
  311. else if(Stranica[ playerid ] == 3)
  312. {
  313. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  314. Stranica[ playerid ] = 4;
  315. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 356);
  316. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  317. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "M4");
  318. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_5000$");
  319. }
  320. else if(Stranica[ playerid ] == 4)
  321. {
  322. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  323. Stranica[ playerid ] = 5;
  324. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 353);
  325. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  326. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "M5");
  327. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_4500$");
  328. }
  329. else if(Stranica[ playerid ] == 5)
  330. {
  331. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  332. Stranica[ playerid ] = 6;
  333. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 352);
  334. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  335. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "Uzi");
  336. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_4000$");
  337. }
  338. else if(Stranica[ playerid ] == 6)
  339. {
  340. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  341. Stranica[ playerid ] = 7;
  342. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 372);
  343. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  344. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "Tec-9");
  345. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_4000$");
  346. }
  347. else if(Stranica[ playerid ] == 7)
  348. {
  349. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  350. Stranica[ playerid ] = 8;
  351. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 349);
  352. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  353. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "Shotgun");
  354. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_5000$");
  355. }
  356. else if(Stranica[ playerid ] == 8)
  357. {
  358. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  359. Stranica[ playerid ] = 9;
  360. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 358);
  361. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  362. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "Sniper");
  363. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_8500$");
  364. }
  365. else if(Stranica[ playerid ] == 9)
  366. {
  367. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  368. Stranica[ playerid ] = 10;
  369. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 373);
  370. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  371. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "Armour");
  372. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_7000$");
  373. }
  374. else if(Stranica[ playerid ] == 10)
  375. {
  376. PlayerTextDrawHide(playerid, GunTD[ playerid ][ 8 ]);
  377. Stranica[ playerid ] = 1;
  378. PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 348);
  379. PlayerTextDrawShow(playerid, GunTD[ playerid ][ 8 ]);
  380. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "Deagle");
  381. PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "Cena:_4000$");
  382. }
  383. }
  384. else if(playertextid == GunTD[ playerid ][ 13 ])
  385. {
  386. if(Stranica[ playerid ] == 1)
  387. {
  388. for(new i; i < 15; i++) { PlayerTextDrawHide(playerid, GunTD[ playerid ][ i ]); Stranica[ playerid ] = 0; CancelSelectTextDraw(playerid); }
  389. if(GetPlayerMoney(playerid) < 4000) return SendClientMessage(playerid, -1, "Nemate dovoljno novca.");
  390. GivePlayerMoney(playerid, -4000);
  391. GivePlayerWeapon(playerid, 24, 100);
  392. SendClientMessage(playerid, -1, "Uspesno ste kupili Deagle za 4000$ ( 100 metkova ).");
  393. }
  394. else if(Stranica[ playerid ] == 2)
  395. {
  396. for(new i; i < 15; i++) { PlayerTextDrawHide(playerid, GunTD[ playerid ][ i ]); Stranica[ playerid ] = 0; CancelSelectTextDraw(playerid); }
  397. if(GetPlayerMoney(playerid) < 2500) return SendClientMessage(playerid, -1, "Nemate dovoljno novca.");
  398. GivePlayerMoney(playerid, -2500);
  399. GivePlayerWeapon(playerid, 22, 100);
  400. SendClientMessage(playerid, -1, "Uspesno ste kupili 9mm za 2500$ ( 100 metkova ).");
  401. }
  402. else if(Stranica[ playerid ] == 3)
  403. {
  404. for(new i; i < 15; i++) { PlayerTextDrawHide(playerid, GunTD[ playerid ][ i ]); Stranica[ playerid ] = 0; CancelSelectTextDraw(playerid); }
  405. if(GetPlayerMoney(playerid) < 5000) return SendClientMessage(playerid, -1, "Nemate dovoljno novca.");
  406. GivePlayerMoney(playerid, -5000);
  407. GivePlayerWeapon(playerid, 30, 150);
  408. SendClientMessage(playerid, -1, "Uspesno ste kupili AK-47 za 5000$ ( 150 metkova ).");
  409. }
  410. else if(Stranica[ playerid ] == 4)
  411. {
  412. for(new i; i < 15; i++) { PlayerTextDrawHide(playerid, GunTD[ playerid ][ i ]); Stranica[ playerid ] = 0; CancelSelectTextDraw(playerid); }
  413. if(GetPlayerMoney(playerid) < 5000) return SendClientMessage(playerid, -1, "Nemate dovoljno novca.");
  414. GivePlayerMoney(playerid, -5000);
  415. GivePlayerWeapon(playerid, 31, 150);
  416. SendClientMessage(playerid, -1, "Uspesno ste kupili M4 za 5000$ ( 150 metkova ).");
  417. }
  418. else if(Stranica[ playerid ] == 5)
  419. {
  420. for(new i; i < 15; i++) { PlayerTextDrawHide(playerid, GunTD[ playerid ][ i ]); Stranica[ playerid ] = 0; CancelSelectTextDraw(playerid); }
  421. if(GetPlayerMoney(playerid) < 4500) return SendClientMessage(playerid, -1, "Nemate dovoljno novca.");
  422. GivePlayerMoney(playerid, -4500);
  423. GivePlayerWeapon(playerid, 29, 150);
  424. SendClientMessage(playerid, -1, "Uspesno ste kupili M5 za 4500$ ( 150 metkova ).");
  425. }
  426. else if(Stranica[ playerid ] == 6)
  427. {
  428. for(new i; i < 15; i++) { PlayerTextDrawHide(playerid, GunTD[ playerid ][ i ]); Stranica[ playerid ] = 0; CancelSelectTextDraw(playerid); }
  429. if(GetPlayerMoney(playerid) < 4000) return SendClientMessage(playerid, -1, "Nemate dovoljno novca.");
  430. GivePlayerMoney(playerid, -4000);
  431. GivePlayerWeapon(playerid, 28, 150);
  432. SendClientMessage(playerid, -1, "Uspesno ste kupili Uzi za 4000$ ( 150 metkova ).");
  433. }
  434. else if(Stranica[ playerid ] == 7)
  435. {
  436. for(new i; i < 15; i++) { PlayerTextDrawHide(playerid, GunTD[ playerid ][ i ]); Stranica[ playerid ] = 0; CancelSelectTextDraw(playerid); }
  437. if(GetPlayerMoney(playerid) < 4000) return SendClientMessage(playerid, -1, "Nemate dovoljno novca.");
  438. GivePlayerMoney(playerid, -4000);
  439. GivePlayerWeapon(playerid, 32, 150);
  440. SendClientMessage(playerid, -1, "Uspesno ste kupili Tec-9 za 4000$ ( 150 metkova ).");
  441. }
  442. else if(Stranica[ playerid ] == 8)
  443. {
  444. for(new i; i < 15; i++) { PlayerTextDrawHide(playerid, GunTD[ playerid ][ i ]); Stranica[ playerid ] = 0; CancelSelectTextDraw(playerid); }
  445. if(GetPlayerMoney(playerid) < 5000) return SendClientMessage(playerid, -1, "Nemate dovoljno novca.");
  446. GivePlayerMoney(playerid, -5000);
  447. GivePlayerWeapon(playerid, 25, 50);
  448. SendClientMessage(playerid, -1, "Uspesno ste kupili Shotgun za 5000$ ( 50 metkova ).");
  449. }
  450. else if(Stranica[ playerid ] == 9)
  451. {
  452. for(new i; i < 15; i++) { PlayerTextDrawHide(playerid, GunTD[ playerid ][ i ]); Stranica[ playerid ] = 0; CancelSelectTextDraw(playerid); }
  453. if(GetPlayerMoney(playerid) < 8500) return SendClientMessage(playerid, -1, "Nemate dovoljno novca.");
  454. GivePlayerMoney(playerid, -8500);
  455. GivePlayerWeapon(playerid, 34, 30);
  456. SendClientMessage(playerid, -1, "Uspesno ste kupili Sniper za 8500$ ( 30 metkova ).");
  457. }
  458. else if(Stranica[ playerid ] == 10)
  459. {
  460. for(new i; i < 15; i++) { PlayerTextDrawHide(playerid, GunTD[ playerid ][ i ]); Stranica[ playerid ] = 0; CancelSelectTextDraw(playerid); }
  461. if(GetPlayerMoney(playerid) < 7000) return SendClientMessage(playerid, -1, "Nemate dovoljno novca.");
  462. GivePlayerMoney(playerid, -7000);
  463. SetPlayerArmour(playerid, 100);
  464. SendClientMessage(playerid, -1, "Uspesno ste kupili Armour za 7000$");
  465. }
  466. }
  467. return 1;
  468. }
  469.  
  470. CMD:kupigun(playerid, params[])
  471. {
  472. if(Stranica[ playerid ] > 0) { for(new i; i < 15; i++) { PlayerTextDrawHide(playerid, GunTD[ playerid ][ i ]); Stranica[ playerid ] = 0; CancelSelectTextDraw(playerid); } }
  473. else { for(new i; i < 15; i++) { PlayerTextDrawSetPreviewModel(playerid, GunTD[ playerid ][ 8 ], 348); PlayerTextDrawShow(playerid, GunTD[ playerid ][ i ]); Stranica[ playerid ] = 1; SelectTextDraw(playerid, 0xFFA500FF); PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 4 ], "Deagle"); PlayerTextDrawSetString(playerid, GunTD[ playerid ][ 7 ], "4000$"); } }
  474. return 1;
  475. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement