You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
But the player starts using a func_tank in PlayerUse, called by ImpulseCommands. The very first frame that the player starts using a func_tank or other controllable gun the remaining code in the ItemPostFrame function will still execute, causing weapons to respond to inputs after being holstered.
In the Gauss gun's case holding down secondary attack, using the gun and then moving away causes the Gauss gun to discharge.
To fix this an additional check is needed:
ImpulseCommands();
// check again if the player is using a tank if they started using it in PlayerUseif (m_pTank != NULL)
return;
if (!m_pActiveItem)
return;
m_pActiveItem->ItemPostFrame( );
Originally found by Oxofemple.
The text was updated successfully, but these errors were encountered:
SamVanheer
added a commit
to twhl-community/halflife-updated
that referenced
this issue
Apr 1, 2023
When the player is using a func_tank they normally can't send inputs to their weapons. This is because of this check here:
halflife/dlls/player.cpp
Lines 3866 to 3885 in c7240b9
But the player starts using a func_tank in
PlayerUse
, called byImpulseCommands
. The very first frame that the player starts using a func_tank or other controllable gun the remaining code in theItemPostFrame
function will still execute, causing weapons to respond to inputs after being holstered.In the Gauss gun's case holding down secondary attack, using the gun and then moving away causes the Gauss gun to discharge.
To fix this an additional check is needed:
Originally found by Oxofemple.
The text was updated successfully, but these errors were encountered: