From e21f8265cbdefc02b31ba3638ac7e30c19a875dd Mon Sep 17 00:00:00 2001 From: Samual Lenks Date: Sat, 15 Dec 2012 06:11:56 -0500 Subject: [PATCH] also force a check to see if there is even a string for info messages --- qcsrc/common/notifications.qc | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/qcsrc/common/notifications.qc b/qcsrc/common/notifications.qc index ba9b49ab9..fe1aadce2 100644 --- a/qcsrc/common/notifications.qc +++ b/qcsrc/common/notifications.qc @@ -511,6 +511,12 @@ string normal_or_gentle(string normal, string gentle) #endif } +float notif_checkstring(string input) +{ + if not(input == "") { return TRUE; } + else { return FALSE; } +} + float notif_stringcount(string s1, string s2) { float stringcount; @@ -677,7 +683,7 @@ void Local_Notification(float net_type, float net_name, string s1, string s2, fl #define MSG_INFO_NOTIF(name,strnum,flnum,args,hudargs,icon,normal,gentle) \ { NOTIF_MATCH(name, net_name) CHECK_AUTOCVAR(name) \ { \ - print(sprintf(CCR(normal_or_gentle(normal, gentle)), args)); \ + if(notif_checkstring(normal)) { print(sprintf(CCR(normal_or_gentle(normal, gentle)), args)); } \ if(strtolower(icon) != "") { HUD_Notify_Push(icon, hudargs); } \ } } MSG_INFO_NOTIFICATIONS -- 2.39.2