16.07.2008, 19:19
X_Jobs Include By PeaToN^ And [K4L]Leopard.
This include allows you to add players in 12 different jobs!
The jobs are Police, Medic, army, swat, groove, ballas, drug dealer, president, Driver instructor, Hacker, trucker and Carjacker!![Smiley](images/smilies/smile.png)
Commands
Jobs IDs:
•1 = Police
•2 = Medic
•3 = Army
•4 = SWAT
•5 = Groove
•6 = Ballas
•7 = DrugDealer
•8 = President
•9 = Drive Instructor
•10 = Hacker
•11 = Trucker
•12 = Car Jacker
Script Example:SetJob(10, 55); This will add playerid 55 to job hacker
Note!!! I edited this from "SetJob(jobid, playerid) to SetJob(playerid, jobid)" !!!!
Script Example: RemoveJob(11); Its remove playerids 11 Jobs
Script Example: PaymentTime(240000); It sets Time betwen paychecks 240 Seconds(4 Minutes)
Same ids as for SetJob(jobid, playerid).
Script Example: SetPayment(11, 10000); It changes truckers payment amouind too 10k
Script Example: TeamKillOn(1); It makes a Team Kill protection.
Script Example: SetSkin(11, 155); It changes Truckers Skin to Skinid 155.NOTE: It dont change ACTIVE Truckers SKIN!!!
Script Example: if(GetPlayerJobId(11) == 1) It will check if playerid 11 is a cop.
Download
<== Version 1.9 C [2008-11-03 23:14 GMT +1] Recommended for best results!
PASTABIN: http://pastebin.com/f5c8acf2f
Ideas For Next Release:
but for more that 1 suggestion you can post
Changelog:
This include allows you to add players in 12 different jobs!
The jobs are Police, Medic, army, swat, groove, ballas, drug dealer, president, Driver instructor, Hacker, trucker and Carjacker!
![Smiley](images/smilies/smile.png)
Commands
- Setjob(playerid, jobid)
Jobs IDs:
•1 = Police
•2 = Medic
•3 = Army
•4 = SWAT
•5 = Groove
•6 = Ballas
•7 = DrugDealer
•8 = President
•9 = Drive Instructor
•10 = Hacker
•11 = Trucker
•12 = Car Jacker
Script Example:SetJob(10, 55); This will add playerid 55 to job hacker
Note!!! I edited this from "SetJob(jobid, playerid) to SetJob(playerid, jobid)" !!!!
- Removejob(playerid)
Script Example: RemoveJob(11); Its remove playerids 11 Jobs
- PaymentTime(time);
Script Example: PaymentTime(240000); It sets Time betwen paychecks 240 Seconds(4 Minutes)
- SetPayment(jobid, Payment)
Same ids as for SetJob(jobid, playerid).
Script Example: SetPayment(11, 10000); It changes truckers payment amouind too 10k
- TeamKillOn(True/False)
Script Example: TeamKillOn(1); It makes a Team Kill protection.
- SetSkin(Jobid, Skinid)
Script Example: SetSkin(11, 155); It changes Truckers Skin to Skinid 155.NOTE: It dont change ACTIVE Truckers SKIN!!!
- GetPlayerJobID(playerid)
Script Example: if(GetPlayerJobId(11) == 1) It will check if playerid 11 is a cop.
Download
PASTABIN: http://pastebin.com/f5c8acf2f
Ideas For Next Release:
- Car Jacker = 100%
but for more that 1 suggestion you can post
Changelog:
Код:
[INC]xJobs V 1.9 C: Fixed bug with SetJob(playerid, 1) now it shows right message! ================================ [INC]X_Jobs V 1.9 B: Added Jobs: car jacker Added Function: Orther: Bug fix release. Violation with trucker job fixed now. ================================ [INC]Jobs V 1.9: Added Jobs: Trucker Added Function: Orther: Bug Fix Release, Fixed some Bugs. ================================ [INC]Jobs V 1.8: Added Jobs, Drive Instructor, Hacker Function Added: GetPlayerJobID(playerid); ============================== [INC]Jobs V 1.7: Added Jobs: Drug Dealer, President Added Function: SetSkin(Jobid, Skinid) Orther: A .pwn and .amx included to check how to script those commands. ==================================================Код:[INC]Jobs V 1.6: Added Jobs: Added Function: TeamKillOn(True/False) ================================ [INC]Jobs V 1.5: Added Jobs: SWAT,Groove,Ballas Function Added:PaymentTime(time) ============================== [INC]Jobs V 1.0: Added jobs Police, Medic and Army. Function Added: Setjob(jobid, playerid) Removejob(playerid) SetPayment(jobid, Payment)Код:Script Snippers! Example of SetPlayerJob: if (strcmp("/police", cmdtext, true, 10) == 0) { SetPlayerJob(1,playerid); //This command will make player a police officer. return 1; } Example Of RemoveJob(playerid); public OnPlayerConnect(playerid) { RemoveJob(playerid); return 1; } Example Of SetPayment(jobid); public OnGameModeInit() { SetPayment(1, 1000); // It will set police payment to 1000 return 1; } Example Of TeamKillOn(tru/false); public OnGameModeInit() { TeamKillOn(1);//It will make able to kill polices if your police. return 1; } public OnPlayerConnect(playerid) { if(GetPlayerJobId(playerid) == 0)//This checks if playerid have any job, If not, they jobid is 0, so it means civilian. { SendClientMessage(playerid, COLOR, "SERVER: Your a civilian!"); } return 1; }