@@ -1520,12 +1520,12 @@ class HumanSkeleton(
15201520 @JvmOverloads
15211521 fun resetTrackersFull (resetSourceName : String? , bodyParts : List <Int > = ArrayList ()) {
15221522 var referenceRotation = IDENTITY
1523- if (bodyParts.isEmpty() || bodyParts.contains( BodyPart . HEAD )) {
1524- headTracker?. let {
1523+ headTracker?. let {
1524+ if (bodyParts.isEmpty() || bodyParts.contains( BodyPart . HEAD )) {
15251525 // Always reset the head (ifs in resetsHandler)
15261526 it.resetsHandler.resetFull(referenceRotation)
1527- referenceRotation = it.getRotation()
15281527 }
1528+ referenceRotation = it.getRotation()
15291529 }
15301530
15311531 // Resets all axes of the trackers with the HMD as reference.
@@ -1551,14 +1551,14 @@ class HumanSkeleton(
15511551 fun resetTrackersYaw (resetSourceName : String? , bodyParts : List <Int > = TrackerUtils .allBodyPartsButFingers) {
15521552 // Resets the yaw of the trackers with the head as reference.
15531553 var referenceRotation = IDENTITY
1554- if (bodyParts.isEmpty() || bodyParts.contains( BodyPart . HEAD )) {
1555- headTracker?. let {
1554+ headTracker?. let {
1555+ if (bodyParts.isEmpty() || bodyParts.contains( BodyPart . HEAD )) {
15561556 // Only reset if head needsReset and isn't computed
15571557 if (it.needsReset && ! it.isComputed) {
15581558 it.resetsHandler.resetYaw(referenceRotation)
15591559 }
1560- referenceRotation = it.getRotation()
15611560 }
1561+ referenceRotation = it.getRotation()
15621562 }
15631563 for (tracker in trackersToReset) {
15641564 // Only reset if tracker needsReset
@@ -1572,7 +1572,7 @@ class HumanSkeleton(
15721572
15731573 @VRServerThread
15741574 @JvmOverloads
1575- fun resetTrackersMounting (resetSourceName : String? , bodyParts : List <Int > = ArrayList () ) {
1575+ fun resetTrackersMounting (resetSourceName : String? , bodyParts : List <Int > = TrackerUtils .allBodyPartsButFeetAndFingers ) {
15761576 val trackersToReset = trackersToReset
15771577
15781578 // TODO: PLEASE rewrite this handling at some point in the future... This is so
@@ -1587,14 +1587,14 @@ class HumanSkeleton(
15871587
15881588 // Resets the mounting orientation of the trackers with the HMD as reference.
15891589 var referenceRotation = IDENTITY
1590- if (bodyParts.isEmpty() || bodyParts.contains( BodyPart . HEAD )) {
1591- headTracker?. let {
1590+ headTracker?. let {
1591+ if (bodyParts.isEmpty() || bodyParts.contains( BodyPart . HEAD )) {
15921592 // Only reset if head needsMounting or is computed but not HMD
15931593 if (it.needsMounting || (it.isComputed && ! it.isHmd)) {
15941594 it.resetsHandler.resetMounting(referenceRotation)
15951595 }
1596- referenceRotation = it.getRotation()
15971596 }
1597+ referenceRotation = it.getRotation()
15981598 }
15991599 for (tracker in trackersToReset) {
16001600 // Only reset if tracker needsMounting
0 commit comments