Advertisement
Guest User

Untitled

a guest
Feb 16th, 2014
104
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 131.19 KB | None | 0 0
  1. ////////////////////////////////////ZABAWY//////////////////////////////////////
  2. #include <a_samp>
  3. #include <zcmd>
  4. #include <Dini>
  5. #include <foreach>
  6.  
  7. new bool:SianoMen[MAX_PLAYERS];
  8. new bool:SianoZaglosowal[MAX_PLAYERS];
  9. new bool:SianoON;
  10. new bool:SianoStartON;
  11. new SianoTimer;
  12. new Text:event22;
  13. new Text:event11;
  14.  
  15. #define LICZBA_CH 4
  16. #define LICZBA_RC 2
  17. #define LICZBA_WG 4
  18. #define LICZBA_CTF 4
  19. #define LICZBA_LB 4
  20. #define LICZBA_ST 4
  21. #define LICZBA_DB 2
  22. #define LICZBA_SS 2
  23. #define LICZBA_SN 2
  24. #define LICZBA_PB 2
  25. #define LICZBA_TR 2
  26. #define LICZBA_HAY 2
  27. #define LICZBA_SM 2
  28. #define LICZBA_CW 2
  29. #define LICZBA_US 2
  30. #define MAX_RACE_CHECK 50
  31. #define C_ZIELONY "{00A600}"
  32. #define Zielony 0x3C9605FF
  33. #define zielony "{69E91D}"
  34. #define C_INFO 0xEAB171FF
  35. #define C_TD 0x006dd6FF
  36. #define POL_ZOLTY 0xF5DC0BFF
  37. #define POL_NIEBIESKI 0x209CF2FF
  38. #define COLOR_LIGHTYELLOW 0xFAEAA9FF
  39. #define COLOR_LIGHTORANGE 0xF7A26FFF
  40. #define COLOR_VIOLET 0x9955DEEE
  41. #define COLOR_LIGHTRED 0xFF99AADD
  42. #define COLOR_SEAGREEN
  43. #define COLOR_BROWN 0x8F4747FF
  44. #define C_RED2 0x8F4747FF
  45. #define COLOR_KREM 0xFF8080FF
  46. #define COLOR_GRAYWHITE 0xEEEEFFC4
  47. #define COLOR_LIGHTNEUTRALBLUE 0xabcdef66
  48. #define COLOR_GREENISHGOLD 0xDEAD4370
  49. #define COLOR_LIGHTBLUEGREEN 0x0FFDD349
  50. #define COLOR_NEUTRALBLUE 0xABCDEF01
  51. #define COLOR_LIGHTCYAN 0xAAFFCC33
  52. #define COLOR_LEMON 0xDDDD2357
  53. #define COLOR_MEDIUMBLUE 0x63AFF00A
  54. #define COLOR_LIGHT_ORANGE 0xFF9900AA
  55. #define COLOR_NEUTRAL 0xABCDEF97
  56. #define COLOR_BLACK 0x00000000
  57. #define COLOR_NEUTRALGREEN 0x81CFAB00
  58. #define COLOR_DARKGREEN 0x12900BBF
  59. #define COLOR_LIGHTGREEN 0x24FF0AB9
  60. #define COLOR_DARKBLUE 0x300FFAAB
  61. #define COLOR_BLUEGREEN 0x46BBAA00
  62. #define COLOR_PINK 0xFF66FFAA
  63. #define COLOR_BLUE 0x0000BBAA
  64. #define COLOR_LIGHTBLUE 0x33CCFFAA
  65. #define COLOR_GRAD1 0xB4B5B7FF
  66. #define COLOR_DARKRED 0x660000AA
  67. #define COLOR_ORANGE 0xFF9900AA
  68. #define COLOR_GREY 0xAFAFAFAA
  69. #define COLOR_GREEN 0x33AA33AA
  70. #define COLOR_RED 0xAA3333AA
  71. #define COLOR_YELLOW 0xFFFF00AA
  72. #define COLOR_WHITE 0xFFFFFFAA
  73. #define COLOR_ADMIN 0xFF0000AA
  74. #define COLOR_KOMENDA 0xC83322FF
  75. #define COLOR_BLOOD 0xE60005FF
  76. #define COLOR_BGREEN 0x08FD04FF
  77. #define COLOR_YELLOW2 0xF5DEB3AA
  78. #define COLOR_RED2 0xFF0000FF
  79. #define COLOR_BLUE2 0x0000A0FF
  80. #define COLOR_LIST 0xC7C7C7FF
  81. #define COLOR_ANIM 0x8000FFFF
  82. #define COLOR_VIP 0xE9E312FF
  83. //kolory do gui
  84. #define C_GREEN "{6EF83C}"
  85. #define C_BLUE "{0000FF}"
  86. #define C_RED "{FF0000}"
  87. #define C_WHITE "{FFFFFF}"
  88. #define C_BLUE2 "{3D51DA}"
  89. #define C_YELLOW ""
  90. #define C_GREEN2 "{00FF00}"
  91. #define C_ZIELONY "{00A600}"
  92. #define VEHICLE_CONTROL_DIALOG 39
  93. #define AUTO_REOPEN_DIALOG
  94. #define PRIZE_MONEY 10000
  95. #define LIME 0x88AA62FF
  96. #define WHITE 0xFFFFFFAA
  97. #define RULE 0xFBDF89AA
  98. #define ORANGE 0xDB881AAA
  99. #define COL_LIME \
  100. "{88AA62}"
  101. #define COL_WHITE \
  102. "{FFFFFF}"
  103. #define COL_RULE \
  104. "{FBDF89}"
  105. #define COL_ORANGE \
  106. "{DB881A}"
  107.  
  108. new bool:PaintbMen[MAX_PLAYERS];
  109. new bool:PaintbZaglosowal[MAX_PLAYERS];
  110. new bool:PaintbON;
  111. new bool:PaintbStartON;
  112. new Float:PaintbSpawn[17][3] = {
  113. {885.64227294922,2262.5041503906,10.8203125},
  114. {858.53332519531,2260.9731445313,10.8203125},
  115. {846.79254150391,2219.9660644531,11.3085689},
  116. {832.21008300781,2224.9645996094,10.6599082},
  117. {847.60260009766,2278.6362304688,10.8203125},
  118. {855.65753173828,2245.0827636719,10.8203125},
  119. {865.6669921875,2255.6584472656,11.30110933},
  120. {840.81787109375,2261.4084472656,11.3011093},
  121. {876.60119628906,2221.4406738281,11.3011093},
  122. {886.18725585938,2233.6752929688,10.8203125},
  123. {875.96441650391,2255.3081054688,11.3011031},
  124. {824.82867431641,2260.0739746094,10.8260832},
  125. {854.61932373047,2242.3735351563,10.8203125},
  126. {875.47369384766,2271.9409179688,10.8203125},
  127. {854.46929931641,2224.109375,10.82031345374},
  128. {889.22772216797,2248.2478027344,10.8203125},
  129. {860.29180908203,2213.4450683594,10.8203134}
  130. };
  131. new bool:TowerMen[MAX_PLAYERS];
  132. new bool:TowerZaglosowal[MAX_PLAYERS];
  133. new bool:TowerON;
  134. new bool:TowerStartON;
  135. new bool:HayMen[MAX_PLAYERS];
  136. new bool:HayZaglosowal[MAX_PLAYERS];
  137. new bool:HayON;
  138. new bool:HayStartON;
  139. new HayTimer;
  140. new bool:ColorwMen[MAX_PLAYERS];
  141. new bool:ColorwZaglosowal[MAX_PLAYERS];
  142. new bool:ColorwON;
  143. new bool:ColorwStartON;
  144. new Float:ColorwSpawn[17][3] = {
  145. {885.64227294922,2262.5041503906,10.8203125},
  146. {858.53332519531,2260.9731445313,10.8203125},
  147. {846.79254150391,2219.9660644531,11.3085689},
  148. {832.21008300781,2224.9645996094,10.6599082},
  149. {847.60260009766,2278.6362304688,10.8203125},
  150. {855.65753173828,2245.0827636719,10.8203125},
  151. {865.6669921875,2255.6584472656,11.30110933},
  152. {840.81787109375,2261.4084472656,11.3011093},
  153. {876.60119628906,2221.4406738281,11.3011093},
  154. {886.18725585938,2233.6752929688,10.8203125},
  155. {875.96441650391,2255.3081054688,11.3011031},
  156. {824.82867431641,2260.0739746094,10.8260832},
  157. {854.61932373047,2242.3735351563,10.8203125},
  158. {875.47369384766,2271.9409179688,10.8203125},
  159. {854.46929931641,2224.109375,10.82031345374},
  160. {889.22772216797,2248.2478027344,10.8203125},
  161. {860.29180908203,2213.4450683594,10.8203134}
  162. };
  163. new DerbyCar[16];
  164. new bool:DerbyMen[MAX_PLAYERS];
  165. new bool:DerbyZaglosowal[MAX_PLAYERS];
  166. new bool:DerbyON;
  167. new bool:DerbyStartON;
  168. new bool:DerbyLoad;
  169. new DragTime[MAX_PLAYERS];
  170. new bool:Strzelnica[MAX_PLAYERS];
  171. new bool:StrzelnicaSniper[MAX_PLAYERS];
  172. new bool:StrzelnicaON;
  173. new bool:StrzelnicaZaglosowal[MAX_PLAYERS];
  174. new bool:StrzelnicaStartON;
  175. new bool:Skoczek[MAX_PLAYERS];
  176. new bool:SkoczekZaglosowa[MAX_PLAYERS];
  177. new bool:SkokiStartON = false;
  178. new bool:Labirynt[MAX_PLAYERS];
  179. new bool:LabiryntZaglosowal[MAX_PLAYERS];
  180. new bool:LabStartON = false;
  181. new bool:LabON = false;
  182. new LabTimer;
  183. new Text:ChowanyTD[2];
  184. new Text:ChowanyBack;
  185. new Float:CarSpawnX[10];
  186. new Float:CarSpawnY[10];
  187. new Float:CarSpawnZ[10];
  188.  
  189. new CarModel;
  190. new Interior;
  191. new CPSize;
  192. new CPliczba;
  193. new Float:CPx[MAX_RACE_CHECK];
  194. new Float:CPy[MAX_RACE_CHECK];
  195. new Float:CPz[MAX_RACE_CHECK];
  196. new bool:RaceMen[MAX_PLAYERS];
  197. new RaceMenLiczba = 0;
  198. new Float:SpawnAngle;
  199. new Car[10];
  200. new RaceCheck[MAX_PLAYERS];
  201. new MiejsceMeta = 0;
  202. new bool:RaceWystartowal;
  203. new CountLicz = 3;
  204. new PlayerCarNum = 0;
  205. new Pozycja[MAX_RACE_CHECK];
  206. new ActualPos[MAX_PLAYERS];
  207. new CPType;
  208. new RaceNitro;
  209. new RaceTimer;
  210. new RaceStartTimer;
  211. new RaceID;
  212. new RaceOnFoot;
  213. new bool:ChowanyZapisany[MAX_PLAYERS];
  214. new bool:ChowanyChceTD[MAX_PLAYERS];
  215. new bool:Chowany[MAX_PLAYERS];
  216. new bool:Szukajacy[MAX_PLAYERS];
  217. new ChowanyKandydat[50];
  218. new bool:ChStarted = false;
  219. new ChLiczba;
  220. new SzLiczba;
  221. new ChEndTimer;
  222. new Chtimercount;
  223. new Chtimerszuk;
  224. new ChCountLiczba;
  225. new AwayCount[MAX_PLAYERS];
  226. new bool:ChWystartowala;
  227. new ChArena;
  228. new ChNum;
  229. new Float:ChowPosX;
  230. new Float:ChowPosY;
  231. new Float:ChowPosZ;
  232. new Float:SzukPosX;
  233. new Float:SzukPosY;
  234. new Float:SzukPosZ;
  235. new Float:ChAreaX;
  236. new Float:ChAreaY;
  237. new Float:ChAreaZ;
  238. new Float:ChAreaA;
  239. new ChInt;
  240.  
  241. new Count2 = 0;
  242. new CountDowning = 0;
  243. new bool:WGStarted;
  244. new ArenaZone;
  245. new WGTimer;
  246. new bool:WGKandydat[MAX_PLAYERS];
  247. new WGTeam[MAX_PLAYERS];
  248. new WGLiczba;
  249. new bool:WGON;
  250. new bool:WGGlos[MAX_PLAYERS];
  251. new WGTeamLiczba[3];
  252. new Float:WGAreaX,Float:WGAreaY,Float:WGAreaZ,Float:WGAreaA;
  253. new InteriorWG;
  254. new WGAwayCount[MAX_PLAYERS];
  255.  
  256. new CTFTimer;
  257. new bool:CTFKandydat[MAX_PLAYERS];
  258. new CTFTeam[MAX_PLAYERS];
  259. new CTFLiczba;
  260. new CTFON;
  261. new bool:CTFGlos[MAX_PLAYERS];
  262. new CTFTeamLiczba[2];
  263. new FlageMa = -1;
  264. new CTFScore[2];
  265. new flaga;
  266. new Text:CTFtd;
  267. new Float:CTFFlagPos[3];
  268. new Float:CTFSpawnPos[2][3];
  269. new CTFInterior;
  270. new Float:SkokiSpawn[9][3] = {
  271. {2140.6675,993.1867,1596.9131},
  272. {-853.6121,1987.3927,1554.2291},
  273. {-2308.0127,-1652.3405,1332.5613},
  274. {-1802.6826,738.5115,1524.7009},
  275. {-681.6522,-2136.8035,1508.1331},
  276. {2019.6737,-155.8575,1477.2969},
  277. {1544.9108,-1351.4625,735.3508},
  278. {367.6675,-1897.8132,1492.6903},
  279. {-2899.8555,2880.6531,685.1454}
  280. };
  281.  
  282. new Float:LabiryntSpawn[6][3] = {
  283. {1536.1250,-1565.1254,23.5469},
  284. {1514.1735,-1533.9346,23.5481},
  285. {1504.2450,-1526.6760,23.5481},
  286. {1484.5762,-1543.8284,23.5481},
  287. {1477.4609,-1536.6530,23.5481},
  288. {1479.9331,-1518.8024,23.5481}
  289. };
  290.  
  291. forward AtrakcjeCheck();
  292. public AtrakcjeCheck()
  293. {
  294. WGEndCheck();
  295. WGPlayerCheck();
  296. ChowanyCheck();
  297. ChowanyAreaCheck();
  298. DerbyCheck();
  299. SianoCheck();
  300. HayCheck();
  301. ColorwCheck();
  302. PaintbCheck();
  303. StrzelnicaCheck();
  304. TowerCheck();
  305. CTFUpdate();
  306. return 1;
  307. }
  308.  
  309. forward ZapisyUpdate();
  310. public ZapisyUpdate()
  311. {
  312.  
  313. new str[13][17];
  314. new strr[13][11];
  315.  
  316. new Liczba[13];
  317.  
  318. Liczba[0] = WGLiczba;
  319. Liczba[1] = CTFLiczba;
  320. Liczba[4] = RaceMenLiczba;
  321. Liczba[6] = ChNum;
  322.  
  323. for(new x=0;x<MAX_PLAYERS;x++){
  324. if(IsPlayerConnected(x)){
  325.  
  326. if(PaintbMen[x]){
  327. Liczba[1] ++;
  328. }
  329.  
  330. if(DerbyMen[x]){
  331. Liczba[2] ++;
  332. }
  333.  
  334. if(Skoczek[x]){
  335. Liczba[3] ++;
  336. }
  337.  
  338. if(SianoMen[x]){
  339. Liczba[8] ++;
  340. }
  341.  
  342. if(Strzelnica[x]){
  343. Liczba[5] ++;
  344. }
  345.  
  346. if(Labirynt[x]){
  347. Liczba[7] ++;
  348. }
  349.  
  350. if(TowerMen[x]){
  351. Liczba[9] ++;
  352. }
  353.  
  354. if(ColorwMen[x]){
  355. Liczba[10] ++;
  356. }
  357.  
  358.  
  359. if(HayMen[x]){
  360. Liczba[11] ++;
  361. }
  362.  
  363.  
  364.  
  365. }
  366. }
  367.  
  368.  
  369. if(Liczba[0] < LICZBA_WG){
  370. format(str[0],16,"WG:");
  371. format(strr[0],10,"~w~%d/%d",Liczba[0],LICZBA_WG);
  372. }else{
  373. format(str[0],16,"WG:");
  374. format(strr[0],10,"~y~%d",Liczba[0]);
  375. }
  376. if(WGON){
  377. format(str[0],16,"WG:");
  378. format(strr[0],10,"~r~~h~Trwa");
  379. }
  380.  
  381. if(Liczba[1] < LICZBA_CTF){
  382. format(str[1],16,"CTF:");
  383. format(strr[1],10,"~w~%d/%d",Liczba[1],LICZBA_CTF);
  384. }else{
  385. format(str[1],16,"CTF:");
  386. format(strr[1],10,"~y~%d",Liczba[1]);
  387. }
  388. if(CTFON){
  389. format(str[1],16,"CTF:");
  390. format(strr[1],10,"~r~~h~Trwa");
  391. }
  392.  
  393. if(Liczba[2] < LICZBA_DB){
  394. format(str[2],16,"DB:");
  395. format(strr[2],10,"~w~%d/%d",Liczba[2],LICZBA_DB);
  396. }else{
  397. format(str[2],16,"DB:");
  398. format(strr[2],10,"~y~%d",Liczba[2]);
  399. }
  400. if(DerbyON || Liczba[2] >= 16){
  401. format(str[2],16,"DB:");
  402. format(strr[2],10,"~r~~h~Trwa");
  403. }
  404.  
  405. if(Liczba[3] < LICZBA_SS){
  406. format(str[3],16,"SS:");
  407. format(strr[3],10,"~w~%d/%d",Liczba[3],LICZBA_SS);
  408. }else{
  409. format(str[3],16,"SS:");
  410. format(strr[3],10,"~y~%d",Liczba[3]);
  411. }
  412.  
  413. if(Liczba[4] < LICZBA_RC){
  414. format(str[4],16,"WS:");
  415. format(strr[4],10,"~w~%d/%d",Liczba[4], LICZBA_RC);
  416. }else{
  417. format(str[4],16,"WS:");
  418. format(strr[4],10,"~y~%d",Liczba[4]);
  419. }
  420. if(RaceWystartowal || Liczba[4] >= 10){
  421. format(str[4],16,"WS:");
  422. format(strr[4],10,"~r~~h~Trwa");
  423. }
  424.  
  425.  
  426. if(Liczba[5] < LICZBA_ST){
  427. format(str[5],16,"ST:");
  428. format(strr[5],10,"~w~%d/%d",Liczba[5], LICZBA_ST);
  429. }else{
  430. format(str[5],16,"ST:");
  431. format(strr[5],10,"~y~%d",Liczba[5]);
  432. }
  433. if(StrzelnicaON){
  434. format(str[5],16,"ST:");
  435. format(strr[5],10,"~r~~h~Trwa");
  436. }
  437.  
  438.  
  439. if(Liczba[6] < LICZBA_CH){
  440. format(str[6],16,"CH:");
  441. format(strr[6],10,"~w~%d/%d",Liczba[6], LICZBA_CH);
  442. }else{
  443. format(str[6],16,"CH:");
  444. format(strr[6],10,"~y~%d",Liczba[6]);
  445. }
  446. if(ChWystartowala || Liczba[6] >= 49){
  447. format(str[6],16,"CH:");
  448. format(strr[6],10,"~r~~h~Trwa");
  449. }
  450.  
  451.  
  452. if(Liczba[7] < LICZBA_LB){
  453. format(str[7],16,"LB:");
  454. format(strr[7],10,"~w~%d/%d",Liczba[7], LICZBA_LB);
  455. }else{
  456. format(str[7],16,"LB:");
  457. format(strr[7],10,"~y~%d",Liczba[7]);
  458. }
  459. if(LabON){
  460. format(str[7],16,"LB:");
  461. format(strr[7],10,"~r~~h~Trwa");
  462. }
  463.  
  464. if(Liczba[8] < LICZBA_SN){
  465. format(str[8],16,"SO:");
  466. format(strr[8],10,"~w~%d/%d",Liczba[8],LICZBA_SN);
  467. }else{
  468. format(str[8],16,"SO:");
  469. format(strr[8],10,"~y~%d",Liczba[8]);
  470. }
  471. if(SianoON){
  472. format(str[8],16,"SO:");
  473. format(strr[8],10,"~r~TRWA");
  474. }
  475.  
  476. if(Liczba[1] < LICZBA_PB){
  477. format(str[1],16,"PL:");
  478. format(strr[1],10,"~w~%d/%d",Liczba[1],LICZBA_PB);
  479. }else{
  480. format(str[1],16,"PL:");
  481. format(strr[1],10,"~y~%d",Liczba[1]);
  482. }
  483. if(PaintbON){
  484. format(str[1],16,"PL:");
  485. format(strr[1],10,"~r~TRWA");
  486. }
  487.  
  488. if(Liczba[9] < LICZBA_TR){
  489. format(str[9],16,"WP:");
  490. format(strr[9],10,"~w~%d/%d",Liczba[9],LICZBA_TR);
  491. }else{
  492. format(str[9],16,"WP:");
  493. format(strr[9],10,"~y~%d",Liczba[9]);
  494. }
  495. if(TowerON){
  496. format(str[9],16,"WP:");
  497. format(strr[9],10,"~r~TRWA");
  498. }
  499.  
  500. if(Liczba[10] < LICZBA_CW){
  501. format(str[10],16,"CW:");
  502. format(strr[10],10,"~w~%d/%d",Liczba[10],LICZBA_CW);
  503. }else{
  504. format(str[10],16,"CW:");
  505. format(strr[10],10,"~y~%d",Liczba[10]);
  506. }
  507. if(ColorwON){
  508. format(str[10],16,"CW:");
  509. format(strr[10],10,"~r~TRWA");
  510. }
  511.  
  512.  
  513. if(Liczba[11] < LICZBA_HAY){
  514. format(str[11],16,"HAY:");
  515. format(strr[11],10,"~w~%d/%d",Liczba[11],LICZBA_HAY);
  516. }else{
  517. format(str[11],16,"HAY:");
  518. format(strr[11],10,"~y~%d",Liczba[11]);
  519. }
  520. if(HayON){
  521. format(str[11],16,"HAY:");
  522. format(strr[11],10,"~r~TRWA");
  523. }
  524.  
  525. new string[256];
  526. new string2[256];
  527. format(string,sizeof(string),"~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~",str[0],str[1],str[2],str[3],str[4],str[5],str[6],str[7],str[8],str[9],str[10],str[11]);
  528. format(string2,sizeof(string2),"~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~%s~n~~n~",strr[0],strr[1],strr[2],strr[3],strr[4],strr[5],strr[6],strr[7],strr[8],strr[9],strr[10],strr[11]);
  529.  
  530. TextDrawSetString(event11,string);
  531. TextDrawSetString(event22,string2);
  532.  
  533. return 1;
  534. }
  535.  
  536. forward StrzelnicaEnd();
  537. public StrzelnicaEnd()
  538. {
  539. foreach(Player, playerid)
  540. {
  541. if(Strzelnica[playerid])
  542. SetPlayerRandomSpawn(playerid);
  543.  
  544. Strzelnica[playerid] = false;
  545. StrzelnicaSniper[playerid] = false;
  546. StrzelnicaZaglosowal[playerid] = false;
  547. }
  548.  
  549. StrzelnicaON = false;
  550. StrzelnicaStartON = false;
  551. ZapisyUpdate();
  552. return 1;
  553. }
  554.  
  555. forward StrzelnicaCheck();
  556. public StrzelnicaCheck()
  557. {
  558. if(!StrzelnicaON)
  559. return 1;
  560.  
  561. foreach(Player, playerid)
  562. {
  563. if(Strzelnica[playerid])
  564. {
  565. if(!StrzelnicaSniper[playerid] && !IsPlayerInArea(playerid, 270.3151, 293.5906, -144.3372, -126.0463))
  566. SetPlayerPos(playerid, 285.2184, -134.4836, 1004.0625);
  567.  
  568. if(GetPlayerWeapon(playerid) != 0 && !StrzelnicaSniper[playerid])
  569. {
  570. Strzelnica[playerid] = false;
  571. StrzelnicaSniper[playerid] = false;
  572. StrzelnicaZaglosowal[playerid] = false;
  573. SetPlayerRandomSpawn(playerid);
  574. SendClientMessage(playerid, COLOR_RED2, "Tutaj nie wolno używać broni!");
  575. }
  576. SetPlayerArmour(playerid, 0);
  577. }
  578. }
  579. return 1;
  580. }
  581.  
  582. forward StrzelnicaStart();
  583. public StrzelnicaStart()
  584. {
  585. StrzelnicaON = true;
  586. new Num;
  587. foreach(Player, playerid)
  588. if(Strzelnica[playerid])
  589. Num++;
  590.  
  591. new rand = random(Num);
  592.  
  593. foreach(Player, x)
  594. {
  595. if(Strzelnica[x])
  596. {
  597. if(!(rand--))
  598. {
  599. StrzelnicaSniper[x] = true;
  600. break;
  601. }
  602. }
  603. }
  604.  
  605. foreach(Player, x)
  606. {
  607. if(Strzelnica[x])
  608. {
  609. SendClientMessage(x, COLOR_GREEN, "Aby się wypisać wpisz: /StrzelnicaExit");
  610. SetPlayerInterior(x, 7);
  611. SetPlayerVirtualWorld(x, 1);
  612. ResetPlayerWeapons(x);
  613. RaceMen[x] = false;
  614. Chowany[x] = false;
  615. WGTeam[x] = 0;
  616. WGKandydat[x] = false;
  617. if(FlageMa == x)
  618. CTFFlagDown(x);
  619.  
  620. CTFTeam[x] = 0;
  621. CTFKandydat[x] = false;
  622. TextDrawHideForPlayer(x, CTFtd);
  623. for(new i; i < 50; i++)
  624. {
  625. if(ChowanyKandydat[i] == x)
  626. {
  627. ChowanyKandydat[i] = -1;
  628. break;
  629. }
  630. }
  631. if(!StrzelnicaSniper[x])
  632. {
  633. SetPlayerPos(x, 285.2184 + random(7), -134.4836 + random(7), 1004.0625);
  634. SetPlayerArmour(x, 0);
  635. SetPlayerHealth(x, 40);
  636. }
  637. else
  638. {
  639. SetPlayerPos(x, 302.1640, -142.1149, 1004.0625);
  640. GivePlayerWeapon(x, 34, 200);
  641. SetPlayerHealth(x, 100);
  642. }
  643. }
  644. }
  645.  
  646. SendClientMessageToAll(0x8080C0FF, "Strzelnica wystartowała!");
  647. ZapisyUpdate();
  648. return 1;
  649. }
  650.  
  651.  
  652.  
  653. forward SianoStart();
  654. public SianoStart()
  655. {
  656.  
  657. SianoON = true;
  658.  
  659. new rand1 = random(10);
  660. new rand2 = random(11);
  661.  
  662. for(new x=0;x<MAX_PLAYERS;x++){
  663. if(IsPlayerConnected(x) && SianoMen[x]){
  664.  
  665. RaceMen[x] = false;
  666. Chowany[x] = false;
  667. WGTeam[x] = 0;
  668. WGKandydat[x] = false;
  669. for(new i=0;i<50;i++){
  670. if(ChowanyKandydat[i] == x){
  671. ChowanyKandydat[i] = -1;
  672. break;
  673. }
  674. }
  675.  
  676. ResetPlayerWeapons(x);
  677. SendClientMessage(x,COLOR_GREEN,"Aby się wypisać: /SianoExit");
  678. TogglePlayerControllable(x,0);
  679. SetTimerEx("JailUnfreeze",3000,0,"i",x);
  680. SetPlayerVirtualWorld(x,0);
  681. SetPlayerPos(x, 2603.95703125+rand1, -1296.984375+rand2, 596.72399902344);
  682. SianoTimer = SetTimer("SianoGun",10000,true);
  683. }
  684. }
  685.  
  686. SendClientMessageToAll(COLOR_BLUE,"Siano wystartowały!");
  687.  
  688. ZapisyUpdate();
  689.  
  690. return 1;
  691. }
  692. forward SianoGun();
  693. public SianoGun()
  694. {
  695. for(new x=0;x<MAX_PLAYERS;x++){
  696. if(IsPlayerConnected(x) && SianoMen[x]){
  697. GivePlayerWeapon(x,24,1);
  698. }
  699. }
  700. return 1;
  701. }
  702. forward SianoCheck();
  703. public SianoCheck()
  704. {
  705.  
  706. if(!SianoON) return 1;
  707.  
  708. new Licz;
  709.  
  710. for(new x=0;x<MAX_PLAYERS;x++){
  711. if(IsPlayerConnected(x) && SianoMen[x]){
  712. Licz ++;
  713. new Float:xx,Float:y,Float:z;
  714. GetPlayerPos(x,xx,y,z);
  715.  
  716. if(floatround(z) < 400 || AFK[x]){
  717. Licz --;
  718. SianoMen[x] = false;
  719. SianoZaglosowal[x] = false;
  720. SetPlayerRandomSpawn(x);
  721. KillTimer(SianoTimer);
  722. }
  723. }
  724. }
  725.  
  726. if(Licz <= 1){
  727.  
  728. for(new x=0;x<MAX_PLAYERS;x++){
  729. if(IsPlayerConnected(x) && SianoMen[x]){
  730. new str[64];
  731. format(str,sizeof(str),"Siano wygrywa %s , Zapisy wznowione!",PlayerName(x));
  732. SendClientMessageToAll(0xA346FFFF,str);
  733. WinSound(x);
  734. GameTextForPlayer(x,"respekt~n~~g~+15", 1000, 1);
  735. SetPlayerScore(x, GetPlayerScore(x) + 15);
  736. }
  737. }
  738. SianoEnd();
  739. return 1;
  740. }
  741.  
  742. return 1;
  743. }
  744.  
  745. forward SianoEnd();
  746. public SianoEnd()
  747. {
  748.  
  749. SianoON = false;
  750. SianoStartON = false;
  751.  
  752. for(new x=0;x<MAX_PLAYERS;x++){
  753. if(SianoMen[x]){
  754. SetPlayerRandomSpawn(x);
  755. KillTimer(SianoTimer);
  756. }
  757. SianoMen[x] = false;
  758. SianoZaglosowal[x] = false;
  759. }
  760.  
  761. ZapisyUpdate();
  762.  
  763. return 1;
  764. }
  765.  
  766. forward PaintbStart();
  767. public PaintbStart()
  768. {
  769. PaintbON = true;
  770. for(new x=0;x<MAX_PLAYERS;x++){
  771. if(IsPlayerConnected(x) && PaintbMen[x]){
  772.  
  773. RaceMen[x] = false;
  774. Chowany[x] = false;
  775. WGTeam[x] = 0;
  776. WGKandydat[x] = false;
  777.  
  778. for(new i=0;i<50;i++){
  779. if(ChowanyKandydat[i] == x){
  780. ChowanyKandydat[i] = -1;
  781. break;
  782. }
  783. }
  784.  
  785. ResetPlayerWeapons(x);
  786. SendClientMessage(x,COLOR_GREEN,"Aby się wypisać: /PBExit");
  787. TogglePlayerControllable(x,0);
  788. SetTimerEx("JailUnfreeze",3000,0,"i",x);
  789. SetPlayerVirtualWorld(x,5);
  790. new RandomSpawn = random(sizeof(PaintbSpawn));
  791. SetPlayerPos(x,PaintbSpawn[RandomSpawn][0],PaintbSpawn[RandomSpawn][1],PaintbSpawn[RandomSpawn][2]);
  792. GivePlayerWeapon(x, 23, 99999);
  793. SetPlayerArmour(x,0);
  794. SetPlayerHealth(x,5);
  795. SetPlayerColor(x,0xFFFFFF00);
  796. }
  797. }
  798. SendClientMessageToAll(0xA346FFFF,"PaintBall wystartował!");
  799. ZapisyUpdate();
  800. return 1;
  801. }
  802.  
  803. forward PaintbCheck();
  804. public PaintbCheck()
  805. {
  806. if(!PaintbON) return 1;
  807. new Licz;
  808.  
  809. for(new x=0;x<MAX_PLAYERS;x++){
  810. if(IsPlayerConnected(x) && PaintbMen[x]){
  811. Licz ++;
  812. new Float:xx,Float:y,Float:z;
  813. GetPlayerPos(x,xx,y,z);
  814.  
  815. if(AFK[x]){
  816. Licz --;
  817. PaintbMen[x] = false;
  818. PaintbZaglosowal[x] = false;
  819. SetPlayerRandomSpawn(x);
  820. }
  821. }
  822. }
  823.  
  824. if(Licz <= 1){
  825. for(new x=0;x<MAX_PLAYERS;x++){
  826. if(IsPlayerConnected(x) && PaintbMen[x]){
  827. new str[64];
  828. format(str,sizeof(str),"PaintBall wygrywa %s , Zapisy wznowione!",PlayerName(x));
  829. SendClientMessageToAll(0xA346FFFF,str);
  830. WinSound(x);
  831. GameTextForPlayer(x,"respekt~n~~g~+15", 1000, 1);
  832. SetPlayerScore(x, GetPlayerScore(x) + 15);
  833. SetPlayerHealth(x,100);
  834. }
  835. }
  836. PaintbEnd();
  837. return 1;
  838. }
  839. return 1;
  840. }
  841.  
  842. forward PaintbEnd();
  843. public PaintbEnd()
  844. {
  845.  
  846. PaintbON = false;
  847. PaintbStartON = false;
  848.  
  849. for(new x=0;x<MAX_PLAYERS;x++){
  850. if(PaintbMen[x]){
  851. SetPlayerRandomSpawn(x);
  852. }
  853. PaintbMen[x] = false;
  854. PaintbZaglosowal[x] = false;
  855. }
  856. ZapisyUpdate();
  857. return 1;
  858. }
  859.  
  860.  
  861. forward TowerStart();
  862. public TowerStart()
  863. {
  864.  
  865. TowerON = true;
  866.  
  867. new rand1 = random(10);
  868. new rand2 = random(11);
  869.  
  870. for(new x=0;x<MAX_PLAYERS;x++){
  871. if(IsPlayerConnected(x) && TowerMen[x]){
  872.  
  873. RaceMen[x] = false;
  874. Chowany[x] = false;
  875. WGTeam[x] = 0;
  876. WGKandydat[x] = false;
  877. for(new i=0;i<50;i++){
  878. if(ChowanyKandydat[i] == x){
  879. ChowanyKandydat[i] = -1;
  880. break;
  881. }
  882. }
  883.  
  884. ResetPlayerWeapons(x);
  885. SendClientMessage(x,COLOR_GREEN,"Aby się wypisać: /wpExit");
  886. TogglePlayerControllable(x,0);
  887. SetTimerEx("JailUnfreeze",3000,0,"i",x);
  888. SetPlayerVirtualWorld(x,0);
  889. SetPlayerPos(x, 2305.5197+rand1, -559.602+rand2, -34.5498);
  890. }
  891. }
  892.  
  893. SendClientMessageToAll(COLOR_BLUE,"Wipeout wystartował!");
  894.  
  895. ZapisyUpdate();
  896.  
  897. return 1;
  898. }
  899. forward TowerCheck();
  900. public TowerCheck()
  901. {
  902.  
  903. if(!TowerON) return 1;
  904.  
  905. new Licz;
  906.  
  907. for(new x=0;x<MAX_PLAYERS;x++){
  908. if(IsPlayerConnected(x) && TowerMen[x]){
  909. Licz ++;
  910. if(AFK[x]){
  911. Licz --;
  912. TowerMen[x] = false;
  913. TowerZaglosowal[x] = false;
  914. SetPlayerRandomSpawn(x);
  915. }
  916. }
  917. }
  918. for(new x=0;x<MAX_PLAYERS;x++){
  919. if(IsPlayerConnected(x) && TowerMen[x]){
  920. new Float:xx,Float:y,Float:z;
  921. GetPlayerPos(x,xx,y,z);
  922. if(Licz <= 1 || floatround(z) > 104){
  923. new str[64];
  924. format(str,sizeof(str),"Wipeout wygrywa %s , Zapisy wznowione!",PlayerName(x));
  925. SendClientMessageToAll(0xA346FFFF,str);
  926. WinSound(x);
  927. GameTextForPlayer(x,"respekt~n~~g~+20", 1000, 1);
  928. SetPlayerScore(x, GetPlayerScore(x) + 20);
  929. TowerEnd();
  930.  
  931. }
  932. }
  933. }
  934.  
  935.  
  936. return 1;
  937. }
  938. forward TowerEnd();
  939. public TowerEnd()
  940. {
  941.  
  942. TowerON = false;
  943. TowerStartON = false;
  944.  
  945. for(new x=0;x<MAX_PLAYERS;x++){
  946. if(TowerMen[x]){
  947. SetPlayerRandomSpawn(x);
  948. }
  949. TowerMen[x] = false;
  950. TowerZaglosowal[x] = false;
  951. }
  952.  
  953. ZapisyUpdate();
  954.  
  955. return 1;
  956. }
  957.  
  958.  
  959. forward HayStart();
  960. public HayStart()
  961. {
  962.  
  963. HayON = true;
  964.  
  965. new rand1 = random(10);
  966. new rand2 = random(11);
  967.  
  968. for(new x=0;x<MAX_PLAYERS;x++){
  969. if(IsPlayerConnected(x) && HayMen[x]){
  970.  
  971. RaceMen[x] = false;
  972. Chowany[x] = false;
  973. WGTeam[x] = 0;
  974. WGKandydat[x] = false;
  975. for(new i=0;i<50;i++){
  976. if(ChowanyKandydat[i] == x){
  977. ChowanyKandydat[i] = -1;
  978. break;
  979. }
  980. }
  981.  
  982. ResetPlayerWeapons(x);
  983. SendClientMessage(x,COLOR_GREEN,"Aby się wypisać: /SianoExit");
  984. TogglePlayerControllable(x,0);
  985. SetTimerEx("JailUnfreeze",3000,0,"i",x);
  986. SetPlayerVirtualWorld(x,0);
  987. SetPlayerPos(x, 2603.95703125+rand1, -1296.984375+rand2, 596.72399902344);
  988. HayTimer = SetTimer("HayGun",10000,true);
  989. }
  990. }
  991.  
  992. SendClientMessageToAll(COLOR_BLUE,"Hay wystartowały!");
  993.  
  994. ZapisyUpdate();
  995.  
  996. return 1;
  997. }
  998.  
  999. forward HayGun();
  1000. public HayGun()
  1001. {
  1002. for(new x=0;x<MAX_PLAYERS;x++){
  1003. if(IsPlayerConnected(x) && HayMen[x]){
  1004. GivePlayerWeapon(x,24,1);
  1005. }
  1006. }
  1007. return 1;
  1008. }
  1009.  
  1010. forward HayCheck();
  1011. public HayCheck()
  1012. {
  1013.  
  1014. if(!HayON) return 1;
  1015.  
  1016. new Licz;
  1017.  
  1018. for(new x=0;x<MAX_PLAYERS;x++){
  1019. if(IsPlayerConnected(x) && HayMen[x]){
  1020. Licz ++;
  1021. new Float:xx,Float:y,Float:z;
  1022. GetPlayerPos(x,xx,y,z);
  1023.  
  1024. if(floatround(z) < 400 || AFK[x]){
  1025. Licz --;
  1026. HayMen[x] = false;
  1027. HayZaglosowal[x] = false;
  1028. SetPlayerRandomSpawn(x);
  1029. KillTimer(HayTimer);
  1030. }
  1031. }
  1032. }
  1033.  
  1034. if(Licz <= 1){
  1035.  
  1036. for(new x=0;x<MAX_PLAYERS;x++){
  1037. if(IsPlayerConnected(x) && HayMen[x]){
  1038. new str[64];
  1039. format(str,sizeof(str),"Siano wygrywa %s , Zapisy wznowione!",PlayerName(x));
  1040. SendClientMessageToAll(0xA346FFFF,str);
  1041. WinSound(x);
  1042. GameTextForPlayer(x,"respekt~n~~g~+15", 1000, 1);
  1043. SetPlayerScore(x, GetPlayerScore(x) + 15);
  1044. }
  1045. }
  1046. HayEnd();
  1047. return 1;
  1048. }
  1049.  
  1050. return 1;
  1051. }
  1052.  
  1053. forward HayEnd();
  1054. public HayEnd()
  1055. {
  1056.  
  1057. HayON = false;
  1058. HayStartON = false;
  1059.  
  1060. for(new x=0;x<MAX_PLAYERS;x++){
  1061. if(HayMen[x]){
  1062. SetPlayerRandomSpawn(x);
  1063. KillTimer(HayTimer);
  1064. }
  1065. HayMen[x] = false;
  1066. HayZaglosowal[x] = false;
  1067. }
  1068.  
  1069. ZapisyUpdate();
  1070.  
  1071. return 1;
  1072. }
  1073.  
  1074.  
  1075.  
  1076. forward ColorwStart();
  1077. public ColorwStart()
  1078. {
  1079. ColorwON = true;
  1080. for(new x=0;x<MAX_PLAYERS;x++){
  1081. if(IsPlayerConnected(x) && ColorwMen[x]){
  1082.  
  1083. RaceMen[x] = false;
  1084. Chowany[x] = false;
  1085. WGTeam[x] = 0;
  1086. WGKandydat[x] = false;
  1087.  
  1088. for(new i=0;i<50;i++){
  1089. if(ChowanyKandydat[i] == x){
  1090. ChowanyKandydat[i] = -1;
  1091. break;
  1092. }
  1093. }
  1094.  
  1095. ResetPlayerWeapons(x);
  1096. SendClientMessage(x,COLOR_GREEN,"Aby się wypisać: /CWExit");
  1097. TogglePlayerControllable(x,0);
  1098. SetTimerEx("JailUnfreeze",3000,0,"i",x);
  1099. SetPlayerVirtualWorld(x,5);
  1100. new RandomSpawn = random(sizeof(ColorwSpawn));
  1101. SetPlayerPos(x,ColorwSpawn[RandomSpawn][0],ColorwSpawn[RandomSpawn][1],ColorwSpawn[RandomSpawn][2]);
  1102. GivePlayerWeapon(x, 23, 99999);
  1103. SetPlayerArmour(x,0);
  1104. SetPlayerHealth(x,5);
  1105. SetPlayerColor(x,0xFFFFFF00);
  1106. }
  1107. }
  1108. SendClientMessageToAll(0xA346FFFF,"Color Wars wystartował!");
  1109. ZapisyUpdate();
  1110. return 1;
  1111. }
  1112.  
  1113.  
  1114. forward ColorwCheck();
  1115. public ColorwCheck()
  1116. {
  1117. if(!ColorwON) return 1;
  1118. new Licz;
  1119.  
  1120. for(new x=0;x<MAX_PLAYERS;x++){
  1121. if(IsPlayerConnected(x) && ColorwMen[x]){
  1122. Licz ++;
  1123. new Float:xx,Float:y,Float:z;
  1124. GetPlayerPos(x,xx,y,z);
  1125.  
  1126. if(AFK[x]){
  1127. Licz --;
  1128. ColorwMen[x] = false;
  1129. ColorwZaglosowal[x] = false;
  1130. SetPlayerRandomSpawn(x);
  1131. }
  1132. }
  1133. }
  1134.  
  1135. if(Licz <= 1){
  1136. for(new x=0;x<MAX_PLAYERS;x++){
  1137. if(IsPlayerConnected(x) && ColorwMen[x]){
  1138. new str[64];
  1139. format(str,sizeof(str),"Color Wars wygrywa %s , Zapisy wznowione!",PlayerName(x));
  1140. SendClientMessageToAll(0xA346FFFF,str);
  1141. WinSound(x);
  1142. GameTextForPlayer(x,"respekt~n~~g~+15", 1000, 1);
  1143. SetPlayerScore(x, GetPlayerScore(x) + 15);
  1144. SetPlayerHealth(x,100);
  1145. }
  1146. }
  1147. ColorwEnd();
  1148. return 1;
  1149. }
  1150. return 1;
  1151. }
  1152.  
  1153.  
  1154. forward ColorwEnd();
  1155. public ColorwEnd()
  1156. {
  1157.  
  1158. ColorwON = false;
  1159. ColorwStartON = false;
  1160.  
  1161. for(new x=0;x<MAX_PLAYERS;x++){
  1162. if(ColorwMen[x]){
  1163. SetPlayerRandomSpawn(x);
  1164. }
  1165. ColorwMen[x] = false;
  1166. ColorwZaglosowal[x] = false;
  1167. }
  1168. ZapisyUpdate();
  1169. return 1;
  1170. }
  1171.  
  1172.  
  1173.  
  1174.  
  1175.  
  1176.  
  1177.  
  1178. forward DerbyPutInCar(playerid, carid);
  1179. public DerbyPutInCar(playerid, carid)
  1180. {
  1181. PutPlayerInVehicle(playerid, carid, 0);
  1182. DerbyLoad = false;
  1183. return 1;
  1184. }
  1185.  
  1186. forward DerbyStart();
  1187. public DerbyStart()
  1188. {
  1189. DerbyON = true;
  1190. DerbyLoad = true;
  1191.  
  1192. new cd;
  1193.  
  1194. foreach(Player, x)
  1195. {
  1196. if(DerbyMen[x])
  1197. {
  1198. RaceMen[x] = false;
  1199. Chowany[x] = false;
  1200. WGTeam[x] = 0;
  1201. WGKandydat[x] = false;
  1202. if(FlageMa == x)
  1203. CTFFlagDown(x);
  1204.  
  1205. CTFTeam[x] = 0;
  1206. CTFKandydat[x] = false;
  1207. TextDrawHideForPlayer(x, CTFtd);
  1208. for(new i; i < 50; i++)
  1209. {
  1210. if(ChowanyKandydat[i] == x)
  1211. {
  1212. ChowanyKandydat[i] = -1;
  1213. break;
  1214. }
  1215. }
  1216.  
  1217. ResetPlayerWeapons(x);
  1218. SendClientMessage(x, COLOR_GREEN, "Aby się wypisać: /DerbyExit");
  1219. TogglePlayerControllable(x, 0);
  1220. SetTimerEx("JailUnfreeze", 3000, 0, "i", x);
  1221. SetVehicleVirtualWorld(DerbyCar[cd], 5);
  1222. SetPlayerVirtualWorld(x, 5);
  1223. SetVehicleToRespawn(DerbyCar[cd]);
  1224. SetVehicleHealth(DerbyCar[cd], 999999);
  1225. SetPlayerPos(x, -189.3335, -612.0821, 67.7825);
  1226. SetTimerEx("DerbyPutInCar", 2000, 0, "ii", x, DerbyCar[cd]);
  1227. cd++;
  1228. }
  1229. }
  1230.  
  1231. SendClientMessageToAll(0xA346FFFF, "Derby wystartowały!");
  1232. ZapisyUpdate();
  1233. return 1;
  1234. }
  1235.  
  1236.  
  1237. forward DerbyCheck();
  1238. public DerbyCheck()
  1239. {
  1240.  
  1241. if(!DerbyON) return 1;
  1242. if(DerbyLoad) return 1;
  1243.  
  1244. new Licz;
  1245.  
  1246. for(new x=0;x<MAX_PLAYERS;x++){
  1247. if(IsPlayerConnected(x) && DerbyMen[x]){
  1248. Licz ++;
  1249. new Float:xx,Float:y,Float:z;
  1250. GetPlayerPos(x,xx,y,z);
  1251.  
  1252. if(floatround(z) < 20 || !IsPlayerInAnyVehicle(x) || AFK[x]){
  1253. Licz --;
  1254. DerbyMen[x] = false;
  1255. DerbyZaglosowal[x] = false;
  1256. if(IsPlayerInAnyVehicle(x)){
  1257. new veh = GetPlayerVehicleID(x);
  1258. SetVehicleVirtualWorld(veh,2);
  1259. }
  1260. SetPlayerRandomSpawn(x);
  1261. }
  1262. }
  1263. }
  1264.  
  1265. if(Licz <= 1){
  1266.  
  1267. for(new x=0;x<MAX_PLAYERS;x++){
  1268. if(IsPlayerConnected(x) && DerbyMen[x]){
  1269. new str[64];
  1270. format(str,sizeof(str),"Derby wygrywa %s , Zapisy wznowione!",PlayerName(x));
  1271. SendClientMessageToAll(0xA346FFFF,str);
  1272. WinSound(x);
  1273. if(logged[x]){
  1274. GameTextForPlayer(x,"respekt~n~~g~+15", 1000, 1);
  1275. Respekt[x] += 15;
  1276. }
  1277. }
  1278. }
  1279. DerbyEnd();
  1280. return 1;
  1281. }
  1282.  
  1283. return 1;
  1284. }
  1285.  
  1286. forward DerbyEnd();
  1287. public DerbyEnd()
  1288. {
  1289. DerbyON = false;
  1290. DerbyStartON = false;
  1291. foreach(Player, x)
  1292. {
  1293. if(DerbyMen[x])
  1294. SetPlayerRandomSpawn(x);
  1295.  
  1296. DerbyMen[x] = false;
  1297. DerbyZaglosowal[x] = false;
  1298. }
  1299.  
  1300. for(new x; x < 16; x++)
  1301. SetVehicleVirtualWorld(DerbyCar[x], 2);
  1302.  
  1303. ZapisyUpdate();
  1304. return 1;
  1305. }
  1306.  
  1307. forward LabiryntAutoEnd();
  1308. public LabiryntAutoEnd()
  1309. {
  1310. LabiryntEnd();
  1311. SendClientMessageToAll(COLOR_RED2, "Labirynt został zakończony przez serwer");
  1312. return 1;
  1313. }
  1314.  
  1315. forward LabiryntEnd();
  1316. public LabiryntEnd()
  1317. {
  1318. foreach(Player, x)
  1319. {
  1320. if(Labirynt[x])
  1321. {
  1322. SetPlayerRandomSpawn(x);
  1323. SetPlayerVirtualWorld(x, 0);
  1324. DisablePlayerCheckpoint(x);
  1325. }
  1326. Labirynt[x] = false;
  1327. LabiryntZaglosowal[x] = false;
  1328. }
  1329.  
  1330. LabON = false;
  1331. LabStartON = false;
  1332. KillTimer(LabTimer);
  1333. ZapisyUpdate();
  1334. return 1;
  1335. }
  1336.  
  1337. forward LabiryntStart();
  1338. public LabiryntStart()
  1339. {
  1340. new rand = random(sizeof LabiryntSpawn);
  1341. foreach(Player, x)
  1342. {
  1343. if(Labirynt[x])
  1344. {
  1345. SetPlayerPos(x, 1543.6432, -1519.4767, 23.5469);
  1346. SetPlayerInterior(x, 0);
  1347. SetPlayerVirtualWorld(x, 3);
  1348. ResetPlayerWeapons(x);
  1349. AnnForPlayer(x, 5000, "Znajdz wyjscie z labiryntu!");
  1350. SetPlayerCheckpoint(x, LabiryntSpawn[rand][0], LabiryntSpawn[rand][1], LabiryntSpawn[rand][2], 1);
  1351. }
  1352. }
  1353.  
  1354. LabON = true;
  1355. LabStartON = false;
  1356. ZapisyUpdate();
  1357. return 1;
  1358. }
  1359.  
  1360. forward SkokiSpadochronowe();
  1361. public SkokiSpadochronowe()
  1362. {
  1363. new rand = random(sizeof SkokiSpawn);
  1364. foreach(Player, x)
  1365. {
  1366. if(Skoczek[x])
  1367. {
  1368. SetPlayerPos(x, SkokiSpawn[rand][0] + random(50), SkokiSpawn[rand][1] + random(50), SkokiSpawn[rand][2]);
  1369. SetPlayerInterior(x, 0);
  1370. SetPlayerVirtualWorld(x, 0);
  1371. GivePlayerWeapon(x, 46, 1);
  1372. PlayerPlaySound(x, 1039, 0, 0, 0);
  1373. }
  1374. Skoczek[x] = false;
  1375. SkoczekZaglosowa[x] = false;
  1376. }
  1377.  
  1378. SendClientMessageToAll(0x009CE8FF, "Skoki spadochronowe wystartowały! (Zapisy wznowione)");
  1379. SkokiStartON = false;
  1380. ZapisyUpdate();
  1381. return 1;
  1382. }
  1383. forward RespawnFlaga();
  1384. public RespawnFlaga()
  1385. {
  1386. flaga = CreateObject(11245, CTFFlagPos[0],CTFFlagPos[1],CTFFlagPos[2], 0, 288.54, 328.24);
  1387. FlageMa = -1;
  1388. foreach(Player, x)
  1389. {
  1390. if(CTFTeam[x] > 0)
  1391. {
  1392. SetPlayerRaceCheckpoint(x, 2, CTFFlagPos[0], CTFFlagPos[1], CTFFlagPos[2], CTFFlagPos[0], CTFFlagPos[1], CTFFlagPos[2], 2);
  1393. AnnForPlayer(x, 3000, "~y~Flaga na respawnie!");
  1394. }
  1395. }
  1396. return 1;
  1397. }
  1398. forward CTFFlagDown(playerid);
  1399. public CTFFlagDown(playerid)
  1400. {
  1401. new Float:x, Float:y, Float:z;
  1402. GetPlayerPos(playerid, x, y, z);
  1403. DetachObject(flaga, 11245);
  1404. SetObjectPos(flaga, x, y, z);
  1405. //MoveObject(flaga, x, y, z, 999);
  1406. FlageMa = -2;
  1407. SetPlayerPos(playerid, -865.8600, -1463.4523, 96.2856);
  1408. foreach(Player, i)
  1409. {
  1410. if(CTFTeam[i])
  1411. {
  1412. SetPlayerRaceCheckpoint(i, 2, x, y, z, x, y, z, 2);
  1413. AnnForPlayer(i, 3000, "~y~Flaga na ziemi!");
  1414. }
  1415. }
  1416. return 1;
  1417. }
  1418.  
  1419. forward CTFEndWin(Team);
  1420. public CTFEndWin(Team)
  1421. {
  1422. switch(Team)
  1423. {
  1424. case 0:
  1425. {
  1426. foreach(Player, x)
  1427. {
  1428. if(CTFTeam[x] == 1)
  1429. {
  1430. GameTextForPlayer(x, "respekt~n~~g~+10", 1000, 1);
  1431. Respekt[x] += 10;
  1432. WinSound(x);
  1433. PlayerSetColor(x);
  1434. SetPlayerRandomSpawn(x);
  1435. DisablePlayerRaceCheckpoint(x);
  1436. CTFKandydat[x] = false;
  1437. CTFTeam[x] = 0;
  1438. CTFGlos[x] = false;
  1439. }
  1440.  
  1441. if(ChceAnn[x])
  1442. AnnForPlayer(x, 5000, "CTF wygrywaja ~b~~h~~h~Niebiescy");
  1443. }
  1444. }
  1445. case 1:
  1446. {
  1447. foreach(Player, x)
  1448. {
  1449. if(CTFTeam[x] == 2)
  1450. {
  1451. GameTextForPlayer(x, "respekt~n~~g~+10", 1000, 1);
  1452. Respekt[x] += 10;
  1453. WinSound(x);
  1454. PlayerSetColor(x);
  1455. SetPlayerRandomSpawn(x);
  1456. DisablePlayerRaceCheckpoint(x);
  1457. CTFKandydat[x] = false;
  1458. CTFTeam[x] = 0;
  1459. CTFGlos[x] = false;
  1460. }
  1461.  
  1462. if(ChceAnn[x])
  1463. AnnForPlayer(x, 5000, "CTF wygrywaja ~g~Zieloni");
  1464. }
  1465. }
  1466. case 3:
  1467. SendClientMessageToAll(COLOR_RED2, "CTF przerwane przez admina");
  1468. }
  1469.  
  1470. KillTimer(CTFTimer);
  1471. CTFLiczba = 0;
  1472. CTFON = false;
  1473. CTFTeamLiczba[0] = 0;
  1474. CTFTeamLiczba[1] = 0;
  1475. FlageMa = -1;
  1476. CTFScore[0] = 0;
  1477. CTFScore[1] = 0;
  1478. DestroyObject(flaga);
  1479. TextDrawHideForAll(CTFtd);
  1480. ZapisyUpdate();
  1481. return 1;
  1482. }
  1483.  
  1484. forward CTFSpawn(playerid);
  1485. public CTFSpawn(playerid)
  1486. {
  1487. TogglePlayerControllable(playerid, 0);
  1488. SetTimerEx("JailUnfreeze", 2500, 0, "i", playerid);
  1489.  
  1490. if(FlageMa == -1)
  1491. SetPlayerRaceCheckpoint(playerid, 2, CTFFlagPos[0], CTFFlagPos[1], CTFFlagPos[2], CTFFlagPos[0], CTFFlagPos[1], CTFFlagPos[2], 2);
  1492.  
  1493. switch(CTFTeam[playerid])
  1494. {
  1495. case 1: // niebiescy
  1496. {
  1497. PlayerTeleport(playerid, 0, CTFSpawnPos[0][0], CTFSpawnPos[0][1], CTFSpawnPos[0][2]);
  1498. SetPlayerColor(playerid, 0x0482FFFF);
  1499. }
  1500. case 2: // zieloni
  1501. {
  1502. PlayerTeleport(playerid, 0, CTFSpawnPos[1][0], CTFSpawnPos[1][1], CTFSpawnPos[1][2]);
  1503. SetPlayerColor(playerid, 0x00CC00FF);
  1504. }
  1505. }
  1506.  
  1507. SetPlayerVirtualWorld(playerid, 11);
  1508. SetPlayerInterior(playerid, CTFInterior);
  1509. SetPlayerHealth(playerid, 100);
  1510. SetPlayerArmour(playerid, 0);
  1511. ResetPlayerWeapons(playerid);
  1512. GivePlayerWeapon(playerid, 4, 1);
  1513. GivePlayerWeapon(playerid, 24, 1000);
  1514. GivePlayerWeapon(playerid, 31, 3000);
  1515. GivePlayerWeapon(playerid, 34, 3000);
  1516. return 1;
  1517. }
  1518.  
  1519. forward CTFUpdate();
  1520. public CTFUpdate()
  1521. {
  1522. if(!CTFON)
  1523. return 1;
  1524.  
  1525. new string[50];
  1526. format(string, sizeof(string), "~b~~h~Niebiescy:~w~ %d/3~n~~g~ Zieloni:~w~ %d/3", CTFScore[0], CTFScore[1]);
  1527. TextDrawSetString(CTFtd, string);
  1528.  
  1529. CTFTeamLiczba[0] = 0;
  1530. CTFTeamLiczba[1] = 0;
  1531. foreach(Player, x)
  1532. {
  1533. switch(CTFTeam[x])
  1534. {
  1535. case 1:
  1536. CTFTeamLiczba[0]++;
  1537. case 2:
  1538. CTFTeamLiczba[1]++;
  1539. }
  1540. }
  1541.  
  1542. if(CTFTeamLiczba[0] <= 0)
  1543. CTFEndWin(1);
  1544. else if(CTFTeamLiczba[1] <= 0)
  1545. CTFEndWin(0);
  1546. return 1;
  1547. }
  1548.  
  1549. forward CTFStart();
  1550. public CTFStart()
  1551. {
  1552. TextDrawSetString(CTFtd, "Load...");
  1553. KillTimer(CTFTimer);
  1554. CTFLiczba = 0;
  1555. CTFON = true;
  1556. CTFTeamLiczba[0] = 0;
  1557. CTFTeamLiczba[1] = 0;
  1558. FlageMa = -1;
  1559. CTFScore[0] = 0;
  1560. CTFScore[1] = 0;
  1561. DestroyObject(flaga);
  1562.  
  1563. new Rand = random(5);
  1564. new string[32];
  1565. format(string, sizeof(string), "PXS/CaptureTheFlag/%d.ini", Rand);
  1566.  
  1567. if(!fexist(string)) {
  1568. CTFStart();
  1569. return 1;
  1570. }
  1571.  
  1572. new tmp[256];
  1573. new e,f,g;
  1574. tmp = dini_Get(string,"Flaga");
  1575. CTFFlagPos[0] = floatstr(strtok(tmp,e,','));
  1576. CTFFlagPos[1] = floatstr(strtok(tmp,e,','));
  1577. CTFFlagPos[2] = floatstr(strtok(tmp,e,','));
  1578. tmp = dini_Get(string,"Spawn1");
  1579. CTFSpawnPos[0][0] = floatstr(strtok(tmp,f,','));
  1580. CTFSpawnPos[0][1] = floatstr(strtok(tmp,f,','));
  1581. CTFSpawnPos[0][2] = floatstr(strtok(tmp,f,','));
  1582. tmp = dini_Get(string,"Spawn2");
  1583. CTFSpawnPos[1][0] = floatstr(strtok(tmp,g,','));
  1584. CTFSpawnPos[1][1] = floatstr(strtok(tmp,g,','));
  1585. CTFSpawnPos[1][2] = floatstr(strtok(tmp,g,','));
  1586. tmp = dini_Get(string,"Interior");
  1587. CTFInterior = strval(tmp);
  1588.  
  1589. flaga = CreateObject(11245, CTFFlagPos[0],CTFFlagPos[1],CTFFlagPos[2], 0, 288.53997802734, 328.23999023438);
  1590.  
  1591. new bool:TeamCount = false;
  1592. for(new x; x<MAX_PLAYERS; x++)
  1593. {
  1594.  
  1595. if(CTFKandydat[x]){
  1596.  
  1597. Chowany[x] = false;
  1598. WGTeam[x] = 0;
  1599. WGKandydat[x] = false;
  1600. RaceMen[x] = false;
  1601.  
  1602. for(new i=0;i<50;i++){
  1603. if(ChowanyKandydat[i] == x){
  1604. ChowanyKandydat[i] = -1;
  1605. break;
  1606. }
  1607. }
  1608.  
  1609.  
  1610.  
  1611. TextDrawShowForPlayer(x,CTFtd);
  1612. if(TeamCount == false){
  1613. CTFTeam[x] = 1;
  1614. SendClientMessage(x,0x00FFFFFF,"Startujesz w drużynie niebieskich, biegnij po flage !");
  1615. CTFSpawn(x);
  1616. TeamCount = true;
  1617. }
  1618. else
  1619. {
  1620. CTFTeam[x] = 2;
  1621. SendClientMessage(x,COLOR_GREEN,"Startujesz w drużynie zielonych, biegnij po flage !");
  1622. CTFSpawn(x);
  1623. TeamCount = false;
  1624. }
  1625.  
  1626. }
  1627. }
  1628.  
  1629.  
  1630. ZapisyUpdate();
  1631.  
  1632. return 1;
  1633. }
  1634. forward RaceAutoStart();
  1635. public RaceAutoStart()
  1636. {
  1637. if(RaceWystartowal) return 1;
  1638.  
  1639. new string[32];
  1640. RaceID = random(30);
  1641. format(string,sizeof(string),"PXS/Wyscigi/%d.ini",RaceID);
  1642.  
  1643. if(fexist(string)) {
  1644.  
  1645. new tmp[256];
  1646.  
  1647. tmp = dini_Get(string,"Interior");
  1648. Interior = strval(tmp);
  1649.  
  1650. tmp = dini_Get(string,"CarModel");
  1651. CarModel = strval(tmp);
  1652.  
  1653. tmp = dini_Get(string,"CP_NUM");
  1654. CPliczba = strval(tmp);
  1655.  
  1656. tmp = dini_Get(string,"Angle");
  1657. SpawnAngle = floatstr(tmp);
  1658.  
  1659. tmp = dini_Get(string,"CP_SIZE");
  1660. CPSize = strval(tmp);
  1661.  
  1662. tmp = dini_Get(string,"NITRO");
  1663. RaceNitro = strval(tmp);
  1664.  
  1665. tmp = dini_Get(string,"CP_TYPE");
  1666. CPType = strval(tmp);
  1667.  
  1668. tmp = dini_Get(string,"ON_FOOT");
  1669. RaceOnFoot = strval(tmp);
  1670.  
  1671.  
  1672. RaceMenLiczba = 0;
  1673. foreach(Player, x){
  1674. if(RaceMen[x]){
  1675. RaceMenLiczba ++;
  1676. }
  1677. }
  1678.  
  1679. for(new x=0;x<RaceMenLiczba;x++){
  1680. new str[10];
  1681. format(str,sizeof(str),"C%d_Spawn",x);
  1682. tmp = dini_Get(string,str);
  1683. new e;
  1684. CarSpawnX[x] = floatstr(strtok(tmp,e,','));
  1685. CarSpawnY[x] = floatstr(strtok(tmp,e,','));
  1686. CarSpawnZ[x] = floatstr(strtok(tmp,e,','));
  1687. }
  1688.  
  1689. for(new x=0;x<CPliczba;x++){
  1690. new str[10];
  1691. format(str,sizeof(str),"CP_%d",x);
  1692. tmp = dini_Get(string,str);
  1693.  
  1694. new e;
  1695. CPx[x] = floatstr(strtok(tmp,e,','));
  1696. CPy[x] = floatstr(strtok(tmp,e,','));
  1697. CPz[x] = floatstr(strtok(tmp,e,','));
  1698.  
  1699. }
  1700.  
  1701.  
  1702. for(new x=0;x<RaceMenLiczba;x++){
  1703.  
  1704.  
  1705. Car[x] = CreateVehicle(CarModel,CarSpawnX[x],CarSpawnY[x],CarSpawnZ[x],SpawnAngle,-1,-1,9999);
  1706. LinkVehicleToInterior(Car[x],Interior);
  1707. SetVehicleVirtualWorld(Car[x],1);
  1708. if(RaceNitro == 1){
  1709. AddVehicleComponent(Car[x],1010);
  1710. new b=Car[x];
  1711. HaveNitro[b] = true;
  1712. }
  1713. }
  1714.  
  1715. RaceWystartowal = true;
  1716. PlayerCarNum = 0;
  1717. SendClientMessageToAll(0xFF00FFFF,"Wyścig wystartował!");
  1718.  
  1719. KillTimer(RaceStartTimer);
  1720. RaceStartTimer = SetTimer("RaceStart",1000,0);
  1721.  
  1722. }else{
  1723. RaceAutoStart();
  1724. }
  1725.  
  1726. return 1;
  1727. }
  1728. forward SoundOff(playerid);
  1729. public SoundOff(playerid)
  1730. {
  1731. PlayerPlaySound(playerid, 1098, 0.0, 0.0, 0.0);
  1732. return 1;
  1733. }
  1734.  
  1735. forward TotalRaceEnd();
  1736. public TotalRaceEnd()
  1737. {
  1738. KillTimer(RaceTimer);
  1739.  
  1740. foreach(Player, x)
  1741. {
  1742. if(RaceMen[x])
  1743. {
  1744. DisablePlayerRaceCheckpoint(x);
  1745. SetPlayerVirtualWorld(x, 0);
  1746. }
  1747. RaceMen[x] = false;
  1748. RaceCheck[x] = 0;
  1749. }
  1750.  
  1751. RaceMenLiczba = 0;
  1752. MiejsceMeta = 0;
  1753. RaceWystartowal = false;
  1754. PlayerCarNum = 0;
  1755.  
  1756. for(new x; x < MAX_RACE_CHECK; x++)
  1757. Pozycja[x] = 0;
  1758.  
  1759. for(new x; x < 10; x++)
  1760. if(!IsVehicleInUse(Car[x]))
  1761. DestroyVehicle(Car[x]);
  1762.  
  1763. ZapisyUpdate();
  1764. return 1;
  1765. }
  1766.  
  1767.  
  1768. forward RaceCount();
  1769. public RaceCount()
  1770. {
  1771. foreach(Player, x){
  1772. if(RaceMen[x]){
  1773. new string[3];
  1774. if(CountLicz >= 1){
  1775. format(string,3,"%d",CountLicz);
  1776. GameTextForPlayer(x,string,2000,3);
  1777. PlayerPlaySound(x, 1056, 0, 0, 0);
  1778. TogglePlayerControllable(x,0);
  1779. }else{
  1780. GameTextForPlayer(x,"~r~go",2000,3);
  1781. PlayerPlaySound(x, 1057, 0, 0, 0);
  1782. }
  1783.  
  1784. }
  1785. }
  1786. if(CountLicz <= 0){
  1787. foreach(Player, x){
  1788. if(RaceMen[x]){
  1789. TogglePlayerControllable(x,1);
  1790. }
  1791. }
  1792. return 1;
  1793. }
  1794.  
  1795. CountLicz --;
  1796. SetTimer("RaceCount",1000,0);
  1797.  
  1798.  
  1799. return 1;
  1800. }
  1801.  
  1802.  
  1803.  
  1804.  
  1805. forward RaceStart();
  1806. public RaceStart()
  1807. {
  1808.  
  1809. KillTimer(RaceTimer);
  1810. RaceTimer = SetTimer("TotalRaceEnd",300000,false);
  1811.  
  1812. foreach(Player, x){
  1813. if(RaceMen[x]){
  1814.  
  1815. Chowany[x] = false;
  1816. DerbyMen[x] = false;
  1817. Strzelnica[x] = false;
  1818. StrzelnicaSniper[x] = false;
  1819. WGTeam[x] = 0;
  1820. WGKandydat[x] = false;
  1821.  
  1822. if(FlageMa == x){
  1823. CTFFlagDown(x);
  1824. }
  1825. CTFTeam[x] = 0;
  1826. CTFKandydat[x] = false;
  1827. TextDrawHideForPlayer(x,CTFtd);
  1828.  
  1829. for(new i=0;i<50;i++){
  1830. if(ChowanyKandydat[i] == x){
  1831. ChowanyKandydat[i] = -1;
  1832. break;
  1833. }
  1834. }
  1835.  
  1836.  
  1837. SetPlayerInterior(x,Interior);
  1838. SetPlayerVirtualWorld(x,1);
  1839. ResetPlayerWeapons(x);
  1840. PutPlayerInVehicle(x,Car[PlayerCarNum],0);
  1841. RaceCheck[x] = 0;
  1842. SetPlayerRaceCheckpoint(x,CPType,CPx[RaceCheck[x]],CPy[RaceCheck[x]],CPz[RaceCheck[x]],CPx[RaceCheck[x]+1],CPy[RaceCheck[x]+1],CPz[RaceCheck[x]+1],CPSize);
  1843. TogglePlayerControllable(x,0);
  1844. if(RaceOnFoot == 1){
  1845. DestroyVehicle(Car[PlayerCarNum]);
  1846. }
  1847. PlayerCarNum ++;
  1848. }
  1849. }
  1850.  
  1851.  
  1852.  
  1853. CountLicz = 3;
  1854. RaceCount();
  1855. ZapisyUpdate();
  1856.  
  1857. return 1;
  1858. }
  1859.  
  1860. forward ChowanyWyznaczArene();
  1861. public ChowanyWyznaczArene()
  1862. {
  1863. new rand = random(22);
  1864. new string[24];
  1865. format(string,sizeof(string),"PXS/Chowany/%d.ini",rand);
  1866.  
  1867. if(!fexist(string))
  1868. {
  1869. ChowanyWyznaczArene();
  1870. return 1;
  1871. }
  1872.  
  1873. new tmp2[256];
  1874. ChWystartowala = true;
  1875. ChArena = rand;
  1876.  
  1877. tmp2 = dini_Get(string, "ChowanyTP");
  1878. new e;
  1879. ChowPosX = floatstr(strtok(tmp2,e,','));
  1880. ChowPosY = floatstr(strtok(tmp2,e,','));
  1881. ChowPosZ = floatstr(strtok(tmp2,e,','));
  1882.  
  1883. tmp2 = dini_Get(string, "SzukanyTP");
  1884. new f;
  1885. SzukPosX = floatstr(strtok(tmp2,f,','));
  1886. SzukPosY = floatstr(strtok(tmp2,f,','));
  1887. SzukPosZ = floatstr(strtok(tmp2,f,','));
  1888.  
  1889. tmp2 = dini_Get(string, "Interior");
  1890. ChInt = strval(tmp2);
  1891.  
  1892. tmp2 = dini_Get(string, "Strefa");
  1893. new g;
  1894. ChAreaX = floatstr(strtok(tmp2,g,','));
  1895. ChAreaY = floatstr(strtok(tmp2,g,','));
  1896. ChAreaZ = floatstr(strtok(tmp2,g,','));
  1897. ChAreaA = floatstr(strtok(tmp2,g,','));
  1898.  
  1899. SetTimer("ChowWyznaczSzuk",500,0);
  1900. ChNum = 0;
  1901. ZapisyUpdate();
  1902.  
  1903. return 1;
  1904. }
  1905.  
  1906. forward ChowWyznaczSzuk();
  1907. public ChowWyznaczSzuk()
  1908. {
  1909. new num;
  1910. foreach(Player, x){
  1911. if(ChowanyZapisany[x]){
  1912. num ++;
  1913. }
  1914. }
  1915.  
  1916. if(num <= 0){
  1917. ChowanyEnd();
  1918. SendClientMessageToAll(COLOR_RED2,"Zabawa w chowanego nie mogła wystartować, nikt się nie zapisał");
  1919. return 1;
  1920. }
  1921.  
  1922. new num2 = num/5;
  1923. if(num2 <=0) num2 = 1;
  1924. new cd;
  1925.  
  1926. for(new x=0;x<num;x++){
  1927. new id = ChowanyKandydat[x];
  1928. if(IsPlayerConnected(id) && !Szukajacy[id]){
  1929. Chowany[id] = false;
  1930. Szukajacy[id] = true;
  1931. cd ++;
  1932. SendClientMessage(id,COLOR_GREEN,"Zostałeś(aś) wylosowany(a) jako szukający(a)");
  1933. if(cd >= num2) break;
  1934. }
  1935. }
  1936.  
  1937. for(new x=0;x<50;x++){
  1938. if(ChowanyKandydat[x] > -1){
  1939. new idd = ChowanyKandydat[x];
  1940. if(!Szukajacy[idd] && IsPlayerConnected(idd)){
  1941. Chowany[idd] = true;
  1942. Szukajacy[idd] = false;
  1943. SendClientMessage(idd,COLOR_GREEN,"Zostałeś(aś) wylosowany(a) jako chowający(a) się");
  1944. }
  1945. }
  1946. }
  1947.  
  1948. SetTimer("ChowStrt",2000,0);
  1949.  
  1950. return 1;
  1951. }
  1952.  
  1953.  
  1954. forward ChowStrt();
  1955. public ChowStrt()
  1956. {
  1957. foreach(Player, x){
  1958. ChowanyZapisany[x] = false;
  1959. if(Chowany[x]){
  1960.  
  1961. RaceMen[x] = false;
  1962. WGTeam[x] = 0;
  1963. WGKandydat[x] = false;
  1964. Strzelnica[x] = false;
  1965. StrzelnicaSniper[x] = false;
  1966.  
  1967. if(FlageMa == x){
  1968. CTFFlagDown(x);
  1969. }
  1970. CTFTeam[x] = 0;
  1971. CTFKandydat[x] = false;
  1972. TextDrawHideForPlayer(x,CTFtd);
  1973.  
  1974.  
  1975. SetPlayerPos(x,ChowPosX,ChowPosY,ChowPosZ);
  1976. SetPlayerInterior(x,ChInt);
  1977. SetPlayerVirtualWorld(x,2);
  1978.  
  1979. SetPlayerColor(x,0xFFFFFF00);
  1980.  
  1981. ResetPlayerWeapons(x);
  1982. }
  1983. }
  1984.  
  1985. new bla = 0;
  1986. foreach(Player, x){
  1987. if(Chowany[x]){
  1988. bla ++;
  1989. }
  1990. }
  1991.  
  1992. if(bla < 2){
  1993. ChowanyEnd();
  1994. SendClientMessageToAll(COLOR_RED2,"Zabawa w chowanego nie mogła wystartować, zbyt mało chowających się");
  1995. return 1;
  1996. }
  1997.  
  1998. foreach(Player, x){
  1999. if(Szukajacy[x]){
  2000. new string[64];
  2001. format(string, sizeof(string), "Do znalezienia masz %d graczy!!!", bla);
  2002. SendClientMessage(x, COLOR_WHITE, string);
  2003. }
  2004. }
  2005. ChCountLiczba = 31;
  2006. KillTimer(Chtimercount);
  2007. Chtimercount = SetTimer("Count",1000,1);
  2008. Chtimerszuk = SetTimer("Szukaja",31000,0);
  2009.  
  2010.  
  2011. SendClientMessageToAll(COLOR_GREEN,"Zabawa w chowanego Wystartowała!");
  2012. foreach(Player, x)
  2013. {
  2014. if(ChowanyChceTD[x])
  2015. {
  2016. TextDrawShowForPlayer(x, ChowanyTD[0]);
  2017. TextDrawShowForPlayer(x, ChowanyTD[1]);
  2018. for(new i; i < 10; i++)
  2019. TextDrawShowForPlayer(x, ChowanyBack);
  2020. }
  2021. }
  2022.  
  2023. TextDrawSetString(ChowanyTD[1], "~n~");
  2024. return 1;
  2025. }
  2026.  
  2027. forward ChowanyCheck();
  2028. public ChowanyCheck()
  2029. {
  2030. if(!ChWystartowala)
  2031. return 1;
  2032.  
  2033. ChLiczba = 0;
  2034. SzLiczba = 0;
  2035. foreach(Player, x)
  2036. {
  2037. if(Chowany[x])
  2038. ChLiczba++;
  2039. else if(Szukajacy[x])
  2040. SzLiczba++;
  2041. }
  2042.  
  2043. if(ChLiczba == 1){
  2044.  
  2045. foreach(Player, i){
  2046. if(Chowany[i]){
  2047.  
  2048. new string[128];
  2049. new Name[MAX_PLAYER_NAME];
  2050. GetPlayerName(i, Name, sizeof(Name));
  2051. if(logged[i]){
  2052. GameTextForPlayer(i,"respekt~n~~g~+10", 1000, 1);
  2053. Respekt[i] += 10;
  2054. }
  2055.  
  2056. for(new x=0;x<50;x++){
  2057. ChowanyKandydat[x] = -1;
  2058. }
  2059. ChNum = 0;
  2060. WinSound(i);
  2061. format(string, sizeof(string), "%s (%d) Wygrał(a) zabawę w Chowanego !", Name,i);
  2062. SendClientMessageToAll(COLOR_PINK, string);
  2063. KillTimer(Chtimercount);
  2064. KillTimer(Chtimerszuk);
  2065. ChStarted = false;
  2066. ChLiczba = 0;
  2067. ChCountLiczba = 31;
  2068. ChWystartowala = false;
  2069.  
  2070. format(string,sizeof(string),"~r~Zwyciezca!~h~~n~~n~%s (%d)",Name,i);
  2071. TextDrawSetString(ChowanyTD[1],string);
  2072. SetTimer("ChowanyTDoff",7000,0);
  2073.  
  2074. }
  2075. }
  2076. for(new u=0;u<MAX_PLAYERS;u++){
  2077. if(Szukajacy[u] || Chowany[u]){
  2078. ResetPlayerWeapons(u);
  2079. SetPlayerRandomSpawn(u);
  2080. SetPlayerHealth(u,100);
  2081. SetPlayerInterior(u,0);
  2082. SetPlayerVirtualWorld(u,0);
  2083. }
  2084. Chowany[u] = false;
  2085. Szukajacy[u] = false;
  2086. ChowanyZapisany[u] = false;
  2087. }
  2088.  
  2089. return 1;
  2090. }
  2091.  
  2092. if(ChLiczba <= 0 || SzLiczba <= 0){
  2093.  
  2094. for(new x=0;x<50;x++){
  2095. ChowanyKandydat[x] = -1;
  2096. }
  2097. ChNum = 0;
  2098.  
  2099. SendClientMessageToAll(COLOR_RED2,"Chowany zakończony bez zwycięzcy!");
  2100. KillTimer(Chtimercount);
  2101. KillTimer(Chtimerszuk);
  2102. ChLiczba = 0;
  2103. ChWystartowala = false;
  2104. ChStarted = false;
  2105. ChCountLiczba = 31;
  2106. ChowanyTDoff();
  2107. for(new u=0;u<MAX_PLAYERS;u++){
  2108. if(Szukajacy[u] || Chowany[u]){
  2109. ResetPlayerWeapons(u);
  2110. SetPlayerHealth(u,100);
  2111. SetPlayerRandomSpawn(u);
  2112. SetPlayerInterior(u,0);
  2113. SetPlayerVirtualWorld(u,0);
  2114. }
  2115. Chowany[u] = false;
  2116. Szukajacy[u] = false;
  2117. ChowanyZapisany[u] = false;
  2118. }
  2119. }
  2120.  
  2121. new string[64];
  2122. format(string,sizeof(string),"Arena: %d~n~Szukajacych: %d~n~Chowajacych: %d",ChArena,SzLiczba,ChLiczba);
  2123. TextDrawSetString(ChowanyTD[1],string);
  2124.  
  2125. return 1;
  2126. }
  2127.  
  2128.  
  2129. forward ChowanyTDoff();
  2130. public ChowanyTDoff()
  2131. {
  2132. TextDrawHideForAll(ChowanyTD[0]);
  2133. TextDrawHideForAll(ChowanyTD[1]);
  2134. for(new x=0;x<10;x++){
  2135. TextDrawHideForAll(ChowanyBack);
  2136. }
  2137.  
  2138. return 1;
  2139. }
  2140.  
  2141.  
  2142. forward Count();
  2143. public Count()
  2144. {
  2145. ChCountLiczba --;
  2146. new string[128];
  2147. format(string, sizeof(string), "Kryc sie!~n~%d sek.", ChCountLiczba);
  2148. TextDrawSetString(ChowanyTD[1],string);
  2149.  
  2150. if(ChCountLiczba == 0){
  2151. KillTimer(Chtimercount);
  2152. return 1;
  2153. }
  2154.  
  2155. return 1;
  2156. }
  2157.  
  2158.  
  2159.  
  2160. forward Szukaja();
  2161. public Szukaja()
  2162. {
  2163.  
  2164. foreach(Player, x){
  2165. if(Szukajacy[x]){
  2166.  
  2167. RaceMen[x] = false;
  2168. WGTeam[x] = 0;
  2169. WGKandydat[x] = false;
  2170.  
  2171. if(FlageMa == x){
  2172. CTFFlagDown(x);
  2173. }
  2174. CTFTeam[x] = 0;
  2175. CTFKandydat[x] = false;
  2176. TextDrawHideForPlayer(x,CTFtd);
  2177.  
  2178. SetPlayerPos(x,SzukPosX,SzukPosY,SzukPosZ);
  2179. SetPlayerInterior(x,ChInt);
  2180. GivePlayerWeapon(x,38,10000);
  2181. SetPlayerHealth(x,99999);
  2182. SetPlayerVirtualWorld(x,2);
  2183. SetPlayerColor(x,0xFFB591FF);
  2184. }
  2185. if(Chowany[x]){
  2186. SetPlayerVirtualWorld(x,2);
  2187. }
  2188. }
  2189.  
  2190. return 1;
  2191. }
  2192.  
  2193. forward ChowanyAutoEnd();
  2194. public ChowanyAutoEnd()
  2195. {
  2196. SendClientMessageToAll(COLOR_RED2,"Chowany został przerwany przez serwer");
  2197. ChowanyEnd();
  2198. return 1;
  2199. }
  2200.  
  2201. forward ChowanyEnd();
  2202. public ChowanyEnd()
  2203. {
  2204. ChWystartowala = false;
  2205.  
  2206. foreach(Player, x){
  2207. if(Szukajacy[x] || Chowany[x]){
  2208. PlayerSetColor(x);
  2209.  
  2210. ResetPlayerWeapons(x);
  2211. SetPlayerHealth(x,100);
  2212. SetPlayerRandomSpawn(x);
  2213. SetPlayerInterior(x,0);
  2214. SetPlayerVirtualWorld(x,0);
  2215. }
  2216. Chowany[x] = false;
  2217. Szukajacy[x] = false;
  2218. ChowanyZapisany[x] = false;
  2219. }
  2220. ChLiczba = 0;
  2221. ChCountLiczba = 31;
  2222. KillTimer(Chtimercount);
  2223. KillTimer(Chtimerszuk);
  2224. ChowanyTDoff();
  2225.  
  2226. for(new x=0;x<50;x++){
  2227. ChowanyKandydat[x] = -1;
  2228. }
  2229. ChNum = 0;
  2230. ChStarted = false;
  2231.  
  2232. ZapisyUpdate();
  2233.  
  2234. return 1;
  2235. }
  2236.  
  2237.  
  2238. forward ChowanyAreaCheck();
  2239. public ChowanyAreaCheck()
  2240. {
  2241.  
  2242. if(!ChWystartowala) return 1;
  2243.  
  2244. foreach(Player, x){
  2245. if(Chowany[x] || Szukajacy[x]){
  2246.  
  2247.  
  2248. new idx = GetPlayerAnimationIndex(x);
  2249. if(ChCountLiczba <= 0){
  2250. if(!IsPlayerInArea(x,ChAreaX,ChAreaY,ChAreaZ,ChAreaA) && ChInt == 0 || GetPlayerInterior(x) != ChInt || idx == 1538 || idx == 1539 || idx == 1541 || idx == 1544){
  2251.  
  2252. if(AwayCount[x] < 2){
  2253. SendPlayerWarning(x,3000,"Wracaj na teren zabawy w Chowanego!");
  2254. AwayCount[x] ++;
  2255. return 1;
  2256. }
  2257.  
  2258. SendClientMessage(x,COLOR_RED2,"Uciekłeś(aś) poza teren zabawy i zostałeś(aś) zdyskwalifikowany(a)");
  2259. ResetPlayerWeapons(x);
  2260. SetPlayerPos(x, 2140.6675,993.1867,10.5248);
  2261. SetPlayerInterior(x,0);
  2262. SetPlayerVirtualWorld(x,0);
  2263. PlayerSetColor(x);
  2264. SetPlayerHealth(x,100);
  2265.  
  2266. Chowany[x] = false;
  2267. Szukajacy[x] = false;
  2268. ChowanyZapisany[x] = false;
  2269. AwayCount[x] = 0;
  2270. }else{
  2271. AwayCount[x] = 0;
  2272. }
  2273. }
  2274. }
  2275. }
  2276. return 1;
  2277. }
  2278. forward WGPlayerEnd(playerid);
  2279. public WGPlayerEnd(playerid)
  2280. {
  2281.  
  2282. WGTeam[playerid] = 0;
  2283. WGKandydat[playerid] = false;
  2284. PlayerSetColor(playerid);
  2285. SetPlayerInterior(playerid,0);
  2286. SetPlayerVirtualWorld(playerid,0);
  2287. SetPlayerTeam(playerid,playerid+10);
  2288.  
  2289. return 1;
  2290. }
  2291.  
  2292. forward WGoff();
  2293. public WGoff()
  2294. {
  2295. KillTimer(WGTimer);
  2296. foreach(Player, x){
  2297. WGGlos[x] = false;
  2298. if(WGTeam[x] == 1 || WGTeam[x] == 2){
  2299. PlayerSetColor(x);
  2300. SetPlayerRandomSpawn(x);
  2301. SetPlayerInterior(x,0);
  2302. SetPlayerVirtualWorld(x,0);
  2303. }
  2304. SetPlayerTeam(x,x+10);
  2305. WGTeam[x] = 0;
  2306. WGKandydat[x] = false;
  2307. }
  2308. WGLiczba = 0;
  2309. WGTeamLiczba[1] = 0;
  2310. WGTeamLiczba[2] = 0;
  2311. WGON = false;
  2312. WGStarted = false;
  2313. GangZoneHideForAll(ArenaZone);
  2314. ZapisyUpdate();
  2315.  
  2316. return 1;
  2317. }
  2318.  
  2319. forward WGPlayerCheck();
  2320. public WGPlayerCheck()
  2321. {
  2322.  
  2323. if(!WGON) return 1;
  2324.  
  2325. foreach(Player, x){
  2326. if(WGTeam[x] > 0){
  2327.  
  2328. if(InteriorWG == 0){
  2329. if(!IsPlayerInArea(x,WGAreaX,WGAreaY,WGAreaZ,WGAreaA)){
  2330. WGAwayCount[x] ++;
  2331. SendPlayerWarning(x,3000,"Wracaj na teren Wojny Gangow!");
  2332. if(WGAwayCount[x] >= 3){
  2333. WGPlayerEnd(x);
  2334. SetPlayerRandomSpawn(x);
  2335. SendClientMessage(x,COLOR_RED2,"Uciekłeś(aś) właśnie z Wojny Gangów!");
  2336. }
  2337. }
  2338. }
  2339.  
  2340. if(InteriorWG != 0){
  2341. if(GetPlayerInterior(x) != InteriorWG){
  2342. WGAwayCount[x] ++;
  2343. SendPlayerWarning(x,3000,"Wracaj na teren Wojny Gangow!");
  2344. if(WGAwayCount[x] >= 3){
  2345. WGPlayerEnd(x);
  2346. SetPlayerRandomSpawn(x);
  2347. SendClientMessage(x,COLOR_RED2,"Uciekłeś(aś) właśnie z Wojny Gangów!");
  2348. }
  2349. }
  2350. }
  2351.  
  2352. new weap = GetPlayerWeapon(x);
  2353. if(weap != 0 && weap != 24 && weap != 25 && weap != 34 && weap != 4){
  2354. SendClientMessage(x,COLOR_RED2,"Ta broń jest niedozwolona na WG!");
  2355. ResetPlayerWeapons(x);
  2356. GivePlayerWeapon(x,4,1);
  2357. GivePlayerWeapon(x,24,3000);
  2358. GivePlayerWeapon(x,25,3000);
  2359. GivePlayerWeapon(x,34,3000);
  2360. }
  2361. }
  2362. }
  2363.  
  2364. return 1;
  2365. }
  2366.  
  2367. forward WGEndCheck();
  2368. public WGEndCheck()
  2369. {
  2370.  
  2371. if(!WGON) return 1;
  2372.  
  2373. WGTeamLiczba[1] = 0;
  2374. WGTeamLiczba[2] = 0;
  2375. WGLiczba = 0;
  2376.  
  2377. foreach(Player, x){
  2378. if(WGTeam[x] == 1){
  2379. WGTeamLiczba[1] ++;
  2380. WGLiczba ++;
  2381. }
  2382. if(WGTeam[x] == 2){
  2383. WGTeamLiczba[2] ++;
  2384. WGLiczba ++;
  2385. }
  2386. }
  2387.  
  2388. if(WGLiczba <= 0){
  2389. WGoff();
  2390. // SendClientMessageToAll(COLOR_RED2,"Wojna gangów przerwana automatycznie");
  2391. return 1;
  2392. }
  2393.  
  2394. if(WGON && WGTeamLiczba[1] == 0 || WGTeamLiczba[2] == 0){
  2395.  
  2396.  
  2397. if(WGTeamLiczba[1] == WGTeamLiczba[2]){
  2398. SendClientMessageToAll(0x008080FF,"Mamy Remis na Wojnie Gangów!");
  2399. WGoff();
  2400. return 1;
  2401. }
  2402.  
  2403. if(WGTeamLiczba[1] > WGTeamLiczba[2]){
  2404. SendClientMessageToAll(0x0080FF64,"Wojne Gangów wygrywają Niebiescy");
  2405. foreach(Player, x){
  2406. if(IsPlayerConnected(x) && WGTeam[x] == 1){
  2407. WinSound(x);
  2408. if(logged[x]){
  2409. Respekt[x] += 5;
  2410. GameTextForPlayer(x,"respekt~n~~g~+5", 1000, 1);
  2411. }
  2412. }
  2413. }
  2414. WGoff();
  2415. return 1;
  2416. }
  2417.  
  2418. if(WGTeamLiczba[1] < WGTeamLiczba[2]){
  2419. SendClientMessageToAll(0x00FF0064,"Wojne Gangów wygrywają Zieloni");
  2420. foreach(Player, x){
  2421. if(WGTeam[x] == 2){
  2422. WinSound(x);
  2423. if(logged[x]){
  2424. Respekt[x] += 5;
  2425. GameTextForPlayer(x,"respekt~n~~g~+5", 1000, 1);
  2426. }
  2427. }
  2428. }
  2429. WGoff();
  2430. return 1;
  2431. }
  2432. }
  2433.  
  2434. return 1;
  2435. }
  2436.  
  2437. forward WGStart();
  2438. public WGStart()
  2439. {
  2440. new Rand = random(18);
  2441.  
  2442. new tmp[256];
  2443. new string[32];
  2444. new Float:Team1SpawnX,Float:Team1SpawnY,Float:Team1SpawnZ;
  2445. new Float:Team2SpawnX,Float:Team2SpawnY,Float:Team2SpawnZ;
  2446.  
  2447. format(string,sizeof(string),"PXS/WojnaGangow/%d.ini",Rand);
  2448.  
  2449. if(!fexist(string)) {
  2450. WGStart();
  2451. return 1;
  2452. }
  2453.  
  2454. tmp = dini_Get(string,"spawn1");
  2455. new e;
  2456. new f;
  2457. new g;
  2458. Team1SpawnX = floatstr(strtok(tmp,e,','));
  2459. Team1SpawnY = floatstr(strtok(tmp,e,','));
  2460. Team1SpawnZ = floatstr(strtok(tmp,e,','));
  2461. tmp = dini_Get(string,"spawn2");
  2462. Team2SpawnX = floatstr(strtok(tmp,f,','));
  2463. Team2SpawnY = floatstr(strtok(tmp,f,','));
  2464. Team2SpawnZ = floatstr(strtok(tmp,f,','));
  2465.  
  2466. tmp = dini_Get(string,"area");
  2467. WGAreaX = floatstr(strtok(tmp,g,','));
  2468. WGAreaY = floatstr(strtok(tmp,g,','));
  2469. WGAreaZ = floatstr(strtok(tmp,g,','));
  2470. WGAreaA = floatstr(strtok(tmp,g,','));
  2471.  
  2472. ArenaZone = GangZoneCreate(WGAreaX,WGAreaZ,WGAreaY,WGAreaA);
  2473. GangZoneShowForAll(ArenaZone,0x8080FF77);
  2474.  
  2475. tmp = dini_Get(string,"interior");
  2476. InteriorWG = strval(tmp);
  2477.  
  2478. WGLiczba = 0;
  2479.  
  2480. SendClientMessageToAll(0x008080FF,"Wojna Gangów Rozpoczęta!");
  2481. WGON = true;
  2482.  
  2483. foreach(Player, x){
  2484. if(WGKandydat[x]){
  2485. WGAwayCount[x] = 0;
  2486. ResetPlayerWeapons(x);
  2487. GivePlayerWeapon(x,4,1);
  2488. GivePlayerWeapon(x,24,1000);
  2489. GivePlayerWeapon(x,25,200);
  2490. GivePlayerWeapon(x,34,1000);
  2491. SetPlayerHealth(x,100);
  2492. SetPlayerArmour(x,0);
  2493.  
  2494. WGTeam[x] = 1;
  2495. SetPlayerTeam(x,1);
  2496.  
  2497. SetPlayerColor(x,0x0080FFFF);
  2498.  
  2499. SetPlayerInterior(x,InteriorWG);
  2500. SetPlayerVirtualWorld(x,8);
  2501. new randx = random(10);
  2502. new randy = random(10);
  2503.  
  2504. SetPlayerPos(x,Team1SpawnX-5+randx,Team1SpawnY-5+randy,Team1SpawnZ);
  2505. TogglePlayerControllable(x,0);
  2506. SetTimerEx("JailUnfreeze",2000,0,"i",x);
  2507.  
  2508. WGTeamLiczba[1] ++;
  2509.  
  2510. if(WGTeamLiczba[1] > WGTeamLiczba[2]){
  2511.  
  2512. WGTeam[x] = 2;
  2513. SetPlayerTeam(x,2);
  2514.  
  2515. SetPlayerColor(x,0x00D900FF);
  2516.  
  2517. SetPlayerInterior(x,InteriorWG);
  2518. SetPlayerVirtualWorld(x,8);
  2519.  
  2520. SetPlayerPos(x,Team2SpawnX-5+randx,Team2SpawnY-5+randy,Team2SpawnZ);
  2521. TogglePlayerControllable(x,0);
  2522. SetTimerEx("JailUnfreeze",2000,0,"i",x);
  2523.  
  2524. WGTeamLiczba[2] ++;
  2525. WGTeamLiczba[1] --;
  2526.  
  2527. }
  2528. }
  2529. }
  2530.  
  2531. ZapisyUpdate();
  2532.  
  2533. return 1;
  2534. }
  2535.  
  2536. public OnPlayerConnect(playerid)
  2537. {
  2538. DerbyMen[playerid] = false;
  2539. DerbyZaglosowal[playerid] = false;
  2540. FSTag[playerid] = false;
  2541. Strzelnica[playerid] = false;
  2542. StrzelnicaSniper[playerid] = false;
  2543. StrzelnicaZaglosowal[playerid] = false;
  2544. Skoczek[playerid] = false;
  2545. ColorwZaglosowal[playerid] = false;
  2546. ColorwMen[playerid] = false;
  2547. SkoczekZaglosowa[playerid] = false;
  2548. SianoMen[playerid] = false;
  2549. SianoZaglosowal[playerid] = false;
  2550. CTFTeam[playerid] = 0;
  2551. CTFKandydat[playerid] = false;
  2552. CTFGlos[playerid] = false;
  2553. ChowanyZapisany[playerid] = false;
  2554. ChceAnn[playerid] = true;
  2555. ChowanyChceTD[playerid] = true;
  2556. WGGlos[playerid] = false;
  2557. TowerMen[playerid] = false;
  2558. TowerZaglosowal[playerid] = false;
  2559. RaceMen[playerid] = false;
  2560. RaceCheck[playerid] = 0;
  2561. Chowany[playerid] = false;
  2562. Szukajacy[playerid] = false;
  2563. WGKandydat[playerid] = false;
  2564. WGTeam[playerid] = 0;
  2565. HayMen[playerid] = false;
  2566. HayZaglosowal[playerid] = false;
  2567. return 1;
  2568. }
  2569.  
  2570.  
  2571. public OnPlayerDisconnect(playerid, reason)
  2572. {
  2573. Chowany[playerid] = false;
  2574. Szukajacy[playerid] = false;
  2575. WGTeam[playerid] = 0;
  2576. SianoZaglosowal[playerid] = false;
  2577. SianoMen[playerid] = false;
  2578. WGKandydat[playerid] = false;
  2579. TowerMen[playerid] = false;
  2580. TowerZaglosowal[playerid] = false;
  2581. PaintbMen[playerid] = false;
  2582. PaintbZaglosowal[playerid] = false;
  2583. ColorwMen[playerid] = false;
  2584. ColorwZaglosowal[playerid] = false;
  2585. HayMen[playerid] = false;
  2586. HayZaglosowal[playerid] = false;
  2587.  
  2588.  
  2589. if(Strzelnica[playerid] && StrzelnicaON)
  2590. Strzelnica[playerid] = false;
  2591. StrzelnicaSniper[playerid] = false;
  2592. new StrzLicz, SnipLicz;
  2593.  
  2594. foreach(Player, x)
  2595. {
  2596. if(!StrzelnicaSniper[x] && Strzelnica[x])
  2597. StrzLicz++;
  2598. else if(StrzelnicaSniper[x])
  2599. SnipLicz++;
  2600. }
  2601.  
  2602. if(StrzLicz <= 1)
  2603. {
  2604. foreach(Player, x)
  2605. {
  2606. if(!StrzelnicaSniper[x] && Strzelnica[x])
  2607. {
  2608. new str[80];
  2609. format(str, sizeof(str), "Na strzelnicy najdłużej wytrzymał(a) %s", PlayerName(x));
  2610. SendClientMessageToAll(0x8080C0FF,str);
  2611. WinSound(x);
  2612. if(logged[x])
  2613. {
  2614. GameTextForPlayer(x, "respekt~n~~g~+7", 1000, 1);
  2615. Respekt[x] += 7;
  2616. }
  2617. }
  2618. }
  2619. StrzelnicaEnd();
  2620. }
  2621. else if(SnipLicz <= 0)
  2622. {
  2623. SendClientMessageToAll(COLOR_RED2, "Strzelnica przerwana z powodu braku strzelca");
  2624. StrzelnicaEnd();
  2625. }
  2626. }
  2627. return 1;
  2628. }
  2629.  
  2630. public OnPlayerCommandReceived(playerid, cmdtext[])
  2631. {
  2632. if(strfind(cmdtext,"/rsp",true) == 0) return 1;
  2633. if(strfind(cmdtext,"/flo",true) == 0) return 1;
  2634. if(strfind(cmdtext,"/pm",true) == 0) return 1;
  2635. if(strfind(cmdtext,"/raport",true) == 0) return 1;
  2636. if(strfind(cmdtext,"/toadmin",true) == 0) return 1;
  2637.  
  2638. if(Chowany[playerid] || Szukajacy[playerid] && ChWystartowala){
  2639. if(strfind(cmdtext,"/chexit",true) == 0) return 1;
  2640. SendClientMessage(playerid,COLOR_RED2,"Na Chowanym nie można używać komend, wyjątek: /CHexit");
  2641. return 0;
  2642. }
  2643.  
  2644. if(Strzelnica[playerid] && StrzelnicaON){
  2645. if(strfind(cmdtext,"/strzelnicaexit",true) == 0) return 1;
  2646. SendClientMessage(playerid,COLOR_RED2,"Na Strzelnicy nie można używać komend, wyjątek: /StrzelnicaExit");
  2647. return 0;
  2648. }
  2649.  
  2650. if(DerbyMen[playerid] && DerbyON){
  2651. if(strfind(cmdtext,"/derbyexit",true) == 0) return 1;
  2652. SendClientMessage(playerid,COLOR_RED2,"Na Derbach nie można używać komend, wyjątek: /DerbyExit");
  2653. return 0;
  2654. }
  2655.  
  2656.  
  2657.  
  2658. if(SianoMen[playerid] && SianoON){
  2659. if(strfind(cmdtext,"/snexit",true) == 0) return 1;
  2660. SendClientMessage(playerid,COLOR_RED,"Na Siano nie można używać komend, wyjątek: /SNexit");
  2661. return 0;
  2662. }
  2663.  
  2664.  
  2665.  
  2666. if(HayMen[playerid] && HayON){
  2667. if(strfind(cmdtext,"/hayexit",true) == 0) return 1;
  2668. SendClientMessage(playerid,COLOR_RED,"Na Hay nie można używać komend, wyjątek: /hayexit");
  2669. return 0;
  2670. }
  2671.  
  2672. if(PaintbMen[playerid] && PaintbON){
  2673. if(strfind(cmdtext,"/pbexit",true) == 0) return 1;
  2674. SendClientMessage(playerid,COLOR_RED,"Na PaintBall nie można używać komend, wyjątek: /PBexit");
  2675. return 0;
  2676. }
  2677.  
  2678. if(ColorwMen[playerid] && ColorwON){
  2679. if(strfind(cmdtext,"/cwexit",true) == 0) return 1;
  2680. SendClientMessage(playerid,COLOR_RED,"Na Color Wars nie można używać komend, wyjątek: /CWexit");
  2681. return 0;
  2682. }
  2683.  
  2684. if(TowerMen[playerid] && TowerON){
  2685. if(strfind(cmdtext,"/trexit",true) == 0) return 1;
  2686. SendClientMessage(playerid,COLOR_RED,"Na Tower nie można używać komend, wyjątek: /TRexit");
  2687. return 0;
  2688. }
  2689.  
  2690. if(WGTeam[playerid] == 1 || WGTeam[playerid] == 2){
  2691. if(strfind(cmdtext,"/wgexit",true) == 0) return 1;
  2692. SendClientMessage(playerid,COLOR_RED2,"Na Wojnie Gangów nie można używać komend, wyjątek: /WGexit");
  2693. return 0;
  2694. }
  2695.  
  2696.  
  2697. if(CTFTeam[playerid] == 1 || CTFTeam[playerid] == 2){
  2698. if(strfind(cmdtext,"/ctfexit",true) == 0) return 1;
  2699. SendClientMessage(playerid,COLOR_RED2,"Na Capture The Flag nie można używać komend, wyjątek: /CTFexit");
  2700. return 0;
  2701. }
  2702.  
  2703. if(Labirynt[playerid]){
  2704. if(strfind(cmdtext,"/labiryntexit",true) == 0) return 1;
  2705. SendClientMessage(playerid,COLOR_RED2,"W labiryncie nie można używać komend, wyjątek: /LabiryntExit");
  2706. return 0;
  2707. }
  2708.  
  2709. if(RaceWystartowal && RaceMen[playerid] || Drager[playerid]){
  2710. if(strfind(cmdtext,"/nos",true) == 0) return 1;
  2711. if(strfind(cmdtext,"/napraw",true) == 0) return 1;
  2712. if(strfind(cmdtext,"/flip",true) == 0) return 1;
  2713. if(strfind(cmdtext,"/raceexit",true) == 0) return 1;
  2714. SendClientMessage(playerid, COLOR_RED2, "Na wyścigu nie można używać komend, wyjątki: /RaceExit /Napraw /Nos /Flip");
  2715. return 0;
  2716. }
  2717. }
  2718.  
  2719. return 1;
  2720. }
  2721.  
  2722. public OnPlayerSpawn(playerid)
  2723. {
  2724. if(CTFTeam[playerid] > 0){
  2725. CTFSpawn(playerid);
  2726. return 1;
  2727. }
  2728. return 1;
  2729. }
  2730. public OnPlayerDeath(playerid, killerid, reason)
  2731. {
  2732.  
  2733. if(RaceWystartowal){
  2734. RaceMen[playerid] = false;
  2735. }
  2736.  
  2737. if(DerbyON){
  2738. DerbyMen[playerid] = false;
  2739. }
  2740.  
  2741.  
  2742.  
  2743. if(SianoON){
  2744. SianoMen[playerid] = false;
  2745. }
  2746.  
  2747. if(HayON){
  2748. HayMen[playerid] = false;
  2749. }
  2750.  
  2751. if(PaintbON){
  2752. PaintbMen[playerid] = false;
  2753. }
  2754.  
  2755. if(ColorwON){
  2756. ColorwMen[playerid] = false;
  2757. }
  2758.  
  2759. if(TowerON){
  2760. TowerMen[playerid] = false;
  2761. }
  2762.  
  2763. if(FlageMa == playerid){
  2764. CTFFlagDown(playerid);
  2765. SendClientMessage(playerid,COLOR_RED2,"Flag Down!");
  2766. }
  2767.  
  2768. if(WGTeam[playerid] > 0){
  2769. WGPlayerEnd(playerid);
  2770. return 1;
  2771. }
  2772.  
  2773.  
  2774.  
  2775. if(ChWystartowala){
  2776. if(Chowany[killerid] || Chowany[playerid]){
  2777. Chowany[playerid] = false;
  2778. SetPlayerPos(playerid, 2140.6675,993.1867,10.5248);
  2779. PlayerSetColor(playerid);
  2780. if(Chowany[killerid]){
  2781. Chowany[killerid] = false;
  2782. SendClientMessage(killerid,COLOR_RED2,"Zostałeś(aś) usunięty(a) z zabawy za zabijanie!");
  2783. SetPlayerPos(playerid, 2140.6675,993.1867,10.5248);
  2784. PlayerSetColor(playerid);
  2785. }
  2786. return 1;
  2787. }
  2788. }
  2789.  
  2790. if(StrzelnicaON && Strzelnica[playerid]){
  2791.  
  2792. Strzelnica[playerid] = false;
  2793. StrzelnicaSniper[playerid] = false;
  2794. new StrzLicz,SnipLicz;
  2795.  
  2796. foreach(Player, x){
  2797. if(!StrzelnicaSniper[x] && Strzelnica[x] && IsPlayerConnected(x)){
  2798. StrzLicz ++;
  2799. }
  2800. if(StrzelnicaSniper[x] && IsPlayerConnected(x)){
  2801. SnipLicz ++;
  2802. }
  2803. }
  2804.  
  2805. if(StrzLicz <= 1){
  2806. foreach(Player, x){
  2807. if(!StrzelnicaSniper[x] && Strzelnica[x] && IsPlayerConnected(x)){
  2808. new str[80];
  2809. format(str,sizeof(str),"Na strzelnicy najdłużej wytrzymał(a) %s",PlayerName(x));
  2810. SendClientMessageToAll(0x8080C0FF,str);
  2811. WinSound(x);
  2812. if(logged[x]){
  2813. GameTextForPlayer(x,"respekt~n~~g~+7", 1000, 1);
  2814. Respekt[x] += 7;
  2815. }
  2816. }
  2817. }
  2818. StrzelnicaEnd();
  2819. }
  2820. else if(SnipLicz <= 0){
  2821. SendClientMessageToAll(COLOR_RED2,"Strzelnica przerwana z powodu braku strzelca");
  2822. StrzelnicaEnd();
  2823. }
  2824. return 1;
  2825. }
  2826. return 1;
  2827. }
  2828.  
  2829. public OnPlayerEnterRaceCheckpoint(playerid)
  2830. {
  2831.  
  2832. if(CTFTeam[playerid] > 0 && !Drager[playerid] && !RaceMen[playerid]){
  2833.  
  2834. if(FlageMa < 0){
  2835. AttachObjectToPlayer(flaga, playerid, 1.5, 0.2, 0, 0, 1.5, 2 );
  2836. SetPlayerHealth(playerid,10);
  2837. FlageMa = playerid;
  2838.  
  2839. if(CTFTeam[playerid] == 1)
  2840. {
  2841. for(new x; x <MAX_PLAYERS; x++){
  2842. if(CTFTeam[x] > 0){
  2843. AnnForPlayer(x,3000,"~b~~h~~h~Niebiescy przejmuja flage!");
  2844. DisablePlayerRaceCheckpoint(x);
  2845. }
  2846. }
  2847. SetPlayerRaceCheckpoint (playerid, 2, CTFSpawnPos[0][0],CTFSpawnPos[0][1],CTFSpawnPos[0][2],CTFSpawnPos[0][0],CTFSpawnPos[0][1],CTFSpawnPos[0][2], 2);
  2848. }
  2849. else if(CTFTeam[playerid] == 2)
  2850. {
  2851. for(new x; x <MAX_PLAYERS; x++){
  2852. if(CTFTeam[x] > 0){
  2853. AnnForPlayer(x,3000,"~g~Zieloni przejmuja flage!");
  2854. DisablePlayerRaceCheckpoint(x);
  2855. }
  2856. }
  2857. SetPlayerRaceCheckpoint (playerid, 2, CTFSpawnPos[1][0],CTFSpawnPos[1][1],CTFSpawnPos[1][2],CTFSpawnPos[1][0],CTFSpawnPos[1][1],CTFSpawnPos[1][2], 2);
  2858. }
  2859. return 1;
  2860. }
  2861.  
  2862. if(FlageMa == playerid){
  2863. DestroyObject(flaga);
  2864. SetTimer("RespawnFlaga",7000,0);
  2865. FlageMa = -1;
  2866. SetPlayerHealth(playerid,100);
  2867.  
  2868. foreach(Player, x){
  2869. if(CTFTeam[x] > 0){
  2870. DisablePlayerRaceCheckpoint(x);
  2871. AnnForPlayer(x,3000,"~y~Respawn Flagi za kilka sekund!");
  2872. }
  2873. }
  2874.  
  2875. if(CTFTeam[playerid] == 1){
  2876. CTFScore[0] ++;
  2877. if(CTFScore[0] >= 3){
  2878. CTFEndWin(0);
  2879. }
  2880.  
  2881. }else if(CTFTeam[playerid] == 2){
  2882. CTFScore[1] ++;
  2883. if(CTFScore[1] >= 3){
  2884. CTFEndWin(1);
  2885. }
  2886. }
  2887. }
  2888. return 1;
  2889. }
  2890.  
  2891. if(RaceMen[playerid] && !Drager[playerid] && CTFTeam[playerid] == 0){
  2892.  
  2893. new bla = RaceCheck[playerid];
  2894. Pozycja[bla] ++;
  2895. RaceCheck[playerid] ++;
  2896.  
  2897. ActualPos[playerid] = Pozycja[bla];
  2898.  
  2899. RaceMenLiczba = 0;
  2900. foreach(Player, x){
  2901. if(RaceMen[x]){
  2902. RaceMenLiczba ++;
  2903. }
  2904. }
  2905.  
  2906. if(RaceCheck[playerid] == CPliczba){
  2907. new string[100];
  2908. new name[MAX_PLAYER_NAME];
  2909. GetPlayerName(playerid,name,sizeof(name));
  2910. MiejsceMeta ++;
  2911. format(string,sizeof(string),"%s id(%d) dotarł(a) na mete wyścigu | %d Miejsce",name,playerid,MiejsceMeta);
  2912. if(MiejsceMeta == 1){
  2913.  
  2914. if(logged[playerid]){
  2915. GameTextForPlayer(playerid,"respekt~n~~g~+10", 1000, 1);
  2916. Respekt[playerid] += 10;
  2917. }
  2918.  
  2919. }
  2920. if(MiejsceMeta == 2){
  2921.  
  2922. if(logged[playerid]){
  2923. GameTextForPlayer(playerid,"respekt~n~~g~+5", 1000, 1);
  2924. Respekt[playerid] += 5;
  2925. }
  2926.  
  2927. }
  2928. if(MiejsceMeta == 3){
  2929.  
  2930. if(logged[playerid]){
  2931. GameTextForPlayer(playerid,"respekt~n~~g~+2", 1000, 1);
  2932. Respekt[playerid] += 2;
  2933. }
  2934.  
  2935. }
  2936. foreach(Player, x){
  2937. if(PlayerToPoint(100,x,CPx[CPliczba-1],CPy[CPliczba-1],CPz[CPliczba-1]) || RaceMen[x]){
  2938. SendClientMessage(x,0xFF00FFFF,string);
  2939. }
  2940. }
  2941. RaceMen[playerid] = false;
  2942. DisablePlayerRaceCheckpoint(playerid);
  2943. DestroyVehicle(GetPlayerVehicleID(playerid));
  2944. WinSound(playerid);
  2945.  
  2946. if(RaceMenLiczba <= 2){
  2947. SendClientMessageToAll(COLOR_GREEN,"Wyścig zakończony!");
  2948. TotalRaceEnd();
  2949. }
  2950.  
  2951. return 1;
  2952. }
  2953.  
  2954.  
  2955. if(RaceCheck[playerid] == CPliczba-1){
  2956. PlayerPlaySound(playerid, 1139, 0, 0, 0);
  2957. SetPlayerRaceCheckpoint(playerid,CPType+1,CPx[RaceCheck[playerid]],CPy[RaceCheck[playerid]],CPz[RaceCheck[playerid]],CPx[RaceCheck[playerid]],CPy[RaceCheck[playerid]],CPz[RaceCheck[playerid]],CPSize);
  2958. }else{
  2959. PlayerPlaySound(playerid, 1139, 0, 0, 0);
  2960. SetPlayerRaceCheckpoint(playerid,CPType,CPx[RaceCheck[playerid]],CPy[RaceCheck[playerid]],CPz[RaceCheck[playerid]],CPx[RaceCheck[playerid]+1],CPy[RaceCheck[playerid]+1],CPz[RaceCheck[playerid]+1],CPSize);
  2961. }
  2962.  
  2963. return 1;
  2964. }
  2965.  
  2966.  
  2967. if(Drager[playerid] && !RaceMen[playerid] && CTFTeam[playerid] == 0){
  2968. DragCheck[playerid] ++;
  2969. PlayerPlaySound(playerid,1057,0,0,0);
  2970.  
  2971. if(DragCheck[playerid] == 1){
  2972. if(Drager1[playerid]){
  2973. SetPlayerRaceCheckpoint(playerid,0,848.0184,-1392.2720,13.1114,966.4977,-1392.7513,12.8072,5);
  2974.  
  2975. }else if(Drager2[playerid]){
  2976. SetPlayerRaceCheckpoint(playerid,0,848.2114,-1397.7303,12.7792,966.8767,-1398.0573,12.7047,5);
  2977.  
  2978. }else if(Drager3[playerid]){
  2979. SetPlayerRaceCheckpoint(playerid,0,848.5390,-1402.8962,13.1847,967.2685,-1402.6027,13.0538,5);
  2980.  
  2981. }else if(Drager4[playerid]){
  2982. SetPlayerRaceCheckpoint(playerid,0,848.4573,-1408.2458,12.9308,965.1777,-1408.0708,12.8785,5);
  2983.  
  2984. }
  2985.  
  2986. }
  2987.  
  2988. if(DragCheck[playerid] == 2){
  2989. if(Drager1[playerid]){
  2990. SetPlayerRaceCheckpoint(playerid,0,966.4977,-1392.7513,12.8072,1091.8967,-1392.9240,13.2658,5);
  2991. }else if(Drager2[playerid]){
  2992. SetPlayerRaceCheckpoint(playerid,0,966.8767,-1398.0573,12.7047,1092.4669,-1398.4116,13.0968,5);
  2993.  
  2994. }else if(Drager3[playerid]){
  2995. SetPlayerRaceCheckpoint(playerid,0,967.2685,-1402.6027,13.0538,1093.7964,-1402.9365,13.3639,5);
  2996.  
  2997. }else if(Drager4[playerid]){
  2998. SetPlayerRaceCheckpoint(playerid,0,965.1777,-1408.0708,12.8785,1093.6565,-1407.8411,13.1829,5);
  2999.  
  3000. }
  3001.  
  3002. }
  3003.  
  3004. if(DragCheck[playerid] == 3){
  3005. if(Drager1[playerid]){
  3006. SetPlayerRaceCheckpoint(playerid,0,1091.8967,-1392.9240,13.2658,1225.4003,-1392.8851,12.9379,5);
  3007. }else if(Drager2[playerid]){
  3008. SetPlayerRaceCheckpoint(playerid,0,1092.4669,-1398.4116,13.0968,1225.0206,-1397.9462,12.7785,5);
  3009.  
  3010. }else if(Drager3[playerid]){
  3011. SetPlayerRaceCheckpoint(playerid,0,1093.7964,-1402.9365,13.3639,1224.3564,-1403.2108,13.0298,5);
  3012.  
  3013. }else if(Drager4[playerid]){
  3014. SetPlayerRaceCheckpoint(playerid,0,1093.6565,-1407.8411,13.1829,1226.7388,-1407.6307,12.8202,5);
  3015.  
  3016. }
  3017.  
  3018. }
  3019.  
  3020.  
  3021. if(DragCheck[playerid] == 4){
  3022. if(Drager1[playerid]){
  3023. SetPlayerRaceCheckpoint(playerid,0,1225.4003,-1392.8851,12.9379,1335.0629,-1393.2385,13.1205,5);
  3024.  
  3025. }else if(Drager2[playerid]){
  3026. SetPlayerRaceCheckpoint(playerid,0,1225.0206,-1397.9462,12.7785,1335.0239,-1398.0027,12.9679,5);
  3027.  
  3028. }else if(Drager3[playerid]){
  3029. SetPlayerRaceCheckpoint(playerid,0,1224.3564,-1403.2108,13.0298,1335.1765,-1403.1411,13.2389,5);
  3030.  
  3031. }else if(Drager4[playerid]){
  3032. SetPlayerRaceCheckpoint(playerid,0,1226.7388,-1407.6307,12.8202,1335.2096,-1407.9459,13.0682,5);
  3033.  
  3034. }
  3035.  
  3036. }
  3037.  
  3038.  
  3039. if(DragCheck[playerid] == 5){
  3040. if(Drager1[playerid]){
  3041. SetPlayerRaceCheckpoint(playerid,1,1335.0629,-1393.2385,13.1205,1335.0629,-1393.2385,13.1205,5);
  3042.  
  3043. }else if(Drager2[playerid]){
  3044. SetPlayerRaceCheckpoint(playerid,1,1335.0239,-1398.0027,12.9679,1335.0239,-1398.0027,12.9679,5);
  3045.  
  3046. }else if(Drager3[playerid]){
  3047. SetPlayerRaceCheckpoint(playerid,1,1335.1765,-1403.1411,13.2389,1335.1765,-1403.1411,13.2389,5);
  3048.  
  3049. }else if(Drager4[playerid]){
  3050. SetPlayerRaceCheckpoint(playerid,1,1335.2096,-1407.9459,13.0682,1335.2096,-1407.9459,13.0682,5);
  3051.  
  3052. }
  3053.  
  3054. }
  3055.  
  3056. if(DragCheck[playerid] == 6){
  3057. DragMiejsce ++;
  3058.  
  3059. new Bla = GetTickCount();
  3060. new Bla2 = Bla-DragTick[playerid];
  3061. new string[70];
  3062. format(string, sizeof(string), "[Drag] %s Dojechał(a) na mete! > %d miejsce < (%d:%03d)",PlayerName(playerid),DragMiejsce,Bla2/1000,Bla2-((Bla2/1000)*1000));
  3063. SendClientMessageToAllDrag(0x0080FFFF,string);
  3064. Drager[playerid] = false;
  3065. DragCheck[playerid] = 0;
  3066. Drager1[playerid] = false;
  3067. Drager2[playerid] = false;
  3068. Drager3[playerid] = false;
  3069. Drager4[playerid] = false;
  3070. DisablePlayerRaceCheckpoint(playerid);
  3071.  
  3072. if(Bla2 >= 12500){
  3073.  
  3074. if(DragTime[playerid] > Bla2){
  3075. DragTime[playerid] = Bla2;
  3076. SendClientMessage(playerid,COLOR_GREEN,"Poprawiłeś(aś) swój rekordowy czas na Dragu!");
  3077. }
  3078.  
  3079. }else{
  3080. SendClientMessage(playerid,COLOR_RED2,"Twój czas wydaje się nieosiągalny i nie jest brany pod uwagę!");
  3081. }
  3082.  
  3083. SetTimerEx("DragTeleport",3000,0,"i",playerid);
  3084.  
  3085. if(DragMiejsce == 1){
  3086. WinSound(playerid);
  3087. GivePlayerMoney(playerid,10000);
  3088. Money[playerid] += 10000;
  3089. if(logged[playerid]){
  3090. GameTextForPlayer(playerid,"respekt~n~~g~+2", 1000, 1);
  3091. Respekt[playerid] += 2;
  3092. }
  3093.  
  3094. }
  3095.  
  3096. if(DragMiejsce == 2){
  3097. GivePlayerMoney(playerid,5000);
  3098. Money[playerid] += 5000;
  3099. }
  3100.  
  3101. if(DragMiejsce == 3){
  3102. GivePlayerMoney(playerid,2500);
  3103. Money[playerid] += 2500;
  3104. }
  3105.  
  3106. if(DragMiejsce == 4){
  3107. GivePlayerMoney(playerid,1000);
  3108. Money[playerid] += 1000;
  3109. }
  3110.  
  3111. if(DragMiejsce >= 4 || DragMiejsce >= Dragliczba){
  3112.  
  3113. DragON = false;
  3114. DragMiejsce = 0;
  3115. Dragliczba = 0;
  3116. KillTimer(DragTimer);
  3117. foreach(Player, x){
  3118. if(Drager[x]){
  3119. DisablePlayerCheckpoint(x);
  3120. DisablePlayerRaceCheckpoint(x);
  3121. Drager[x] = false;
  3122. Drager1[x] = false;
  3123. Drager2[x] = false;
  3124. Drager3[x] = false;
  3125. Drager4[x] = false;
  3126. DragCheck[x] = 0;
  3127. }
  3128. }
  3129.  
  3130. }
  3131. }
  3132. return 1;
  3133. }
  3134. return 1;
  3135. }
  3136.  
  3137. public OnPlayerEnterCheckpoint(playerid)
  3138. {
  3139. if(LabON && Labirynt[playerid])
  3140. {
  3141. new str[64];
  3142. format(str, sizeof str, "Labirynt wygrywa: %s. Zapisy wznowione!", PlayerName(playerid));
  3143. SendClientMessageToAll(0x5EAEAEFF, str);
  3144. WinSound(playerid);
  3145. if(logged[playerid])
  3146. {
  3147. GameTextForPlayer(playerid, "respekt~n~~g~+10", 1000, 1);
  3148. Respekt[playerid] += 10;
  3149. }
  3150.  
  3151. LabiryntEnd();
  3152. return 1;
  3153. }
  3154. return 1;
  3155. }
  3156.  
  3157. public OnGameModeInit()
  3158. {
  3159. for(new x=0;x<50;x++){
  3160. ChowanyKandydat[x] = -1;
  3161. }
  3162.  
  3163. ChowanyTD[0] = Text:TextDrawCreate(485.000000,356.800000, "Chowany:");
  3164. TextDrawTextSize(ChowanyTD[0],160.000000,160.000000);
  3165. TextDrawAlignment(ChowanyTD[0],2);
  3166. TextDrawBackgroundColor(ChowanyTD[0],0x000000ff);
  3167. TextDrawFont(ChowanyTD[0],1);
  3168. TextDrawColor(ChowanyTD[0],0x0080FFFF);
  3169. TextDrawLetterSize(ChowanyTD[0],0.50000,1.4000);
  3170. TextDrawSetProportional(ChowanyTD[0],1);
  3171. TextDrawSetOutline(ChowanyTD[0],1);
  3172.  
  3173. ChowanyTD[1] = Text:TextDrawCreate(483.000000,360.800000, "Arena: 100~n~Szukajacych: 600~n~Chowajacych: 500");
  3174. TextDrawTextSize(ChowanyTD[1],160.000000,160.000000);
  3175. TextDrawAlignment(ChowanyTD[1],2);
  3176. TextDrawBackgroundColor(ChowanyTD[1],0x000000ff);
  3177. TextDrawFont(ChowanyTD[1],1);
  3178. TextDrawLetterSize(ChowanyTD[1],0.30000,1.2000);
  3179. TextDrawSetProportional(ChowanyTD[1],1);
  3180. TextDrawSetOutline(ChowanyTD[1],1);
  3181.  
  3182. CTFtd = Text:TextDrawCreate(35, 245, "~r~---");
  3183. TextDrawSetOutline(Text:CTFtd, 1);
  3184. TextDrawFont(Text:CTFtd, 2);
  3185. TextDrawLetterSize(Text:CTFtd, 0.35, 0.85);
  3186. TextDrawSetOutline(Text:CTFtd, 1);
  3187.  
  3188. ////////////////////////////Obiekty Do Siano/////////////////////////////
  3189. CreateDynamicObject(3374,2587.98730469,-1310.75878906,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (6)
  3190. CreateDynamicObject(3374,2587.98730469,-1306.83691406,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (7)
  3191. CreateDynamicObject(3374,2587.98730469,-1302.86523438,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (8)
  3192. CreateDynamicObject(3374,2587.98730469,-1298.89941406,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (9)
  3193. CreateDynamicObject(3374,2587.98730469,-1294.95117188,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (10)
  3194. CreateDynamicObject(3374,2587.98730469,-1291.00195312,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (11)
  3195. CreateDynamicObject(3374,2587.98730469,-1287.01953125,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (12)
  3196. CreateDynamicObject(3374,2591.89160156,-1310.80859375,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (13)
  3197. CreateDynamicObject(3374,2595.84057617,-1310.80859375,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (14)
  3198. CreateDynamicObject(3374,2599.78222656,-1310.80859375,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (15)
  3199. CreateDynamicObject(3374,2603.76220703,-1310.80859375,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (16)
  3200. CreateDynamicObject(3374,2607.71435547,-1310.80859375,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (17)
  3201. CreateDynamicObject(3374,2611.66577148,-1310.81250000,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (18)
  3202. CreateDynamicObject(3374,2611.66577148,-1306.83752441,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3203. CreateDynamicObject(3374,2607.71435547,-1306.83752441,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (20)
  3204. CreateDynamicObject(3374,2603.76220703,-1306.83752441,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (21)
  3205. CreateDynamicObject(3374,2599.78222656,-1306.83752441,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (22)
  3206. CreateDynamicObject(3374,2595.84057617,-1306.83752441,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (23)
  3207. CreateDynamicObject(3374,2591.89160156,-1306.83752441,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (24)
  3208. CreateDynamicObject(3374,2591.89160156,-1302.86596680,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (25)
  3209. CreateDynamicObject(3374,2595.84057617,-1302.86596680,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (26)
  3210. CreateDynamicObject(3374,2599.78222656,-1302.86596680,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (27)
  3211. CreateDynamicObject(3374,2603.76220703,-1302.86596680,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (28)
  3212. CreateDynamicObject(3374,2607.71435547,-1302.86596680,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (29)
  3213. CreateDynamicObject(3374,2611.66577148,-1302.86596680,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (30)
  3214. CreateDynamicObject(3374,2611.66577148,-1298.89953613,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (31)
  3215. CreateDynamicObject(3374,2607.71435547,-1298.89953613,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (32)
  3216. CreateDynamicObject(3374,2603.76220703,-1298.89953613,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (33)
  3217. CreateDynamicObject(3374,2599.78222656,-1298.89953613,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (34)
  3218. CreateDynamicObject(3374,2595.84057617,-1298.89953613,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (35)
  3219. CreateDynamicObject(3374,2591.89160156,-1298.84948730,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (36)
  3220. CreateDynamicObject(3374,2591.89160156,-1294.95117188,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (37)
  3221. CreateDynamicObject(3374,2595.83984375,-1294.95117188,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (38)
  3222. CreateDynamicObject(3374,2599.78222656,-1294.95117188,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (39)
  3223. CreateDynamicObject(3374,2603.76171875,-1294.95117188,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (40)
  3224. CreateDynamicObject(3374,2607.71435547,-1294.95117188,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (41)
  3225. CreateDynamicObject(3374,2611.66577148,-1294.95117188,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (42)
  3226. CreateDynamicObject(3374,2611.66577148,-1291.00268555,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (43)
  3227. CreateDynamicObject(3374,2607.71435547,-1291.00268555,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (44)
  3228. CreateDynamicObject(3374,2603.76220703,-1291.00268555,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (45)
  3229. CreateDynamicObject(3374,2599.78222656,-1291.00268555,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (46)
  3230. CreateDynamicObject(3374,2595.84057617,-1291.00268555,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (47)
  3231. CreateDynamicObject(3374,2591.89160156,-1291.00268555,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (48)
  3232. CreateDynamicObject(3374,2591.89160156,-1287.02014160,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (49)
  3233. CreateDynamicObject(3374,2595.84057617,-1287.02014160,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (50)
  3234. CreateDynamicObject(3374,2599.78222656,-1287.02014160,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (51)
  3235. CreateDynamicObject(3374,2603.76220703,-1287.02014160,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (52)
  3236. CreateDynamicObject(3374,2607.71435547,-1287.02014160,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (53)
  3237. CreateDynamicObject(3374,2611.66577148,-1287.02014160,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (54)
  3238. CreateDynamicObject(3374,2615.63012695,-1310.81176758,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (18)
  3239. CreateDynamicObject(3374,2587.98730469,-1283.05468750,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (12)
  3240. CreateDynamicObject(3374,2587.98730469,-1279.05371094,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (12)
  3241. CreateDynamicObject(3374,2619.59033203,-1310.81372070,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (18)
  3242. CreateDynamicObject(3374,2615.63012695,-1306.83752441,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3243. CreateDynamicObject(3374,2615.63012695,-1302.86596680,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3244. CreateDynamicObject(3374,2615.63012695,-1298.89953613,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3245. CreateDynamicObject(3374,2615.63012695,-1294.95117188,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3246. CreateDynamicObject(3374,2615.63012695,-1291.00268555,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3247. CreateDynamicObject(3374,2615.63012695,-1287.02014160,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3248. CreateDynamicObject(3374,2619.59033203,-1306.83752441,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3249. CreateDynamicObject(3374,2619.59033203,-1302.86596680,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3250. CreateDynamicObject(3374,2619.59033203,-1298.89953613,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3251. CreateDynamicObject(3374,2619.58984375,-1294.95117188,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3252. CreateDynamicObject(3374,2619.59033203,-1291.00268555,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3253. CreateDynamicObject(3374,2619.59033203,-1287.02014160,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3254. CreateDynamicObject(3374,2615.63012695,-1283.05493164,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3255. CreateDynamicObject(3374,2615.63012695,-1279.05419922,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3256. CreateDynamicObject(3374,2619.59033203,-1283.05493164,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3257. CreateDynamicObject(3374,2619.59033203,-1279.05419922,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3258. CreateDynamicObject(3374,2591.89160156,-1283.05493164,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3259. CreateDynamicObject(3374,2595.84057617,-1283.05493164,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3260. CreateDynamicObject(3374,2599.78222656,-1283.05493164,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3261. CreateDynamicObject(3374,2603.76220703,-1283.05493164,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3262. CreateDynamicObject(3374,2607.71435547,-1283.05493164,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3263. CreateDynamicObject(3374,2591.89160156,-1279.05419922,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3264. CreateDynamicObject(3374,2595.84057617,-1279.05419922,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3265. CreateDynamicObject(3374,2599.78222656,-1279.05419922,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3266. CreateDynamicObject(3374,2603.76220703,-1279.05419922,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3267. CreateDynamicObject(3374,2607.71435547,-1279.05419922,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3268. CreateDynamicObject(3374,2611.66577148,-1279.05419922,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3269. CreateDynamicObject(3374,2611.66577148,-1283.05493164,594.21795654,0.00000000,0.00000000,0.00000000); //object(sw_haybreak02) (19)
  3270. /////////////////////////////////Koniec obiekty do siana///////////////////////////////////////////////////////////////////////////
  3271.  
  3272.  
  3273. ////////////////////////////////Obiekty Do Tower//////////////////////////////////////////////////////////////
  3274. CreateDynamicObject(6115,2302.84790039,-539.29846191,4.39784241,359.95959473,90.24694824,272.00073242); //object(lawroads_law09) (5)
  3275. CreateDynamicObject(6115,2320.57910156,-545.32983398,4.39784241,359.95605469,90.24151611,231.99949646); //object(lawroads_law09) (7)
  3276. CreateDynamicObject(6115,2328.13281250,-561.64721680,4.39784241,359.95593262,90.23660278,181.99832153); //object(lawroads_law09) (6)
  3277. CreateDynamicObject(6115,2321.04101562,-578.23504639,4.41840219,359.95605469,90.23071289,131.99401855); //object(lawroads_law09) (9)
  3278. CreateDynamicObject(6115,2303.58447266,-584.76037598,4.25682688,359.95593262,90.23660278,88.24829102); //object(lawroads_law09) (10)
  3279. CreateDynamicObject(6115,2285.45092773,-546.26904297,4.23377991,359.95605469,90.24151611,313.24957275); //object(lawroads_law09) (11)
  3280. CreateDynamicObject(6115,2278.15600586,-562.93347168,4.25433969,359.95593262,90.23660278,359.24761963); //object(lawroads_law09) (12)
  3281. CreateDynamicObject(6115,2285.72998047,-578.57867432,4.42088938,359.95605469,90.23071289,51.24737549); //object(lawroads_law09) (13)
  3282. CreateDynamicObject(6115,2285.81933594,-578.33984375,83.72438812,359.95605469,90.21972656,51.24572754); //object(lawroads_law09) (14)
  3283. CreateDynamicObject(6115,2278.47265625,-562.90039062,83.72438812,359.95605469,90.22521973,359.24194336); //object(lawroads_law09) (15)
  3284. CreateDynamicObject(6115,2285.82250977,-546.51049805,83.72438812,359.95605469,90.23620605,313.24768066); //object(lawroads_law09) (16)
  3285. CreateDynamicObject(6115,2302.86669922,-539.62750244,83.52437592,359.95605469,90.24169922,271.99951172); //object(lawroads_law09) (17)
  3286. CreateDynamicObject(6115,2320.49316406,-545.35668945,83.34936523,359.95605469,90.23620605,231.99829102); //object(lawroads_law09) (18)
  3287. CreateDynamicObject(6115,2327.73535156,-561.69824219,83.72438812,359.95605469,90.22521973,179.98901367); //object(lawroads_law09) (19)
  3288. CreateDynamicObject(6115,2320.82519531,-578.04547119,83.72438812,359.95605469,90.22521973,131.98977661); //object(lawroads_law09) (20)
  3289. CreateDynamicObject(6115,2303.76855469,-584.42285156,83.72438812,359.95605469,90.22558594,88.24215698); //object(lawroads_law09) (21)
  3290. CreateDynamicObject(8171,2288.66040039,-568.09466553,-35.21777344,0.00000000,0.00000000,0.00000000); //object(vgssairportland06) (1)
  3291. CreateDynamicObject(8171,2320.98779297,-571.78582764,-35.19277191,0.00000000,0.00000000,0.00000000); //object(vgssairportland06) (2)
  3292. CreateDynamicObject(3095,2304.98461914,-559.06512451,-35.19277191,0.00000000,0.00000000,0.00000000); //object(a51_jetdoor) (1)
  3293. CreateDynamicObject(3095,2307.34350586,-575.87591553,-29.38740540,0.00000000,11.75000000,23.75000000); //object(a51_jetdoor) (2)
  3294. CreateDynamicObject(3095,2314.18359375,-575.56317139,-33.19277191,0.00000000,0.00000000,0.00000000); //object(a51_jetdoor) (3)
  3295. CreateDynamicObject(3095,2300.44042969,-568.63311768,-26.08204079,0.00000000,0.00000000,330.00000000); //object(a51_jetdoor) (4)
  3296. CreateDynamicObject(3095,2307.11352539,-566.89624023,-22.02667618,0.00000000,321.25000000,70.00000000); //object(a51_jetdoor) (5)
  3297. CreateDynamicObject(3095,2308.44189453,-557.02337646,-19.14631271,0.00000000,0.00000000,340.00000000); //object(a51_jetdoor) (6)
  3298. CreateDynamicObject(3095,2299.55859375,-553.45513916,-15.59094810,0.00000000,0.00000000,294.00000000); //object(a51_jetdoor) (7)
  3299. CreateDynamicObject(3095,2307.74731445,-549.51812744,-12.53558254,0.00000000,342.00000000,299.99963379); //object(a51_jetdoor) (8)
  3300. CreateDynamicObject(3095,2293.89257812,-555.83148193,-11.78558254,0.00000000,18.25000000,13.99963379); //object(a51_jetdoor) (9)
  3301. CreateDynamicObject(3095,2305.33544922,-563.22137451,-9.48021698,0.00000000,0.00000000,279.99963379); //object(a51_jetdoor) (10)
  3302. CreateDynamicObject(3095,2297.59716797,-569.90283203,-5.42485142,0.00000000,0.00000000,309.99572754); //object(a51_jetdoor) (11)
  3303. CreateDynamicObject(3095,2304.21069336,-560.96319580,-1.11948586,30.25000000,0.00000000,333.99572754); //object(a51_jetdoor) (12)
  3304. CreateDynamicObject(3095,2292.64916992,-563.12603760,1.43587971,348.00000000,0.00000000,241.99574280); //object(a51_jetdoor) (13)
  3305. CreateDynamicObject(3095,2292.66577148,-574.68408203,4.74124527,1.94058228,14.00817871,193.50631714); //object(a51_jetdoor) (14)
  3306. CreateDynamicObject(3095,2300.41259766,-578.61834717,10.08661175,30.00000000,0.00000000,229.98229980); //object(a51_jetdoor) (15)
  3307. CreateDynamicObject(3095,2311.66943359,-571.67602539,10.64197731,0.00000000,20.00000000,209.98229980); //object(a51_jetdoor) (16)
  3308. CreateDynamicObject(3095,2317.05566406,-564.55297852,15.44734287,4.45523071,317.84344482,88.00015259); //object(a51_jetdoor) (17)
  3309. CreateDynamicObject(3095,2309.80151367,-557.44305420,19.72770500,0.00000000,0.00000000,273.97705078); //object(a51_jetdoor) (18)
  3310. CreateDynamicObject(3095,2313.74194336,-568.80676270,-7.17485142,0.00000000,0.00000000,309.99572754); //object(a51_jetdoor) (19)
  3311. CreateDynamicObject(3095,2303.05615234,-560.41729736,23.30807304,0.00000000,0.00000000,293.97705078); //object(a51_jetdoor) (20)
  3312. CreateDynamicObject(3095,2295.84692383,-555.17016602,25.61343765,0.00000000,342.00000000,243.97216797); //object(a51_jetdoor) (21)
  3313. CreateDynamicObject(3095,2297.79687500,-564.94207764,29.30499649,0.00000000,0.00000000,299.97216797); //object(a51_jetdoor) (23)
  3314. CreateDynamicObject(3095,2311.34741211,-571.07525635,31.61036110,0.00000000,0.00000000,329.97070312); //object(a51_jetdoor) (24)
  3315. CreateDynamicObject(3095,2317.37915039,-565.73333740,33.16572571,0.00000000,0.00000000,29.96887207); //object(a51_jetdoor) (25)
  3316. CreateDynamicObject(3095,2319.64013672,-556.47222900,37.47109222,12.00000000,0.00000000,29.96520996); //object(a51_jetdoor) (26)
  3317. CreateDynamicObject(3095,2311.09497070,-561.46099854,38.87683868,354.00073242,2.01101685,52.17547607); //object(a51_jetdoor) (27)
  3318. CreateDynamicObject(3095,2306.66381836,-551.64257812,41.79191971,353.99597168,2.01049805,64.17407227); //object(a51_jetdoor) (28)
  3319. CreateDynamicObject(3095,2299.81835938,-551.38409424,44.34577942,353.99597168,2.01049805,80.17114258); //object(a51_jetdoor) (29)
  3320. CreateDynamicObject(3095,2290.15112305,-551.21105957,48.96571732,33.96878052,2.41113281,78.60913086); //object(a51_jetdoor) (30)
  3321. CreateDynamicObject(3095,2291.12231445,-562.98883057,48.74391174,353.99597168,2.01049805,80.16723633); //object(a51_jetdoor) (31)
  3322. CreateDynamicObject(3095,2295.99072266,-568.45458984,51.06890106,353.99597168,2.01049805,112.16723633); //object(a51_jetdoor) (32)
  3323. CreateDynamicObject(3095,2299.95898438,-559.79650879,54.22595596,354.12402344,12.06378174,117.20797729); //object(a51_jetdoor) (33)
  3324. CreateDynamicObject(3095,2311.31689453,-557.05108643,57.58482361,359.99053955,359.99862671,119.95397949); //object(a51_jetdoor) (34)
  3325. CreateDynamicObject(3095,2315.24072266,-565.18383789,60.64010239,359.98901367,359.99450684,153.94873047); //object(a51_jetdoor) (35)
  3326. CreateDynamicObject(3095,2308.55395508,-567.10858154,63.61529541,21.98352051,359.98815918,157.95037842); //object(a51_jetdoor) (36)
  3327. CreateDynamicObject(3095,2304.92358398,-577.07562256,65.20106506,1.97814941,359.98468018,157.93933105); //object(a51_jetdoor) (37)
  3328. CreateDynamicObject(3095,2296.60009766,-574.04077148,67.00154877,1.97753906,359.98352051,157.93395996); //object(a51_jetdoor) (38)
  3329. CreateDynamicObject(3095,2292.24121094,-565.03906250,70.47853851,1.97204590,359.97802734,197.92971802); //object(a51_jetdoor) (39)
  3330. CreateDynamicObject(3095,2310.46679688,-566.23834229,74.27788544,1.96655273,359.97802734,237.92419434); //object(a51_jetdoor) (43)
  3331. CreateDynamicObject(3095,2297.14746094,-559.09606934,74.02267456,1.97204590,359.97802734,197.92968750); //object(a51_jetdoor) (39)
  3332. CreateDynamicObject(3095,2317.12182617,-556.24102783,74.80375671,335.96105957,359.97595215,257.90939331); //object(a51_jetdoor) (43)
  3333. CreateDynamicObject(3095,2307.99804688,-553.85937500,77.77385712,1.96105957,359.97802734,237.91990662); //object(a51_jetdoor) (43)
  3334. CreateDynamicObject(3095,2300.89184570,-552.42315674,80.80257416,1.96105957,359.97802734,277.91992188); //object(a51_jetdoor) (43)
  3335. CreateDynamicObject(3095,2288.88452148,-556.69512939,82.72107697,323.95556641,359.97283936,321.89892578); //object(a51_jetdoor) (43)
  3336. CreateDynamicObject(3095,2292.20190430,-566.54809570,86.98894501,1.95556641,359.97802734,299.91564941); //object(a51_jetdoor) (43)
  3337. CreateDynamicObject(3095,2301.31689453,-573.00445557,90.03491974,7.68328857,356.19381714,330.41909790); //object(a51_jetdoor) (43)
  3338. CreateDynamicObject(3095,2313.52807617,-568.95562744,91.19895935,327.77465820,355.53924561,27.52221680); //object(a51_jetdoor) (43)
  3339. CreateDynamicObject(3095,2307.99218750,-559.97613525,91.51599884,3.68493652,356.21539307,30.14947510); //object(a51_jetdoor) (43)
  3340. CreateDynamicObject(3095,2304.71777344,-551.85546875,95.17199707,3.68041992,356.21520996,30.14648438); //object(a51_jetdoor) (43)
  3341. CreateDynamicObject(3095,2308.72558594,-559.39440918,99.56198883,3.68041992,356.21520996,30.14648438); //object(a51_jetdoor) (43)
  3342. CreateDynamicObject(3095,2305.69433594,-569.14282227,101.62189484,3.68041992,356.21520996,60.14648438); //object(a51_jetdoor) (43)
  3343. CreateDynamicObject(3095,2298.95434570,-563.33673096,104.82051086,3.67492676,356.20971680,62.14465332); //object(a51_jetdoor) (43)
  3344. CreateDynamicObject(3095,2295.15869141,-561.33563232,109.79172516,87.02651978,205.56018066,214.37207031); //object(a51_jetdoor) (43)
  3345. CreateDynamicObject(3095,2297.58447266,-565.79882812,109.09960938,65.28234863,183.07214355,328.85925293); //object(a51_jetdoor) (43)
  3346. CreateDynamicObject(3095,2299.87646484,-561.56604004,108.98298645,56.79006958,182.34394836,147.93206787); //object(a51_jetdoor) (43)
  3347. ///////////////////////////////////////////Koniec obiekty do tower////////////////////////////////////////////////////////////////////
  3348.  
  3349.  
  3350.  
  3351.  
  3352. /////////////////////////////////Obiekty Do Paintball///////////////////////////////////////////////////////
  3353. CreateDynamicObject(3865, 840.81, 2259.70, 11.75, 0.00, 0.00, 0.00);
  3354. CreateDynamicObject(3865, 866.73, 2255.05, 11.75, 0.00, 0.00, 60.00);
  3355. CreateDynamicObject(3865, 847.37, 2219.05, 11.75, 0.00, 0.00, 18.00);
  3356. CreateDynamicObject(3865, 874.85, 2234.39, 11.75, 0.00, 0.00, 278.00);
  3357. CreateDynamicObject(3865, 859.32, 2278.21, 11.75, 0.00, 0.00, 120.00);
  3358. CreateDynamicObject(3865, 825.65, 2239.71, 11.41, 0.00, 0.00, 60.00);
  3359. CreateDynamicObject(3095, 855.45, 2235.14, 9.82, 86.00, 0.00, 0.00);
  3360. CreateDynamicObject(3095, 852.25, 2262.38, 9.82, 86.00, 0.00, 300.00);
  3361. CreateDynamicObject(3095, 886.79, 2249.57, 9.82, 86.00, 0.00, 26.00);
  3362. CreateDynamicObject(3095, 858.39, 2215.03, 9.82, 86.00, 0.00, 270.00);
  3363. CreateDynamicObject(3095, 841.57, 2229.41, 9.82, 86.00, 0.00, 270.00);
  3364. CreateDynamicObject(3095, 827.19, 2251.61, 9.79, 86.00, 0.00, 10.00);
  3365. CreateDynamicObject(3095, 876.69, 2270.32, 9.82, 86.00, 0.00, 10.00);
  3366. CreateDynamicObject(3095, 855.92, 2242.80, 9.82, 86.00, 0.00, 160.00);
  3367. CreateDynamicObject(3095, 840.29, 2245.94, 9.82, 86.00, 0.00, 360.00);
  3368. CreateDynamicObject(3095, 865.20, 2267.47, 9.82, 86.00, 0.00, 160.00);
  3369. CreateDynamicObject(3095, 838.03, 2271.13, 9.82, 86.00, 0.00, 159.99);
  3370. CreateDynamicObject(3095, 827.53, 2262.12, 9.85, 86.00, 0.00, 79.99);
  3371. CreateDynamicObject(3865, 877.82, 2220.85, 11.75, 0.00, 0.00, 60.00);
  3372. CreateDynamicObject(3095, 865.82, 2224.61, 9.82, 86.00, 0.00, 80.00);
  3373. CreateDynamicObject(3095, 875.80, 2246.07, 9.82, 86.00, 0.00, 330.00);
  3374. CreateDynamicObject(3095, 835.92, 2222.17, 9.76, 86.00, 0.00, 300.00);
  3375. CreateDynamicObject(3095, 882.51, 2261.17, 9.82, 86.00, 0.00, 300.00);
  3376. CreateDynamicObject(3095, 836.26, 2242.17, 9.79, 86.00, 0.00, 100.00);
  3377. CreateDynamicObject(3095, 885.00, 2230.96, 9.82, 86.00, 0.00, 290.00);
  3378. CreateDynamicObject(3095, 863.42, 2245.24, 9.82, 86.00, 0.00, 310.00);
  3379. CreateDynamicObject(3095, 848.53, 2276.38, 9.82, 86.00, 0.00, 49.99);
  3380. CreateDynamicObject(3095, 860.83, 2261.19, 9.82, 86.00, 0.00, 49.99);
  3381. CreateDynamicObject(3095, 849.59, 2251.19, 9.82, 86.00, 0.00, 49.99);
  3382. CreateDynamicObject(3095, 856.99, 2224.74, 9.82, 86.00, 0.00, 159.99);
  3383. CreateDynamicObject(3095, 888.77, 2244.56, 9.82, 86.00, 0.00, 289.99);
  3384. CreateDynamicObject(3095, 890.01, 2238.47, 9.82, 86.00, 0.00, 49.99);
  3385. CreateDynamicObject(3865, 876.71, 2258.18, 11.75, 0.00, 0.00, 60.00);
  3386. CreateDynamicObject(3865, 840.81, 2259.70, 11.75, 0.00, 0.00, 0.00);
  3387. CreateDynamicObject(3865, 866.73, 2255.05, 11.75, 0.00, 0.00, 60.00);
  3388. CreateDynamicObject(3865, 847.37, 2219.05, 11.75, 0.00, 0.00, 18.00);
  3389. CreateDynamicObject(3865, 874.85, 2234.39, 11.75, 0.00, 0.00, 278.00);
  3390. CreateDynamicObject(3865, 859.32, 2278.21, 11.75, 0.00, 0.00, 120.00);
  3391. CreateDynamicObject(3865, 825.65, 2239.71, 11.41, 0.00, 0.00, 60.00);
  3392. CreateDynamicObject(3095, 855.45, 2235.14, 9.82, 86.00, 0.00, 0.00);
  3393. CreateDynamicObject(3095, 852.25, 2262.38, 9.82, 86.00, 0.00, 300.00);
  3394. CreateDynamicObject(3095, 886.79, 2249.57, 9.82, 86.00, 0.00, 26.00);
  3395. CreateDynamicObject(3095, 858.39, 2215.03, 9.82, 86.00, 0.00, 270.00);
  3396. CreateDynamicObject(3095, 841.57, 2229.41, 9.82, 86.00, 0.00, 270.00);
  3397. CreateDynamicObject(3095, 827.19, 2251.61, 9.79, 86.00, 0.00, 10.00);
  3398. CreateDynamicObject(3095, 876.69, 2270.32, 9.82, 86.00, 0.00, 10.00);
  3399. CreateDynamicObject(3095, 855.92, 2242.80, 9.82, 86.00, 0.00, 160.00);
  3400. CreateDynamicObject(3095, 840.29, 2245.94, 9.82, 86.00, 0.00, 360.00);
  3401. CreateDynamicObject(3095, 865.20, 2267.47, 9.82, 86.00, 0.00, 160.00);
  3402. CreateDynamicObject(3095, 838.03, 2271.13, 9.82, 86.00, 0.00, 159.99);
  3403. CreateDynamicObject(3095, 827.53, 2262.12, 9.85, 86.00, 0.00, 79.99);
  3404. CreateDynamicObject(3865, 877.82, 2220.85, 11.75, 0.00, 0.00, 60.00);
  3405. CreateDynamicObject(3095, 865.82, 2224.61, 9.82, 86.00, 0.00, 80.00);
  3406. CreateDynamicObject(3095, 875.80, 2246.07, 9.82, 86.00, 0.00, 330.00);
  3407. CreateDynamicObject(3095, 835.92, 2222.17, 9.76, 86.00, 0.00, 300.00);
  3408. CreateDynamicObject(3095, 882.51, 2261.17, 9.82, 86.00, 0.00, 300.00);
  3409. CreateDynamicObject(3095, 836.26, 2242.17, 9.79, 86.00, 0.00, 100.00);
  3410. CreateDynamicObject(3095, 885.00, 2230.96, 9.82, 86.00, 0.00, 290.00);
  3411. CreateDynamicObject(3095, 863.42, 2245.24, 9.82, 86.00, 0.00, 310.00);
  3412. CreateDynamicObject(3095, 848.53, 2276.38, 9.82, 86.00, 0.00, 49.99);
  3413. CreateDynamicObject(3095, 860.83, 2261.19, 9.82, 86.00, 0.00, 49.99);
  3414. CreateDynamicObject(3095, 849.59, 2251.19, 9.82, 86.00, 0.00, 49.99);
  3415. CreateDynamicObject(3095, 856.99, 2224.74, 9.82, 86.00, 0.00, 159.99);
  3416. CreateDynamicObject(3095, 888.77, 2244.56, 9.82, 86.00, 0.00, 289.99);
  3417. CreateDynamicObject(3095, 890.01, 2238.47, 9.82, 86.00, 0.00, 49.99);
  3418. CreateDynamicObject(3865, 876.71, 2258.18, 11.75, 0.00, 0.00, 60.00);
  3419. CreateDynamicObject(18845, 857.80, 2248.00, 7.00, 0.00, 0.00, 0.00);
  3420. /////////////////////////////Koniec obiekty do paintball/////////////////////////
  3421.  
  3422. DerbyCar[0] = CreateVehicle(444,-189.3335,-612.0821,63.7825,272.4385,32,32,0); //
  3423. DerbyCar[1] = CreateVehicle(444,-128.6777,-610.3533,47.9714,91.0741,32,36,0); //
  3424. DerbyCar[2] = CreateVehicle(444,-158.3339,-578.9396,55.7017,179.7889,32,14,0); //
  3425. DerbyCar[3] = CreateVehicle(444,-155.7805,-641.2036,55.0360,6.9555,32,53,0); //
  3426. DerbyCar[4] = CreateVehicle(444,-188.1995,-599.5789,63.4914,248.7901,32,36,0); //
  3427. DerbyCar[5] = CreateVehicle(444,-131.2628,-621.7962,48.6449,69.8603,32,32,0); //
  3428. DerbyCar[6] = CreateVehicle(444,-147.0963,-582.7581,52.7723,159.0907,32,42,0); //
  3429. DerbyCar[7] = CreateVehicle(444,-165.7696,-640.3754,57.6418,343.8235,32,53,0); //
  3430. DerbyCar[8] = CreateVehicle(444,-185.9509,-624.5323,62.9007,295.9437,32,42,0); //
  3431. DerbyCar[9] = CreateVehicle(444,-131.8944,-599.3342,48.8112,113.5459,32,53,0); //
  3432. DerbyCar[10] = CreateVehicle(444,-169.0654,-582.7039,58.5010,202.8040,32,14,0); //
  3433. DerbyCar[11] = CreateVehicle(444,-147.1512,-636.6563,52.7866,22.6119,32,66,0); //
  3434. DerbyCar[12] = CreateVehicle(444,-178.5293,-636.4559,60.9678,323.1482,32,66,0); //
  3435. DerbyCar[13] = CreateVehicle(444,-137.0095,-589.4589,50.1445,137.5518,32,42,0); //
  3436. DerbyCar[14] = CreateVehicle(444,-181.1408,-587.8377,61.6472,222.2664,32,66,0); //
  3437. DerbyCar[15] = CreateVehicle(444,-139.0930,-631.4850,50.6860,43.4002,32,14,0); //
  3438.  
  3439.  
  3440. for(new x; x < 16; x++)
  3441. {
  3442. printf("%d", DerbyCar[x]);
  3443. SetVehicleVirtualWorld(DerbyCar[x], 2);
  3444. }
  3445. //---------------[ CTF Statek ]------------------------//
  3446.  
  3447. SetVehicleVirtualWorld( AddStaticVehicle(473,-1282.1331,1638.1915,-0.1608,169.1792,56,53) ,11);
  3448. SetVehicleVirtualWorld( AddStaticVehicle(473,-1287.1108,1639.5765,-0.2539,168.6744,56,15),11);
  3449. SetVehicleVirtualWorld( AddStaticVehicle(473,-1290.7316,1642.9519,-0.2732,137.1957,56,53),11);
  3450. SetVehicleVirtualWorld( AddStaticVehicle(473,-1294.5740,1646.4120,-0.2456,140.0210,56,15),11);
  3451. SetVehicleVirtualWorld( AddStaticVehicle(473,-1491.7477,1390.1398,-0.4864,337.3904,56,15),11);
  3452. SetVehicleVirtualWorld( AddStaticVehicle(473,-1513.8723,1387.1368,-0.1155,7.6053,56,53),11);
  3453. SetVehicleVirtualWorld( AddStaticVehicle(473,-1508.8218,1387.5779,-0.1616,6.1958,56,15),11);
  3454. SetVehicleVirtualWorld( AddStaticVehicle(473,-1503.5488,1388.4106,-0.3497,9.5085,56,53),11);
  3455.  
  3456. //---------------[ INTERIORS ]-------------------------//
  3457.  
  3458. //KSS
  3459. LinkVehicleToInterior(
  3460. AddStaticVehicle(444,-1492.4644,1621.9382,1052.9025,270.3307,32,14),14); //
  3461. LinkVehicleToInterior(
  3462. AddStaticVehicle(468,-1493.8662,1607.5486,1052.1970,271.0642,3,3),14); //
  3463. LinkVehicleToInterior(
  3464. AddStaticVehicle(468,-1494.0038,1608.9308,1052.1760,273.6895,6,6),14); //
  3465. LinkVehicleToInterior(
  3466. AddStaticVehicle(468,-1494.1541,1610.4962,1052.1995,278.0568,46,46),14);//
  3467. LinkVehicleToInterior(
  3468. AddStaticVehicle(522,-1494.0809,1612.6964,1052.0991,275.1321,3,8),14); //
  3469. LinkVehicleToInterior(
  3470. AddStaticVehicle(522,-1493.8159,1614.7366,1052.1011,268.8207,3,8),14); //
  3471. LinkVehicleToInterior(
  3472. AddStaticVehicle(522,-1493.8563,1616.8672,1052.1039,272.0705,3,8),14); //
  3473.  
  3474.  
  3475. //DB
  3476. LinkVehicleToInterior(
  3477. AddStaticVehicle(468,-1437.9542,-646.6154,1050.0419,248.6400,53,53),4); //
  3478. LinkVehicleToInterior(
  3479. AddStaticVehicle(468,-1437.4786,-645.0378,1049.7626,248.6887,3,3),4); //
  3480. LinkVehicleToInterior(
  3481. AddStaticVehicle(468,-1437.0680,-643.5625,1049.5391,247.1457,6,6),4); //
  3482. LinkVehicleToInterior(
  3483. AddStaticVehicle(468,-1436.2480,-642.2493,1049.4943,257.7117,46,46),4); //
  3484. LinkVehicleToInterior(
  3485. AddStaticVehicle(471,-1436.2731,-639.8793,1048.7136,250.3959,103,111),4); //
  3486. LinkVehicleToInterior(
  3487. AddStaticVehicle(471,-1435.1364,-635.9240,1049.1923,250.2289,74,91),4); //
  3488. LinkVehicleToInterior(
  3489. AddStaticVehicle(471,-1435.6688,-637.8844,1048.6672,250.8790,120,114),4); //
  3490.  
  3491. //DD
  3492.  
  3493. LinkVehicleToInterior(
  3494. AddStaticVehicle(504,-1352.9280,938.3043,1036.2068,17.7235,57,38), 15); // dd:auto-1
  3495. LinkVehicleToInterior(
  3496. AddStaticVehicle(504,-1490.0773,952.5486,1036.6932,331.2003,14,1), 15); // dd-auto
  3497. LinkVehicleToInterior(
  3498. AddStaticVehicle(504,-1499.1383,961.6018,1036.8599,321.4333,65,9), 15); // dd-auto
  3499. LinkVehicleToInterior(
  3500. AddStaticVehicle(504,-1505.7516,972.4949,1037.0544,301.0165,34,9), 15); // dd-auto
  3501. LinkVehicleToInterior(
  3502. AddStaticVehicle(504,-1511.3676,986.8600,1037.3036,294.6465,45,29), 15); // dd-auto
  3503. LinkVehicleToInterior(
  3504. AddStaticVehicle(504,-1512.7253,999.1296,1037.5059,263.3817,57,38), 15); // dd-auto
  3505. LinkVehicleToInterior(
  3506. AddStaticVehicle(504,-1507.5730,1017.6364,1037.8011,241.7172,51,39), 15); // dd-auto
  3507. LinkVehicleToInterior(
  3508. AddStaticVehicle(504,-1499.8105,1027.1980,1037.9489,228.5874,26,1), 15); // dd-auto
  3509. LinkVehicleToInterior(
  3510. AddStaticVehicle(504,-1484.5031,1038.5229,1038.1136,215.4444,12,9), 15); // dd-auto
  3511. LinkVehicleToInterior(
  3512. AddStaticVehicle(504,-1469.1527,1045.6360,1038.1989,212.7548,14,1), 15); // dd-auto
  3513. LinkVehicleToInterior(
  3514. AddStaticVehicle(504,-1453.5883,1051.7992,1038.2715,202.6581,65,9), 15); // dd-auto
  3515. LinkVehicleToInterior(
  3516. AddStaticVehicle(504,-1435.9102,1055.0287,1038.3020,199.4608,34,9), 15); // dd-auto
  3517. LinkVehicleToInterior(
  3518. AddStaticVehicle(504,-1417.3086,1056.3545,1038.2883,187.5230,45,29), 15); // dd-auto
  3519. LinkVehicleToInterior(
  3520. AddStaticVehicle(504,-1397.2771,1056.7366,1038.2618,185.7977,57,38), 15); // dd-auto
  3521. LinkVehicleToInterior(
  3522. AddStaticVehicle(504,-1380.6863,1057.2357,1038.2456,181.8720,51,39), 15); // dd-auto
  3523. LinkVehicleToInterior(
  3524. AddStaticVehicle(504,-1365.6376,1055.9902,1038.1979,180.2804,26,1), 15); // dd-auto
  3525. LinkVehicleToInterior(
  3526. AddStaticVehicle(504,-1344.1788,1052.7750,1038.1049,174.5971,12,9), 15); // dd-auto
  3527. LinkVehicleToInterior(
  3528. AddStaticVehicle(504,-1325.6730,1047.2588,1037.9476,154.9616,14,1), 15); // dd-auto
  3529. LinkVehicleToInterior(
  3530. AddStaticVehicle(504,-1307.6199,1034.2521,1037.7346,156.8991,65,9), 15); // dd-auto
  3531. LinkVehicleToInterior(
  3532. AddStaticVehicle(504,-1293.9332,1020.8791,1037.4844,138.6608,34,9), 15); // dd-auto
  3533. LinkVehicleToInterior(
  3534. AddStaticVehicle(504,-1285.2561,1001.3178,1037.1443,110.3759,51,39), 15); // dd-auto
  3535. LinkVehicleToInterior(
  3536. AddStaticVehicle(504,-1285.2317,989.4346,1036.9491,89.2480,45,29), 15); // dd-auto
  3537. LinkVehicleToInterior(
  3538. AddStaticVehicle(504,-1296.1692,967.5569,1036.5953,74.3806,26,1), 15); // dd-auto
  3539. LinkVehicleToInterior(
  3540. AddStaticVehicle(504,-1313.5422,953.1486,1036.3883,63.7932,34,9), 15); // dd-auto
  3541. LinkVehicleToInterior(
  3542. AddStaticVehicle(504,-1329.2750,944.7968,1036.2806,53.3132,12,9), 15); // dd-auto
  3543. LinkVehicleToInterior(
  3544. AddStaticVehicle(504,-1352.9280,938.3043,1036.2068,17.7226,57,38), 15); // dd-auto
  3545. return 1;
  3546. }
  3547.  
  3548. forward UpdateStat2();
  3549. public UpdateStat2()
  3550. {
  3551. new veh;
  3552. foreach(Player, x)
  3553. {
  3554. if(GetPlayerState(x) == PLAYER_STATE_DRIVER)
  3555. {
  3556. veh = GetPlayerVehicleID(x);
  3557. CanNitro[x] = false;
  3558. if(HaveNitro[veh])
  3559. CanNitro[x] = true;
  3560.  
  3561. if(!CarInfoChce[x])
  3562. continue;
  3563.  
  3564. if(RaceMen[x])
  3565. {
  3566. new bla = RaceCheck[x] - 1;
  3567. bla = bla < 0 ? 0 : bla;
  3568. new model = GetVehicleModel(veh);
  3569. new Float:fX,Float:fY,Float:fZ,Float:heal;
  3570. GetVehicleVelocity(veh,fX,fY,fZ);
  3571. new speed = floatround(floatmul(floatmul(fX, fX) + floatmul(fY, fY) + floatmul(fZ, fZ), 190));
  3572. GetVehicleHealth(veh,heal);
  3573. heal = ((heal-250)/750)*100;
  3574. new dmg = floatround(heal);
  3575. dmg = dmg < 0 ? 0 : dmg > 100 ? 100: dmg;
  3576.  
  3577. new str[128];
  3578. format(str, sizeof(str), "%s ~w~Szybkosc: ~g~%d km/h/n ~w~Stan HP: ~g~%d/100/n ~w~Checkpoint: ~y~%d/%d/n ~w~Miejsce: ~r~%d/%d",CarList[model-400],speed,dmg,RaceCheck[x],CPliczba,ActualPos[x],RaceMenLiczba);
  3579. TextDrawSetString(tdStatus2[x], str);
  3580.  
  3581. }
  3582. else
  3583. {
  3584. new model = GetVehicleModel(veh);
  3585. new Float:fX,Float:fY,Float:fZ,Float:heal;
  3586. GetVehicleVelocity(veh,fX,fY,fZ);
  3587. new speed = floatround(floatmul(floatmul(fX, fX) + floatmul(fY, fY) + floatmul(fZ, fZ), 190));
  3588. GetVehicleHealth(veh,heal);
  3589. heal = ((heal-250)/750)*100;
  3590. new dmg = floatround(heal);
  3591. dmg = dmg < 0 ? 0 : dmg > 100 ? 100: dmg;
  3592.  
  3593. new str[128];
  3594.  
  3595. if(VehicleLocked[veh] >= 0 && HaveNitro[veh]){
  3596. format(str,sizeof(str)," %s~n~~y~%d ~w~km/h ~y~%d/100 ~w~HP~n~ ~w~Zamkniety: ~r~tak",CarList[model-400],speed,dmg);
  3597. }else if(VehicleLocked[veh] >= 0 && !HaveNitro[veh]){
  3598. format(str,sizeof(str)," %s~n~~y~%d ~w~km/h ~y~%d/100 ~w~HP~n~ ~w~Zamkniety: ~r~tak",CarList[model-400],speed,dmg);
  3599. }else if(VehicleLocked[veh] < 0 && HaveNitro[veh]){
  3600. format(str,sizeof(str)," %s~n~~y~%d ~w~km/h ~y~%d/100 ~w~HP~n~ ~w~Zamkniety: ~y~nie",CarList[model-400],speed,dmg);
  3601. }else if(VehicleLocked[veh] < 0 && !HaveNitro[veh]){
  3602. format(str,sizeof(str)," %s~n~~y~%d ~w~km/h ~y~%d/100 ~w~HP~n~ ~w~Zamkniety: ~y~nie",CarList[model-400],speed,dmg);
  3603. }
  3604. TextDrawSetString(tdStatus2[x], str);
  3605.  
  3606. }
  3607. }
  3608. else
  3609. CanNitro[x] = false;
  3610. }
  3611. return 1;
  3612. }
  3613.  
  3614. CMD:wgexit(playerid,cmdtext[]){
  3615. #pragma unused cmdtext
  3616.  
  3617. if(WGON && WGTeam[playerid] > 0){
  3618. SetPlayerRandomSpawn(playerid);
  3619. }
  3620.  
  3621. WGTeam[playerid] = 0;
  3622. WGKandydat[playerid] = false;
  3623. PlayerSetColor(playerid);
  3624. SetPlayerTeam(playerid,playerid+10);
  3625.  
  3626. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Wypisałeś(aś) się z WG");
  3627. return 1;
  3628. }
  3629.  
  3630. CMD:skokiexit(playerid,cmdtext[]){
  3631. #pragma unused cmdtext
  3632. Skoczek[playerid] = false;
  3633. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Wypisałeś(aś) się ze skoku spadochronowego");
  3634. return 1;
  3635. }
  3636.  
  3637.  
  3638.  
  3639.  
  3640.  
  3641.  
  3642.  
  3643. CMD:derbyexit(playerid,cmdtext[]){
  3644. #pragma unused cmdtext
  3645. if(DerbyMen[playerid] && DerbyON){
  3646. SetPlayerRandomSpawn(playerid);
  3647. }
  3648. DerbyMen[playerid] = false;
  3649. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Wypisałeś(aś) się z derbów");
  3650. return 1;
  3651. }
  3652.  
  3653.  
  3654. CMD:labiryntexit(playerid,cmdtext[]){
  3655. #pragma unused cmdtext
  3656. if(Labirynt[playerid] && LabON){
  3657. SetPlayerRandomSpawn(playerid);
  3658. }
  3659. Labirynt[playerid] = false;
  3660. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Wypisałeś(aś) się z labiryntu");
  3661. return 1;
  3662. }
  3663.  
  3664.  
  3665.  
  3666.  
  3667. CMD:strzelnicaexit(playerid,cmdtext[]){
  3668. #pragma unused cmdtext
  3669.  
  3670. if(Strzelnica[playerid] && StrzelnicaON){
  3671. SetPlayerRandomSpawn(playerid);
  3672. }
  3673.  
  3674. Strzelnica[playerid] = false;
  3675. StrzelnicaSniper[playerid] = false;
  3676.  
  3677. if(StrzelnicaON)
  3678. {
  3679. if(Strzelnica[playerid])
  3680. {
  3681. Strzelnica[playerid] = false;
  3682. StrzelnicaSniper[playerid] = false;
  3683. new StrzLicz;
  3684. new SnipLicz;
  3685. foreach(Player, x){
  3686. if(!StrzelnicaSniper[x] && Strzelnica[x] && IsPlayerConnected(x)){
  3687. StrzLicz ++;
  3688. }else if(StrzelnicaSniper[x] && IsPlayerConnected(x)){
  3689. SnipLicz ++;
  3690. }
  3691. }
  3692.  
  3693. if(StrzLicz <= 1){
  3694. new str[128];
  3695. foreach(Player, x){
  3696. if(!StrzelnicaSniper[x] && Strzelnica[x] && IsPlayerConnected(x)){
  3697. format(str,sizeof(str),">>>>>>{FF0000}{FFFFFF}Na strzelnicy najdłużej wytrzymał(a) %s",PlayerName(x));
  3698. SendClientMessageToAll(0x8080C0FF,str);
  3699. if(logged[x]){
  3700. GameTextForPlayer(x,"respekt~n~~g~+7", 1000, 1);
  3701. Respekt[x] += 7;
  3702. }
  3703. }
  3704. }
  3705. StrzelnicaEnd();
  3706. }else if(SnipLicz <= 0){
  3707. SendClientMessageToAll(COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Strzelnica przerwana z powodu braku strzelca");
  3708. StrzelnicaEnd();
  3709. }
  3710. }
  3711. }
  3712.  
  3713. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Wypisałeś(aś) się ze strzelnicy");
  3714. return 1;
  3715. }
  3716.  
  3717. CMD:ctfexit(playerid,cmdtext[]){
  3718. #pragma unused cmdtext
  3719. if(FlageMa == playerid){
  3720. CTFFlagDown(playerid);
  3721. }
  3722. CTFTeam[playerid] = 0;
  3723. CTFKandydat[playerid] = false;
  3724. TextDrawHideForPlayer(playerid,CTFtd);
  3725. SetPlayerRandomSpawn(playerid);
  3726. DisablePlayerRaceCheckpoint(playerid);
  3727. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Wypisałeś(aś) się z CTF");
  3728. return 1;
  3729. }
  3730.  
  3731. CMD:ctfend(playerid,cmdtext[]){
  3732. #pragma unused cmdtext
  3733. if(!Administrator[playerid]) return ShowPlayerDialog(playerid,40,0,"{FFFFFF}"NazwaGI" - {FFFF00}Informacja","Brak Uprawnien Admina!","OK","");
  3734. CTFEndWin(3);
  3735. return 1;
  3736. }
  3737.  
  3738. CMD:strzelnicaend(playerid,cmdtext[]){
  3739. #pragma unused cmdtext
  3740. if(!Administrator[playerid]) return ShowPlayerDialog(playerid,40,0,"{FFFFFF}"NazwaGI" - {FFFF00}Informacja","Brak Uprawnien Admina!","OK","");
  3741. StrzelnicaEnd();
  3742. SendClientMessageToAll(COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Strzelnica przerwana przez admina!");
  3743. return 1;
  3744. }
  3745.  
  3746. CMD:labiryntend(playerid,cmdtext[]){
  3747. #pragma unused cmdtext
  3748. if(!Administrator[playerid]) return ShowPlayerDialog(playerid,40,0,"{FFFFFF}"NazwaGI" - {FFFF00}Informacja","Brak Uprawnien Admina!","OK","");
  3749. LabiryntEnd();
  3750. SendClientMessageToAll(COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Labirynt przerwany przez admina!");
  3751. return 1;
  3752. }
  3753.  
  3754. CMD:derbyend(playerid,cmdtext[]){
  3755. #pragma unused cmdtext
  3756. if(!Administrator[playerid]) return ShowPlayerDialog(playerid,40,0,"{FFFFFF}"NazwaGI" - {FFFF00}Informacja","Brak Uprawnien Admina!","OK","");
  3757. DerbyEnd();
  3758. SendClientMessageToAll(COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Derby przerwane przez admina!");
  3759. return 1;
  3760. }
  3761.  
  3762. CMD:st(playerid,cmdtext[]){
  3763. #pragma unused cmdtext
  3764.  
  3765. if(StrzelnicaON){
  3766. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Strzelnica już wystartowała!");
  3767. return 1;
  3768. }
  3769.  
  3770. if(Strzelnica[playerid]){
  3771. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Jesteś już zapisany(a) na strzelnice!");
  3772. return 1;
  3773. }
  3774.  
  3775. if(StrzelnicaZaglosowal[playerid]){
  3776. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Wypisałeś(aś) się już z tej rundy na strzelnicy!");
  3777. return 1;
  3778. }
  3779.  
  3780. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Zapisałeś(aś) się na strzelnice");
  3781. new string[500];
  3782. format(string, sizeof(string), "{00FF00}+ {C0C0C0}%s (%d){999999} zapisał(a) się na {C0C0C0}Strzelnica!",PlayerName(playerid),playerid);
  3783. SendClientMessageToAll(COLOR_LIGHTRED,string);
  3784.  
  3785. Strzelnica[playerid] = true;
  3786. StrzelnicaSniper[playerid] = false;
  3787. StrzelnicaZaglosowal[playerid] = true;
  3788.  
  3789. new LiczbaStrz = 0;
  3790. foreach(Player, x){
  3791. if(Strzelnica[x] && IsPlayerConnected(x)){
  3792. LiczbaStrz ++;
  3793. }
  3794. }
  3795.  
  3796. ZapisyUpdate();
  3797.  
  3798. if(LiczbaStrz == 3 && !StrzelnicaStartON){
  3799. SendClientMessageToAll(0x8080C0FF,">>>>>>{FF0000}{FFFFFF}Strzelnica wystartuje za 20 sek. (Nadal Trwaja zapisy!)");
  3800. SetTimer("StrzelnicaStart",20000,0);
  3801. StrzelnicaStartON = true;
  3802. }
  3803.  
  3804. return 1;
  3805. }
  3806.  
  3807.  
  3808.  
  3809.  
  3810. CMD:pl(playerid,cmdtext[])
  3811. {
  3812. if(PaintbON){
  3813. SendClientMessage(playerid,COLOR_RED,"PaintBall już wystartowały");
  3814. return 1;
  3815. }
  3816.  
  3817. if(PaintbMen[playerid]){
  3818. SendClientMessage(playerid,COLOR_RED,"Jesteś już zapisany(a) na PaintBall!");
  3819. return 1;
  3820. }
  3821.  
  3822. if(PaintbZaglosowal[playerid]){
  3823. SendClientMessage(playerid,COLOR_RED,"Wypisałeś(aś) się już z tej rundy PaintBalla!");
  3824. return 1;
  3825. }
  3826.  
  3827.  
  3828. SendClientMessage(playerid,COLOR_GREEN,"Zapisałeś(aś) się na PaintBall");
  3829. new string[500];
  3830. format(string, sizeof(string), "{00FF00}+ {C0C0C0}%s (%d){999999} zapisał(a) się na {C0C0C0}Paint Ball!",PlayerName(playerid),playerid);
  3831. SendClientMessageToAll(COLOR_LIGHTRED,string);
  3832.  
  3833. PaintbMen[playerid] = true;
  3834. PaintbZaglosowal[playerid] = true;
  3835.  
  3836. new LiczbaPaintb = 0;
  3837. for(new x=0;x<MAX_PLAYERS;x++){
  3838. if(PaintbMen[x] && IsPlayerConnected(x)){
  3839. LiczbaPaintb ++;
  3840. }
  3841. }
  3842.  
  3843. ZapisyUpdate();
  3844.  
  3845. if(LiczbaPaintb == 2 && !PaintbStartON){
  3846. SendClientMessageToAll(0xA346FFFF,"PaintBall wystartuje za 20 sek. (Nadal Trwaja zapisy!)");
  3847. SetTimer("PaintbStart",20000,0);
  3848. PaintbStartON = true;
  3849. }
  3850.  
  3851. return 1;
  3852. }
  3853.  
  3854.  
  3855. CMD:plexit(playerid,cmdtext[])
  3856. {
  3857. if(PaintbMen[playerid] && PaintbON){
  3858. SetPlayerRandomSpawn(playerid);
  3859. }
  3860. PaintbMen[playerid] = false;
  3861. SendClientMessage(playerid,COLOR_GREEN,"Wypisałeś(aś) się z PaintBalla");
  3862. return 1;
  3863. }
  3864.  
  3865.  
  3866. CMD:plend(playerid,cmdtext[])
  3867. {
  3868. if(!Administrator[playerid]) return SendClientMessage(playerid,C_RED2,"Nie jesteś Administrator'em !");
  3869. DerbyEnd();
  3870. SendClientMessageToAll(COLOR_BLUE,"•• |Info| PaintBall przerwane przez admina!");
  3871. return 1;
  3872. }
  3873.  
  3874.  
  3875. CMD:wp(playerid,cmdtext[]){
  3876. cmd_wipeout(playerid,cmdtext);
  3877. return 1;
  3878. }
  3879.  
  3880. CMD:wipeout(playerid,cmdtext[])
  3881. {
  3882. if(TowerON){
  3883. SendClientMessage(playerid,COLOR_RED,"Wipeout już wystartował");
  3884. return 1;
  3885. }
  3886. if(TowerMen[playerid]){
  3887. SendClientMessage(playerid,COLOR_RED,"jestes już zapisany(a) na Wipeout!");
  3888. return 1;
  3889. }
  3890. if(TowerZaglosowal[playerid]){
  3891. SendClientMessage(playerid,COLOR_RED,"Wypisałeś(aś) się już z tej rundy Wipeout!");
  3892. return 1;
  3893. }
  3894. SendClientMessage(playerid,COLOR_GREEN,"Zapisałeś(aś) się na Wipeout");
  3895. new string[500];
  3896. format(string, sizeof(string), "{00FF00}+ {C0C0C0}%s (%d){999999} zapisał(a) się na {C0C0C0}Wipeout!",PlayerName(playerid),playerid);
  3897. SendClientMessageToAll(COLOR_LIGHTRED,string);
  3898. TowerMen[playerid] = true;
  3899. TowerZaglosowal[playerid] = true;
  3900.  
  3901. new LiczbaSian = 0;
  3902. for(new x=0;x<MAX_PLAYERS;x++){
  3903. if(TowerMen[x] && IsPlayerConnected(x)){
  3904. LiczbaSian ++;
  3905. }
  3906. }
  3907. ZapisyUpdate();
  3908. if(LiczbaSian == 2 && !TowerStartON){
  3909. SendClientMessageToAll(0xA346FFFF,"Wipeout wystartuje za 20 sek. (Nadal Trwaja zapisy!)");
  3910. SetTimer("TowerStart",20000,0);
  3911. TowerStartON = true;
  3912. }
  3913. return 1;
  3914. }
  3915. CMD:trexit(playerid,cmdtext[]){
  3916. #pragma unused cmdtext
  3917. if(TowerMen[playerid] && TowerON){
  3918. SetPlayerRandomSpawn(playerid);
  3919. }
  3920. TowerMen[playerid] = false;
  3921. SendClientMessage(playerid,COLOR_GREEN,"Wypisałeś(aś) się z Tower");
  3922. return 1;
  3923. }
  3924. CMD:trend(playerid,cmdtext[])
  3925. {
  3926. if(!Administrator[playerid]) return SendClientMessage(playerid,COLOR_RED,"Nie jesteś Administrator'em !");
  3927. TowerEnd();
  3928. SendClientMessageToAll(COLOR_GREEN,"Tower przerwane przez admina!");
  3929. return 1;
  3930. }
  3931.  
  3932.  
  3933.  
  3934.  
  3935. CMD:so(playerid,cmdtext[]){
  3936. cmd_siano(playerid,cmdtext);
  3937. return 1;
  3938. }
  3939.  
  3940. CMD:siano(playerid,cmdtext[])
  3941. {
  3942. if(SianoON){
  3943. SendClientMessage(playerid,COLOR_RED,"Siano już wystartowały");
  3944. return 1;
  3945. }
  3946. if(SianoMen[playerid]){
  3947. SendClientMessage(playerid,COLOR_RED,"Jesteś już zapisany(a) na Siano!");
  3948. return 1;
  3949. }
  3950. if(SianoZaglosowal[playerid]){
  3951. SendClientMessage(playerid,COLOR_RED,"Wypisałeś(aś) się już z tej rundy derbów!");
  3952. return 1;
  3953. }
  3954. SendClientMessage(playerid,COLOR_GREEN,"Zapisałeś(aś) się na Siano");
  3955. new string[500];
  3956. format(string, sizeof(string), "{00FF00}+ {C0C0C0}%s (%d){999999} zapisał(a) się na {C0C0C0}Siano!",PlayerName(playerid),playerid);
  3957. SendClientMessageToAll(COLOR_LIGHTRED,string);
  3958. SianoMen[playerid] = true;
  3959. SianoZaglosowal[playerid] = true;
  3960. new LiczbaSian = 0;
  3961. for(new x=0;x<MAX_PLAYERS;x++){
  3962. if(SianoMen[x] && IsPlayerConnected(x)){
  3963. LiczbaSian ++;
  3964. }
  3965. }
  3966. ZapisyUpdate();
  3967. if(LiczbaSian == 2 && !SianoStartON){
  3968. SendClientMessageToAll(0xA346FFFF,"Siano wystartują za 20 sek. (Nadal Trwaja zapisy!)");
  3969. SetTimer("SianoStart",20000,0);
  3970. SianoStartON = true;
  3971. }
  3972. return 1;
  3973. }
  3974. CMD:snexit(playerid,cmdtext[]){
  3975. #pragma unused cmdtext
  3976. if(SianoMen[playerid] && SianoON){
  3977. SetPlayerRandomSpawn(playerid);
  3978. }
  3979. SianoMen[playerid] = false;
  3980. SendClientMessage(playerid,COLOR_GREEN,"Wypisałeś(aś) się z siana");
  3981. return 1;
  3982. }
  3983. CMD:snend(playerid,cmdtext[])
  3984. {
  3985. if(!Administrator[playerid]) return SendClientMessage(playerid,C_RED2,"Nie jesteś Administrator'em !");
  3986. SianoEnd();
  3987. SendClientMessageToAll(C_INFO,"Siano przerwane przez admina!");
  3988. return 1;
  3989. }
  3990.  
  3991.  
  3992.  
  3993. CMD:cw(playerid,cmdtext[])
  3994. {
  3995. if(ColorwON){
  3996. SendClientMessage(playerid,COLOR_RED,"Color Wars już wystartowały");
  3997. return 1;
  3998. }
  3999.  
  4000. if(ColorwMen[playerid]){
  4001. SendClientMessage(playerid,COLOR_RED,"Jesteś już zapisany(a) na Color Wars!");
  4002. return 1;
  4003. }
  4004.  
  4005. if(ColorwZaglosowal[playerid]){
  4006. SendClientMessage(playerid,COLOR_RED,"Wypisałeś(aś) się już z tej rundy PaintBalla!");
  4007. return 1;
  4008. }
  4009.  
  4010.  
  4011. SendClientMessage(playerid,COLOR_GREEN,"Zapisałeś(aś) się na Color Wars");
  4012. new string[500];
  4013. format(string, sizeof(string), "{00FF00}+ {C0C0C0}%s (%d){999999} zapisał(a) się na {C0C0C0}Color Wars!",PlayerName(playerid),playerid);
  4014. SendClientMessageToAll(COLOR_LIGHTRED,string);
  4015.  
  4016. ColorwMen[playerid] = true;
  4017. ColorwZaglosowal[playerid] = true;
  4018.  
  4019. new LiczbaColorw = 0;
  4020. for(new x=0;x<MAX_PLAYERS;x++){
  4021. if(ColorwMen[x] && IsPlayerConnected(x)){
  4022. LiczbaColorw ++;
  4023. }
  4024. }
  4025.  
  4026. ZapisyUpdate();
  4027.  
  4028. if(LiczbaColorw == LICZBA_CW && !ColorwStartON){
  4029. SendClientMessageToAll(0xA346FFFF,"Color Wars wystartuje za 20 sek. (Nadal Trwaja zapisy!)");
  4030. SetTimer("ColorwStart",20000,0);
  4031. ColorwStartON = true;
  4032. }
  4033.  
  4034. return 1;
  4035. }
  4036.  
  4037. CMD:cwexit(playerid,cmdtext[])
  4038. {
  4039. if(ColorwMen[playerid] && ColorwON){
  4040. SetPlayerRandomSpawn(playerid);
  4041. }
  4042. ColorwMen[playerid] = false;
  4043. SendClientMessage(playerid,COLOR_GREEN,"Wypisałeś(aś) się z Color Wars");
  4044. return 1;
  4045. }
  4046.  
  4047. CMD:cwend(playerid,cmdtext[])
  4048. {
  4049. if(!Administrator[playerid]) return SendClientMessage(playerid,COLOR_RED,"Nie jesteś Administrator'em !");
  4050. ColorwEnd();
  4051. SendClientMessageToAll(COLOR_RED,"Color Wars przerwane przez admina lub!");
  4052. return 1;
  4053. }
  4054.  
  4055.  
  4056.  
  4057.  
  4058.  
  4059.  
  4060.  
  4061.  
  4062. CMD:db(playerid,cmdtext[]){
  4063. #pragma unused cmdtext
  4064.  
  4065. if(DerbyON){
  4066. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Derby już wystartowały");
  4067. return 1;
  4068. }
  4069.  
  4070. if(DerbyMen[playerid]){
  4071. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Jesteś już zapisany(a) na derby!");
  4072. return 1;
  4073. }
  4074.  
  4075. if(DerbyZaglosowal[playerid]){
  4076. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Wypisałeś(aś) się już z tej rundy derbów!");
  4077. return 1;
  4078. }
  4079.  
  4080. new licz;
  4081. foreach(Player, x){
  4082. if(IsPlayerConnected(x) && DerbyMen[x]){
  4083. licz ++;
  4084. }
  4085. }
  4086.  
  4087. if(licz >= 16){
  4088. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Mamy już max. zapisanych, spróbuj następnym razem!");
  4089. return 1;
  4090. }
  4091.  
  4092. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Zapisałeś(aś) się na derby");
  4093. new string[500];
  4094. format(string, sizeof(string), "{00FF00}+ {C0C0C0}%s (%d){999999} zapisał(a) się na {C0C0C0}Derby!",PlayerName(playerid),playerid);
  4095. SendClientMessageToAll(COLOR_LIGHTRED,string);
  4096. DerbyMen[playerid] = true;
  4097. DerbyZaglosowal[playerid] = true;
  4098.  
  4099. new LiczbaDerb = 0;
  4100. foreach(Player, x){
  4101. if(DerbyMen[x] && IsPlayerConnected(x)){
  4102. LiczbaDerb ++;
  4103. }
  4104. }
  4105.  
  4106. ZapisyUpdate();
  4107.  
  4108. if(LiczbaDerb == 2 && !DerbyStartON){
  4109. SendClientMessageToAll(0xA346FFFF,">>>>>>{FF0000}{FFFFFF}Derby wystartują za 20 sek. (Nadal Trwaja zapisy!)");
  4110. SetTimer("DerbyStart",20000,0);
  4111. DerbyStartON = true;
  4112. }
  4113.  
  4114. return 1;
  4115. }
  4116.  
  4117.  
  4118.  
  4119. CMD:ss(playerid,cmdtext[]){
  4120. #pragma unused cmdtext
  4121.  
  4122. if(Skoczek[playerid]){
  4123. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Jesteś już zapisany(a) na skoki spadochronowe!");
  4124. return 1;
  4125. }
  4126.  
  4127. if(SkoczekZaglosowa[playerid]){
  4128. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Wypisałeś(aś) się już z tej kolejki skoków!");
  4129. return 1;
  4130. }
  4131.  
  4132. Skoczek[playerid] = true;
  4133. SkoczekZaglosowa[playerid] = true;
  4134.  
  4135. new LiczbaSkok = 0;
  4136. foreach(Player, x){
  4137. if(Skoczek[x] && IsPlayerConnected(x)){
  4138. LiczbaSkok ++;
  4139. }
  4140. }
  4141.  
  4142. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Zapisałeś(aś) się na skoki spadochronowe");
  4143. new string[500];
  4144. format(string, sizeof(string), "{00FF00}+ {C0C0C0}%s (%d){999999} zapisał(a) się na {C0C0C0}Skoki Spadochronowe!",PlayerName(playerid),playerid);
  4145. SendClientMessageToAll(COLOR_LIGHTRED,string);
  4146. ZapisyUpdate();
  4147.  
  4148. if(LiczbaSkok == 2 && !SkokiStartON){
  4149. SendClientMessageToAll(0x009CE8FF,">>>>>>{FF0000}{FFFFFF}Skoki spadochronowe wystartują za 20 sek. (Nadal Trwaja zapisy!)");
  4150. SetTimer("SkokiSpadochronowe",20000,0);
  4151. SkokiStartON = true;
  4152. }
  4153.  
  4154. return 1;
  4155. }
  4156.  
  4157.  
  4158.  
  4159. CMD:lb(playerid,cmdtext[]){
  4160. #pragma unused cmdtext
  4161.  
  4162. if(Labirynt[playerid]){
  4163. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Jesteś już zapisany(a) do labiryntu!");
  4164. return 1;
  4165. }
  4166.  
  4167. if(LabON){
  4168. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Labirynt już wystartował!");
  4169. return 1;
  4170. }
  4171.  
  4172. if(LabiryntZaglosowal[playerid]){
  4173. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Wypisałeś(aś) się już z tej kolejki labiryntu!");
  4174. return 1;
  4175. }
  4176.  
  4177. Labirynt[playerid] = true;
  4178. LabiryntZaglosowal[playerid] = true;
  4179.  
  4180. new LiczbaLab = 0;
  4181. foreach(Player, x){
  4182. if(Labirynt[x] && IsPlayerConnected(x)){
  4183. LiczbaLab ++;
  4184. }
  4185. }
  4186.  
  4187. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Zapisałeś(aś) się do labiryntu");
  4188. new string[500];
  4189. format(string, sizeof(string), "{00FF00}+ {C0C0C0}%s (%d){999999} zapisał(a) się na {C0C0C0}Labirynt!",PlayerName(playerid),playerid);
  4190. SendClientMessageToAll(COLOR_LIGHTRED,string);
  4191. ZapisyUpdate();
  4192.  
  4193. if(LiczbaLab == 4 && !LabStartON){
  4194. SendClientMessageToAll(0x5EAEAEFF,">>>>>>{FF0000}{FFFFFF}Labirynt wystartuje za 20 sek. (Nadal Trwaja zapisy!)");
  4195. SetTimer("LabiryntStart",20000,0);
  4196. LabStartON = true;
  4197. KillTimer(LabTimer);
  4198. LabTimer = SetTimer("LabiryntAutoEnd",200000,false);
  4199. }
  4200.  
  4201. return 1;
  4202. }
  4203.  
  4204. CMD:hay(playerid,cmdtext[])
  4205. {
  4206. if(HayON){
  4207. SendClientMessage(playerid,COLOR_RED2,"Hay już wystartowały");
  4208. return 1;
  4209. }
  4210. if(HayMen[playerid]){
  4211. SendClientMessage(playerid,COLOR_RED2,"Jesteś już zapisany(a) na Hay!");
  4212. return 1;
  4213. }
  4214. if(HayZaglosowal[playerid]){
  4215. SendClientMessage(playerid,COLOR_RED2,"Wypisałeś(aś) się już z tej rundy Hay!");
  4216. return 1;
  4217. }
  4218. SendClientMessage(playerid,COLOR_GREEN,"Zapisałeś(aś) się na Hay");
  4219. new string[500];
  4220. format(string, sizeof(string), "{00FF00}+ {C0C0C0}%s (%d){999999} zapisał(a) się na {C0C0C0}Hay!",PlayerName(playerid),playerid);
  4221. SendClientMessageToAll(COLOR_LIGHTRED,string);
  4222. HayMen[playerid] = true;
  4223. HayZaglosowal[playerid] = true;
  4224. new LiczbaHay = 0;
  4225. for(new x=0;x<MAX_PLAYERS;x++){
  4226. if(HayMen[x] && IsPlayerConnected(x)){
  4227. LiczbaHay ++;
  4228. }
  4229. }
  4230. ZapisyUpdate();
  4231. if(LiczbaHay == 2 && !HayStartON){
  4232. SendClientMessageToAll(0xA346FFFF,"Hay wystartują za 20 sek. (Nadal Trwaja zapisy!)");
  4233. SetTimer("HayStart",20000,0);
  4234. HayStartON = true;
  4235. }
  4236. return 1;
  4237. }
  4238. CMD:hayexit(playerid,cmdtext[]){
  4239. #pragma unused cmdtext
  4240. if(HayMen[playerid] && HayON){
  4241. SetPlayerRandomSpawn(playerid);
  4242. }
  4243. HayMen[playerid] = false;
  4244. SendClientMessage(playerid,COLOR_GREEN,"Wypisałeś(aś) się z Hay");
  4245. return 1;
  4246. }
  4247. CMD:hayend(playerid,cmdtext[])
  4248. {
  4249. if(!Administrator[playerid]) return SendClientMessage(playerid,COLOR_RED2,"Nie jesteś Administrator'em !");
  4250. HayEnd();
  4251. SendClientMessageToAll(COLOR_BLUE,"•• |Info| Siano przerwane przez admina!");
  4252. return 1;
  4253. }
  4254. CMD:chexit(playerid,cmdtext[]){
  4255. #pragma unused cmdtext
  4256. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Wypisałeś(aś) się z zabawy w chowanego!");
  4257.  
  4258. if(Chowany[playerid] && ChWystartowala){
  4259. SetPlayerHealth(playerid,100);
  4260. SetPlayerVirtualWorld(playerid,0);
  4261. SetPlayerRandomSpawn(playerid);
  4262. ResetPlayerWeapons(playerid);
  4263. }
  4264.  
  4265. Chowany[playerid] = false;
  4266. Szukajacy[playerid] = false;
  4267.  
  4268. for(new x=0;x<50;x++){
  4269. if(ChowanyKandydat[x] == playerid){
  4270. ChowanyKandydat[x] = -1;
  4271. break;
  4272. }
  4273. }
  4274.  
  4275. return 1;
  4276. }
  4277. CMD:ch(playerid,cmdtext[]){
  4278. #pragma unused cmdtext
  4279.  
  4280. if(Szukajacy[playerid]){
  4281. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Jesteś już zapisany(a) jako szukający!");
  4282. return 1;
  4283. }
  4284.  
  4285. if(ChWystartowala){
  4286. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Zabawa już wystartowała!");
  4287. return 1;
  4288. }
  4289.  
  4290. if(ChowanyZapisany[playerid]){
  4291. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Zapisałeś(aś) się już na chowanego!");
  4292. return 1;
  4293. }
  4294.  
  4295.  
  4296. if(ChNum > -1 && ChNum < 50){
  4297. ChowanyKandydat[ChNum] = playerid;
  4298. ChowanyZapisany[playerid] = true;
  4299. ChNum ++;
  4300. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Zapisałeś(aś) się na zabawę w chowanego!");
  4301. new string[500];
  4302. format(string, sizeof(string), "{00FF00}+ {C0C0C0}%s (%d){999999} zapisał(a) się na {C0C0C0}Chowanego!",PlayerName(playerid),playerid);
  4303. SendClientMessageToAll(COLOR_LIGHTRED,string);
  4304. ZapisyUpdate();
  4305. }else{
  4306. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Zapisało się 50 garczy i jest to maksimum! Spróbuj następnym razem");
  4307. }
  4308.  
  4309. if(ChNum == 4 && !ChStarted){
  4310.  
  4311. SendClientMessageToAll(0x0080FFFF,">>>>>>{FF0000}{FFFFFF}Chowany wystartuje za 20 sek. (Nadal Trwaja zapisy!)");
  4312. KillTimer(ChEndTimer);
  4313. ChEndTimer = SetTimer("ChowanyAutoEnd",600000,false);
  4314. SetTimer("ChowanyWyznaczArene",20000,false);
  4315. ChStarted = true;
  4316.  
  4317. }
  4318.  
  4319. return 1;
  4320. }
  4321.  
  4322.  
  4323. CMD:raceend(playerid,cmdtext[]){
  4324.  
  4325. if(!Administrator[playerid]) return ShowPlayerDialog(playerid,40,0,"{FFFFFF}"NazwaGI" - {FFFF00}Informacja","Brak Uprawnien Admina!","OK","");
  4326.  
  4327. #pragma unused cmdtext
  4328. #pragma unused playerid
  4329. SendClientMessageToAll(COLOR_RED2,"Wyścig został zakończony przez Admina");
  4330. TotalRaceEnd();
  4331. return 1;
  4332. }
  4333.  
  4334.  
  4335. CMD:raceexit(playerid,cmdtext[]){
  4336. #pragma unused cmdtext
  4337. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Wypisałeś(aś) się z wyścigu!");
  4338.  
  4339. if(RaceWystartowal && RaceMen[playerid]){
  4340. SetPlayerVirtualWorld(playerid,0);
  4341. DisablePlayerRaceCheckpoint(playerid);
  4342. }
  4343.  
  4344. RaceMen[playerid] = false;
  4345.  
  4346. RaceMenLiczba = 0;
  4347. foreach(Player, x){
  4348. if(RaceMen[x]){
  4349. RaceMenLiczba ++;
  4350. }
  4351. }
  4352.  
  4353. if(RaceMenLiczba <= 0){
  4354. SendClientMessageToAll(COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Wyścig zakończony!");
  4355. TotalRaceEnd();
  4356. }
  4357.  
  4358. return 1;
  4359. }
  4360.  
  4361. CMD:ws(playerid,cmdtext[]){
  4362. #pragma unused cmdtext
  4363.  
  4364. RaceMenLiczba = 0;
  4365. foreach(Player, x){
  4366. if(RaceMen[x]){
  4367. RaceMenLiczba ++;
  4368. }
  4369. }
  4370.  
  4371. if(RaceWystartowal){
  4372. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Wyścig już wystarował!");
  4373. return 1;
  4374. }
  4375. if(RaceMen[playerid]){
  4376. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Już jesteś zapisany(a) na ten wyścig!");
  4377. return 1;
  4378. }
  4379. if(RaceMenLiczba >= 10){
  4380. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Mamy już pierwszych 10 kandydatów, może następnym razem ci sie uda");
  4381. return 1;
  4382. }
  4383.  
  4384. Drager[playerid] = false;
  4385. RaceMen[playerid] = true;
  4386. RaceCheck[playerid] = 0;
  4387. RaceMenLiczba ++;
  4388.  
  4389. if(RaceMenLiczba == 2){ //4
  4390. SendClientMessageToAll(0x8080FFFF,">>>>>>{FF0000}{FFFFFF}Wyścig wystartuje za 20 sek. (Nadal trwają zapisy)");
  4391. }
  4392.  
  4393. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Zapisałeś(aś) się na wyścig! Aby się wypisać /raceexit");
  4394. new string[500];
  4395. format(string, sizeof(string), "{00FF00}+ {C0C0C0}%s (%d){999999} zapisał(a) się na {C0C0C0}Wyscig!",PlayerName(playerid),playerid);
  4396. SendClientMessageToAll(COLOR_LIGHTRED,string);
  4397. ZapisyUpdate();
  4398.  
  4399. if(RaceMenLiczba == 2){ //4
  4400. SetTimer("RaceAutoStart",20000,0);
  4401. }
  4402.  
  4403. return 1;
  4404. }
  4405. CMD:wgend(playerid,cmdtext[]){//Na Dole Mapy!
  4406.  
  4407. if(!Administrator[playerid]) return ShowPlayerDialog(playerid,40,0,"{FFFFFF}"NazwaGI" - {FFFF00}Informacja","Brak Uprawnien Admina!","OK","");
  4408.  
  4409. WGoff();
  4410. SendClientMessageToAll(COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Wojna Gangow zakonczona przez Admina!");
  4411. return 1;
  4412. #pragma unused cmdtext
  4413. #pragma unused playerid
  4414. }
  4415.  
  4416. CMD:wg(playerid,cmdtext[]){//Na Dole Mapy!
  4417.  
  4418. if(WGON){
  4419. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Wojna Gangow juz wystartowala!");
  4420. return 1;
  4421. }
  4422.  
  4423. if(WGKandydat[playerid]){
  4424. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Jestes juz zapisany(a) na Wojne Gangow!");
  4425. return 1;
  4426. }
  4427.  
  4428. if(WGGlos[playerid]){
  4429. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Wycofales(as) sie z tej rundy WG");
  4430. return 1;
  4431. }
  4432.  
  4433.  
  4434. WGLiczba ++;
  4435. WGKandydat[playerid] = true;
  4436. WGGlos[playerid] = true;
  4437. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Zapisales(as) sie na Wojne Gangow!");
  4438. new string[500];
  4439. format(string, sizeof(string), "{00FF00}+ {C0C0C0}%s (%d){999999} zapisał(a) się na {C0C0C0}Wojne Gangów!",PlayerName(playerid),playerid);
  4440. SendClientMessageToAll(COLOR_LIGHTRED,string);
  4441. ZapisyUpdate();
  4442.  
  4443. if(WGLiczba == 4 && !WGStarted){ //6
  4444. WGStarted = true;
  4445. WGKandydat[playerid] = true;
  4446. SetTimer("WGStart",20000,0);
  4447. SendClientMessageToAll(0x008080FF,">>>>>>{FF0000}{FFFFFF}Wojna Gangow wystartuje za 20 sek. (Nadal Trwaja zapisy!)");
  4448. KillTimer(WGTimer);
  4449. WGTimer = SetTimer("WGoff",240000,0);
  4450. return 1;
  4451. }
  4452.  
  4453. return 1;
  4454. #pragma unused cmdtext
  4455. }
  4456. CMD:ctf(playerid,cmdtext[]){//Na Dole Mapy!
  4457.  
  4458. if(CTFON == 1){
  4459. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Capture The Flag juz wystartowala!");
  4460. return 1;
  4461. }
  4462. if(CTFKandydat[playerid]){
  4463. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Jestes juz zapisany(a) na Capture The Flag!");
  4464. return 1;
  4465. }
  4466.  
  4467. if(CTFGlos[playerid]){
  4468. SendClientMessage(playerid,COLOR_RED2,">>>>>>{FF0000}{FFFFFF}Wycofales(as) sie z tej rundy Capture The Flag");
  4469. return 1;
  4470. }
  4471.  
  4472.  
  4473. CTFLiczba ++;
  4474. CTFKandydat[playerid] = true;
  4475. CTFGlos[playerid] = true;
  4476. SendClientMessage(playerid,COLOR_GREEN,">>>>>>{FF0000}{FFFFFF}Zapisales(as) sie na Capture The Flag!");
  4477. new string[500];
  4478. format(string, sizeof(string), "{00FF00}+ {C0C0C0}%s (%d){999999} zapisał(a) się na {C0C0C0}Capture The Flag!",PlayerName(playerid),playerid);
  4479. SendClientMessageToAll(COLOR_LIGHTRED,string);
  4480. ZapisyUpdate();
  4481.  
  4482.  
  4483. if(CTFLiczba == 4){
  4484. CTFKandydat[playerid] = true;
  4485. SetTimer("CTFStart",20000,0);
  4486. SendClientMessageToAll(0x54A9A9FF,">>>>>>{FF0000}{FFFFFF}Capture The Flag wystartuje za 20 sek. (Nadal Trwaja zapisy!)");
  4487. KillTimer(CTFTimer);
  4488. CTFTimer = SetTimer("CTFoff",240000,0);
  4489. return 1;
  4490. }
  4491.  
  4492.  
  4493. return 1;
  4494. #pragma unused cmdtext
  4495. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement