point's day [help needed]
#1

well my problem is my exp is not increasing. It's stay's on 0 all the time and in all the point's day. Well here is my code


pawn Код:
public pointsday()
{
    for(new i=0; i<=MAX_PLAYERS; i++)
    {
        GivePlayerMoney(i, 1000);
        PlayerInfo[i][pExp]++;
        GameTextForAll("It's Point's Day", 1000, 1);
    }
}
Please help me generously
Reply
#2

Did you add a timer?
Reply
#3

yep added
Reply
#4

this is my whole code

At the top of the script:


pawn Код:
forward pointsday();

Under OnGameModeInit:

pawn Код:
SetTimer("pointsday", 900000, 1);
And at last:

pawn Код:
public pointsday()
{
    for(new i=0; i<=MAX_PLAYERS; i++)
    {
        GivePlayerMoney(i, 1000);
        PlayerInfo[i][pExp]++;
        GameTextForAll("It's Point's Day", 1000, 1);
    }
}
Well now can anyone help me
Reply
#5

Is my code alright or what?
Reply
#6

Your code is okei, but checkout foreach() by ******.

pawn Код:
PlayerInfo[i][pExp]++; // This should increase it by one
PlayerInfo[i][pExp] = PlayerInfo[i][pExp]+1; // You could try this, can't see why the other one shouldn't work tho.
Reply
#7

it's worked. Lol unique bug
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)