]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/player.qc
Using bprint instead of sprint
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / player.qc
index 067ed02e938064cdd78d354372d4d3873515680f..fa203b4f667859e0bb4a624675383ad7df4629bf 100644 (file)
@@ -678,6 +678,34 @@ void dedicated_print(string input)
        if (server_is_dedicated) print(input);
 }
 
+void PrintToChat(entity player, string text)
+{
+       text = strcat("\{1}^7", text, "\n");
+       sprint(player, text);
+}
+
+void DebugPrintToChat(entity player, string text)
+{
+       if (autocvar_developer)
+       {
+               PrintToChat(player, text);
+       }
+}
+
+void PrintToChatAll(string text)
+{
+       text = strcat("\{1}^7", text, "\n");
+       bprint(text);
+}
+
+void DebugPrintToChatAll(string text)
+{
+       if (autocvar_developer)
+       {
+               PrintToChatAll(text);
+       }
+}
+
 /**
  * message "": do not say, just test flood control
  * return value: