From bf658945a52b70b99fdec29992d8398598ab01fa Mon Sep 17 00:00:00 2001 From: def Date: Sat, 8 Feb 2014 21:55:08 +0100 Subject: [PATCH] Fix some +showhookcoll --- src/game/client/gameclient.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/game/client/gameclient.cpp b/src/game/client/gameclient.cpp index 9568868a6..0c805d1af 100644 --- a/src/game/client/gameclient.cpp +++ b/src/game/client/gameclient.cpp @@ -1286,6 +1286,9 @@ int CGameClient::IntersectCharacter(vec2 HookPos, vec2 NewPos, vec2& NewPos2, in float Distance = 0.0f; int ClosestID = -1; + if (!m_Tuning.m_PlayerHooking) + return ClosestID; + for (int i=0; iIntraGameTick()); - if (!cData.m_Active || cData.m_Team == TEAM_SPECTATORS || i == ownID || !m_Teams.CanCollide(i, ownID) || !m_PredictedChar.m_Collision) + if (!cData.m_Active || cData.m_Team == TEAM_SPECTATORS || i == ownID || !m_Teams.SameTeam(i, ownID)) continue; vec2 ClosestPoint = closest_point_on_line(HookPos, NewPos, Position);