Paycheck to Payday
#1

How to make every payments of job will get on PayDay
For example i working in PizzaStack and i Delivered 10 Pizza i will get 400$ on my PayDay
Is there any link of Example?
Reply
#2

Which values that would be assigned per Pizza Delivered?

@Edit
400/10 = 40, so I put 40 for this value.
PHP код:
#include <a_samp>
forward PayDay();
#define DELIVERED_PIZZA_VALUE (40) // Change if you wish
new
    
DeliveredPizza[MAX_PLAYERS], // Pizzas Delivered
    
PizzaDelivery[MAX_PLAYERS]; // If he works of Pizza Delivery
    
public OnFilterScriptInit()
{
    
SetTimer("PayDay"60000*60true); // Payday Of one in one hour
    
return 1;
}
public 
PayDay()
{
    for(new 
iMAX_PLAYERSi++)
        if(
PizzaDelivery[i])
            
GivePlayerMoney(iDeliveredPizza[i]*DELIVERED_PIZZA_VALUE);
    return 
1;

sorry for my bad english.
Reply
#3

Quote:
Originally Posted by DanDRT
Посмотреть сообщение
Which values that would be assigned per Pizza Delivered?

@Edit
400/10 = 40, so I put 40 for this value.
PHP код:
#include <a_samp>
forward PayDay();
#define DELIVERED_PIZZA_VALUE (40) // Change if you wish
new
    
DeliveredPizza[MAX_PLAYERS], // Pizzas Delivered
    
PizzaDelivery[MAX_PLAYERS]; // If he works of Pizza Delivery
    
public OnFilterScriptInit()
{
    
SetTimer("PayDay"60000*60true); // Payday Of one in one hour
    
return 1;
}
public 
PayDay()
{
    for(new 
iMAX_PLAYERSi++)
        if(
PizzaDelivery[i])
            
GivePlayerMoney(iDeliveredPizza[i]*DELIVERED_PIZZA_VALUE);
    return 
1;

sorry for my bad english.
Can you transfer this??
Define
PHP код:
#define TYPE_TPPIZZARUNTIMER 13
#define TYPE_PIZZATIMER 14 
Command
Код:
CMD:getpizza(playerid, params[])
{
	if(PlayerInfo[playerid][pJob] != 21 && PlayerInfo[playerid][pJob2] != 21)
	{
		SendClientMessage(playerid,COLOR_GREY,"   You're not a Pizza Boy!");
		return 1;
	}
    new vehicleid = GetPlayerVehicleID(playerid);
    if(!(IsAPizzaCar(vehicleid) && GetPlayerState(playerid) == PLAYER_STATE_DRIVER))
	{
	    SendClientMessage(playerid,COLOR_GREY,"   You need to be driving a pizzaboy found at the side of the Pizza Stack!");
	    return 1;
	}
	if(!(GetPlayerSkin(playerid) == 155))
	{
	    SendClientMessage(playerid,COLOR_GREY,"   You need to be in the Pizza Stack uniform!");
	    return 1;
	}
	new playername[MAX_PLAYER_NAME];
	GetPlayerName(playerid, playername, sizeof(playername));
	if(!IsPlayerInRangeOfPoint(playerid, 3.0, 2099.2761,-1804.8387,13.5547))
	{
		SendClientMessage(playerid,COLOR_GREY,"   You're not at the Pizza Stack pickup!");
		return 1;
	}
	if(GetPVarInt(playerid, "Pizza") > 0)
	{
		SendClientMessage(playerid, COLOR_GREY, "   You're already delivering pizzas!");
		return 1;
	}

	/*new rand = random(MAX_HOUSES -1);
	while(!(HouseInfo[rand][hExteriorZ] < 150.0 && HouseInfo[rand][hExteriorX] > 17.59 && HouseInfo[rand][hExteriorX] < 3004.64 && HouseInfo[rand][hExteriorY] < -805.45 && HouseInfo[rand][hExteriorY] > -2736.25))
	{
	    rand++;
	    if(rand == MAX_HOUSES) {
	    	rand = 1;
		}
		//printf("%d", rand);
	}*/

	new rand = random(165);
	while(!(HouseInfo[rand][hExteriorZ] < 150.0 && HouseInfo[rand][hExteriorX] > 17.59 && HouseInfo[rand][hExteriorX] < 3004.64 && HouseInfo[rand][hExteriorY] < -805.45 && HouseInfo[rand][hExteriorY] > -2736.25))
	{
	    rand++;
	    if(rand == 165) {
	    	rand = 1;
		}
		//printf("%d", rand);
	}

	SetPVarInt(playerid, "tpPizzaTimer", floatround((GetPizzaDistance(rand) / 60), floatround_round));
	SetPVarInt(playerid, "pizzaTotal", floatround((GetPizzaDistance(rand) / 10), floatround_round));
	SetPVarInt(playerid, "pizzaTimer", GetPVarInt(playerid, "pizzaTotal"));
 	SetTimerEx("OtherTimerEx", 1000, false, "ii", playerid, TYPE_TPPIZZARUNTIMER);
 	SetTimerEx("OtherTimerEx", 1000, false, "ii", playerid, TYPE_PIZZATIMER);
	new szMessage[128];

 	if(HouseInfo[rand][hOwned] == 0)
 	{
 	    format(szMessage, sizeof(szMessage), "You have picked up a pizza for someone. You have %d seconds to deliver it!", GetPVarInt(playerid, "pizzaTotal"));
 	}
 	else
	{
		format(szMessage, sizeof(szMessage), "You have picked up a pizza for %s. You have %d seconds to deliver it!", HouseInfo[rand][hOwner], GetPVarInt(playerid, "pizzaTotal"));
	}

	SendClientMessage(playerid, COLOR_WHITE, szMessage);
	SetPVarInt(playerid, "Pizza", rand);
	PizzaBar[playerid] = CreateProgressBar(258.00, 137.00, 131.50, 3.19, COLOR_GREEN, 100.0);
	SetProgressBarValue(PizzaBar[playerid], 100.0);
	ShowProgressBarForPlayer(playerid, PizzaBar[playerid]);
	SetPlayerCheckpoint(playerid, HouseInfo[rand][hExteriorX], HouseInfo[rand][hExteriorY], HouseInfo[rand][hExteriorZ], 5);
	return 1;
}
Payments
PHP код:
// Pizza Delivery
      
if(GetPVarInt(playerid"Pizza") > && IsPlayerInRangeOfPoint(playerid5.0HouseInfo[GetPVarInt(playerid"Pizza")][hExteriorX], HouseInfo[GetPVarInt(playerid"Pizza")][hExteriorY], HouseInfo[GetPVarInt(playerid"Pizza")][hExteriorZ]))
    {
        new 
string[128];
        if (
GetPVarInt(playerid"tpPizzaTimer") != 0)
        {
            
format(stringsizeof(string), "{AA3333}AdmWarning{FFFF00}: %s (ID %d) is possibly teleport pizzarunning."GetPlayerNameEx(playerid), playerid);
              
ABroadCastCOLOR_YELLOWstring);
            
format(stringsizeof(string), "%s (ID %d) is possibly teleport pizzarunning."GetPlayerNameEx(playerid), playerid);
            
Log("logs/hack.log"string);
        }
        
DestroyProgressBar(PizzaBar[playerid]);
        
format(stringsizeof(string), "You have delivered the pizza to the destination! You have made $%d.", (GetPVarInt(playerid"pizzaTimer")));
        
Tax -= (GetPVarInt(playerid"pizzaTimer") * 10);
        
SaveStuff();
        
GivePlayerCash(playeridfloatround((GetPVarInt(playerid"pizzaTimer")), floatround_round));
        
SendClientMessageEx(playeridCOLOR_WHITEstring);
        
SetPVarInt(playerid"Pizza"0);
        
DisablePlayerCheckpoint(playerid);
    } 
PayDay
PHP код:
public PayDay()
{
    new 
string[128];
    new 
account,interest,businesspay[MAX_PLAYERS], welfarepay;
    new 
rent 0;
    
GiftAllowed 1;
    
RaidAllowed 1;
    
matssys[MatsAmmount] += random(50000)+5000;
    
Tax -= random(500000); // Money for running public services.
    // For New Turf Perks
    
for(new tw=0tw<MAX_TURFStw++)
    {
        new 
twpcount;
        foreach(
Playerp)
         {
            if(
GetPlayerTurfWarsZone(p) == tw && PlayerInfo[p][pFMember] == TurfWars[tw][twOwnerId])
            {
                
twpcount ++;
            }
        }
        if(
twpcount >= 3)
        {
            switch(
TurfWars[tw][twSpecial])
            {
                case 
0// Default, none
                
{
                }
                case 
1// Pot Seeds Generation
                
{
                    new 
potrand random(100);
                    
FamilyInfo[TurfWars[tw][twOwnerId]][FamilySeeds] += potrand;
                    
format(string,sizeof(string),"[FAMILY EXTORTION] Your family has received %d Pot Seeds into the family safe from extortion.",potrand);
                    
SendFamMessage(TurfWars[tw][twOwnerId], COLOR_YELLOWstring);
                }
                case 
2// Crack Ingredients Generation
                
{
                    new 
crackrand random(100);
                    
FamilyInfo[TurfWars[tw][twOwnerId]][FamilyCrackStuff] += crackrand;
                    
format(string,sizeof(string),"[FAMILY EXTORTION] Your family has received %d Grams of Sodium Bicarbonate into the family safe from extortion.",crackrand);
                    
SendFamMessage(TurfWars[tw][twOwnerId], COLOR_YELLOWstring);
                }
                case 
3// Raw Opium Generation
                
{
                    new 
heroinrand random(10);
                    
FamilyInfo[TurfWars[tw][twOwnerId]][FamilyOpium] += heroinrand;
                    
format(string,sizeof(string),"[FAMILY EXTORTION] Your family has received %d grams of Raw Opium into the family safe from extortion.",heroinrand);
                    
SendFamMessage(TurfWars[tw][twOwnerId], COLOR_YELLOWstring);
                }
                case 
4// Battery Acid Generation
                
{
                    new 
acidrand random(50);
                    
FamilyInfo[TurfWars[tw][twOwnerId]][FamilyAcid] += acidrand;
                    
format(string,sizeof(string),"[FAMILY EXTORTION] Your family has received %d gallons of Battery Acid into the family safe from extortion.",acidrand);
                    
SendFamMessage(TurfWars[tw][twOwnerId], COLOR_YELLOWstring);
                }
                case 
5// Materials Generation
                
{
                    new 
matsrand random(100000);
                    
FamilyInfo[TurfWars[tw][twOwnerId]][FamilyMats] += matsrand;
                    
format(string,sizeof(string),"[FAMILY EXTORTION] Your family has received %d Materials into the family safe from extortion.",matsrand);
                    
SendFamMessage(TurfWars[tw][twOwnerId], COLOR_YELLOWstring);
                }
                case 
6// Money Laundering
                
{
                    new 
cashrand random(150000);
                    
FamilyInfo[TurfWars[tw][twOwnerId]][FamilyCash] += cashrand;
                    
format(string,sizeof(string),"[FAMILY EXTORTION] Your family has received $%d into the family safe from extortion.",cashrand);
                    
SendFamMessage(TurfWars[tw][twOwnerId], COLOR_YELLOWstring);
                }
            }
        }
    }
    foreach(
Playeri)
    {
        
PlayerInfo[i][pOverdose] = 0;
        
PlayerInfo[i][pChopShopped] = 0;
        
Addiction(i);
            if(
PlayerInfo[i][pLevel] > 0)
            {
                if(
GetPVarType(i"debtMsg")) {
                    if(
GetPlayerCash(i) < && PlayerInfo[i][pJailTime] < && !IsACop(i) && PlayerInfo[i][pWantedLevel] < 6) {
                        
format(string,sizeof(string),"You're failing to pay your debt of $%d - now the police are on the look out for you.",GetPlayerCash(i));
                        
SendClientMessageEx(iCOLOR_LIGHTREDstring);
                        
PlayerInfo[i][pCrimes]++;
                        
SetPlayerWantedLevel(i, ++PlayerInfo[i][pWantedLevel]);
                    }
                    else 
DeletePVar(i"debtMsg");
                }
                if(
TicketMessage[i]==&& PlayerInfo[i][pSpeedTix] >= 5001)
                {
                    if( 
PlayerInfo[i][pJailed] < && !IsACop(i) && !IsALVMPDCop(i))
                    {
                        
format(string,sizeof(string),"A warrant has been issued for your arrest, You have failed to pay off your speeding violations");
                        
SendClientMessageEx(iCOLOR_LIGHTREDstring);
                        if(
PlayerInfo[i][pWantedLevel] < 6PlayerInfo[i][pWantedLevel] += 1;
                        
PlayerInfo[i][pCrimes] += 1;
                        
SetPlayerWantedLevel(iPlayerInfo[i][pWantedLevel]);
                        
AddWarrant(i555"Unpaid Speeding Tickets");
                        
format(PlayerInfo[i][pWarrant], 64"Unpaid Speeding Tickets");
                    }
                } 
                else if(
TicketMessage[i]==&& PlayerInfo[i][pSpeedTix] < 5000) { TicketMessage[i] = 0RemoveWarrant(i); }
                
                
account PlayerInfo[i][pAccount];
                if(
PlayerInfo[i][pRenting] != INVALID_HOUSE_ID)
                {
                    if(
HouseInfo[PlayerInfo[i][pRenting]][hRentFee] > PlayerInfo[i][pAccount])
                    {
                        
PlayerInfo[i][pRenting] = INVALID_HOUSE_ID;
                        
SendClientMessageEx(iCOLOR_WHITE"You have been evicted.");
                    }
                    else {
                        
HouseInfo[PlayerInfo[i][pRenting]][hSafeMoney] += HouseInfo[PlayerInfo[i][pRenting]][hRentFee];
                        
PlayerInfo[i][pAccount] -= HouseInfo[PlayerInfo[i][pRenting]][hRentFee];
                    }
                }
                new 
tmpintratefaretaxinsuretaxsocialsecproptaxutilitiesezpassfee;
                
tmpintrate 5;
                if(
PlayerInfo[i][pLevel] <= 5SendClientMessageEx(i,COLOR_LIGHTBLUE,"Need to travel somewhere and don't have wheels? Use '/service taxi' to call a cab!");
                if(
PlayerInfo[i][pPayDay] >= 5)
                {
                    if(
GetPVarInt(i"AdvisorDuty") == 1)
                    {
                        
PlayerInfo[i][pDutyHours]++;
                    }
                    if(
PlayerInfo[i][pDonateRank] > 0)
                    {
                        new 
bonus PlayerInfo[i][pPayCheck] / 2;
                        
PlayerInfo[i][pPayCheck] += bonus;
                    }
                    if(
SpecTimer == 1)
                    {
                        
AddSpecialToken(i);
                    }
                    
rent 0;
                    
faretax 0;
                    
insuretax 0proptax 0utilities 0;
                    
socialsec 0;
                    
ezpassfee 0;
                    new 
checks PlayerInfo[i][pPayCheck];
                    if(
PlayerInfo[i][pTaxiLicense] == 1faretax = (checks/100)*5;
                    if(
PlayerInfo[i][pCarInsurance] == 1insuretax = (checks/100)*9;
                    
socialsec = (checks/100)*4;
                    if(
PlayerInfo[i][pPhousekey] != INVALID_HOUSE_ID || PlayerInfo[i][pPhousekey2] != INVALID_HOUSE_ID)
                    {
                        
proptax += (checks/100)*8;
                        
utilities += (checks/100)*2;
                    }
                    new 
Taxable = (( checks 100 ) * TaxValue);
                    
PlayerInfo[i][pAccount] -= Taxable faretax insuretax socialsec proptax utilities ezpassfee;
                    
Tax += Taxable faretax insuretax socialsec proptax utilities;
                    
interest = (PlayerInfo[i][pAccount]/1000)*(tmpintrate);
                    if(
PlayerInfo[i][pDonateRank] == && interest 5000)
                    {
                        
interest 5000;
                    }
                    else if(
PlayerInfo[i][pDonateRank] == && interest 10000)
                    {
                        
interest 10000;
                    }
                    else if(
PlayerInfo[i][pDonateRank] == && interest 15000)
                    {
                        
interest 15000;
                    }
                    else if(
PlayerInfo[i][pDonateRank] == && interest 20000)
                    {
                        
interest 20000;
                    }
                    else if(
PlayerInfo[i][pDonateRank] >= && interest 25000)
                    {
                        
interest 25000;
                    }
                    
PlayerInfo[i][pExp]++;
                    
PlayerInfo[i][pAccount] = account+interest;
                    
SendClientMessageEx(iCOLOR_WHITE"________ BANK STATEMENT ________");
                    
format(stringsizeof(string), "  Paycheck: $%d  |  Tax Money: -$%d (%d percent)"checksTaxableTaxValue);
                    
SendClientMessageEx(iCOLOR_GRAD1string);
                    
format(stringsizeof(string), "  Property Tax: -$%d  |  Utilities: -$%d"proptaxutilities);
                    
SendClientMessageEx(iCOLOR_GRAD5string);
                    
format(stringsizeof(string), "  Social Security: -$%d"socialsec);
                    
SendClientMessageEx(iCOLOR_GRAD5string);
                    if(
PlayerInfo[i][pDonateRank] == 0)
                    {
                        
format(stringsizeof(string), "  Balance: $%d  |  Interest rate: 0.%d percent (5k max)"accounttmpintrate);
                        
SendClientMessageEx(iCOLOR_GRAD1string);
                    }
                    else if(
PlayerInfo[i][pDonateRank] == 1)
                    {
                        
format(stringsizeof(string), "  Balance: $%d  |  Interest rate: 0.%d percent {FFFF00}(Bronze VIP: 10k max)"accounttmpintrate);
                        
SendClientMessageEx(iCOLOR_GRAD1string);
                        
                        
PlayerInfo[i][pTokens] += 2;
                        
format(stringsizeof(string), "  You have received 2 VIP Tokens (Bronze). You now have %d tokens"PlayerInfo[i][pTokens]);
                        
SendClientMessageEx(iCOLOR_GRAD1string);
                    }
                    else if(
PlayerInfo[i][pDonateRank] == 2)
                    {
                        
format(stringsizeof(string), "  Balance: $%d  |  Interest rate: 0.%d percent {FFFF00}(Silver VIP: 15k max)"accounttmpintrate);
                        
SendClientMessageEx(iCOLOR_GRAD1string);
                        
                        
PlayerInfo[i][pTokens] += 4;
                        
format(stringsizeof(string), "  You have received 4 VIP Tokens (Silver). You now have %d tokens"PlayerInfo[i][pTokens]);
                        
SendClientMessageEx(iCOLOR_GRAD1string);
                    }
                    else if(
PlayerInfo[i][pDonateRank] == 3)
                    {
                        
format(stringsizeof(string), "  Balance: $%d  |  Interest rate: 0.%d percent {FFFF00}(Gold VIP: 20k max)"accounttmpintrate);
                        
SendClientMessageEx(iCOLOR_GRAD1string);
                        
                        
PlayerInfo[i][pTokens] += 6;
                        
format(stringsizeof(string), "  You have received 6 VIP Tokens (Gold). You now have %d tokens"PlayerInfo[i][pTokens]);
                        
SendClientMessageEx(iCOLOR_GRAD1string);
                    }
                    else if(
PlayerInfo[i][pDonateRank] >= 4)
                    {
                        
format(stringsizeof(string), "  Balance: $%d  |  Interest rate: 0.%d percent {FFFF00}(Platinum VIP: 25k max)"accounttmpintrate);
                        
SendClientMessageEx(iCOLOR_GRAD1string);
                        
                        
PlayerInfo[i][pTokens] += 8;
                        
format(stringsizeof(string), "  You have received 8 VIP Tokens (Platinum). You now have %d tokens"PlayerInfo[i][pTokens]);
                        
SendClientMessageEx(iCOLOR_GRAD1string);
                    }
                    else if(
PlayerInfo[i][pDonateRank] == 5)
                    {
                        
format(stringsizeof(string), "  Balance: $%d  |  Interest rate: 0.%d percent {FFFF00}(Investor: 25k max)"accounttmpintrate);
                        
SendClientMessageEx(iCOLOR_GRAD1string);
                        
                        
PlayerInfo[i][pTokens] += 10;
                        
format(stringsizeof(string), "  You have received 10 VIP Tokens (Investor). You now have %d tokens"PlayerInfo[i][pTokens]);
                        
SendClientMessageEx(iCOLOR_GRAD1string);
                    }
                    if(
PlayerInfo[i][pTaxiLicense] == 1)
                    {
                        
format(stringsizeof(string), "  Taxi licensing fee (5 percent): -$%d",faretax);
                        
SendClientMessageEx(iCOLOR_GRAD2string);
                    }
                    if(
PlayerInfo[i][pCarInsurance] == 1)
                    {
                        
format(stringsizeof(string), "  Car insurance fee (9 percent): -$%d",insuretax);
                        
SendClientMessageEx(iCOLOR_GRAD2string);
                    }
                    if(
PlayerInfo[i][pEnrolledEZPass] == 1)
                    {
                        for(new 
0MAX_PLAYERVEHICLESv++)
                        {
                            if(
PlayerVehicleInfo[i][v][pvEZPass] == 1)
                            {
                                
ezpassfee += 510;
                            }
                        }
                            
format(stringsizeof(string), "  EZPass fee: -$%d",ezpassfee);
                            
SendClientMessageEx(iCOLOR_GRAD2string);
                    }
                    
                    new 
paycheck checks Taxable faretax proptax utilities socialsec insuretax ezpassfee// Final outcome of money
                    
new name[24];
                    
GetPlayerName(i,name,24);
                    for(new 
biz=0biz<MAX_BUSINESSbiz++)
                    {
                        if(!
strcmp(nameBizInfo[biz][bOwner], false))
                        {
                            if(
BizInfo[biz][bType] == 1)
                            {
                                
businesspay[i] += random(10000);
                            }
                            if(
BizInfo[biz][bType] == 2)
                            {
                                
businesspay[i] += random(4500);
                            }
                            if(
BizInfo[biz][bType] == 3)
                            {
                                
businesspay[i] += random(5000);
                            }
                        }
                    }
                    if(
businesspay[i] != 0)
                    {
                        
format(string,sizeof(string),"  Business Profits: $%d"businesspay[i]);
                        
SendClientMessageEx(iCOLOR_GRAD2string);
                        
PlayerInfo[i][pAccount] += businesspay[i];
                    }
                    
                    if(
PlayerInfo[i][pMember] != && PlayerInfo[i][pMember] != && PlayerInfo[i][pMember] != 13)
                    {
                        if(
Tax <= 0)
                        {
                            
SendClientMessageEx(i,COLOR_RED,"The government is in debt; no money is available for pay.");
                        }
                        else if(
PlayerInfo[i][pDuty] == 1)
                        {
                            
Tax -= FactionPay[PlayerInfo[i][pMember]-1][PlayerInfo[i][pRank]];
                            
format(string,sizeof(string),"  Government pay: $%d"FactionPay[PlayerInfo[i][pMember]-1][PlayerInfo[i][pRank]]);
                            
SendClientMessageEx(iCOLOR_GRAD2string);
                        }
                        else
                        {
                            
format(string,sizeof(string),"    You did not work enough to get Government Pay, go on duty!");
                            
SendClientMessageEx(iCOLOR_YELLOWstring);
                        }
                    }
                    else {
                        if(
Tax <= 0)
                        {
                            
SendClientMessageEx(i,COLOR_RED,"The government is in debt; no welfare money is available for pay.");
                        }
                        else
                        {
                            if(
PlayerInfo[i][pLevel] <= 10) {
                                
welfarepay = (PlayerInfo[i][pLevel]*25);
                            }
                            else 
welfarepay 500;
                            
Tax -= welfarepay;
                            
format(string,sizeof(string),"  Welfare check: $%d"welfarepay);
                            
SendClientMessageEx(iCOLOR_GRAD2string);
                            
PlayerInfo[i][pAccount] += welfarepay;
                        }
                    }
                    
format(stringsizeof(string), "  Interest gained: $%d"interest);
                    
SendClientMessageEx(iCOLOR_GRAD3string);
                    
SendClientMessageEx(iCOLOR_GRAD4"______________________________________");
                    
format(stringsizeof(string), "  New account balance: $%d  |  Rent paid: -$%d"PlayerInfo[i][pAccount],rent);
                    
SendClientMessageEx(iCOLOR_GRAD5string);
                    
format(stringsizeof(string), "  Paycheck (Taxes and profits applied): $%d"paycheck+businesspay[i]+interest);
                    
SendClientMessageEx(iCOLOR_GRAD5string);
                    
                    if(
PlayerInfo[i][pMember] != && PlayerInfo[i][pMember] != && PlayerInfo[i][pMember] != 13 && Tax >= 0)
                    {
                        new 
facmemberpay FactionPay[PlayerInfo[i][pMember]-1][PlayerInfo[i][pRank]];
                        
PlayerInfo[i][pAccount] += facmemberpay;
                    }
                    
PlayerInfo[i][pAccount] += paycheck;
                    
GameTextForPlayer(i"~p~PayDay~n~~w~Paycheck"50001);
                    
PlayerInfo[i][pPayDay] = 0;
                    
PlayerInfo[i][pPayCheck] = 0;
                    
PlayerInfo[i][pConnectTime] += 1;
                    if(
PlayerInfo[i][pConnectTime] == 2SendClientMessageEx(iCOLOR_LIGHTRED"You may now possess/use weapons!");
                    if(
PlayerInfo[i][pDonateRank] > 0)
                    {
                        
PlayerInfo[i][pPayDayHad] = 0;
                        
//PlayerInfo[i][pPayDayHad] += 1;
                        
if(PlayerInfo[i][pPayDayHad] >= 5)
                        {
                            
PlayerInfo[i][pExp]++;
                            
PlayerInfo[i][pPayDayHad] = 0;
                        }
                    }
                    if(
PlayerInfo[i][pWRestricted] > 0)
                    {
                        
PlayerInfo[i][pWRestricted]--;
                        if(
PlayerInfo[i][pWRestricted] == 0SendClientMessageEx(iCOLOR_LIGHTRED"Your weapons are no longer restricted!");
                    }
                }
                else
                {
                    
SendClientMessageEx(iCOLOR_LIGHTRED"* You haven't played long enough to obtain a paycheck.");
                }
            }
    }
    for (new 
x=0x<MAX_POINTSx++)
    {
        
Points[x][Announced] = 0;
        if (
Points[x][Vulnerable] > 0)
        {
            
Points[x][Vulnerable]--;
            
UpdatePoints();
        }
        if(
Points[x][Vulnerable] == && Points[x][Announced] == 1)
        {
        }
        if (
Points[x][Vulnerable] == && Points[x][Type] >= && Points[x][Announced] == && Points[x][ClaimerId] == INVALID_PLAYER_ID)
        {
        
//    format(string, sizeof(string), "%s has become available for capture.", Points[x][Name]);
        //    SendClientMessageToAllEx(COLOR_YELLOW, string);
            //SetPlayerCheckpoint(i, Points[i][Pointx], Points[i][Pointy], Points[i][Pointz], 3);
            
ReadyToCapture(x);
            
Points[x][Announced] = 1;
        }
    }
    
SaveStuff();
    
SaveServerStats();
    
FMemberCounter(); // Family member counter (requested by game affairs to track gang activity)
    
return 1;

Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)