Timer updated for a player every minute.
#6

Argh... I got this:

pawn Код:
// Defines
forward Time();
forward ScoreUpdate();

new PlayerTime[MAX_PLAYERS];
new Timer;
new Text:Score[MAX_PLAYERS];

// OnPlayerConnect

TextDrawShowForPlayer(playerid, Score[playerid]);
Timer = SetTimerEx("Time", 60000, 0, "ii", playerid);

// On the end of the script

public ScoreUpdate()
{
    new string[100];
    format(string,sizeof(string),"%d", PlayerTime);
    TextDrawSetString(Score[playerid], string);
    Score[playerid] = TextDrawCreate(493.000000,98.000000,"00000000");
    TextDrawAlignment(Score[playerid],0);
    TextDrawBackgroundColor(Score[playerid],0x000000ff);
    TextDrawFont(Score[playerid],3);
    TextDrawLetterSize(Score[playerid],0.699999,2.000000);
    TextDrawColor(Score[playerid],0xff0000ff);
    TextDrawSetOutline(Score[playerid],1);
    TextDrawSetProportional(Score[playerid],1);
    TextDrawSetShadow(Score[playerid],1);
}

public Time()
{
   for(new i = 0; i < MAX_PLAYERS; i++)
   {
     if(IsPlayerConnected(i))
     {
        PlayerTime[i] += 1;
     }
   }
   return 1;
}
And the errors:

Код:
G:\Program Files\Rockstar Games\San Andreas Online\SAMP Server RoS\gamemodes\Stunt.pwn(3387) : error 017: undefined symbol "playerid"
G:\Program Files\Rockstar Games\San Andreas Online\SAMP Server RoSr\gamemodes\Stunt.pwn(3388) : error 017: undefined symbol "playerid"
G:\Program Files\Rockstar Games\San Andreas Online\SAMP Server RoS\gamemodes\Stunt.pwn(3389) : error 017: undefined symbol "playerid"
G:\Program Files\Rockstar Games\San Andreas Online\SAMP Server RoS\gamemodes\Stunt.pwn(3390) : error 017: undefined symbol "playerid"
G:\Program Files\Rockstar Games\San Andreas Online\SAMP Server RoS\gamemodes\Stunt.pwn(3391) : error 017: undefined symbol "playerid"
G:\Program Files\Rockstar Games\San Andreas Online\SAMP Server RoS\gamemodes\Stunt.pwn(3392) : error 017: undefined symbol "playerid"
G:\Program Files\Rockstar Games\San Andreas Online\SAMP Server RoS\gamemodes\Stunt.pwn(3393) : error 017: undefined symbol "playerid"
G:\Program Files\Rockstar Games\San Andreas Online\SAMP Server RoS\gamemodes\Stunt.pwn(3394) : error 017: undefined symbol "playerid"
G:\Program Files\Rockstar Games\San Andreas Online\SAMP Server RoS\gamemodes\Stunt.pwn(3395) : error 017: undefined symbol "playerid"
G:\Program Files\Rockstar Games\San Andreas Online\SAMP Server RoS\gamemodes\Stunt.pwn(3396) : error 017: undefined symbol "playerid"
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)