mirror of
https://github.com/overte-org/overte.git
synced 2025-08-12 21:29:49 +02:00
prevent most other-hand accidental firing
This commit is contained in:
parent
4a7e3c66bd
commit
7f841b3828
1 changed files with 2 additions and 1 deletions
|
@ -84,6 +84,7 @@
|
|||
var _t = this;
|
||||
this.canShootTimeout = Script.setTimeout(function() {
|
||||
_t.canShoot = false;
|
||||
_t.whichHand=null;
|
||||
}, 250)
|
||||
},
|
||||
|
||||
|
@ -97,7 +98,7 @@
|
|||
if (this.triggerValue < RELOAD_THRESHOLD) {
|
||||
// print('RELOAD');
|
||||
this.canShoot = true;
|
||||
} else if (this.triggerValue >= RELOAD_THRESHOLD && this.canShoot === true) {
|
||||
} else if (this.triggerValue >= RELOAD_THRESHOLD && this.canShoot === true && this.hand === this.whichHand) {
|
||||
var gunProperties = Entities.getEntityProperties(this.entityID, ["position", "rotation"]);
|
||||
this.shootBall(gunProperties);
|
||||
this.canShoot = false;
|
||||
|
|
Loading…
Reference in a new issue