14.12.2009, 18:41
Hello i have been trying to get my payday to work right. It not given any players any money just doing nothink other then sending the player one message "Payday is here!" If any one could help i would be most thankfull.
Код:
forward Payday(playerid);
Код:
SetTimer("Payday", 60000 , true); // Every 1 minutes the Timer will go off.900000
Код:
public Payday(playerid) { for(new i = 0; i < MAX_PLAYERS; i++) { new payday = 200; if(IsPlayerConnected(i)) { if(AccountInfo[i][pTeam] == 1) { SendClientMessage(i, COLOUR_TRECE, "[Payday]: You recieve your paycheck."); GivePlayerMoney(i, payday); } else if(AccountInfo[i][pTeam] == 2) { SendClientMessage(i, COLOUR_TRECE, "[Payday]: Sup, Holmes heres your cut."); GivePlayerMoney(i, payday); } else if(AccountInfo[i][pTeam] == 3) { SendClientMessage(i, COLOUR_HELLSANGELS, "[Payday]: Sup, Kid heres your cut."); GivePlayerMoney(i, payday); } else if(AccountInfo[i][pTeam] == 4) { SendClientMessage(i, COLOUR_CAPPELLI, "[Payday]: Your cut from the don."); GivePlayerMoney(i, payday); } else if(AccountInfo[i][pTeam] == 5) { SendClientMessage(i, COLOUR_NORTHSIDE, "[Payday]: Sup, Dawg here's your cut."); GivePlayerMoney(i, payday); } else { SendClientMessage(i, COLOUR_OTHER, "[Payday]: You have recieved a Welfare Cheque."); GivePlayerMoney(i, 100); } print("Payday Function Called"); OnPlayerUpdateAccount(i); GameTextForAll("Payday is here!", 5000, 3 ); return 1; } } return 1; }