]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Fix missing countdown messages and announcements when a round is starting. Fixes... 254/head
authorterencehill <piuntn@gmail.com>
Fri, 13 Nov 2015 17:28:27 +0000 (18:28 +0100)
committerTimePath <andrew.hardaker1995@gmail.com>
Sat, 14 Nov 2015 07:46:25 +0000 (18:46 +1100)
qcsrc/client/announcer.qc

index fa8f2b0055b51395ed0248ae4129cc1e741d55fa..6fcdbb9d69354114ce2a0f36582b885218600481 100644 (file)
@@ -15,6 +15,8 @@ string AnnouncerOption()
        return ret;
 }
 
+entity announcer_countdown;
+
 void Announcer_Countdown()
 {
        SELFPARAM();
@@ -24,6 +26,7 @@ void Announcer_Countdown()
        {
                Local_Notification(MSG_CENTER, CENTER_COUNTDOWN_ROUNDSTOP);
                remove(this);
+               announcer_countdown = NULL;
                return;
        }
        if(roundstarttime >= starttime)
@@ -39,6 +42,7 @@ void Announcer_Countdown()
                Local_Notification(MSG_CENTER, CENTER_COUNTDOWN_BEGIN);
                Local_Notification(MSG_MULTI, MULTI_COUNTDOWN_BEGIN);
                remove(this);
+               announcer_countdown = NULL;
                return;
        }
        else // countdown is still going
@@ -78,7 +82,6 @@ void Announcer_Gamestart()
        {
                if(time < startTime)
                {
-                       static entity announcer_countdown;
                        if (!announcer_countdown)
                        {
                                announcer_countdown = new(announcer_countdown);