17.03.2010, 23:16
Hello, I made code about adding exp points to players every 30seconds...
So after they play 1seconds they will get 0.346 experience points, when I tried it, player got A WAY TOO MUCH EXP like 1318926827 I was surprised...
Here is the code...
Please help me so I get 0.346 exp every 30 secs
So after they play 1seconds they will get 0.346 experience points, when I tried it, player got A WAY TOO MUCH EXP like 1318926827 I was surprised...
Here is the code...
Код:
public Experience()
{
for(new i=0; i<MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
Seconds[i]++;
if(Seconds[i] >= 30)
{
Seconds[i]=0;
PlayerInfo[i][Exppoints]+=0.346;
GameTextForPlayer(i, "Exp~n~~w~+0.346", 3000, 1);
}
}
}
}


?