]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/weapons/weaponstats.qc
Fix #2850 "xonotic crashes when pressing restart level after match end in campaign"
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / weapons / weaponstats.qc
index 2b4be7e917f32fb71bd0b9f1a375399af03344c2..47805fea6576e1f8b9f2b811e04f916784b657d9 100644 (file)
@@ -1,8 +1,10 @@
 #include "weaponstats.qh"
 
-#include "../g_world.qh"
-
-#include <common/weapons/all.qh>
+#include <common/stats.qh>
+#include <common/weapons/_all.qh>
+#include <common/weapons/_all.qh>
+#include <server/intermission.qh>
+#include <server/world.qh>
 
 void WeaponStats_Init()
 {
@@ -47,21 +49,21 @@ void WeaponStats_ready(entity fh, entity pass, float status)
                case URL_READY_CANREAD:
                        // url_fclose is processing, we got a response for writing the data
                        // this must come from HTTP
-                       LOG_INFO("Got response from weapon stats server:\n");
+                       LOG_INFO("Got response from weapon stats server:");
                        while((s = url_fgets(fh)))
-                               LOG_INFO("  ", s, "\n");
-                       LOG_INFO("End of response.\n");
+                               LOG_INFO("  ", s);
+                       LOG_INFO("End of response.");
                        url_fclose(fh);
                        break;
                case URL_READY_CLOSED:
                        // url_fclose has finished
-                       LOG_INFO("Weapon stats written\n");
+                       LOG_INFO("Weapon stats written");
                        buf_del(weaponstats_buffer);
                        weaponstats_buffer = -1;
                        break;
                case URL_READY_ERROR:
                default:
-                       LOG_INFO("Weapon stats writing failed: ", ftos(status), "\n");
+                       LOG_INFO("Weapon stats writing failed: ", ftos(status));
                        buf_del(weaponstats_buffer);
                        weaponstats_buffer = -1;
                        break;