Commit 3b69c908 authored by Mario's avatar Mario

Properly unassign hook from player's weapon entity on client side (may fix crouching issues)

parent 2e5a87f4
Pipeline #5700734 passed with stages
in 19 minutes and 15 seconds
......@@ -501,8 +501,12 @@ void Remove_GrapplingHook(entity this)
{
sound (this, CH_SHOTS_SINGLE, SND_Null, VOL_BASE, ATTEN_NORM);
if(csqcplayer && csqcplayer.hook == this)
csqcplayer.hook = NULL;
for(int slot = 0; slot < MAX_WEAPONSLOTS; ++slot)
{
entity wep = viewmodels[slot];
if(wep.hook == this)
wep.hook = NULL;
}
}
NET_HANDLE(ENT_CLIENT_HOOK, bool bIsNew)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment