From: LegendaryGuard Date: Mon, 11 Jul 2022 17:40:01 +0000 (+0200) Subject: Fix hunter eyes black screen time when round is started X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=06ab5ed7add95a3e4c4e7de5eb679f566e9ed6c9;p=xonotic%2Fxonotic-data.pk3dir.git Fix hunter eyes black screen time when round is started --- diff --git a/qcsrc/common/gamemodes/gamemode/mh/mh.qh b/qcsrc/common/gamemodes/gamemode/mh/mh.qh index 7f1b0a34a..1b320b281 100644 --- a/qcsrc/common/gamemodes/gamemode/mh/mh.qh +++ b/qcsrc/common/gamemodes/gamemode/mh/mh.qh @@ -103,6 +103,9 @@ MUTATOR_HOOKFUNCTION(cl_hunteryes, HUD_Draw_overlay) if(!eyesblinded) return false; + if(!STAT(GAME_STOPPED) && !warmup_stage && STAT(MH_ROUNDTIMER) > 0) + eyesblinded = false; + if(time <= huntereyes_fadetime) { HUD_HunterEyes(); @@ -123,22 +126,6 @@ NET_HANDLE(TE_CSQC_HUNTEREYES, bool isNew) eyesblinded = true; huntereyes_appeartime = time; - float time_mh_roundstart = (time * 2 + cvar("g_mh_warmup")) / 1.655; - if(time <= cvar("g_mh_warmup")) // if it's the first time round starts - { - huntereyes_fadetime = time_mh_roundstart; - // LOG_INFOF("if ENTERED time: %f", time); - } - else - { - huntereyes_fadetime = time + cvar("g_mh_warmup"); - // LOG_INFOF("else ENTERED time: %f", time); - } - - // just another test - // if(huntereyes_fadetime > time) - // huntereyes_fadetime = time; LOG_INFOF("time: %f", time); - - // LOG_INFOF("huntereyes_fadetime: %f", huntereyes_fadetime); + huntereyes_fadetime = time + cvar("g_mh_warmup"); } #endif \ No newline at end of file