From 8cc4399d18cea7364757939568b945e370eb9420 Mon Sep 17 00:00:00 2001 From: timokoesters Date: Tue, 16 Apr 2019 20:43:13 +0200 Subject: [PATCH] Handle bone orientation and scale as well Former-commit-id: 80c80342ae3458b98c2520359bc0a0705b22dbc1 --- voxygen/src/anim/mod.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/voxygen/src/anim/mod.rs b/voxygen/src/anim/mod.rs index 00a2da9bd0..c84599a1ef 100644 --- a/voxygen/src/anim/mod.rs +++ b/voxygen/src/anim/mod.rs @@ -31,6 +31,8 @@ impl Bone { // TODO: Make configurable let factor = 0.3; self.offset += (target.offset - self.offset) * factor; + self.ori = vek::ops::Slerp::slerp(self.ori, target.ori, factor); + self.scale += (target.scale - self.scale) * factor; } }