adding the possibility to pause/resume an animation

This commit is contained in:
Clément Le Bihan
2021-06-02 16:11:14 +02:00
parent f245fe727b
commit b3eae9ebdf
3 changed files with 24 additions and 3 deletions
@@ -24,6 +24,8 @@ namespace BBM
auto &model = entity.getComponent<Drawable3DComponent<RAY::Drawables::Drawables3D::Model>>();
auto &anim = entity.getComponent<AnimationsComponent>();
if (anim.isDisabled())
return;
model.member.setAnimation(anim.getCurrentModelAnim());
anim.setCurrentAnimFrameCounter(anim.getCurrentAnimFrameCounter() + 1);
}