Small change to shutdown routine.
This commit is contained in:
parent
a65e52020c
commit
54fc8f2b76
1 changed files with 3 additions and 3 deletions
|
|
@ -138,8 +138,8 @@ class Server(dispatcher):
|
||||||
"""
|
"""
|
||||||
self.session_list.remove(session)
|
self.session_list.remove(session)
|
||||||
|
|
||||||
def shutdown(self):
|
def shutdown(self, message='The server has been shutdown. Please check back soon.'):
|
||||||
functions_general.announce_all(server, 'The server has been shutdown. Please check back soon.')
|
functions_general.announce_all(server, message)
|
||||||
self.game_running = False
|
self.game_running = False
|
||||||
"""
|
"""
|
||||||
END Server CLASS
|
END Server CLASS
|
||||||
|
|
@ -158,5 +158,5 @@ if __name__ == '__main__':
|
||||||
scheduler.heartbeat()
|
scheduler.heartbeat()
|
||||||
|
|
||||||
except KeyboardInterrupt:
|
except KeyboardInterrupt:
|
||||||
functions_general.announce_all(server, 'The server has been shutdown. Please check back soon.')
|
server.shutdown()
|
||||||
print '--> Server killed by keystroke.'
|
print '--> Server killed by keystroke.'
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue