The attached patch moves the sun module incrementally nearer where it needs to be. Default behavior, i.e. no overriding configuration is to match Second Life's diurnal/nocturnal rhythm. All designated values are now sent to the client.There remain a couple of unanswered questions about how this SHOULD be implemented though.
!!!IMPORTANT NOTE!!! This code snippet provided as an example of coding functional content with region modules. As of 13/3 2008 this module actually renders all regions within the instance unusable if enabled by dragging the dll from ./bin to global /bin. So, use at own peril and in dedicated instance. Peace.