mirror of
https://github.com/AleziaKurdis/overte.git
synced 2025-04-13 21:27:21 +02:00
Merge pull request #27 from wayne-chen/locomotionCRFeedback
adding precheck procedure
This commit is contained in:
commit
a2084259fa
1 changed files with 3 additions and 2 deletions
|
@ -3427,8 +3427,9 @@ glm::vec3 MyAvatar::calculateScaledDirection(){
|
|||
forward = Vectors::ZERO;
|
||||
}
|
||||
right = (handRotation * controllerRight);
|
||||
if (glm::length(right) > EPSILON) {
|
||||
right = glm::normalize(right - (glm::dot(right, Vectors::UNIT_Y) * Vectors::UNIT_Y));
|
||||
transform = right - (glm::dot(right, Vectors::UNIT_Y) * Vectors::UNIT_Y);
|
||||
if (glm::length(transform) > EPSILON) {
|
||||
right = glm::normalize(transform);
|
||||
} else {
|
||||
right = Vectors::ZERO;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue