]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
New fading effect for centerprints -- not done yet, still need to add configuration...
authorSamual <samual@xonotic.org>
Mon, 26 Sep 2011 04:17:31 +0000 (00:17 -0400)
committerSamual <samual@xonotic.org>
Mon, 26 Sep 2011 04:17:31 +0000 (00:17 -0400)
qcsrc/client/hud.qc

index d2ed21eeb7dfd9deb7f867595e67e35c9df6caec..c4364a209ba091ffd8224f0ea6e3d1f5e237cb32 100644 (file)
@@ -4603,13 +4603,14 @@ void HUD_CenterPrint (void)
                if (centerprint_time[j] < 0 || centerprint_expire_time[j] - centerprint_fadetime > time)
                {
                        a = bound(0, (time - (centerprint_expire_time[j] - centerprint_time[j])) / centerprint_fadetime, 1);
-                       sz = 0.8 + a * (1 - 0.8);
                }
                else if (centerprint_expire_time[j] > time)
                {
                        a = (centerprint_expire_time[j] - time) / centerprint_fadetime;
-                       sz = 0.8 + a * (1 - 0.8);
                }
+               
+               a = a * (bound(0.5, (1 - (i / 2)), 1) * bound(0.5, (1 - (i / 10)), 1));
+               sz = 0.8 + a * (1 - 0.8);
 
                drawfontscale = sz * '1 1 0';
                if (centerprint_countdown_num[j])