home · contact · privacy
Fix replay mode overwriting save file on quit.
authorChristian Heller <c.heller@plomlompom.de>
Wed, 26 Aug 2015 03:19:28 +0000 (05:19 +0200)
committerChristian Heller <c.heller@plomlompom.de>
Wed, 26 Aug 2015 03:19:28 +0000 (05:19 +0200)
roguelike-server

index 344f5a5618f59f80ae521404587334a467dbca38..57f0b6c1bc737dd92c8ebd3e14fa9bca2697c662 100755 (executable)
@@ -1111,8 +1111,9 @@ def command_ping():
 
 def command_quit():
     """Abort server process."""
-    save_world()
-    atomic_write(io_db["path_record"], io_db["record_chunk"], do_append=True)
+    if None == opts.replay:
+        save_world()
+        atomic_write(io_db["path_record"], io_db["record_chunk"], do_append=True)
     raise SystemExit("received QUIT command")