fix: rolling

This commit is contained in:
timokoesters 2020-01-27 18:32:05 +01:00
parent 6515daddce
commit 76dfac7366
3 changed files with 3 additions and 20 deletions

View File

@ -16,9 +16,10 @@ impl Animation for RollAnimation {
skeleton: &Self::Skeleton,
(_active_tool_kind, orientation, last_ori, _global_time): Self::Dependency,
anim_time: f64,
_rate: &mut f32,
rate: &mut f32,
skeleton_attr: &SkeletonAttr,
) -> Self::Skeleton {
*rate = 1.0;
let mut next = (*skeleton).clone();
let wave = (anim_time as f32 * 5.5).sin();

View File

@ -14,7 +14,7 @@ use crate::render::FigureBoneData;
use common::comp::{self, ToolKind};
use vek::*;
#[derive(Copy, Clone)]
#[derive(Copy, Clone, Debug)]
pub struct Bone {
pub offset: Vec3<f32>,
pub ori: Quaternion<f32>,

View File

@ -407,24 +407,6 @@ impl FigureMgr {
&mut state_animation_rate,
skeleton_attr,
),
CharacterState::Wielding(_) => {
anim::character::WieldAnimation::update_skeleton(
&target_base,
(active_tool_kind, vel.0.magnitude(), time),
state.state_time,
&mut state_animation_rate,
skeleton_attr,
)
}
CharacterState::Wielded(_) => {
anim::character::WieldAnimation::update_skeleton(
&target_base,
(active_tool_kind, vel.0.magnitude(), time),
state.state_time,
&mut state_animation_rate,
skeleton_attr,
)
}
/*CharacterState::Block(_) => {
anim::character::BlockIdleAnimation::update_skeleton(
&target_base,