Remove unnecessary null pointer checks

worldfactory: add proper initialization of pointer members,
Simplified deconstructor, no need to clear the maps, they are deconstructed anyway.
Also changes the modmanager pointer to be a smart pointer to let it handle its own destruction.