This patch adds a derivable base class that may be added to any object eg player/lua/rat etc and provides a interface to link and unlink them. You still need to implement the virtual methods as they need access to elements of the server/clientactiveobject which i didn't want to touch. This patch won't add any features by itself. There are other patches needed i just wanted to create small patches to increase chances they get merged.
Have a look at it and comment what can be done better!
Patch