World Time
#1

how to set the world time in the game to be like (Saturday to Friday) and (00:00 to 23:00)
and make the weather automatically changes that depends on what time is it.. i mean i'll set the weather manually on what X O'clock will change.
Reply
#2

This is what I use for my script.

Код:
public ClockUpdate()
{
	new string[12];
	Second += 1;
	format(string, sizeof(string), "%i:%i:%i", Hour, Minute, Second);
	if(Second == 60)
	{
	    if(Minute == 59)
		{
		    for(new i = 0; i < MAX_PLAYERS; i++)
		    {
		        if(IsPlayerConnected(i))
		        {
					if(Player[i][Faction] == 0)
					{
					    SendClientMessage(i, ORANGE, "Your check is ready to be picked up. Please head to the Job Center to get it.");
					    CheckReady[i] = 1;
					}
					else
					{
						SendClientMessage(i, ORANGE, "Your check is ready to be picked up. Please head to your headquarters to get it.");
						CheckReady[i] = 1;
					}
					}
			}
		    if(Hour == 23)
		    {
		    	Hour = 0;
		    	Minute = 0;
		    	Second = 0;
			}
			else
			{
			    Hour ++;
				Minute = 0;
				Second = 0;
			}
		}
		else
		{
		    Minute ++;
	    	Second = 0;
	 		}
	}
	format(string,sizeof (string),"%02i:%02i:%02i", Hour, Minute, Second);
	TextDrawSetString(Clock, string);
	SetWorldTime(Hour);
	return 1;
}
Reply
#3

would you please explain, there is just minutes and seconds in the game, so what is hours ?
there is just 24 minutes in day in the game
Reply
#4

Quote:
Originally Posted by AnonScripter
Посмотреть сообщение
would you please explain, there is just minutes and seconds in the game, so what is hours ?
there is just 24 minutes in day in the game
Mine is an RP World Clock. It takes 24 hours IRL time for just one day to pass.

Hit me up on Skype if you would like me to explain in further detail.
Skype: JimmySAMP.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)