MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame^] | 1 | SYNOPSIS |
| 2 | varargs void notify_shutdown (string crash_reason) |
| 3 | |
| 4 | DESCRIPTION |
| 5 | Notify the master about an immediate shutdown. If <crash_reason> is 0, |
| 6 | it is a normal shutdown, otherwise it is a crash and <crash_reason> |
| 7 | gives a hint at the reason. |
| 8 | |
| 9 | The function has the opportunity to perform any cleanup operation, |
| 10 | like informing the mudwho server that the mud is down. This can not be |
| 11 | done when remove_player() is called because the udp connectivity is |
| 12 | already gone then. |
| 13 | |
| 14 | If the gamedriver shuts down normally , this is the last function |
| 15 | called before the mud shuts down the udp connections and the accepting |
| 16 | socket for new players. |
| 17 | |
| 18 | If the gamedriver crashes, this is the last function called before the |
| 19 | mud attempts to dump core and exit. WARNING: Since the driver is in an |
| 20 | unstable state, this function may not be able to run to completion! |
| 21 | The following crash reasons are defined: |
| 22 | "Fatal Error": an internal sanity check failed. |
| 23 | |
| 24 | HISTORY |
| 25 | LDMud 3.2.9 added the <crash_reason> argument and that the function |
| 26 | is called for a crash at all. |
| 27 | |
| 28 | SEE ALSO |
| 29 | slow_shut_down(M), remove_player(M), |