Rust Wiki

Revision Difference

server-wipe-timer#549761

<cat>Play.Hosting</cat> <title>Server Wipe Timer</title> <upload src="2f4/8db4583e08299bf.png" size="941694" name="image.png" /> <warning>This article was last updated on May 3th, 2023, which was before the May update. Things might change in the future.</warning> <warning>This article was last updated on May 3rd, 2023, which was before the May update. Things might change in the future.</warning> On the lowest level of **Nuclear Missile Silo** monument, you might notice a nuclear warhead connected to a small laptop with timer on it. This is not a random countdown timer - in fact, this timer is counting down until the next server wipe. Repopulation unit survival test. If you host a vanilla monthly server, this timer will likely work as intended. However, if you run a server with non-standard wipe time, you might need to add a few convars to make sure that in-game timer works correctly. # How does timer work? Timer is calculated using three following variables: server wipe tag (`monthly`/`biweekly`/`weekly`), `wipeDayofWeek` and `wipeHourofDay` convars, however you can also set an exact wipe date if you need it, using `wipeUnixTimestampOverride` convar. This means that you have three schedule "formats" by default – **monthly**, **bi-weekly** and **weekly**. For example, if you have set the wipe time to Wednesday at 1 PM, and your server is bi-weekly, then timer will reach `00:00:00:00` every two weeks, exactly on Wednesday, 1pm. If your server is running shorter wipe cycles (for example, 3-day cycle) you might need to write a plugin to adjust the timer. Note that server will be using your local machine time, so make sure it is correct, and make sure to clarify your time zone for your players. # Changing the day of week You can add the convar `wipeDayofWeek <0-6>` to change the wipe day to anything other than Thursday. | Value | Day of week | Notes | |:---------:|-------------|----------| | **0** | Sunday | | | **1** | Monday | | | **2** | Tuesday | | | **3** | Wednesday | | | **4** | Thursday | (default)| | **5** | Friday | | | **6** | Saturday | | # Changing the wipe hour You can add the convar `wipeHourofDay <0-23>` to specify when exactly server will wipe. Time is specified in 24-hour format. If you type `wipeHourofDay 14.5`, then it'll be interpreted as *2:30 PM*. # Specifying an exact wipe date If your server is using a wipe schedule that does not work with any formats above (monthly/bi-weekly/weekly), then you can set an exact wipe date using a UNIX timestamp with this server convar: `wipeUnixTimestampOverride <timestamp>`. Keep in mind that this convar will override all other settings for the wipe timer. # Examples Here are a few examples to see how it works: | Wipe Frequency tag | Config | Explanation | | :-----------------:|----------------------------------------|-------------------------------------------------------------------| | Monthly | `+wipeDayofWeek 4 +wipeHourofDay 14.5` | Server will wipe on every first Thursday of the month at 2:30 PM. | | Monthly | `+wipeDayofWeek 1 +wipeHourofDay 9` | Server will wipe on every first Monday of the month at 9 AM. | | Weekly | `+wipeDayofWeek 4 +wipeHourofDay 18` | Server will wipe every Thursday at 6 PM. | | Biweekly | `+wipeDayofWeek 0 +wipeHourofDay 23` | Server will wipe every other Sunday at 11 PM. | | Biweekly | `+wipeDayofWeek 4 +wipeHourofDay 19` | Server will wipe every other Thursday at 7 PM. | | Custom | `+wipeUnixTimestampOverride 1683622506`| Server will wipe exactly on May 9th, 2023 at 08:55:06 (GMT+0) | | Custom | `+wipeUnixTimestampOverride 1686766934`| Server will wipe exactly on June 14th, 2023 at 18:22:14 (GMT+0) | # Commands To check if you have set up the timer correctly, you can use the command `PrintWipe`. This will output two messages, countdown timer itself (`Time until wipe : _ days, _ hours, _ minutes, _ seconds.`) and static date (`Calculated Wipe time static _ month, _ days, _ hours, _ minutes, _ seconds.`) There are some other commands available for use. Most of them are meant to be used only for testing though. ## PrintWipe This command output will output following information: * **[needs more context]** Test Time (current time + `daysToAddTest` + `hoursToAddTest` convars. By default both convars are 0, so if you didn't change them, this line will display your current local time. * Time until wipe: `<value>` days, `<value>` hours, `<value>` minutes, `<value>` seconds. * Calculated wipe time static: `<value>` month, `<value>` days, `<value>` hours, `<value>` minutes, `<value>` seconds. * Wipe time (this will output an exact date of calculated wipe time) * **[needs more context]** How many ticks left # Misc Convars These convars do not seem to be relevant if you are not a developer. Might be removed/changed in the future. So far, they were used only for PrintWipe output info. ## daysToAddTest <value> By default set to `0`. ## hoursToAddTest <value> By default set to `0`. # Code Wipe timer code is available in **WipeTimer.cs**. You can access it through Rust Dedicated Server's `Assembly-CSharp.dll`.