mirror of
https://github.com/DrBeef/JKXR.git
synced 2024-11-10 06:42:17 +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
|
//Does weapon velocity trigger attack
|
||||||
if (vr.velocitytriggered) {
|
if (vr.velocitytriggered) {
|
||||||
static bool fired = false;
|
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
|
//player has to be dual wielding for this to be true
|
||||||
if (vr.dualsabers)
|
if (vr.dualsabers)
|
||||||
{
|
{
|
||||||
vr.secondaryVelocityTriggeredAttack = (vr.secondaryswingvelocity >
|
vr.secondaryVelocityTriggeredAttack = (vr.secondaryswingvelocity > velocityRequired);
|
||||||
vr_weapon_velocity_trigger->value);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool triggered = vr.primaryVelocityTriggeredAttack || (vr.dualsabers && vr.secondaryVelocityTriggeredAttack);
|
bool triggered = vr.primaryVelocityTriggeredAttack || (vr.dualsabers && vr.secondaryVelocityTriggeredAttack);
|
||||||
|
|
Loading…
Reference in a new issue