Clock update problem?
#1

I don't know what's wrong with this. The clock is shown right and all, just the time of the day is not updated. It's always night.

pawn Код:
public UpdateClock()
{
    print("Updating clock...");
    gettime(serverhour, serverminute);
    format(timestr,32,"%02d:%02d",serverhour,serverminute);
    TextDrawSetString(RealClock,timestr);
    print("Setting world time...");
    SetWorldTime(serverhour);
    print(timestr);
   
    print("Starting loop through all players...");
    new x=0;
    while(x!=MAX_PLAYERS)
    {
        if(IsPlayerConnected(x))
        {
            SetPlayerTime(x,serverhour,serverminute);
           
            if(serverminute == 01){
                if(pRespectCheck[x] == 1){
                    pInfo[x][pRespect] = pInfo[x][pRespect] + 1;
                    pRespectCheck[x] = 0;
                }
            }
        }
        x++;
   }
}
Reply
#2

Use this FS: https://sampforum.blast.hk/showthread.php?tid=70445
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)