Question
#5

Quote:
Originally Posted by CuervO
Посмотреть сообщение
There might be an internal timer in your script which handles time. Search for SetWorldTime / SetPlayerTime in your script and check where's it's being handled.

If you create a /settime command make sure it uses the script current variables or things like these will happen. For example, if your time is stored at ServerTime, use that variable when changing the time dynamically.
I only have "SetWorldTime" in my command:

pawn Код:
CMD:settime(playerid, params[]) {
    if(PlayerInfo[playerid][pAdmin] < 3) return SendClientMessage(playerid, COLOR_RED, "[ADMIN] - You're not a high enough level to use this command!");
    new h;
    if(sscanf(params, "i", h)) return SendClientMessage(playerid, COLOR_RED, "[USAGE] - /settime [0-24]");
    if ( h < 0 || h > 24 ) return SendClientMessage( playerid, COLOR_RED, "[ERROR] - Use a number from 0 to 24" );
    new name[MAX_PLAYER_NAME];
    new string[94];
    GetPlayerName(playerid, name, sizeof(name));
    format(string, sizeof(string), "[TIME] - Admin %s[%d] has set the time to %i!", name, playerid, h);
    SendClientMessageToAll(COLOR_GREEN, string);
    format(string, sizeof(string), "[ADMIN] - %s[%d] has used SETTIME( %i )", name, playerid, h);
    SendMessageToAdmins(COLOR_LIME,string);
    SetWorldTime(h);
    return 1;
}
.. ;d
Reply


Messages In This Thread
Question - by Kyance - 08.02.2014, 10:05
Re: Question - by FireCat - 08.02.2014, 11:03
Re: Question - by Kyance - 08.02.2014, 16:08
Re: Question - by CuervO - 08.02.2014, 16:17
Re: Question - by Kyance - 08.02.2014, 16:19
Re: Question - by CuervO - 08.02.2014, 16:21
Re: Question - by Kyance - 08.02.2014, 16:31
Re: Question - by CuervO - 08.02.2014, 16:34
Re: Question - by Kyance - 08.02.2014, 16:42

Forum Jump:


Users browsing this thread: 1 Guest(s)