+ # the world was flagged for a reload of all code/data
+ if universe.reload_flag:
+
+ # reload the mudpy module
+ reload(mudpy)
+ for item in importlist: exec("from mudpy import " + item)
+
+ # do what needs to be done on each pulse
+ on_pulse()
+
+# the loop has terminated, so save persistent data
+universe.save()
+
+# log a final message
+log("Shutting down now.")
+
+# get rid of the pidfile
+remove_pidfile(universe)