#appendto

By using #appendto you can avoid various object definition overloads.

Declaration

#appendto [id] [nowarn]
A script can append itself to one or multiple existing scripts using the #appendto directive. Functions of the same name will overload functions in the target script. The original overloaded functions can still be called using inherited. #included scripts are not appended with #append, but #appended scripts are included by #include. nowarn is optional and if specified suppresses the warning triggered when the given definition can not be found. It can be used for appento-scripts which are non-essential for normal operation. For example if some pack wants to support Knights.c4d but also works without it.
#appendto *
Appending to * will append this script to all definitions.
A script can contain multiple #appendto directives. It is always compiled with the original script. This is of interest whenever local variables or functions from the appended script are used.
Sven2, April 2002
matthes, Juni 2004
Günther, Januar 2006