This is a 24 hours-based timing system with progressive night and day.
It also provides random weather changes, which include rain, snow and storms. Warning, dedicated servers are NOT supported!
You have a digital clock in the bottom-right corner of the screen that can be shown/hidden by turning the clock variable on/off.
If you can't play because of the darkness, you can skip the night by using the sleep command in the console, so the time will pass faster until you use the wakeup command. You have to set allowsleep on to sleep in a netgame.
You can neither move or see while sleeping, so make sure ennemies won't reach you. The clock is still visible, so you can know when this is morning.
Note that you can also sleep during daytime, and that in netgames the time will only speed up if every player (aside from spectators or dead players) is sleeping.
Console commands:
- "sleep": Start sleeping. In netgame it needs allowsleep on.
- "wakeup": Stop sleeping. In netgame it needs allowsleep on.
- "time <hours> [minutes] [seconds]" (server/admin only): Setup the time. If minutes or seconds aren't specified, they default to 0. In addition, you can just type "day", "night", "morning" or "evening" in place of hours, minutes and seconds.
- "displaytime": Displays the current time in the console.
- "weather <weather> [duration]": Sets the weather, regardless of the randomweather variable. weather must be one of the followings: "sun", "sunny", "rain", "snow", "storm", "thunder" or "storm no strikes". duration is optional and is the number of hours (in-game time) before the weather changes automatically. If duration is set to "infinite", the weather will never change until the map is changed or you use the command again.
- "timehelp": Lists all commands and variables available in this script.
Console variables:
- "lightchange" (server/admin only): Actives or desactives the brightness changing. "Auto" will active or desactive it depending on the level.
- "clock": Shows/hides the clock HUD.
- "timefactor" (server/admin only): How many times faster is the time compared to reality? (default is 60, which means 1 second = 1 minute IRL).
- "nighttimefactor" (server/admin only): How many times faster the time passes while sleeping. (default is 16)
- "allowsleep" (server/admin only): Allows players to sleep in a netgame.
- "daylight" (server/admin only): The brightness level during the day. 255 means it'll keep the same lightning as day, 0 means it'll be fully dark. (default is 255)
- "nightlight" (server/admin only): The brightness level during the night. 255 means it'll keep the same lightning as day, 0 means it'll be fully dark. (default is 128)
- "daysky" (server/admin only): The sky number used during the day. 0 will keep the normal sky of the level. (default is 0)
- "nightsky" (server/admin only): The sky number used during the night. (default is 8)
- "morningsky" (server/admin only): The sky number used during the morning.
- "eveningsky" (server/admin only): The sky number used during the evening.
- "randomweather" (server/admin only): Actives or desactives the weather changing. You can also specify one of the following values to disable some types of weather:
-"Rain" will only enable rain and storms.
-"Snow" will only enable snow.
-"Thunder" will only enable thunders with no rain.
-"NoThunder" will disable thunders.
-"NoRain" will disable rain.
-"RainNoThunder" will only enable rain with no thunders.
-"Snow" will only enable snow.
-"Thunder" will only enable thunders with no rain.
-"NoThunder" will disable thunders.
-"NoRain" will disable rain.
-"RainNoThunder" will only enable rain with no thunders.
- "randomweatherfactor" (server/admin only): The frequency of weather changes, in percents. Lowering it will make the weather more stable, raising it will make the weather changing more often. 100% is the default frequency.
- "energy" (server/admin only): active or desactive the energy system.
- "maxenergy" (server/admin only): Maximum amount of energy, in minutes.
Thanks to speed2411 for the morning and evening skies!
Attachments
Last edited: