mirror of
https://github.com/DrBeef/JKXR.git
synced 2024-11-21 19:51:33 +00:00
Lowered Stun Baton trigger velocity
This commit is contained in:
parent
43192a355d
commit
3c64fa7e3e
1 changed files with 6 additions and 4 deletions
|
@ -401,13 +401,15 @@ void HandleInput_Default( ovrInputStateTrackedRemote *pDominantTrackedRemoteNew,
|
|||
//Does weapon velocity trigger attack
|
||||
if (vr.velocitytriggered) {
|
||||
static bool fired = false;
|
||||
vr.primaryVelocityTriggeredAttack = (vr.primaryswingvelocity >
|
||||
vr_weapon_velocity_trigger->value);
|
||||
|
||||
float velocityRequired = (cl.frame.ps.weapon == WP_SABER) ? vr_weapon_velocity_trigger->value :
|
||||
(vr_weapon_velocity_trigger->value / 2.0f);
|
||||
|
||||
vr.primaryVelocityTriggeredAttack = (vr.primaryswingvelocity > velocityRequired);
|
||||
//player has to be dual wielding for this to be true
|
||||
if (vr.dualsabers)
|
||||
{
|
||||
vr.secondaryVelocityTriggeredAttack = (vr.secondaryswingvelocity >
|
||||
vr_weapon_velocity_trigger->value);
|
||||
vr.secondaryVelocityTriggeredAttack = (vr.secondaryswingvelocity > velocityRequired);
|
||||
}
|
||||
|
||||
bool triggered = vr.primaryVelocityTriggeredAttack || (vr.dualsabers && vr.secondaryVelocityTriggeredAttack);
|
||||
|
|
Loading…
Reference in a new issue