From 708b23af5be915c35675093c53f210687c4b8537 Mon Sep 17 00:00:00 2001 From: Mircea Kitsune Date: Tue, 1 Mar 2011 15:29:48 +0200 Subject: [PATCH] Fix possibility of blur getting stuck on when it's not the case to apply it (eg: your screen remained damage blurred, you restarted Xonotic, and when you connected again you'd be stuck with the last blur state) --- qcsrc/client/View.qc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/qcsrc/client/View.qc b/qcsrc/client/View.qc index 9299d98ef..7faad6d3b 100644 --- a/qcsrc/client/View.qc +++ b/qcsrc/client/View.qc @@ -731,7 +731,7 @@ void CSQC_UpdateView(float w, float h) if(autocvar_hud_postprocessing) { - if(autocvar_hud_contents_blur) + if(autocvar_hud_contents_blur && contentavgalpha) { content_blurpostprocess_x = 1; content_blurpostprocess_y = contentavgalpha * autocvar_hud_contents_blur; @@ -808,7 +808,7 @@ void CSQC_UpdateView(float w, float h) if(autocvar_hud_postprocessing) { - if(autocvar_hud_damage_blur) + if(autocvar_hud_damage_blur && myhealth_flash_temp) { damage_blurpostprocess_x = 1; damage_blurpostprocess_y = bound(0, myhealth_flash_temp, 1) * autocvar_hud_damage_blur; @@ -819,7 +819,7 @@ void CSQC_UpdateView(float w, float h) damage_blurpostprocess_x = 0; damage_blurpostprocess_y = 0; damage_blurpostprocess_z = 0; - } + } dprint(strcat(ftos(myhealth_flash_temp), "----------\n")); } } -- 2.39.2