Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // ===== Rank system ======
- function RankGained( player )
- {
- local xp = status[ player.ID ].XP,a;
- switch ( xp.tointeger() )
- {
- case "50":
- ServerMessage( player.Name + " has reached a new achievement, rank up: Private I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $1000, +10XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 10;
- IncCash( player, 1000 );
- break;
- case 100:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Private II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $2000, +10XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 10;
- IncCash( player, 2000 );
- break;
- case 1500:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Private III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $3000, +10XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 10;
- IncCash( player, 3000 );
- break;
- case 2050:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Private First Class I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $4000, +10XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 10;
- IncCash( player, 4000 );
- break;
- case 2570:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Private First Class II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $5000, +10XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 10;
- IncCash( player, 5000 );
- break;
- case 3000:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Private First Class III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $6000, +10XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 10;
- IncCash( player, 6000 );
- break;
- case 3500:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Specialist I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $7000, +15XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 15;
- IncCash( player, 7000 );
- break;
- case 4050:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Specialist II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $8000, +15XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 15;
- IncCash( player, 8000 );
- break;
- case 4500:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Specialist III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $9000, +15XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 15;
- IncCash( player, 9000 );
- break;
- case 5000:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Corporal I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $10000, +15XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 15;
- IncCash( player, 10000 );
- break;
- case 5300:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Corporal II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $11000, +15XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 15;
- IncCash( player, 11000 );
- break;
- case 5500:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Corporal III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $12000, +15XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 15;
- IncCash( player, 12000 );
- break;
- case 5950:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $13000, +20XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
- IncCash( player, 13000 );
- break;
- case 6300:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $14000, +20XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
- IncCash( player, 14000 );
- break;
- case 6550:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $15000, +20XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
- IncCash( player, 15000 );
- break;
- case 6800:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Staff Sergeant I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $16000, +20XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
- IncCash( player, 16000 );
- break;
- case 7000:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Staff Sergeant II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $17000, +20XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
- IncCash( player, 17000 );
- break;
- case 7350:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Staff Sergeant III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $18000, +20XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
- IncCash( player, 18000 );
- break;
- case 7700:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant First Class I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $20000, +20XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
- IncCash( player, 20000 );
- break;
- case 8000:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant First Class II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $22000, +20XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
- IncCash( player, 22000 );
- break;
- case 8300:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant First Class III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $25000, +20XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
- IncCash( player, 25000 );
- break;
- case 8780:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant Major I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $26000, +20XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
- IncCash( player, 26000 );
- break;
- case 9000:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant Major II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $27000, +20XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
- IncCash( player, 27000 );
- break;
- case 9300:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Sergeant Major III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $28000, +20XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 20;
- IncCash( player, 28000 );
- break;
- case 9700:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $30000, +25XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
- IncCash( player, 30000 );
- break;
- case 10000:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $32000, +25XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
- IncCash( player, 32000 );
- break;
- case 10350:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $35000, +25XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
- IncCash( player, 35000 );
- break;
- case 10630:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Captain I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $38000, +25XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
- IncCash( player, 38000 );
- break;
- case 11000:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Captain II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $39000, +25XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
- IncCash( player, 39000 );
- break;
- case 11330:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Captain III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $40000, +25XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
- IncCash( player, 40000 );
- break;
- case 11700:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Major I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $41500, +25XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
- IncCash( player, 41500 );
- break;
- case 12030:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Major II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $43000, +25XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
- IncCash( player, 43000 );
- break;
- case 12400:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Major III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $45000, +25XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 25;
- IncCash( player, 45000 );
- break;
- case 12830:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant Colonel I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $47000, +30XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 30;
- IncCash( player, 47000 );
- break;
- case 13100:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant Colonel II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $48000, +30XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 30;
- IncCash( player, 48000 );
- break;
- case 13530:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant Colonel III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $50000, +30XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 30;
- IncCash( player, 50000 );
- break;
- case 13950:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Colonel I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $52000, +30XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 30;
- IncCash( player, 52000 );
- break;
- case 14230:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Colonel II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $53000, +30XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 30;
- IncCash( player, 53000 );
- break;
- case 14560:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Colonel III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $55000, +30XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 30;
- IncCash( player, 55000 );
- break;
- case 14830:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Brigadier General I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $57000, +35XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 35;
- IncCash( player, 57000 );
- break;
- case 15110:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Brigadier General II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $58000, +35XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 35;
- IncCash( player, 58000 );
- break;
- case 15430:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Brigadier General III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $60000, +35XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 35;
- IncCash( player, 60000 );
- break;
- case 15900:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Major General I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $62000, +35XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 35;
- IncCash( player, 62000 );
- break;
- case 16230:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Major General II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $63500, +35XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 35;
- IncCash( player, 63500 );
- break;
- case 16500:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Major General III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $65000, +35XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 35;
- IncCash( player, 65000 );
- break;
- case 17030:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant General I" );
- SendMessage( "Congratulations, you gained a new rank, reward: $70000, +40XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 40;
- IncCash( player, 70000 );
- break;
- case 18000:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant General II" );
- SendMessage( "Congratulations, you gained a new rank, reward: $75000, +50XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 50;
- IncCash( player, 75000 );
- break;
- case 20300:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Lieutenant General III" );
- SendMessage( "Congratulations, you gained a new rank, reward: $80000, +60XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 60;
- IncCash( player, 80000 );
- break;
- case 22000:
- ServerMessage( player.Name + " has reached a new achievement, rank up: General" );
- SendMessage( "Congratulations, you gained a new rank, reward: $100000, +100XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 100;
- IncCash( player, 100000 );
- break;
- case 25000:
- ServerMessage( player.Name + " has reached a new achievement, rank up: Commander" );
- SendMessage( "Congratulations, you gained a new rank, reward: $150000, +200XP", player );
- status[ player.ID ].XP = status[ player.ID ].XP.tointeger() + 200;
- IncCash( player, 150000 );
- break;
- default:
- }
- }
Add Comment
Please, Sign In to add comment