Is it possible to change [day/night]
#5

Quote:
Originally Posted by kAn3
Посмотреть сообщение
Yes, but I'do it more short

PHP код:
forward ServerTime();
public 
ServerTime()
{
      new 
hms;
      
gettime(hms);
      foreach(
Playerk)SetPlayerTime(khm);
      return 
1;

PHP код:
SetTimer("ServerTime"300000true); // Check every 5 mins 
Also, I'd suggest you to create an enum to store server variables just like server hour,minute and seconds, so you can create a clock with textdraws and add the current server time to it.
do you know what are you doing?

he want 4 hours of dark and 20 hours of morning
and instand of setting each player time you can set the whole server time by using SetWorldTime
your version is not optimized at all but it gonna work.
Reply


Messages In This Thread
Is it possible to change [day/night] - by Escobabe - 22.10.2017, 18:31
Re: Is it possible to change [day/night] - by Puff - 22.10.2017, 18:39
Re: Is it possible to change [day/night] - by Xeon™ - 22.10.2017, 22:00
Re: Is it possible to change [day/night] - by kAn3 - 22.10.2017, 22:19
Re: Is it possible to change [day/night] - by Xeon™ - 22.10.2017, 22:27
Re: Is it possible to change [day/night] - by kAn3 - 22.10.2017, 22:30
Re: Is it possible to change [day/night] - by Escobabe - 22.10.2017, 22:35

Forum Jump:


Users browsing this thread: 1 Guest(s)