GivePlayerCash - On Mod garages.
#6

Right Success !! works perfect spot on bud thanks,
I still get the printf warning lol but it's ok.
and here is the code i implemented:

Код:
new Player_ModShop[MAX_PLAYERS];
public MoneyTimer()
{
    new username[MAX_PLAYER_NAME], money;
    for(new i=0; i<MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i))
        {
            money = GetPlayerMoney(i);
            if(GetPlayerCash(i) != money)
            {
                if (money < Cash[i] && Player_ModShop{i}) Cash[i] = money;
                ResetMoneyBar(i);//Resets the money in the original moneybar, Do not remove!
                UpdateMoneyBar(i,GetPlayerCash(i));//Sets the money in the moneybar to the serverside cash, Do not remove!
                new hack = money - GetPlayerCash(i);
                GetPlayerName(i,username,sizeof(username));
                printf("%s has picked up/attempted to spawn $%d.", username,hack);
            }
        }
    }
}


public OnEnterExitModShop(playerid, enterexit, interiorid)
{
    Player_ModShop{playerid} = !!enterexit;
    return 1;
}
Reply


Messages In This Thread
GivePlayerCash - On Mod garages. - by CharlieSanchez - 22.04.2014, 13:12
Re: GivePlayerCash - On Mod garages. - by Konstantinos - 22.04.2014, 13:45
Re: GivePlayerCash - On Mod garages. - by CharlieSanchez - 22.04.2014, 13:56
Re: GivePlayerCash - On Mod garages. - by Konstantinos - 22.04.2014, 14:05
Re: GivePlayerCash - On Mod garages. - by CharlieSanchez - 22.04.2014, 14:12
Re: GivePlayerCash - On Mod garages. - by CharlieSanchez - 22.04.2014, 14:35
Re: GivePlayerCash - On Mod garages. - by Konstantinos - 22.04.2014, 14:52
Re: GivePlayerCash - On Mod garages. - by CharlieSanchez - 22.04.2014, 15:51

Forum Jump:


Users browsing this thread: 2 Guest(s)