MuhammadZeeshan

asfasfgasgas

May 21st, 2017
31
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 14.70 KB | None | 0 0
  1. // ===== Rank system ======
  2. function RankGained( player )
  3. {
  4. local xp = status[ player.ID ].XP,a;
  5. switch ( xp.tointeger() )
  6. {
  7. case "50":
  8. ServerMessage( player.Name + " has reached a new achievement, rank up: Private I" );
  9. SendMessage( "Congratulations, you gained a new rank, reward: $1000, +10XP", player );
  10. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 10;
  11. IncCash( player, 1000 );
  12. break;
  13.  
  14. case 100:
  15. ServerMessage( player.Name + " has reached a new achievement, rank up: Private II" );
  16. SendMessage( "Congratulations, you gained a new rank, reward: $2000, +10XP", player );
  17. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 10;
  18. IncCash( player, 2000 );
  19. break;
  20.  
  21. case 1500:
  22. ServerMessage( player.Name + " has reached a new achievement, rank up: Private III" );
  23. SendMessage( "Congratulations, you gained a new rank, reward: $3000, +10XP", player );
  24. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 10;
  25. IncCash( player, 3000 );
  26. break;
  27.  
  28. case 2050:
  29. ServerMessage( player.Name + " has reached a new achievement, rank up: Private First Class I" );
  30. SendMessage( "Congratulations, you gained a new rank, reward: $4000, +10XP", player );
  31. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 10;
  32. IncCash( player, 4000 );
  33. break;
  34.  
  35. case 2570:
  36. ServerMessage( player.Name + " has reached a new achievement, rank up: Private First Class II" );
  37. SendMessage( "Congratulations, you gained a new rank, reward: $5000, +10XP", player );
  38. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 10;
  39. IncCash( player, 5000 );
  40. break;
  41.  
  42. case 3000:
  43. ServerMessage( player.Name + " has reached a new achievement, rank up: Private First Class III" );
  44. SendMessage( "Congratulations, you gained a new rank, reward: $6000, +10XP", player );
  45. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 10;
  46. IncCash( player, 6000 );
  47. break;
  48.  
  49. case 3500:
  50. ServerMessage( player.Name + " has reached a new achievement, rank up: Specialist I" );
  51. SendMessage( "Congratulations, you gained a new rank, reward: $7000, +15XP", player );
  52. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 15;
  53. IncCash( player, 7000 );
  54. break;
  55.  
  56. case 4050:
  57. ServerMessage( player.Name + " has reached a new achievement, rank up: Specialist II" );
  58. SendMessage( "Congratulations, you gained a new rank, reward: $8000, +15XP", player );
  59. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 15;
  60. IncCash( player, 8000 );
  61. break;
  62.  
  63. case 4500:
  64. ServerMessage( player.Name + " has reached a new achievement, rank up: Specialist III" );
  65. SendMessage( "Congratulations, you gained a new rank, reward: $9000, +15XP", player );
  66. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 15;
  67. IncCash( player, 9000 );
  68. break;
  69.  
  70. case 5000:
  71. ServerMessage( player.Name + " has reached a new achievement, rank up: Corporal I" );
  72. SendMessage( "Congratulations, you gained a new rank, reward: $10000, +15XP", player );
  73. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 15;
  74. IncCash( player, 10000 );
  75. break;
  76.  
  77. case 5300:
  78. ServerMessage( player.Name + " has reached a new achievement, rank up: Corporal II" );
  79. SendMessage( "Congratulations, you gained a new rank, reward: $11000, +15XP", player );
  80. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 15;
  81. IncCash( player, 11000 );
  82. break;
  83.  
  84. case 5500:
  85. ServerMessage( player.Name + " has reached a new achievement, rank up: Corporal III" );
  86. SendMessage( "Congratulations, you gained a new rank, reward: $12000, +15XP", player );
  87. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 15;
  88. IncCash( player, 12000 );
  89. break;
  90.  
  91. case 5950:
  92. ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant I" );
  93. SendMessage( "Congratulations, you gained a new rank, reward: $13000, +20XP", player );
  94. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
  95. IncCash( player, 13000 );
  96. break;
  97.  
  98. case 6300:
  99. ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant II" );
  100. SendMessage( "Congratulations, you gained a new rank, reward: $14000, +20XP", player );
  101. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
  102. IncCash( player, 14000 );
  103. break;
  104.  
  105. case 6550:
  106. ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant III" );
  107. SendMessage( "Congratulations, you gained a new rank, reward: $15000, +20XP", player );
  108. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
  109. IncCash( player, 15000 );
  110. break;
  111.  
  112. case 6800:
  113. ServerMessage( player.Name + " has reached a new achievement, rank up: Staff Sergeant I" );
  114. SendMessage( "Congratulations, you gained a new rank, reward: $16000, +20XP", player );
  115. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
  116. IncCash( player, 16000 );
  117. break;
  118.  
  119. case 7000:
  120. ServerMessage( player.Name + " has reached a new achievement, rank up: Staff Sergeant II" );
  121. SendMessage( "Congratulations, you gained a new rank, reward: $17000, +20XP", player );
  122. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
  123. IncCash( player, 17000 );
  124. break;
  125.  
  126. case 7350:
  127. ServerMessage( player.Name + " has reached a new achievement, rank up: Staff Sergeant III" );
  128. SendMessage( "Congratulations, you gained a new rank, reward: $18000, +20XP", player );
  129. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
  130. IncCash( player, 18000 );
  131. break;
  132.  
  133. case 7700:
  134. ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant First Class I" );
  135. SendMessage( "Congratulations, you gained a new rank, reward: $20000, +20XP", player );
  136. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
  137. IncCash( player, 20000 );
  138. break;
  139.  
  140. case 8000:
  141. ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant First Class II" );
  142. SendMessage( "Congratulations, you gained a new rank, reward: $22000, +20XP", player );
  143. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
  144. IncCash( player, 22000 );
  145. break;
  146.  
  147. case 8300:
  148. ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant First Class III" );
  149. SendMessage( "Congratulations, you gained a new rank, reward: $25000, +20XP", player );
  150. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
  151. IncCash( player, 25000 );
  152. break;
  153.  
  154. case 8780:
  155. ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant Major I" );
  156. SendMessage( "Congratulations, you gained a new rank, reward: $26000, +20XP", player );
  157. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
  158. IncCash( player, 26000 );
  159. break;
  160.  
  161. case 9000:
  162. ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant Major II" );
  163. SendMessage( "Congratulations, you gained a new rank, reward: $27000, +20XP", player );
  164. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
  165. IncCash( player, 27000 );
  166. break;
  167.  
  168. case 9300:
  169. ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant Major III" );
  170. SendMessage( "Congratulations, you gained a new rank, reward: $28000, +20XP", player );
  171. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
  172. IncCash( player, 28000 );
  173. break;
  174.  
  175. case 9700:
  176. ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant I" );
  177. SendMessage( "Congratulations, you gained a new rank, reward: $30000, +25XP", player );
  178. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
  179. IncCash( player, 30000 );
  180. break;
  181.  
  182. case 10000:
  183. ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant II" );
  184. SendMessage( "Congratulations, you gained a new rank, reward: $32000, +25XP", player );
  185. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
  186. IncCash( player, 32000 );
  187. break;
  188.  
  189. case 10350:
  190. ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant III" );
  191. SendMessage( "Congratulations, you gained a new rank, reward: $35000, +25XP", player );
  192. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
  193. IncCash( player, 35000 );
  194. break;
  195.  
  196. case 10630:
  197. ServerMessage( player.Name + " has reached a new achievement, rank up: Captain I" );
  198. SendMessage( "Congratulations, you gained a new rank, reward: $38000, +25XP", player );
  199. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
  200. IncCash( player, 38000 );
  201. break;
  202.  
  203. case 11000:
  204. ServerMessage( player.Name + " has reached a new achievement, rank up: Captain II" );
  205. SendMessage( "Congratulations, you gained a new rank, reward: $39000, +25XP", player );
  206. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
  207. IncCash( player, 39000 );
  208. break;
  209.  
  210. case 11330:
  211. ServerMessage( player.Name + " has reached a new achievement, rank up: Captain III" );
  212. SendMessage( "Congratulations, you gained a new rank, reward: $40000, +25XP", player );
  213. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
  214. IncCash( player, 40000 );
  215. break;
  216.  
  217. case 11700:
  218. ServerMessage( player.Name + " has reached a new achievement, rank up: Major I" );
  219. SendMessage( "Congratulations, you gained a new rank, reward: $41500, +25XP", player );
  220. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
  221. IncCash( player, 41500 );
  222. break;
  223.  
  224. case 12030:
  225. ServerMessage( player.Name + " has reached a new achievement, rank up: Major II" );
  226. SendMessage( "Congratulations, you gained a new rank, reward: $43000, +25XP", player );
  227. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
  228. IncCash( player, 43000 );
  229. break;
  230.  
  231. case 12400:
  232. ServerMessage( player.Name + " has reached a new achievement, rank up: Major III" );
  233. SendMessage( "Congratulations, you gained a new rank, reward: $45000, +25XP", player );
  234. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
  235. IncCash( player, 45000 );
  236. break;
  237.  
  238. case 12830:
  239. ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant Colonel I" );
  240. SendMessage( "Congratulations, you gained a new rank, reward: $47000, +30XP", player );
  241. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 30;
  242. IncCash( player, 47000 );
  243. break;
  244.  
  245. case 13100:
  246. ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant Colonel II" );
  247. SendMessage( "Congratulations, you gained a new rank, reward: $48000, +30XP", player );
  248. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 30;
  249. IncCash( player, 48000 );
  250. break;
  251.  
  252. case 13530:
  253. ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant Colonel III" );
  254. SendMessage( "Congratulations, you gained a new rank, reward: $50000, +30XP", player );
  255. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 30;
  256. IncCash( player, 50000 );
  257. break;
  258.  
  259. case 13950:
  260. ServerMessage( player.Name + " has reached a new achievement, rank up: Colonel I" );
  261. SendMessage( "Congratulations, you gained a new rank, reward: $52000, +30XP", player );
  262. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 30;
  263. IncCash( player, 52000 );
  264. break;
  265.  
  266. case 14230:
  267. ServerMessage( player.Name + " has reached a new achievement, rank up: Colonel II" );
  268. SendMessage( "Congratulations, you gained a new rank, reward: $53000, +30XP", player );
  269. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 30;
  270. IncCash( player, 53000 );
  271. break;
  272.  
  273. case 14560:
  274. ServerMessage( player.Name + " has reached a new achievement, rank up: Colonel III" );
  275. SendMessage( "Congratulations, you gained a new rank, reward: $55000, +30XP", player );
  276. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 30;
  277. IncCash( player, 55000 );
  278. break;
  279.  
  280. case 14830:
  281. ServerMessage( player.Name + " has reached a new achievement, rank up: Brigadier General I" );
  282. SendMessage( "Congratulations, you gained a new rank, reward: $57000, +35XP", player );
  283. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 35;
  284. IncCash( player, 57000 );
  285. break;
  286.  
  287. case 15110:
  288. ServerMessage( player.Name + " has reached a new achievement, rank up: Brigadier General II" );
  289. SendMessage( "Congratulations, you gained a new rank, reward: $58000, +35XP", player );
  290. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 35;
  291. IncCash( player, 58000 );
  292. break;
  293.  
  294. case 15430:
  295. ServerMessage( player.Name + " has reached a new achievement, rank up: Brigadier General III" );
  296. SendMessage( "Congratulations, you gained a new rank, reward: $60000, +35XP", player );
  297. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 35;
  298. IncCash( player, 60000 );
  299. break;
  300.  
  301. case 15900:
  302. ServerMessage( player.Name + " has reached a new achievement, rank up: Major General I" );
  303. SendMessage( "Congratulations, you gained a new rank, reward: $62000, +35XP", player );
  304. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 35;
  305. IncCash( player, 62000 );
  306. break;
  307.  
  308. case 16230:
  309. ServerMessage( player.Name + " has reached a new achievement, rank up: Major General II" );
  310. SendMessage( "Congratulations, you gained a new rank, reward: $63500, +35XP", player );
  311. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 35;
  312. IncCash( player, 63500 );
  313. break;
  314.  
  315. case 16500:
  316. ServerMessage( player.Name + " has reached a new achievement, rank up: Major General III" );
  317. SendMessage( "Congratulations, you gained a new rank, reward: $65000, +35XP", player );
  318. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 35;
  319. IncCash( player, 65000 );
  320. break;
  321.  
  322. case 17030:
  323. ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant General I" );
  324. SendMessage( "Congratulations, you gained a new rank, reward: $70000, +40XP", player );
  325. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 40;
  326. IncCash( player, 70000 );
  327. break;
  328.  
  329. case 18000:
  330. ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant General II" );
  331. SendMessage( "Congratulations, you gained a new rank, reward: $75000, +50XP", player );
  332. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 50;
  333. IncCash( player, 75000 );
  334. break;
  335.  
  336. case 20300:
  337. ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant General III" );
  338. SendMessage( "Congratulations, you gained a new rank, reward: $80000, +60XP", player );
  339. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 60;
  340. IncCash( player, 80000 );
  341. break;
  342.  
  343. case 22000:
  344. ServerMessage( player.Name + " has reached a new achievement, rank up: General" );
  345. SendMessage( "Congratulations, you gained a new rank, reward: $100000, +100XP", player );
  346. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 100;
  347. IncCash( player, 100000 );
  348. break;
  349.  
  350. case 25000:
  351. ServerMessage( player.Name + " has reached a new achievement, rank up: Commander" );
  352. SendMessage( "Congratulations, you gained a new rank, reward: $150000, +200XP", player );
  353. status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 200;
  354. IncCash( player, 150000 );
  355. break;
  356.  
  357. default:
  358. }
  359. }
Add Comment
Please, Sign In to add comment