Module auto cleanup

Automatically cleans up module functions returned from spawn().  Also makes the API a bit cleaner and easier to use: actions now each take one function instead of a list.  Multiple functions per action were rarely used, and when they were, they could be condensed to one function.  This makes things easier as you no longer have to remember the list syntax for specifying actions because you shouldn't remember it anymore.

Also provides a small base on which we can build proper module unloading later.