eeeasgsfhhfd

Untitled

Aug 18th, 2017
86
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.80 KB | None | 0 0
  1. public OnPlayerDeath(playerid, killerid, reason)
  2. {
  3. SetPlayerArmour(playerid, 0);
  4. //new rand = random(sizeof(RandomSpawn2));
  5. //SetSpawnInfo(playerid, 0, PlayerInfo[playerid][pSkin], RandomSpawn2[rand][0], RandomSpawn2[rand][1], RandomSpawn2[rand][2], 1, 0, 0, 0, 0, 0, 0);
  6. //SpawnPlayer(playerid);
  7. DisablePlayerCheckpoint(playerid);
  8. KillTimer(VuciTimer[playerid]);
  9. PosaoGPS[playerid] = 0;
  10. if(!Policajac(playerid))
  11. {
  12. new Float:Xx,Float:Yy,Float:Zz;
  13. GetPlayerPos(playerid, Xx, Yy, Zz);
  14. DropGun(playerid, GetPlayerWeapon(playerid),GetPlayerAmmo(playerid),Xx,Yy,Zz,GetPlayerVirtualWorld(playerid), GetPlayerInterior(playerid));
  15. }
  16. if(killerid != INVALID_PLAYER_ID) // Valid killer, give cash+score
  17. {
  18. PlayerInfo[killerid][pUbistava]++; PlayerInfo[playerid][pSmrti]++;
  19. ResetPlayerWeapons(playerid); ResetujVar(playerid);
  20. }
  21. if(WarZapocet == 1)
  22. {
  23. if(PlayerInfo[playerid][pWar] == 1)
  24. {
  25. WarBrojanje2++;
  26. PlayerInfo[killerid][pTrazeniLevel] = 0;
  27. SetPlayerColor(killerid, BELA2);
  28. g_NovacPlus(playerid, 100);
  29. }
  30. else if(PlayerInfo[playerid][pWar] == 2)
  31. {
  32. WarBrojanje1++;
  33. PlayerInfo[killerid][pTrazeniLevel] = 0;
  34. SetPlayerColor(killerid, BELA2);
  35. g_NovacPlus(playerid, 100);
  36. }
  37. }
  38. ////////////////////////////////////////////////////////////
  39. if(killerid != INVALID_PLAYER_ID) // Valid killer, give cash+score
  40. {
  41. if(IgracPolicajac(killerid))
  42. {
  43. PlayerInfo[killerid][pTrazeniLevel] = 0;
  44. SetPlayerColor(playerid, 0x2641FEAA);
  45. }
  46. }
  47. ////////////////////////////////////////////////////////////
  48. if(!IgracPolicajac(killerid) && IsPlayerConnected(playerid))
  49. {
  50. if(PlayerInfo[killerid][pWar] > 0) return 1;
  51. if(killerid != INVALID_PLAYER_ID) // Valid killer, give cash+score
  52. {
  53.  
  54. PostaviWanted(killerid, "Ubistvo", "Nepoznat", 3);
  55. }
  56. }
  57. ////////////////////////////////////////////////////////////
  58. if(PlayerInfo[killerid][pTrazeniLevel] > 1000)
  59. {
  60. PlayerInfo[killerid][pTrazeniLevel] = 1000;
  61. }
  62. if((!Policajac(killerid) && PlayerInfo[killerid][pUfbi] == 1) && Policajac(playerid))
  63. {
  64. new rand = random(sizeof(RandomZatvor));
  65. SetPlayerPos(killerid, RandomZatvor[rand][0], RandomZatvor[rand][1], RandomZatvor[rand][2]);
  66. SetPlayerInterior(killerid, 0);
  67. TogglePlayerControllable(killerid, 0);
  68. freeze[killerid] = SetTimerEx("Freeze",5000, false, "i", killerid);
  69. PlayerInfo[killerid][pZatvor] = 2;
  70. PlayerInfo[killerid][pZatvorenVreme] = 30*60;
  71. new string[256];
  72. format(string, sizeof(string), ""CRVENA"[SC:RPG] Zatvoreni ste u zatvor na 30 minuta zbog SK!.");
  73. SCM(killerid, -1, string);
  74. format(string,sizeof(string), ""CRVENA"[SC:RPG SK] "SIVA"Igrac %s (ID:%d) je uradio SK nad igracem %s (ID:%d) i zatvoren je na 30 minuta!", GetName(killerid), killerid, GetName(playerid), playerid);
  75. AdminGameMaster(-1, string);
  76. }
  77. ////////////////////////////////////////////////////////////
  78. if(PlayerInfo[playerid][pTrazeniLevel] > 0)
  79. {
  80. new string[256];
  81. g_NovacMinus(playerid, PlayerInfo[playerid][pTrazeniLevel]*3000);
  82. SCMF(playerid, -1, ""ZUTA"[INFO] "CRVENA"Izgubili ste %d$ zbog umiranja sa wanted level-om "ZUTA"%d!", PlayerInfo[playerid][pTrazeniLevel]*1500, PlayerInfo[playerid][pTrazeniLevel]);
  83. PlayerInfo[playerid][pTrazeniLevel] = 0;
  84. format(string,sizeof(string),""CRVENA"[SC:RPG] "BELA"Igrac %s je ubijen/se ubio sa wanted level-om!",GetName(playerid));
  85. CFBIPD(-1, string);
  86. SetPlayerColor(playerid, BELA2);
  87. }
  88. ////////////////////////////////////////////////////////////
  89. if(IsPlayerConnected(killerid) && GetPlayerState(killerid) == PLAYER_STATE_DRIVER)
  90. {
  91. new string[256];
  92. format(string,sizeof(string), ""CRVENA"[SC:RPG Anti DB] "SIVA"Igrac %s (ID:%d) je uradio Drive By nad igracem %s (ID:%d)!", GetName(killerid), killerid, GetName(playerid), playerid);
  93. AdminGameMaster(-1, string);
  94. SetPlayerColor(killerid, COLOR_RED);
  95. }
  96. ////////////////////////////////////////////////////////////
  97. if(IsPlayerConnected(killerid) && PlayerInfo[playerid][pLevel] >= 1)
  98. {
  99. new string[256];
  100. format(string,sizeof(string), ""CRVENA"[SC:RPG AK] "SIVA"Igrac %s (ID:%d) je ubio igraca %s (ID:%d)", GetName(killerid), killerid, GetName(playerid), playerid);
  101. AdminGameMaster(-1, string);
  102. if(!Policajac(killerid))
  103. {
  104. SetPlayerColor(killerid, COLOR_RED);
  105. }
  106. if(PlayerInfo[playerid][pNarucen] == 1 && (PlayerInfo[killerid][pClan] == 10 || PlayerInfo[killerid][pLider] == 10))
  107. {
  108. g_NovacPlus(killerid, 17000);
  109. SCM(killerid,-1,""SPLAVA"[SC:RPG]:"BELA"Ubili ste trazenog igraca i dobili 17 000 $!");
  110. PlayerInfo[killerid][pTrazeniLevel] = 0;
  111. SetPlayerColor(killerid, BELA2);
  112. PlayerInfo[playerid][pNarucen] = 0;
  113. format(string,sizeof(string),"[SC:RPG] "ZUTA"Placeni ubica je ubio %s i izvrsio svoj zadatak!", GetName(playerid));
  114. SCMTA(-1,string);
  115. }
  116. }
  117. ////////////////////////////////////////////////////////////
  118. if(gPlayerUsingLoopingAnim[playerid])
  119. {
  120. gPlayerUsingLoopingAnim[playerid] = 0;
  121. }
  122.  
  123. if(InCP[playerid][Idlewood] == 1)
  124. {
  125. KillTimer(g_timer[playerid][Idlewood]);
  126. KillTimer(CountTime[playerid]);
  127. UnderAttack[Idlewood] = 0;
  128. }
  129. if(InCP[playerid][Hospital] == 1)
  130. {
  131. KillTimer(g_timer[playerid][Hospital]);
  132. KillTimer(CountTime[playerid]);
  133. UnderAttack[Hospital] = 0;
  134. }
  135. if(InCP[playerid][Ammunation] == 1)
  136. {
  137. KillTimer(g_timer[playerid][Ammunation]);
  138. KillTimer(CountTime[playerid]);
  139. UnderAttack[Ammunation] = 0;
  140. }
  141. if(InCP[playerid][Stadium] == 1)
  142. {
  143. KillTimer(g_timer[playerid][Stadium]);
  144. KillTimer(CountTime[playerid]);
  145. UnderAttack[Stadium] = 0;
  146. }
  147. ////////////////////////////////////////////////////////////
  148. if(reason == 22)
  149. {
  150. if(PlayerInfo[killerid][pPistSkill] >= 0 && PlayerInfo[killerid][pPistSkill] <= 1000)
  151. {
  152. PlayerInfo[killerid][pPistSkill] += 2;
  153. SetPlayerSkills(killerid);
  154. }
  155. }
  156. if(reason == 23)
  157. {
  158. if(PlayerInfo[killerid][pSilenSkill] >= 0 && PlayerInfo[killerid][pSilenSkill] <= 1000)
  159. {
  160. PlayerInfo[killerid][pSilenSkill] += 2;
  161. SetPlayerSkills(killerid);
  162. }
  163. }
  164. if(reason == 24)
  165. {
  166. if(PlayerInfo[killerid][pDesertSkill] >= 0 && PlayerInfo[killerid][pDesertSkill] <= 1000)
  167. {
  168. PlayerInfo[killerid][pDesertSkill] += 2;
  169. SetPlayerSkills(killerid);
  170. }
  171. }
  172. if(reason == 25)
  173. {
  174. if(PlayerInfo[killerid][pShotgSkill] >= 0 && PlayerInfo[killerid][pShotgSkill] <= 1000)
  175. {
  176. PlayerInfo[killerid][pShotgSkill] += 2;
  177. SetPlayerSkills(killerid);
  178. }
  179. }
  180. if(reason == 26)
  181. {
  182. if(PlayerInfo[killerid][pSawnSkill] >= 0 && PlayerInfo[killerid][pSawnSkill] <= 800)
  183. {
  184. PlayerInfo[killerid][pSawnSkill] += 2;
  185. SetPlayerSkills(killerid);
  186. }
  187. }
  188. if(reason == 27)
  189. {
  190. if(PlayerInfo[killerid][pCombSkill] >= 0 && PlayerInfo[killerid][pCombSkill] <= 1000)
  191. {
  192. PlayerInfo[killerid][pCombSkill] += 2;
  193. SetPlayerSkills(killerid);
  194. }
  195. }
  196.  
  197. if(reason == 28 || reason == 32)
  198. {
  199. if(PlayerInfo[killerid][pUziSkill] >= 0 && PlayerInfo[killerid][pUziSkill] <= 800)
  200. {
  201. PlayerInfo[killerid][pUziSkill] += 2;
  202. SetPlayerSkills(killerid);
  203. }
  204. }
  205.  
  206. if(reason == 29)
  207. {
  208. if(PlayerInfo[killerid][pSmgSkill] >= 0 && PlayerInfo[killerid][pSmgSkill] <= 1000)
  209. {
  210. PlayerInfo[killerid][pSmgSkill] += 2;
  211. SetPlayerSkills(killerid);
  212. }
  213. }
  214.  
  215. if(reason == 30)
  216. {
  217. if(PlayerInfo[killerid][pAkSkill] >= 0 && PlayerInfo[killerid][pAkSkill] <= 1000)
  218. {
  219. PlayerInfo[killerid][pAkSkill] += 2;
  220. SetPlayerSkills(killerid);
  221. }
  222. }
  223.  
  224. if(reason == 31)
  225. {
  226. if(PlayerInfo[killerid][pM4Skill] >= 0 && PlayerInfo[killerid][pM4Skill] <= 1000)
  227. {
  228. PlayerInfo[killerid][pM4Skill] += 2;
  229. SetPlayerSkills(killerid);
  230. }
  231. }
  232. return 1;
  233. }
  234.  
  235. encode_tires(tire1, tire2, tire3, tire4) return tire1 | (tire2 << 1) | (tire3 << 2) | (tire4 << 3);
Advertisement
Add Comment
Please, Sign In to add comment