Fix a dumb issue
authorMirceaKitsune <sonichedgehog_hyperblast00@yahoo.com>
Sun, 26 Sep 2010 17:13:45 +0000 (20:13 +0300)
committerMirceaKitsune <sonichedgehog_hyperblast00@yahoo.com>
Sun, 26 Sep 2010 17:13:45 +0000 (20:13 +0300)
data/qcsrc/client/View.qc

index 76f3f2c54ed84563e7a1df57835caef13b41718f..e4dd37f50a8d54cad06b0605596baf4a1c07b2dc 100644 (file)
@@ -498,15 +498,13 @@ void CSQC_UpdateView(float w, float h)
                {\r
                        if(getstati(STAT_WINNING)) // we are the winner\r
                        {\r
-                               if(!cvar("cl_artwork_won"))\r
-                                       return;\r
-                               artwork_image = strcat("gfx/artwork_won_", ftos(floor(1 + (random() * cvar("cl_artwork_won")))));\r
+                               if(cvar("cl_artwork_won"))\r
+                                       artwork_image = strcat("gfx/artwork_won_", ftos(floor(1 + (random() * cvar("cl_artwork_won")))));\r
                        }\r
                        else // we have lost\r
                        {\r
-                               if(!cvar("cl_artwork_lost"))\r
-                                       return;\r
-                               artwork_image = strcat("gfx/artwork_lost_", ftos(floor(1 + (random() * cvar("cl_artwork_lost")))));\r
+                               if(cvar("cl_artwork_lost"))\r
+                                       artwork_image = strcat("gfx/artwork_lost_", ftos(floor(1 + (random() * cvar("cl_artwork_lost")))));\r
                        }\r
                        artwork_image = strzone(artwork_image);\r
                }\r
@@ -531,7 +529,8 @@ void CSQC_UpdateView(float w, float h)
                else\r
                        artwork_fade = cvar("cl_artwork_alpha");\r
 \r
-               drawpic(artwork_pos, artwork_image, artwork_size, '1 1 1', artwork_fade, DRAWFLAG_NORMAL);\r
+               if(artwork_image != "")\r
+                       drawpic(artwork_pos, artwork_image, artwork_size, '1 1 1', artwork_fade, DRAWFLAG_NORMAL);\r
        }\r
        else\r
        {\r