From ccc5cfd2466839553ed813d3172a7e7fa7554ee7 Mon Sep 17 00:00:00 2001 From: TimePath Date: Fri, 18 Dec 2015 11:58:00 +1100 Subject: [PATCH] viewmodels: fix vehicles --- qcsrc/client/view.qc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/qcsrc/client/view.qc b/qcsrc/client/view.qc index 8602ef26a..a5425cb3c 100644 --- a/qcsrc/client/view.qc +++ b/qcsrc/client/view.qc @@ -274,6 +274,11 @@ void viewmodel_draw(entity this) { int mask = (intermission || (STAT(HEALTH) <= 0) || autocvar_chase_active) ? 0 : MASK_NORMAL; float a = this.alpha; + static bool wasinvehicle; + bool invehicle = player_localentnum > maxclients; + if (invehicle) a = -1; + else if (wasinvehicle) a = 1; + wasinvehicle = invehicle; int c = stof(getplayerkeyvalue(current_player, "colors")); vector g; Weapon wep = activeweapon; -- 2.39.2