Update Doku aus Driversourcen
Change-Id: I455f0813b970151089b3dc1b8d9407eea323cdd1
diff --git a/doc/master/prepare_destruct b/doc/master/prepare_destruct
index 3121b88..f24391f 100644
--- a/doc/master/prepare_destruct
+++ b/doc/master/prepare_destruct
@@ -1,22 +1,31 @@
SYNOPSIS
- mixed prepare_destruct(object obj)
+ mixed prepare_destruct(object obj)
DESCRIPTION
- Prepare the destruction of the object obj. Return 0 if the
- object is ready for destruction, any other value will abort
- the attempt. If a string is returned, an error with the string
- as message will be issued.
+ Prepare the destruction of the object obj. Return 0 if the
+ object is ready for destruction; any other value will abort
+ the attempt. If a string is returned, an error with the string
+ as message will be issued.
- The interpreter calls this function whenever an object shall
- be destructed. It expects, that this function cleans the
- inventory of the object, or the destruct will fail.
- Furthermore, the function could notify the former inventory
- objects that their holder is under destruction (useful to move
- users out of rooms which re updated); and it could announce
- systemwide the destruction(quitting) of users.
+ The interpreter calls this function whenever an object shall
+ be destructed. It expects that this function cleans the
+ inventory of the object, or the destruct will fail. It is also
+ recommended to clean up all shadows on obj at this point.
- Strange things will happen if the mastor object does not
- provide this function.
+ Furthermore, the function could notify the former inventory
+ objects that their holder is under destruction (useful to move
+ users out of rooms which are updated); and it could announce
+ systemwide the destruction(quitting) of users.
+
+ Another use for this apply is to take care of any other
+ 'cleanup' work needed to be done, like adjusting weights,
+ light levels, and such. Alternatively and traditionally this
+ is done by calling an lfun 'remove()' in the object, which
+ then calls the efun destruct() after performing all the
+ adjustments.
+
+ Strange things will happen if the master object does not
+ provide this function.
SEE ALSO
- remove_player(M), destruct(E)
+ remove_player(M), destruct(E)