09.11.2010, 13:19
Can someone help me with a script that increase player's score with 1 score point each hour?
Tanks!

Tanks!

public OnPlayerConnect(playerid)
{
SetPVarInt(playerid, "scoreTimer", SetTimerEx("GivePlayerHourlyScore", 60 * 60 * 1000, 1, "i", playerid));
return 1;
}
public OnPlayerDisconnect(playerid, reason)
{
KillTimer(GetPVarInt(playerid, "scoreTimer"));
return 1;
}
forward GivePlayerHourlyScore(playerid);
public GivePlayerHourlyScore(playerid)
{
GivePlayerScore(playerid, GetPlayerScore(playerid) + 1);
}