Salary by profession!
#1

Hello gentlemen, I wonder how can I make a salary system by profession?

variable of profession

pawn Код:
if(PlayerInfo[playerid][courier] == 1)
40 in 40 minutes

thanks
Reply
#2

As in each payday, depending on the job you want them to receive different amounts of cash? If that's the case, then:
PHP код:
//Declare person's salery based on job.
if(PlayerInfo[playerid][courier] == 1)
    
PlayerInfo[playerid][pPayday] = changeme;
if(
PlayerInfo[playerid][pizzaboy] == 1)
    
PlayerInfo[playerid][pPayday] = changeme;
//...continue for how many jobs you have.
//On payday..
GivePlayerMoney(playeridPlayerInfo[playerid][pPayday]); 
Reply
#3

Quote:
Originally Posted by JordanZaundd
Посмотреть сообщение
As in each payday, depending on the job you want them to receive different amounts of cash? If that's the case, then:
PHP код:
//Declare person's salery based on job.
if(PlayerInfo[playerid][courier] == 1)
    
PlayerInfo[playerid][pPayday] = changeme;
if(
PlayerInfo[playerid][pizzaboy] == 1)
    
PlayerInfo[playerid][pPayday] = changeme;
//...continue for how many jobs you have.
//On payday..
GivePlayerMoney(playeridPlayerInfo[playerid][pPayday]); 
In the case of this profession the salary would be 800
Reply
#4

Quote:
Originally Posted by TheM4st3r
Посмотреть сообщение
In the case of this profession the salary would be 800
I have put all the variables that you need to change to the payday values as 'changeme'

PHP код:
//So then you would change the 'changeme' in:
if(PlayerInfo[playerid][courier] == 1
    
PlayerInfo[playerid][pPayday] = changeme;
//to look like..
if(PlayerInfo[playerid][courier] == 1
    
PlayerInfo[playerid][pPayday] = 800
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)