This commit is contained in:
ericrius1 2015-12-21 10:46:54 -08:00
parent 0dd7287e61
commit 45ba7a3d35
2 changed files with 0 additions and 31 deletions

View file

@ -877,24 +877,14 @@ function MyController(hand) {
// if an object is "equipped" and has a spatialKey, use it.
this.ignoreIK = grabbableData.spatialKey.ignoreIK ? grabbableData.spatialKey.ignoreIK : false;
if (grabbableData.spatialKey.relativePosition) {
<<<<<<< HEAD
this.offsetPosition = getSpatialOffsetPosition(this.hand, grabbableData.spatialKey);
=======
this.offsetPosition = getSpatialOffsetPosition(this.hand, grabbableData.spatialKey);
>>>>>>> origin/polylineOptimizations
} else {
this.offsetPosition = Vec3.multiplyQbyV(Quat.inverse(Quat.multiply(handRotation, this.offsetRotation)), offset);
}
if (grabbableData.spatialKey.relativeRotation) {
<<<<<<< HEAD
this.offsetRotation = getSpatialOffsetRotation(this.hand, grabbableData.spatialKey);
} else {
this.offsetRotation = Quat.multiply(Quat.inverse(handRotation), objectRotation);
=======
this.offsetRotation = getSpatialOffsetRotation(this.hand, grabbableData.spatialKey);
} else {
this.offsetRotation = Quat.multiply(Quat.inverse(handRotation), objectRotation);
>>>>>>> origin/polylineOptimizations
}
} else {
this.ignoreIK = false;

View file

@ -33,21 +33,13 @@
},
createBeam: function(startPosition, endPosition) {
<<<<<<< HEAD
// Creates particle arc from start position to end position
=======
// Creates particle arc from start position to end position
>>>>>>> origin/polylineOptimizations
var rotation = Entities.getEntityProperties(this.entityID, "rotation").rotation;
var sourceToTargetVec = Vec3.subtract(endPosition, startPosition);
var emitOrientation = Quat.rotationBetween(Vec3.UNIT_Z, sourceToTargetVec);
emitOrientation = Quat.multiply(Quat.inverse(rotation), emitOrientation);
<<<<<<< HEAD
=======
>>>>>>> origin/polylineOptimizations
var color = {
red: 200,
green: 10,
@ -110,7 +102,6 @@
var rotation = Entities.getEntityProperties(this.entityID, "rotation").rotation;
var sourceToTargetVec = Vec3.subtract(targetPosition, startPosition);
var emitOrientation = Quat.rotationBetween(Vec3.UNIT_Z, sourceToTargetVec);
<<<<<<< HEAD
// emitOrientation = Quat.multiply(emitOrientation,Quat.inverse(rotation));
Entities.editEntity(this.particleArc, {
emitOrientation: emitOrientation
@ -122,18 +113,6 @@
this.updateBeam(startPosition);
},
=======
emitOrientation = Quat.multiply(Quat.inverse(rotation), emitOrientation);
Entities.editEntity(this.particleArc, {emitOrientation: emitOrientation});
Entities.editEntity(this.testBox, {rotation: emitOrientation});
},
continueNearGrab: function() {
var startPosition = Entities.getEntityProperties(this.entityID, "position").position;
this.updateBeam(startPosition);
},
>>>>>>> origin/polylineOptimizations
releaseGrab: function() {
Entities.editEntity(this.particleArc, {
isEmitting: false