]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/notifications/all.qh
Remove references to sendcvar from cvar descriptions, mark setreport as deprecated...
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / notifications / all.qh
index dc63a70803963ceb4c7c8f2e9b49066a6dca225e..2d775d4f219386fe82fc31ab3cc09ef52c53f827 100644 (file)
@@ -856,4 +856,17 @@ REGISTRY_END(Notifications)
                LOG_SEVERE("Notification initialization failed! Read above and fix the errors!");
 }
 
+#ifdef CSQC
+.int cvar_value;
+void ReplicateVars(bool would_destroy)
+{
+       if (!would_destroy)
+               FOREACH(Notifications, it.nent_type == MSG_CHOICE, {
+                       string cvarname = sprintf("notification_%s", Get_Notif_CvarName(it));
+                       // NOTE: REPLICATE_SIMPLE can return;
+                       REPLICATE_SIMPLE(it.cvar_value, cvarname);
+               });
+}
+#endif
+
 #include "all.inc"