From: MirceaKitsune Date: Sun, 29 Jan 2012 21:52:04 +0000 (+0200) Subject: Make portraits expire after an amount of time X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=c8bba5f78a3ef67f99e6c33acd239548dd717430;p=voretournament%2Fvoretournament.git Make portraits expire after an amount of time --- diff --git a/data/qcsrc/client/hud.qc b/data/qcsrc/client/hud.qc index 58c1d378..f2a7a573 100644 --- a/data/qcsrc/client/hud.qc +++ b/data/qcsrc/client/hud.qc @@ -1691,11 +1691,17 @@ void Sbar_Portrait() if(!cvar("sbar_portrait")) return; - if(portrait_time) + if(portrait_time + cvar("sbar_portrait_time") >= time) { drawpic(left + '10 -80 0', portrait_image, '120 160 0', '1 1 1', sbar_alpha_fg, DRAWFLAG_NORMAL); drawcolorcodedstring(left + '10 80 0', portrait_name, '12 12 0', sbar_alpha_fg, DRAWFLAG_NORMAL); } + else if(portrait_time) + { + strunzone(portrait_name); + strunzone(portrait_image); + portrait_time = 0; + } } void Sbar_Score()