mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Bones scaling cleanup
This commit is contained in:
parent
3d23475abd
commit
ef1428f9fe
@ -46,7 +46,7 @@ impl Animation for BetaAnimation {
|
||||
next.hand_r.position = Vec3::new(0.75, -1.5, -0.5);
|
||||
next.hand_r.orientation =
|
||||
Quaternion::rotation_x(1.47) * Quaternion::rotation_y(0.3);
|
||||
next.hand_r.scale = Vec3::one() * 1.05;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(0.0, 5.0, -6.0);
|
||||
next.main.orientation = Quaternion::rotation_x(-0.1)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
|
@ -129,20 +129,17 @@ impl Animation for ChargeAnimation {
|
||||
if velocity < 0.5 {
|
||||
next.jaw.position = Vec3::new(0.0, s_a.jaw.0 - slower * 0.12, s_a.jaw.1 + slow * 0.2);
|
||||
next.jaw.orientation = Quaternion::rotation_x(slow * 0.05);
|
||||
next.jaw.scale = Vec3::one() * 0.98;
|
||||
next.jaw.scale = Vec3::one() * 1.02;
|
||||
|
||||
next.tail.position = Vec3::new(0.0, s_a.tail.0, s_a.tail.1);
|
||||
next.tail.orientation =
|
||||
Quaternion::rotation_z(0.0 + slow * 0.2 + tailmove.x) * Quaternion::rotation_x(0.0);
|
||||
next.tail.scale = Vec3::one();
|
||||
|
||||
next.shoulder_l.position = Vec3::new(-s_a.shoulder.0, s_a.shoulder.1, s_a.shoulder.2);
|
||||
next.shoulder_l.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.0);
|
||||
next.shoulder_l.scale = Vec3::one();
|
||||
|
||||
next.shoulder_r.position = Vec3::new(s_a.shoulder.0, s_a.shoulder.1, s_a.shoulder.2);
|
||||
next.shoulder_r.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.0);
|
||||
next.shoulder_r.scale = Vec3::one();
|
||||
|
||||
next.leg_l.position =
|
||||
Vec3::new(-s_a.leg.0, s_a.leg.1, s_a.leg.2 + breathe * 0.2) * 1.02;
|
||||
@ -155,11 +152,9 @@ impl Animation for ChargeAnimation {
|
||||
|
||||
next.foot_l.position = Vec3::new(-s_a.foot.0, s_a.foot.1, s_a.foot.2);
|
||||
next.foot_l.orientation = Quaternion::rotation_z(0.0);
|
||||
next.foot_l.scale = Vec3::one();
|
||||
|
||||
next.foot_r.position = Vec3::new(s_a.foot.0, s_a.foot.1, s_a.foot.2);
|
||||
next.foot_r.orientation = Quaternion::rotation_z(0.0);
|
||||
next.foot_r.scale = Vec3::one();
|
||||
|
||||
next.torso.position = Vec3::new(0.0, 0.0, 0.0) / 8.0;
|
||||
next.torso.orientation = Quaternion::rotation_z(test * 0.0);
|
||||
@ -169,16 +164,14 @@ impl Animation for ChargeAnimation {
|
||||
next.control.orientation = Quaternion::rotation_x(test * 0.02)
|
||||
* Quaternion::rotation_y(test * 0.02)
|
||||
* Quaternion::rotation_z(test * 0.02);
|
||||
next.control.scale = Vec3::one();
|
||||
} else {
|
||||
next.jaw.position = Vec3::new(0.0, s_a.jaw.0 - slower * 0.12, s_a.jaw.1 + slow * 0.2);
|
||||
next.jaw.orientation = Quaternion::rotation_x(slow * 0.05);
|
||||
next.jaw.scale = Vec3::one() * 0.98;
|
||||
next.jaw.scale = Vec3::one() * 1.02;
|
||||
|
||||
next.tail.position = Vec3::new(0.0, s_a.tail.0, s_a.tail.1);
|
||||
next.tail.orientation =
|
||||
Quaternion::rotation_z(0.0 + slow * 0.2 + tailmove.x) * Quaternion::rotation_x(0.0);
|
||||
next.tail.scale = Vec3::one();
|
||||
|
||||
next.torso.position = Vec3::new(0.0, 0.0, 0.0) / 8.0;
|
||||
next.torso.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(-0.25);
|
||||
@ -202,7 +195,6 @@ impl Animation for ChargeAnimation {
|
||||
);
|
||||
next.foot_l.orientation =
|
||||
Quaternion::rotation_x(-0.5 + footrotl * 0.85) * Quaternion::rotation_y(0.0);
|
||||
next.foot_l.scale = Vec3::one();
|
||||
|
||||
next.foot_r.position = Vec3::new(
|
||||
s_a.foot.0,
|
||||
@ -211,7 +203,6 @@ impl Animation for ChargeAnimation {
|
||||
);
|
||||
next.foot_r.orientation =
|
||||
Quaternion::rotation_x(-0.5 + footrotr * 0.85) * Quaternion::rotation_y(0.0);
|
||||
next.foot_r.scale = Vec3::one();
|
||||
}
|
||||
match active_tool_kind {
|
||||
Some(ToolKind::Bow(_)) => {
|
||||
@ -219,13 +210,13 @@ impl Animation for ChargeAnimation {
|
||||
next.hand_l.orientation = Quaternion::rotation_x(1.20)
|
||||
* Quaternion::rotation_y(-0.6)
|
||||
* Quaternion::rotation_z(-0.3);
|
||||
next.hand_l.scale = Vec3::one() * 1.05;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
|
||||
next.hand_r.position = Vec3::new(5.9, 0.0, -5.0);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(1.20)
|
||||
* Quaternion::rotation_y(-0.6)
|
||||
* Quaternion::rotation_z(-0.3);
|
||||
next.hand_r.scale = Vec3::one() * 1.05;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
|
||||
next.shoulder_l.position = Vec3::new(
|
||||
-s_a.shoulder.0,
|
||||
@ -235,7 +226,6 @@ impl Animation for ChargeAnimation {
|
||||
next.shoulder_l.orientation = Quaternion::rotation_x(1.4 + footrotl * -0.06)
|
||||
* Quaternion::rotation_y(-0.9)
|
||||
* Quaternion::rotation_z(footrotl * -0.05);
|
||||
next.shoulder_l.scale = Vec3::one();
|
||||
|
||||
next.shoulder_r.position = Vec3::new(
|
||||
s_a.shoulder.0,
|
||||
@ -245,7 +235,6 @@ impl Animation for ChargeAnimation {
|
||||
next.shoulder_r.orientation = Quaternion::rotation_x(1.3 + footrotr * -0.06)
|
||||
* Quaternion::rotation_y(-0.5) //1.9
|
||||
* Quaternion::rotation_z(footrotr * -0.05);
|
||||
next.shoulder_r.scale = Vec3::one();
|
||||
|
||||
next.jaw.position = Vec3::new(0.0, s_a.jaw.0, s_a.jaw.1);
|
||||
next.jaw.orientation = Quaternion::rotation_x(stop * 0.05);
|
||||
@ -253,7 +242,6 @@ impl Animation for ChargeAnimation {
|
||||
next.tail.position = Vec3::new(0.0, s_a.tail.0, s_a.tail.1);
|
||||
next.tail.orientation = Quaternion::rotation_z(0.02 * stress * stop + tilt * 2.0)
|
||||
* Quaternion::rotation_x(-0.2 * stop);
|
||||
next.tail.scale = Vec3::one();
|
||||
|
||||
next.main.position = Vec3::new(7.0, 2.0, -13.0);
|
||||
next.main.orientation = Quaternion::rotation_x(-0.3)
|
||||
@ -270,17 +258,16 @@ impl Animation for ChargeAnimation {
|
||||
next.control.orientation = Quaternion::rotation_x(0.0)
|
||||
* Quaternion::rotation_y(stop * -0.4)
|
||||
* Quaternion::rotation_z(stop * -0.6);
|
||||
next.control.scale = Vec3::one();
|
||||
},
|
||||
Some(ToolKind::Staff(_)) => {
|
||||
next.hand_l.position = Vec3::new(11.0, 5.0, -4.0);
|
||||
next.hand_l.orientation = Quaternion::rotation_x(1.27);
|
||||
next.hand_l.scale = Vec3::one() * 1.05;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
|
||||
next.hand_r.position = Vec3::new(12.0, 5.5, 2.0);
|
||||
next.hand_r.orientation =
|
||||
Quaternion::rotation_x(1.57) * Quaternion::rotation_y(0.2);
|
||||
next.hand_r.scale = Vec3::one() * 1.05;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
|
||||
next.shoulder_l.position = Vec3::new(
|
||||
-s_a.shoulder.0,
|
||||
@ -290,7 +277,6 @@ impl Animation for ChargeAnimation {
|
||||
next.shoulder_l.orientation = Quaternion::rotation_x(0.5 + footrotl * -0.16)
|
||||
* Quaternion::rotation_y(0.1)
|
||||
* Quaternion::rotation_z(footrotl * 0.1);
|
||||
next.shoulder_l.scale = Vec3::one();
|
||||
|
||||
next.shoulder_r.position = Vec3::new(
|
||||
s_a.shoulder.0,
|
||||
@ -300,12 +286,10 @@ impl Animation for ChargeAnimation {
|
||||
next.shoulder_r.orientation = Quaternion::rotation_x(0.5 + footrotr * -0.16)
|
||||
* Quaternion::rotation_y(-0.1)
|
||||
* Quaternion::rotation_z(footrotr * -0.1);
|
||||
next.shoulder_r.scale = Vec3::one();
|
||||
|
||||
next.tail.position = Vec3::new(0.0, s_a.tail.0, s_a.tail.1);
|
||||
next.tail.orientation = Quaternion::rotation_z(0.02 * stress * stop + tilt * 2.0)
|
||||
* Quaternion::rotation_x(-0.2 * stop);
|
||||
next.tail.scale = Vec3::one();
|
||||
|
||||
next.main.position = Vec3::new(8.0, 8.5, 13.2);
|
||||
next.main.orientation = Quaternion::rotation_x(0.0)
|
||||
@ -319,7 +303,6 @@ impl Animation for ChargeAnimation {
|
||||
);
|
||||
next.control.orientation =
|
||||
Quaternion::rotation_x(stop * -0.2) * Quaternion::rotation_z(stop * 0.2);
|
||||
next.control.scale = Vec3::one();
|
||||
},
|
||||
_ => {},
|
||||
}
|
||||
|
@ -79,7 +79,7 @@ impl Animation for IdleAnimation {
|
||||
next.jaw.position = Vec3::new(0.0, s_a.jaw.0 - slower * 0.12, s_a.jaw.1 + slow * 0.2);
|
||||
}
|
||||
next.jaw.orientation = Quaternion::rotation_x(-0.1 + breathe * 2.0);
|
||||
next.jaw.scale = Vec3::one() * 0.98;
|
||||
next.jaw.scale = Vec3::one() * 1.02;
|
||||
|
||||
next.tail.position = Vec3::new(0.0, s_a.tail.0, s_a.tail.1);
|
||||
next.tail.orientation =
|
||||
@ -98,10 +98,10 @@ impl Animation for IdleAnimation {
|
||||
next.shoulder_r.scale = Vec3::one() + breathe;
|
||||
|
||||
next.hand_l.position = Vec3::new(-s_a.hand.0, s_a.hand.1, s_a.hand.2 + torso * 0.6);
|
||||
next.hand_l.scale = Vec3::one() * 1.02;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
|
||||
next.hand_r.position = Vec3::new(s_a.hand.0, s_a.hand.1, s_a.hand.2 + torso * 0.6);
|
||||
next.hand_r.scale = Vec3::one() * 1.02;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
|
||||
next.leg_l.position = Vec3::new(-s_a.leg.0, s_a.leg.1, s_a.leg.2 + torso * 0.2);
|
||||
next.leg_l.scale = Vec3::one() * 1.02;
|
||||
|
@ -38,7 +38,6 @@ impl Animation for JumpAnimation {
|
||||
next.upper_torso.position =
|
||||
Vec3::new(0.0, s_a.upper_torso.0, s_a.upper_torso.1 + torso * 0.5);
|
||||
next.upper_torso.orientation = Quaternion::rotation_x(-0.3);
|
||||
next.upper_torso.scale = Vec3::one();
|
||||
|
||||
next.lower_torso.position =
|
||||
Vec3::new(0.0, s_a.lower_torso.0, s_a.lower_torso.1 + torso * 0.15);
|
||||
@ -47,15 +46,12 @@ impl Animation for JumpAnimation {
|
||||
|
||||
next.jaw.position = Vec3::new(0.0, s_a.jaw.0, s_a.jaw.1);
|
||||
next.jaw.orientation = Quaternion::rotation_x(wave_slow * 0.09);
|
||||
next.jaw.scale = Vec3::one();
|
||||
|
||||
next.tail.position = Vec3::new(0.0, s_a.tail.0, s_a.tail.1 + torso * 0.0);
|
||||
next.tail.orientation = Quaternion::rotation_z(0.0);
|
||||
next.tail.scale = Vec3::one();
|
||||
|
||||
next.control.position = Vec3::new(0.0, 0.0, 0.0);
|
||||
next.control.orientation = Quaternion::rotation_z(0.0);
|
||||
next.control.scale = Vec3::one();
|
||||
|
||||
next.second.position = Vec3::new(0.0, 0.0, 0.0);
|
||||
next.second.orientation =
|
||||
@ -69,18 +65,16 @@ impl Animation for JumpAnimation {
|
||||
|
||||
next.shoulder_l.position = Vec3::new(-s_a.shoulder.0, s_a.shoulder.1, s_a.shoulder.2);
|
||||
next.shoulder_l.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.5);
|
||||
next.shoulder_l.scale = Vec3::one();
|
||||
|
||||
next.shoulder_r.position = Vec3::new(s_a.shoulder.0, s_a.shoulder.1, s_a.shoulder.2);
|
||||
next.shoulder_r.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(-0.5);
|
||||
next.shoulder_r.scale = Vec3::one();
|
||||
|
||||
next.hand_l.position = Vec3::new(-s_a.hand.0, s_a.hand.1, s_a.hand.2 + torso * 0.6);
|
||||
next.hand_l.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.8);
|
||||
|
||||
next.hand_r.position = Vec3::new(s_a.hand.0, s_a.hand.1, s_a.hand.2 + torso * 0.6);
|
||||
next.hand_r.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(-0.8);
|
||||
next.hand_r.scale = Vec3::one() * 1.02;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
|
||||
next.leg_l.position = Vec3::new(-s_a.leg.0, s_a.leg.1, s_a.leg.2 + torso * 0.2) * 1.02;
|
||||
next.leg_l.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(-0.4);
|
||||
@ -92,11 +86,9 @@ impl Animation for JumpAnimation {
|
||||
|
||||
next.foot_l.position = Vec3::new(-s_a.foot.0, -5.0 + s_a.foot.1, s_a.foot.2);
|
||||
next.foot_l.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(-0.4);
|
||||
next.foot_l.scale = Vec3::one();
|
||||
|
||||
next.foot_r.position = Vec3::new(s_a.foot.0, 5.0 + s_a.foot.1, s_a.foot.2);
|
||||
next.foot_r.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.4);
|
||||
next.foot_r.scale = Vec3::one();
|
||||
|
||||
next.torso.position = Vec3::new(0.0, 0.0, 0.0) / 8.0;
|
||||
next.torso.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.0);
|
||||
|
@ -45,10 +45,10 @@ impl Animation for LeapAnimation {
|
||||
if let Some(ToolKind::Hammer(_)) = active_tool_kind {
|
||||
next.hand_l.position = Vec3::new(-12.0, 0.0, 0.0);
|
||||
next.hand_l.orientation = Quaternion::rotation_x(PI) * Quaternion::rotation_y(0.0);
|
||||
next.hand_l.scale = Vec3::one() * 1.08;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(2.0, 0.0, 0.0);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(PI) * Quaternion::rotation_y(0.0);
|
||||
next.hand_r.scale = Vec3::one() * 1.06;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(0.0, 0.0, 12.0);
|
||||
next.main.orientation = Quaternion::rotation_y(-1.57) * Quaternion::rotation_z(1.57);
|
||||
|
||||
@ -91,12 +91,12 @@ impl Animation for LeapAnimation {
|
||||
next.hand_l.orientation = Quaternion::rotation_x(PI / 2.0)
|
||||
* Quaternion::rotation_z(0.0)
|
||||
* Quaternion::rotation_y(0.0);
|
||||
next.hand_l.scale = Vec3::one() * 1.08;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(0.5, 0.0, -2.5);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(PI / 2.0)
|
||||
* Quaternion::rotation_z(0.0)
|
||||
* Quaternion::rotation_y(0.0);
|
||||
next.hand_r.scale = Vec3::one() * 1.06;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(-0.0, -2.0, -1.0);
|
||||
next.main.orientation = Quaternion::rotation_x(0.0);
|
||||
|
||||
@ -104,7 +104,6 @@ impl Animation for LeapAnimation {
|
||||
next.control.orientation = Quaternion::rotation_x(1.8)
|
||||
* Quaternion::rotation_y(-0.5)
|
||||
* Quaternion::rotation_z(PI - 0.2);
|
||||
next.control.scale = Vec3::one();
|
||||
|
||||
next.head.position = Vec3::new(0.0, s_a.head.0, s_a.head.1);
|
||||
|
||||
|
@ -145,7 +145,6 @@ impl Animation for RunAnimation {
|
||||
next.tail.orientation =
|
||||
Quaternion::rotation_x(canceler * 1.0 + amplitude * shortalt * 0.1)
|
||||
* Quaternion::rotation_z(tilt * 1.5);
|
||||
next.tail.scale = Vec3::one();
|
||||
|
||||
next.upper_torso.position = Vec3::new(
|
||||
0.0,
|
||||
@ -184,10 +183,10 @@ impl Animation for RunAnimation {
|
||||
* Quaternion::rotation_y(tilt * 1.5);
|
||||
|
||||
next.shoulder_l.position = Vec3::new(-s_a.shoulder.0, s_a.shoulder.1, s_a.shoulder.2);
|
||||
next.shoulder_l.scale = Vec3::one() * 1.02;
|
||||
next.shoulder_l.scale = Vec3::one() * 1.1;
|
||||
|
||||
next.shoulder_r.position = Vec3::new(s_a.shoulder.0, s_a.shoulder.1, s_a.shoulder.2);
|
||||
next.shoulder_r.scale = Vec3::one() * 1.02;
|
||||
next.shoulder_r.scale = Vec3::one() * 1.1;
|
||||
|
||||
next.hand_l.position = Vec3::new(
|
||||
-s_a.hand.0,
|
||||
@ -282,7 +281,6 @@ impl Animation for RunAnimation {
|
||||
|
||||
next.tail.position = Vec3::new(0.0, s_a.tail.0, s_a.tail.1);
|
||||
next.tail.orientation = Quaternion::rotation_x(shortalt * 0.3);
|
||||
next.tail.scale = Vec3::one();
|
||||
|
||||
next.second.position = Vec3::new(0.0, 0.0, 0.0);
|
||||
next.second.orientation = Quaternion::rotation_x(PI)
|
||||
@ -323,7 +321,7 @@ impl Animation for RunAnimation {
|
||||
);
|
||||
next.hand_l.orientation = Quaternion::rotation_x(0.15 + (handhoril * -1.2).max(-0.3))
|
||||
* Quaternion::rotation_y(handhoril * -0.1);
|
||||
next.hand_l.scale = Vec3::one() * 1.02;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
|
||||
next.hand_r.position = Vec3::new(
|
||||
1.0 + s_a.hand.0,
|
||||
@ -332,7 +330,7 @@ impl Animation for RunAnimation {
|
||||
);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(0.15 + (handhorir * -1.2).max(-0.3))
|
||||
* Quaternion::rotation_y(handhorir * 0.1);
|
||||
next.hand_r.scale = Vec3::one() * 1.02;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
|
||||
next.leg_l.position = Vec3::new(-s_a.leg.0, s_a.leg.1, s_a.leg.2) * 0.98;
|
||||
next.leg_l.orientation =
|
||||
@ -352,7 +350,6 @@ impl Animation for RunAnimation {
|
||||
);
|
||||
next.foot_l.orientation =
|
||||
Quaternion::rotation_x(-0.5 + footrotl * 0.85) * Quaternion::rotation_y(0.0);
|
||||
next.foot_l.scale = Vec3::one();
|
||||
|
||||
next.foot_r.position = Vec3::new(
|
||||
s_a.foot.0,
|
||||
@ -361,7 +358,6 @@ impl Animation for RunAnimation {
|
||||
);
|
||||
next.foot_r.orientation =
|
||||
Quaternion::rotation_x(-0.5 + footrotr * 0.85) * Quaternion::rotation_y(0.0);
|
||||
next.foot_r.scale = Vec3::one();
|
||||
|
||||
next.torso.position = Vec3::new(0.0, 0.0, 0.0) / 8.0;
|
||||
next.torso.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(-0.25);
|
||||
|
@ -48,10 +48,10 @@ impl Animation for ShockwaveAnimation {
|
||||
|
||||
next.hand_l.position = Vec3::new(0.0, 0.0, -4.0);
|
||||
next.hand_l.orientation = Quaternion::rotation_x(1.27) * Quaternion::rotation_y(0.0);
|
||||
next.hand_l.scale = Vec3::one() * 1.05;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(0.0, 0.0, 2.0);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(1.57) * Quaternion::rotation_y(0.2);
|
||||
next.hand_r.scale = Vec3::one() * 1.05;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(0.0, 8.0, 13.2);
|
||||
next.main.orientation = Quaternion::rotation_y(PI);
|
||||
|
||||
@ -59,7 +59,6 @@ impl Animation for ShockwaveAnimation {
|
||||
next.control.orientation = Quaternion::rotation_x(-0.3)
|
||||
* Quaternion::rotation_y(0.15)
|
||||
* Quaternion::rotation_z(0.0);
|
||||
next.control.scale = Vec3::one();
|
||||
let twist = movement * 0.8;
|
||||
|
||||
next.control.position = Vec3::new(
|
||||
|
@ -104,7 +104,6 @@ impl Animation for ShootAnimation {
|
||||
Vec3::new(0.0, s_a.upper_torso.0, s_a.upper_torso.1 + breathe * 0.5);
|
||||
next.upper_torso.orientation =
|
||||
Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.0);
|
||||
next.upper_torso.scale = Vec3::one();
|
||||
|
||||
next.lower_torso.position =
|
||||
Vec3::new(0.0, s_a.lower_torso.0, s_a.lower_torso.1 + breathe * 0.15);
|
||||
@ -114,20 +113,17 @@ impl Animation for ShootAnimation {
|
||||
|
||||
next.jaw.position = Vec3::new(0.0, s_a.jaw.0 - slower * 0.12, s_a.jaw.1 + slow * 0.2);
|
||||
next.jaw.orientation = Quaternion::rotation_x(slow * 0.05);
|
||||
next.jaw.scale = Vec3::one() * 0.98;
|
||||
next.jaw.scale = Vec3::one() * 1.02;
|
||||
|
||||
next.tail.position = Vec3::new(0.0, s_a.tail.0, s_a.tail.1);
|
||||
next.tail.orientation =
|
||||
Quaternion::rotation_z(0.0 + slow * 0.2 + tailmove.x) * Quaternion::rotation_x(0.0);
|
||||
next.tail.scale = Vec3::one();
|
||||
|
||||
next.shoulder_l.position = Vec3::new(-s_a.shoulder.0, s_a.shoulder.1, s_a.shoulder.2);
|
||||
next.shoulder_l.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.0);
|
||||
next.shoulder_l.scale = Vec3::one();
|
||||
|
||||
next.shoulder_r.position = Vec3::new(s_a.shoulder.0, s_a.shoulder.1, s_a.shoulder.2);
|
||||
next.shoulder_r.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.0);
|
||||
next.shoulder_r.scale = Vec3::one();
|
||||
|
||||
next.leg_l.position =
|
||||
Vec3::new(-s_a.leg.0, s_a.leg.1, s_a.leg.2 + breathe * 0.2) * 1.02;
|
||||
@ -140,11 +136,9 @@ impl Animation for ShootAnimation {
|
||||
|
||||
next.foot_l.position = Vec3::new(-s_a.foot.0, s_a.foot.1, s_a.foot.2);
|
||||
next.foot_l.orientation = Quaternion::rotation_z(0.0);
|
||||
next.foot_l.scale = Vec3::one();
|
||||
|
||||
next.foot_r.position = Vec3::new(s_a.foot.0, s_a.foot.1, s_a.foot.2);
|
||||
next.foot_r.orientation = Quaternion::rotation_z(0.0);
|
||||
next.foot_r.scale = Vec3::one();
|
||||
|
||||
next.torso.position = Vec3::new(0.0, 0.0, 0.0) / 8.0;
|
||||
next.torso.orientation = Quaternion::rotation_z(test * 0.0);
|
||||
@ -154,7 +148,6 @@ impl Animation for ShootAnimation {
|
||||
next.control.orientation = Quaternion::rotation_x(test * 0.02)
|
||||
* Quaternion::rotation_y(test * 0.02)
|
||||
* Quaternion::rotation_z(test * 0.02);
|
||||
next.control.scale = Vec3::one();
|
||||
} else {
|
||||
next.head.position = Vec3::new(0.0, s_a.head.0, s_a.head.1) * 1.02;
|
||||
next.head.orientation =
|
||||
@ -164,7 +157,6 @@ impl Animation for ShootAnimation {
|
||||
next.upper_torso.position =
|
||||
Vec3::new(0.0, s_a.upper_torso.0, s_a.upper_torso.1 + shortalt * -1.5);
|
||||
next.upper_torso.orientation = Quaternion::rotation_z(short * 0.18);
|
||||
next.upper_torso.scale = Vec3::one();
|
||||
|
||||
next.lower_torso.position = Vec3::new(0.0, s_a.lower_torso.0, s_a.lower_torso.1);
|
||||
next.lower_torso.orientation =
|
||||
@ -178,7 +170,6 @@ impl Animation for ShootAnimation {
|
||||
next.tail.position = Vec3::new(0.0, s_a.tail.0, s_a.tail.1);
|
||||
next.tail.orientation =
|
||||
Quaternion::rotation_z(0.0 + slow * 0.2 + tailmove.x) * Quaternion::rotation_x(0.0);
|
||||
next.tail.scale = Vec3::one();
|
||||
|
||||
next.shoulder_l.position = Vec3::new(
|
||||
-s_a.shoulder.0,
|
||||
@ -188,7 +179,6 @@ impl Animation for ShootAnimation {
|
||||
next.shoulder_l.orientation = Quaternion::rotation_x(0.5 + footrotl * -0.16)
|
||||
* Quaternion::rotation_y(0.1)
|
||||
* Quaternion::rotation_z(footrotl * 0.1);
|
||||
next.shoulder_l.scale = Vec3::one();
|
||||
|
||||
next.shoulder_r.position = Vec3::new(
|
||||
s_a.shoulder.0,
|
||||
@ -198,7 +188,6 @@ impl Animation for ShootAnimation {
|
||||
next.shoulder_r.orientation = Quaternion::rotation_x(0.5 + footrotr * -0.16)
|
||||
* Quaternion::rotation_y(-0.1)
|
||||
* Quaternion::rotation_z(footrotr * -0.1);
|
||||
next.shoulder_r.scale = Vec3::one();
|
||||
|
||||
next.torso.position = Vec3::new(0.0, 0.0, 0.0) / 8.0;
|
||||
next.torso.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(-0.25);
|
||||
@ -222,7 +211,6 @@ impl Animation for ShootAnimation {
|
||||
);
|
||||
next.foot_l.orientation =
|
||||
Quaternion::rotation_x(-0.5 + footrotl * 0.85) * Quaternion::rotation_y(0.0);
|
||||
next.foot_l.scale = Vec3::one();
|
||||
|
||||
next.foot_r.position = Vec3::new(
|
||||
s_a.foot.0,
|
||||
@ -231,7 +219,6 @@ impl Animation for ShootAnimation {
|
||||
);
|
||||
next.foot_r.orientation =
|
||||
Quaternion::rotation_x(-0.5 + footrotr * 0.85) * Quaternion::rotation_y(0.0);
|
||||
next.foot_r.scale = Vec3::one();
|
||||
}
|
||||
match active_tool_kind {
|
||||
Some(ToolKind::Bow(_)) => {
|
||||
@ -240,13 +227,13 @@ impl Animation for ShootAnimation {
|
||||
next.hand_l.orientation = Quaternion::rotation_x(1.20)
|
||||
* Quaternion::rotation_y(-0.6 + exp * 0.8)
|
||||
* Quaternion::rotation_z(-0.3 + exp * 0.9);
|
||||
next.hand_l.scale = Vec3::one() * 1.02;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
|
||||
next.hand_r.position = Vec3::new(4.9, 3.0, -4.0);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(1.20)
|
||||
* Quaternion::rotation_y(-0.6)
|
||||
* Quaternion::rotation_z(-0.3);
|
||||
next.hand_r.scale = Vec3::one() * 1.02;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
|
||||
next.shoulder_l.position = Vec3::new(
|
||||
-s_a.shoulder.0,
|
||||
@ -256,7 +243,6 @@ impl Animation for ShootAnimation {
|
||||
next.shoulder_l.orientation = Quaternion::rotation_x(1.4 + footrotl * -0.06)
|
||||
* Quaternion::rotation_y(-0.9)
|
||||
* Quaternion::rotation_z(footrotl * -0.05);
|
||||
next.shoulder_l.scale = Vec3::one();
|
||||
|
||||
next.shoulder_r.position = Vec3::new(
|
||||
s_a.shoulder.0,
|
||||
@ -266,7 +252,6 @@ impl Animation for ShootAnimation {
|
||||
next.shoulder_r.orientation = Quaternion::rotation_x(1.8 + footrotr * -0.06)
|
||||
* Quaternion::rotation_y(-0.5) //1.9
|
||||
* Quaternion::rotation_z(footrotr * -0.05);
|
||||
next.shoulder_r.scale = Vec3::one();
|
||||
|
||||
next.jaw.position = Vec3::new(0.0, s_a.jaw.0, s_a.jaw.1);
|
||||
next.jaw.orientation = Quaternion::rotation_x(-0.2);
|
||||
@ -280,18 +265,17 @@ impl Animation for ShootAnimation {
|
||||
next.control.orientation = Quaternion::rotation_x(exp * 0.4)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
* Quaternion::rotation_z(0.0);
|
||||
next.control.scale = Vec3::one();
|
||||
},
|
||||
Some(ToolKind::Staff(_)) => {
|
||||
next.hand_l.position = Vec3::new(11.0, 5.0, -4.0);
|
||||
next.hand_l.orientation =
|
||||
Quaternion::rotation_x(1.27) * Quaternion::rotation_y(0.0);
|
||||
next.hand_l.scale = Vec3::one() * 1.02;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
|
||||
next.hand_r.position = Vec3::new(12.0, 5.5, 2.0);
|
||||
next.hand_r.orientation =
|
||||
Quaternion::rotation_x(1.57) * Quaternion::rotation_y(0.2);
|
||||
next.hand_r.scale = Vec3::one() * 1.02;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
|
||||
next.jaw.position = Vec3::new(0.0, s_a.jaw.0, s_a.jaw.1);
|
||||
|
||||
@ -299,13 +283,11 @@ impl Animation for ShootAnimation {
|
||||
Vec3::new(-s_a.shoulder.0, s_a.shoulder.1, s_a.shoulder.2);
|
||||
next.shoulder_l.orientation =
|
||||
Quaternion::rotation_z(0.0) * Quaternion::rotation_x(2.0);
|
||||
next.shoulder_l.scale = Vec3::one();
|
||||
|
||||
next.shoulder_r.position =
|
||||
Vec3::new(s_a.shoulder.0, s_a.shoulder.1, s_a.shoulder.2);
|
||||
next.shoulder_r.orientation =
|
||||
Quaternion::rotation_z(0.4) * Quaternion::rotation_x(2.0);
|
||||
next.shoulder_r.scale = Vec3::one();
|
||||
|
||||
next.jaw.orientation = Quaternion::rotation_x(-0.2);
|
||||
|
||||
@ -318,7 +300,6 @@ impl Animation for ShootAnimation {
|
||||
next.control.orientation = Quaternion::rotation_x(exp * 1.3)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
* Quaternion::rotation_z(exp * 1.5);
|
||||
next.control.scale = Vec3::one();
|
||||
},
|
||||
_ => {},
|
||||
}
|
||||
|
@ -62,10 +62,10 @@ impl Animation for SpinAnimation {
|
||||
if let Some(ToolKind::Sword(_)) = active_tool_kind {
|
||||
next.hand_l.position = Vec3::new(-4.75, -1.0, 2.5);
|
||||
next.hand_l.orientation = Quaternion::rotation_x(1.47) * Quaternion::rotation_y(-0.2);
|
||||
next.hand_l.scale = Vec3::one() * 1.02;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(0.75, -1.5, -0.5);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(1.47) * Quaternion::rotation_y(0.3);
|
||||
next.hand_r.scale = Vec3::one() * 1.02;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(0.0, 5.0, -6.0);
|
||||
next.main.orientation = Quaternion::rotation_x(-0.1)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
@ -113,18 +113,16 @@ impl Animation for SpinAnimation {
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(0.75, -1.5, -5.5);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(1.27);
|
||||
next.hand_r.scale = Vec3::one() * 1.05;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(0.0, 6.0, -1.0);
|
||||
next.main.orientation = Quaternion::rotation_x(-0.3)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
* Quaternion::rotation_z(0.0);
|
||||
next.main.scale = Vec3::one();
|
||||
|
||||
next.control.position = Vec3::new(-4.5 + spinhalf * 4.0, 11.0, 8.0);
|
||||
next.control.orientation = Quaternion::rotation_x(-1.7)
|
||||
* Quaternion::rotation_y(0.2 + spin * -2.0)
|
||||
* Quaternion::rotation_z(1.4 + spin * 0.1);
|
||||
next.control.scale = Vec3::one();
|
||||
next.head.position = Vec3::new(0.0, s_a.head.0 + spin * -0.8, s_a.head.1);
|
||||
next.head.orientation = Quaternion::rotation_z(spin * -0.25)
|
||||
* Quaternion::rotation_x(0.0 + spin * -0.1)
|
||||
@ -133,10 +131,8 @@ impl Animation for SpinAnimation {
|
||||
next.upper_torso.orientation = Quaternion::rotation_z(spin * 0.1)
|
||||
* Quaternion::rotation_x(0.0 + spin * 0.1)
|
||||
* Quaternion::rotation_y(decel * -0.2);
|
||||
next.upper_torso.scale = Vec3::one();
|
||||
|
||||
next.lower_torso.position = Vec3::new(0.0, 0.0, -5.0);
|
||||
next.lower_torso.scale = Vec3::one();
|
||||
next.torso.position = Vec3::new(0.0, 0.0, 0.1) * 1.01;
|
||||
next.torso.orientation = Quaternion::rotation_z((spin * 7.0).max(0.3))
|
||||
* Quaternion::rotation_x(0.0)
|
||||
@ -145,11 +141,9 @@ impl Animation for SpinAnimation {
|
||||
|
||||
next.foot_l.position = Vec3::new(-s_a.foot.0, foot * 1.0, s_a.foot.2);
|
||||
next.foot_l.orientation = Quaternion::rotation_x(foot * -1.2);
|
||||
next.foot_l.scale = Vec3::one();
|
||||
|
||||
next.foot_r.position = Vec3::new(s_a.foot.0, foot * -1.0, s_a.foot.2);
|
||||
next.foot_r.orientation = Quaternion::rotation_x(foot * 1.2);
|
||||
next.foot_r.scale = Vec3::one();
|
||||
|
||||
next.shoulder_l.position = Vec3::new(-5.0, 0.0, 4.7);
|
||||
next.shoulder_l.orientation = Quaternion::rotation_x(0.0);
|
||||
|
@ -124,7 +124,6 @@ impl Animation for SpinMeleeAnimation {
|
||||
|
||||
next.foot_r.position = Vec3::new(s_a.foot.0, 8.0, s_a.foot.2 + 2.0);
|
||||
next.foot_r.orientation = Quaternion::rotation_x(1.0);
|
||||
next.foot_r.scale = Vec3::one();
|
||||
} else if speed < 0.5 {
|
||||
next.foot_l.position = Vec3::new(-s_a.foot.0, 2.0 + quick * -6.0, s_a.foot.2);
|
||||
next.foot_l.orientation = Quaternion::rotation_x(0.5 + slowersmooth * 0.2);
|
||||
|
@ -109,7 +109,7 @@ impl Animation for WieldAnimation {
|
||||
next.hand_r.orientation = Quaternion::rotation_x(0.57) * Quaternion::rotation_z(1.57);
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.jaw.scale = Vec3::one() * 0.98;
|
||||
next.jaw.scale = Vec3::one() * 1.02;
|
||||
next.torso.scale = Vec3::one() / 8.0;
|
||||
next.leg_l.scale = Vec3::one() * 0.98;
|
||||
next.leg_r.scale = Vec3::one() * 0.98;
|
||||
@ -232,6 +232,7 @@ impl Animation for WieldAnimation {
|
||||
next.hold.orientation = Quaternion::rotation_x(-1.7)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
* Quaternion::rotation_z(-0.1);
|
||||
next.hold.scale = Vec3::one() * 1.0;
|
||||
|
||||
next.control.position = Vec3::new(-7.0, 3.0, -8.0);
|
||||
next.control.orientation = Quaternion::rotation_x(u_slow * 0.2)
|
||||
@ -305,7 +306,6 @@ impl Animation for WieldAnimation {
|
||||
|
||||
next.lower_torso.position =
|
||||
Vec3::new(0.0, s_a.lower_torso.0, s_a.lower_torso.1 + torso * 0.15);
|
||||
next.lower_torso.scale = Vec3::one();
|
||||
|
||||
next.jaw.orientation = Quaternion::rotation_x(-0.1);
|
||||
|
||||
@ -346,7 +346,6 @@ impl Animation for WieldAnimation {
|
||||
next.upper_torso.position =
|
||||
Vec3::new(0.0, s_a.upper_torso.0, s_a.upper_torso.1 + shortalt * -1.5);
|
||||
next.upper_torso.orientation = Quaternion::rotation_z(short * 0.18);
|
||||
next.upper_torso.scale = Vec3::one();
|
||||
|
||||
next.lower_torso.position =
|
||||
Vec3::new(0.0, s_a.lower_torso.0, s_a.lower_torso.1);
|
||||
@ -360,7 +359,6 @@ impl Animation for WieldAnimation {
|
||||
|
||||
next.tail.position = Vec3::new(0.0, s_a.tail.0, s_a.tail.1);
|
||||
next.tail.orientation = Quaternion::rotation_x(shortalt * 0.3);
|
||||
next.tail.scale = Vec3::one();
|
||||
|
||||
next.second.position = Vec3::new(0.0, 0.0, 0.0);
|
||||
next.second.orientation = Quaternion::rotation_x(PI)
|
||||
@ -370,7 +368,6 @@ impl Animation for WieldAnimation {
|
||||
|
||||
next.control.position = Vec3::new(0.0, 0.0, 0.0);
|
||||
next.control.orientation = Quaternion::rotation_z(0.0);
|
||||
next.control.scale = Vec3::one();
|
||||
|
||||
next.main.position = Vec3::new(-5.0, -7.0, 7.0);
|
||||
next.main.orientation = Quaternion::rotation_x(PI)
|
||||
@ -413,7 +410,7 @@ impl Animation for WieldAnimation {
|
||||
next.hand_r.orientation =
|
||||
Quaternion::rotation_x(0.15 + (handhorir * -1.2).max(-0.3))
|
||||
* Quaternion::rotation_y(handhorir * 0.1);
|
||||
next.hand_r.scale = Vec3::one() * 1.02;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
|
||||
next.leg_l.position = Vec3::new(-s_a.leg.0, s_a.leg.1, s_a.leg.2) * 0.98;
|
||||
next.leg_l.orientation = Quaternion::rotation_z(short * 0.18)
|
||||
|
@ -39,7 +39,6 @@ impl Animation for FlyAnimation {
|
||||
next.head.position = Vec3::new(0.0, s_a.head.0 + 0.5, s_a.head.1 + center * 0.5 - 1.0);
|
||||
next.head.orientation =
|
||||
Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.0 + center * 0.03);
|
||||
next.head.scale = Vec3::one();
|
||||
|
||||
next.torso.position = Vec3::new(
|
||||
0.0,
|
||||
|
@ -133,30 +133,26 @@ impl Animation for AlphaAnimation {
|
||||
next.control_l.orientation = Quaternion::rotation_x(-1.4 + slow * 0.4)
|
||||
* Quaternion::rotation_y(slow * -1.3)
|
||||
* Quaternion::rotation_z(1.4 + slow * -0.5);
|
||||
next.control_l.scale = Vec3::one();
|
||||
|
||||
next.hand_r.position = Vec3::new(0.0, 0.0, 0.0);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(0.0);
|
||||
next.hand_r.scale = Vec3::one() * 1.12;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
|
||||
next.second.position = Vec3::new(0.0, 0.0, 0.0);
|
||||
next.second.orientation = Quaternion::rotation_x(0.0);
|
||||
|
||||
next.control_r.position = Vec3::new(8.0, 0.0, 0.0);
|
||||
next.control_r.orientation = Quaternion::rotation_x(0.0);
|
||||
next.control_r.scale = Vec3::one();
|
||||
|
||||
next.foot_l.position =
|
||||
Vec3::new(-s_a.foot.0, slow * -3.0 + quick * 3.0 - 4.0, s_a.foot.2);
|
||||
next.foot_l.orientation = Quaternion::rotation_x(slow * 0.6)
|
||||
* Quaternion::rotation_y((slow * -0.2).max(0.0));
|
||||
next.foot_l.scale = Vec3::one();
|
||||
|
||||
next.foot_r.position =
|
||||
Vec3::new(s_a.foot.0, slow * 3.0 + quick * -3.0 + 5.0, s_a.foot.2);
|
||||
next.foot_r.orientation = Quaternion::rotation_x(slow * -0.6)
|
||||
* Quaternion::rotation_y((slow * 0.2).min(0.0));
|
||||
next.foot_r.scale = Vec3::one();
|
||||
|
||||
next.lantern.orientation =
|
||||
Quaternion::rotation_x(slow * -0.7 + 0.4) * Quaternion::rotation_y(slow * 0.4);
|
||||
@ -176,7 +172,6 @@ impl Animation for AlphaAnimation {
|
||||
|
||||
next.chest.position = Vec3::new(0.0, 0.0, 7.0);
|
||||
next.chest.orientation = Quaternion::rotation_z(0.2 + axe * 0.2);
|
||||
next.chest.scale = Vec3::one();
|
||||
|
||||
next.belt.position = Vec3::new(0.0, 0.0, -2.0);
|
||||
next.belt.orientation = Quaternion::rotation_z(0.2 + axe * -0.1);
|
||||
@ -188,12 +183,12 @@ impl Animation for AlphaAnimation {
|
||||
next.hand_l.orientation = Quaternion::rotation_x(PI / 2.0)
|
||||
* Quaternion::rotation_z(0.0)
|
||||
* Quaternion::rotation_y(0.0);
|
||||
next.hand_l.scale = Vec3::one() * 1.08;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(0.5, 0.0, -2.5);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(PI / 2.0)
|
||||
* Quaternion::rotation_z(0.0)
|
||||
* Quaternion::rotation_y(0.0);
|
||||
next.hand_r.scale = Vec3::one() * 1.06;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(-0.0, -2.0, -1.0);
|
||||
next.main.orientation = Quaternion::rotation_x(0.0)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
@ -216,10 +211,10 @@ impl Animation for AlphaAnimation {
|
||||
next.hand_l.position = Vec3::new(-12.0, 0.0, 0.0);
|
||||
next.hand_l.orientation =
|
||||
Quaternion::rotation_x(-0.0) * Quaternion::rotation_y(0.0);
|
||||
next.hand_l.scale = Vec3::one() * 1.08;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(3.0, 0.0, 0.0);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(0.0) * Quaternion::rotation_y(0.0);
|
||||
next.hand_r.scale = Vec3::one() * 1.06;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(0.0, 0.0, 0.0);
|
||||
next.main.orientation = Quaternion::rotation_x(0.0)
|
||||
* Quaternion::rotation_y(-1.57)
|
||||
@ -261,12 +256,10 @@ impl Animation for AlphaAnimation {
|
||||
next.foot_l.position = Vec3::new(-s_a.foot.0, foot * -6.0, s_a.foot.2);
|
||||
next.foot_l.orientation = Quaternion::rotation_x(foot * -0.4)
|
||||
* Quaternion::rotation_z((slower * 0.3).max(0.0));
|
||||
next.foot_l.scale = Vec3::one();
|
||||
|
||||
next.foot_r.position = Vec3::new(s_a.foot.0, foot * 6.0, s_a.foot.2);
|
||||
next.foot_r.orientation = Quaternion::rotation_x(foot * 0.4)
|
||||
* Quaternion::rotation_z((slower * 0.3).max(0.0));
|
||||
next.foot_r.scale = Vec3::one();
|
||||
next.torso.position = Vec3::new(0.0, 0.0, 0.1) * s_a.scaler;
|
||||
next.torso.orientation =
|
||||
Quaternion::rotation_z(0.0) * Quaternion::rotation_x(-0.15);
|
||||
@ -276,23 +269,19 @@ impl Animation for AlphaAnimation {
|
||||
Vec3::new(-s_a.foot.0, -2.5, s_a.foot.2 + (slower * 2.5).max(0.0));
|
||||
next.foot_l.orientation = Quaternion::rotation_x(slower * -0.2 - 0.2)
|
||||
* Quaternion::rotation_z((slower * 1.0).max(0.0));
|
||||
next.foot_l.scale = Vec3::one();
|
||||
|
||||
next.foot_r.position = Vec3::new(s_a.foot.0, 3.5 - slower * 2.0, s_a.foot.2);
|
||||
next.foot_r.orientation = Quaternion::rotation_x(slower * 0.1)
|
||||
* Quaternion::rotation_z((slower * 0.5).max(0.0));
|
||||
next.foot_r.scale = Vec3::one();
|
||||
next.torso.position = Vec3::new(0.0, 0.0, 0.1) * s_a.scaler;
|
||||
next.torso.orientation = Quaternion::rotation_z(0.0);
|
||||
next.torso.scale = Vec3::one() / 11.0 * s_a.scaler;
|
||||
}
|
||||
|
||||
next.control.scale = Vec3::one();
|
||||
next.control.position = Vec3::new(-8.0, 7.0, 1.0);
|
||||
next.control.orientation = Quaternion::rotation_x(-1.5 + slower * 1.5)
|
||||
* Quaternion::rotation_y(slowersmooth * 0.35 - 0.3)
|
||||
* Quaternion::rotation_z(1.4 + slowersmooth * 0.2);
|
||||
next.control.scale = Vec3::one();
|
||||
|
||||
next.torso.position = Vec3::new(0.0, 0.0, 0.1) * s_a.scaler;
|
||||
next.torso.orientation = Quaternion::rotation_z(0.0);
|
||||
@ -304,11 +293,11 @@ impl Animation for AlphaAnimation {
|
||||
next.hand_l.position = Vec3::new(11.0, 5.0, -4.0);
|
||||
next.hand_l.orientation =
|
||||
Quaternion::rotation_x(1.27) * Quaternion::rotation_y(0.0);
|
||||
next.hand_l.scale = Vec3::one() * 1.05;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(12.0, 5.5, 2.0);
|
||||
next.hand_r.orientation =
|
||||
Quaternion::rotation_x(1.57) * Quaternion::rotation_y(0.2);
|
||||
next.hand_r.scale = Vec3::one() * 1.05;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(12.0, 8.5, 13.2);
|
||||
next.main.orientation = Quaternion::rotation_x(0.0)
|
||||
* Quaternion::rotation_y(3.14)
|
||||
@ -321,19 +310,17 @@ impl Animation for AlphaAnimation {
|
||||
next.control.orientation = Quaternion::rotation_x(staff * 1.2)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
* Quaternion::rotation_z(0.0);
|
||||
next.control.scale = Vec3::one();
|
||||
},
|
||||
Some(ToolKind::Debug(_)) => {
|
||||
next.hand_l.position = Vec3::new(-7.0, 4.0, 3.0);
|
||||
next.hand_l.orientation = Quaternion::rotation_x(1.27)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
* Quaternion::rotation_z(0.0);
|
||||
next.hand_l.scale = Vec3::one() * 1.01;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(-5.0, 5.0, 23.0);
|
||||
next.main.orientation = Quaternion::rotation_z(0.0)
|
||||
* Quaternion::rotation_x(PI)
|
||||
* Quaternion::rotation_y(0.0);
|
||||
next.main.scale = Vec3::one();
|
||||
next.torso.position = Vec3::new(0.0, 0.0, 0.1) * s_a.scaler;
|
||||
next.torso.orientation = Quaternion::rotation_x(0.0);
|
||||
next.torso.scale = Vec3::one() / 11.0 * s_a.scaler;
|
||||
@ -346,8 +333,6 @@ impl Animation for AlphaAnimation {
|
||||
next.shoulder_r.scale = Vec3::one() * 1.1;
|
||||
next.glider.position = Vec3::new(0.0, 0.0, 10.0);
|
||||
next.glider.scale = Vec3::one() * 0.0;
|
||||
next.control_l.scale = Vec3::one();
|
||||
next.control_r.scale = Vec3::one();
|
||||
|
||||
next.second.scale = match (
|
||||
active_tool_kind.map(|tk| tk.hands()),
|
||||
|
@ -65,11 +65,9 @@ impl Animation for DanceAnimation {
|
||||
next.chest.orientation = Quaternion::rotation_z(short * 0.35)
|
||||
* Quaternion::rotation_y(shorte * 0.08)
|
||||
* Quaternion::rotation_x(foot * 0.07);
|
||||
next.chest.scale = Vec3::one();
|
||||
|
||||
next.belt.position = Vec3::new(0.0, s_a.belt.0, s_a.belt.1);
|
||||
next.belt.orientation = Quaternion::rotation_z(shorte * 0.25);
|
||||
next.belt.scale = Vec3::one();
|
||||
|
||||
next.back.position = Vec3::new(0.0, s_a.back.0, s_a.back.1);
|
||||
next.back.orientation =
|
||||
@ -78,7 +76,6 @@ impl Animation for DanceAnimation {
|
||||
|
||||
next.shorts.position = Vec3::new(0.0, s_a.shorts.0, s_a.shorts.1);
|
||||
next.shorts.orientation = Quaternion::rotation_z(foot * 0.35);
|
||||
next.shorts.scale = Vec3::one();
|
||||
|
||||
next.hand_l.position = Vec3::new(
|
||||
1.0 - s_a.hand.0,
|
||||
@ -87,7 +84,6 @@ impl Animation for DanceAnimation {
|
||||
);
|
||||
next.hand_l.orientation =
|
||||
Quaternion::rotation_x(1.4 + foot * 0.15) * Quaternion::rotation_y(0.2);
|
||||
next.hand_l.scale = Vec3::one();
|
||||
|
||||
next.hand_r.position = Vec3::new(
|
||||
-1.0 + s_a.hand.0,
|
||||
@ -96,7 +92,6 @@ impl Animation for DanceAnimation {
|
||||
);
|
||||
next.hand_r.orientation =
|
||||
Quaternion::rotation_x(1.4 + foot * -0.15) * Quaternion::rotation_y(-0.2);
|
||||
next.hand_r.scale = Vec3::one();
|
||||
|
||||
next.foot_l.position = Vec3::new(
|
||||
-s_a.foot.0 + foot * 0.8,
|
||||
@ -105,7 +100,6 @@ impl Animation for DanceAnimation {
|
||||
);
|
||||
next.foot_l.orientation =
|
||||
Quaternion::rotation_x(foot * -0.3) * Quaternion::rotation_z(short * -0.15);
|
||||
next.foot_l.scale = Vec3::one();
|
||||
|
||||
next.foot_r.position = Vec3::new(
|
||||
s_a.foot.0 + foot * 0.8,
|
||||
@ -114,7 +108,6 @@ impl Animation for DanceAnimation {
|
||||
);
|
||||
next.foot_r.orientation =
|
||||
Quaternion::rotation_x(foot * 0.3) * Quaternion::rotation_z(short * 0.15);
|
||||
next.foot_r.scale = Vec3::one();
|
||||
|
||||
next.shoulder_l.position = Vec3::new(-s_a.shoulder.0, s_a.shoulder.1, s_a.shoulder.2);
|
||||
next.shoulder_l.orientation = Quaternion::rotation_x(shorte * 0.15);
|
||||
@ -143,7 +136,6 @@ impl Animation for DanceAnimation {
|
||||
next.main.orientation = Quaternion::rotation_y(2.5) * Quaternion::rotation_z(1.57);
|
||||
},
|
||||
}
|
||||
next.main.scale = Vec3::one();
|
||||
|
||||
match second_tool_kind {
|
||||
Some(ToolKind::Dagger(_)) => {
|
||||
@ -162,7 +154,6 @@ impl Animation for DanceAnimation {
|
||||
Quaternion::rotation_y(2.5) * Quaternion::rotation_z(1.57);
|
||||
},
|
||||
}
|
||||
next.second.scale = Vec3::one();
|
||||
|
||||
next.lantern.position = Vec3::new(s_a.lantern.0, s_a.lantern.1, s_a.lantern.2);
|
||||
next.lantern.orientation =
|
||||
@ -176,11 +167,8 @@ impl Animation for DanceAnimation {
|
||||
|
||||
next.control.position = Vec3::new(0.0, 0.0, 0.0);
|
||||
next.control.orientation = Quaternion::rotation_x(0.0);
|
||||
next.control.scale = Vec3::one();
|
||||
|
||||
next.control_l.scale = Vec3::one();
|
||||
|
||||
next.control_r.scale = Vec3::one();
|
||||
|
||||
next.second.scale = match (
|
||||
active_tool_kind.map(|tk| tk.hands()),
|
||||
|
@ -69,7 +69,6 @@ impl Animation for EquipAnimation {
|
||||
next.control.position = Vec3::new(0.0, 0.0, 0.0);
|
||||
next.control.orientation =
|
||||
Quaternion::rotation_x(0.2) * Quaternion::rotation_y(-0.3);
|
||||
next.control.scale = Vec3::one();
|
||||
},
|
||||
Some(ToolKind::Hammer(_)) => {
|
||||
next.hand_l.position = Vec3::new(-7.0, 5.5, 3.5);
|
||||
@ -107,23 +106,21 @@ impl Animation for EquipAnimation {
|
||||
next.hand_l.orientation = Quaternion::rotation_x(1.20)
|
||||
* Quaternion::rotation_y(-0.6)
|
||||
* Quaternion::rotation_z(-0.3);
|
||||
next.hand_l.scale = Vec3::one() * 1.05;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(5.9, 4.5, -5.0);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(1.20)
|
||||
* Quaternion::rotation_y(-0.6)
|
||||
* Quaternion::rotation_z(-0.3);
|
||||
next.hand_r.scale = Vec3::one() * 1.05;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(3.0, 2.0, -13.0);
|
||||
next.main.orientation = Quaternion::rotation_x(-0.3)
|
||||
* Quaternion::rotation_y(0.3)
|
||||
* Quaternion::rotation_z(-0.6);
|
||||
next.main.scale = Vec3::one();
|
||||
|
||||
next.control.position = Vec3::new(-7.0, 6.0, 6.0);
|
||||
next.control.orientation = Quaternion::rotation_x(0.0)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
* Quaternion::rotation_z(0.0);
|
||||
next.control.scale = Vec3::one();
|
||||
},
|
||||
_ => {},
|
||||
}
|
||||
|
@ -45,11 +45,9 @@ impl Animation for GlideWieldAnimation {
|
||||
|
||||
next.hand_l.position = Vec3::new(-2.0 - s_a.hand.0, s_a.hand.1, s_a.hand.2 + 15.0);
|
||||
next.hand_l.orientation = Quaternion::rotation_x(3.35);
|
||||
next.hand_l.scale = Vec3::one();
|
||||
|
||||
next.hand_r.position = Vec3::new(2.0 + s_a.hand.0, s_a.hand.1, s_a.hand.2 + 15.0);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(3.35);
|
||||
next.hand_r.scale = Vec3::one();
|
||||
|
||||
if speed > 0.5 {
|
||||
next.glider.orientation = Quaternion::rotation_x(0.8);
|
||||
|
@ -65,10 +65,8 @@ impl Animation for IdleAnimation {
|
||||
next.hand_r.orientation = Quaternion::rotation_x(0.0 + wave_ultra_slow * -0.06);
|
||||
|
||||
next.foot_l.position = Vec3::new(-s_a.foot.0, s_a.foot.1, s_a.foot.2);
|
||||
next.foot_l.scale = Vec3::one();
|
||||
|
||||
next.foot_r.position = Vec3::new(s_a.foot.0, s_a.foot.1, s_a.foot.2);
|
||||
next.foot_r.scale = Vec3::one();
|
||||
|
||||
next.shoulder_l.position = Vec3::new(-s_a.shoulder.0, s_a.shoulder.1, s_a.shoulder.2);
|
||||
next.shoulder_l.orientation = Quaternion::rotation_x(0.0);
|
||||
@ -96,7 +94,6 @@ impl Animation for IdleAnimation {
|
||||
next.main.orientation = Quaternion::rotation_y(2.5) * Quaternion::rotation_z(1.57);
|
||||
},
|
||||
}
|
||||
next.main.scale = Vec3::one();
|
||||
|
||||
match second_tool_kind {
|
||||
Some(ToolKind::Dagger(_)) => {
|
||||
@ -115,7 +112,6 @@ impl Animation for IdleAnimation {
|
||||
Quaternion::rotation_y(2.5) * Quaternion::rotation_z(1.57);
|
||||
},
|
||||
}
|
||||
next.second.scale = Vec3::one();
|
||||
|
||||
next.lantern.position = Vec3::new(s_a.lantern.0, s_a.lantern.1, s_a.lantern.2);
|
||||
next.lantern.orientation = Quaternion::rotation_x(0.1) * Quaternion::rotation_y(0.1);
|
||||
|
@ -81,12 +81,10 @@ impl Animation for JumpAnimation {
|
||||
);
|
||||
next.hand_l.orientation =
|
||||
Quaternion::rotation_x(1.9 + slow * 0.4) * Quaternion::rotation_y(0.2);
|
||||
next.hand_l.scale = Vec3::one();
|
||||
|
||||
next.hand_r.position = Vec3::new(s_a.hand.0, s_a.hand.1 - 3.0, s_a.hand.2 + slow * 1.5);
|
||||
next.hand_r.orientation =
|
||||
Quaternion::rotation_x(-0.5 + slow * -0.4) * Quaternion::rotation_y(-0.2);
|
||||
next.hand_r.scale = Vec3::one();
|
||||
} else {
|
||||
next.hand_l.position =
|
||||
Vec3::new(-s_a.hand.0, s_a.hand.1 - 3.0, s_a.hand.2 + slow * 1.5);
|
||||
@ -143,7 +141,6 @@ impl Animation for JumpAnimation {
|
||||
next.main.orientation = Quaternion::rotation_y(2.5) * Quaternion::rotation_z(1.57);
|
||||
},
|
||||
}
|
||||
next.main.scale = Vec3::one();
|
||||
|
||||
match second_tool_kind {
|
||||
Some(ToolKind::Dagger(_)) => {
|
||||
@ -162,7 +159,6 @@ impl Animation for JumpAnimation {
|
||||
Quaternion::rotation_y(2.5) * Quaternion::rotation_z(1.57);
|
||||
},
|
||||
}
|
||||
next.second.scale = Vec3::one();
|
||||
|
||||
next.lantern.position = Vec3::new(s_a.lantern.0, s_a.lantern.1, s_a.lantern.2);
|
||||
next.lantern.orientation = Quaternion::rotation_x(1.0 * switch + slow * 0.3 * switch)
|
||||
|
@ -45,10 +45,10 @@ impl Animation for LeapAnimation {
|
||||
if let Some(ToolKind::Hammer(_)) = active_tool_kind {
|
||||
next.hand_l.position = Vec3::new(-12.0, 0.0, 0.0);
|
||||
next.hand_l.orientation = Quaternion::rotation_x(PI) * Quaternion::rotation_y(0.0);
|
||||
next.hand_l.scale = Vec3::one() * 1.08;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(2.0, 0.0, 0.0);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(PI) * Quaternion::rotation_y(0.0);
|
||||
next.hand_r.scale = Vec3::one() * 1.06;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(0.0, 0.0, 0.0);
|
||||
next.main.orientation = Quaternion::rotation_y(-1.57) * Quaternion::rotation_z(1.57);
|
||||
|
||||
@ -104,7 +104,6 @@ impl Animation for LeapAnimation {
|
||||
next.control.orientation = Quaternion::rotation_x(1.8)
|
||||
* Quaternion::rotation_y(-0.5)
|
||||
* Quaternion::rotation_z(PI - 0.2);
|
||||
next.control.scale = Vec3::one();
|
||||
|
||||
next.head.position = Vec3::new(0.0, s_a.head.0, s_a.head.1);
|
||||
|
||||
|
@ -33,8 +33,6 @@ impl Animation for RepeaterAnimation {
|
||||
*rate = 1.0;
|
||||
let mut next = (*skeleton).clone();
|
||||
|
||||
let lab = 1.0;
|
||||
|
||||
let (movement1, movement2, movement3, _movement4) = match stage_section {
|
||||
Some(StageSection::Movement) => (anim_time as f32, 0.0, 0.0, 0.0),
|
||||
Some(StageSection::Buildup) => (1.0, anim_time as f32, 0.0, 0.0),
|
||||
|
@ -58,7 +58,6 @@ impl Animation for ShockwaveAnimation {
|
||||
next.control.orientation = Quaternion::rotation_x(-0.3)
|
||||
* Quaternion::rotation_y(0.15)
|
||||
* Quaternion::rotation_z(0.0);
|
||||
next.control.scale = Vec3::one();
|
||||
|
||||
let twist = movement1 * 0.8;
|
||||
|
||||
|
@ -127,10 +127,7 @@ impl Animation for ShootAnimation {
|
||||
next.lantern.orientation =
|
||||
Quaternion::rotation_x(exp * -0.7 + 0.4) * Quaternion::rotation_y(exp * 0.4);
|
||||
|
||||
next.hold.position = Vec3::new(17.5, -25.0, -10.5);
|
||||
next.hold.orientation = Quaternion::rotation_x(-1.6)
|
||||
* Quaternion::rotation_y(-0.1)
|
||||
* Quaternion::rotation_z(0.0);
|
||||
next.hold.scale = Vec3::one() * 0.0;
|
||||
|
||||
next.second.scale = match (
|
||||
active_tool_kind.map(|tk| tk.hands()),
|
||||
|
@ -109,7 +109,6 @@ impl Animation for SitAnimation {
|
||||
next.main.orientation = Quaternion::rotation_y(2.5) * Quaternion::rotation_z(1.57);
|
||||
},
|
||||
}
|
||||
next.main.scale = Vec3::one();
|
||||
|
||||
match second_tool_kind {
|
||||
Some(ToolKind::Dagger(_)) => {
|
||||
|
@ -124,7 +124,6 @@ impl Animation for SneakAnimation {
|
||||
next.shorts.orientation = Quaternion::rotation_z(short * 0.16 + tilt * -1.5)
|
||||
* Quaternion::rotation_y(tilt * 0.7)
|
||||
* Quaternion::rotation_x(0.3);
|
||||
next.shorts.scale = Vec3::one();
|
||||
|
||||
next.foot_l.position = Vec3::new(
|
||||
-s_a.foot.0,
|
||||
|
@ -147,7 +147,6 @@ impl Animation for SpinAnimation {
|
||||
|
||||
next.foot_l.position = Vec3::new(-s_a.foot.0, foot * 1.0, s_a.foot.2);
|
||||
next.foot_l.orientation = Quaternion::rotation_x(foot * -1.2);
|
||||
next.foot_l.scale = Vec3::one();
|
||||
|
||||
next.foot_r.position = Vec3::new(s_a.foot.0, foot * -1.0, s_a.foot.2);
|
||||
next.foot_r.orientation = Quaternion::rotation_x(foot * 1.2);
|
||||
|
@ -114,7 +114,6 @@ impl Animation for StandAnimation {
|
||||
next.main.orientation = Quaternion::rotation_y(2.5) * Quaternion::rotation_z(1.57);
|
||||
},
|
||||
}
|
||||
next.main.scale = Vec3::one();
|
||||
|
||||
match second_tool_kind {
|
||||
Some(ToolKind::Dagger(_)) => {
|
||||
|
@ -114,7 +114,6 @@ impl Animation for SwimAnimation {
|
||||
next.belt.position = Vec3::new(0.0, s_a.belt.0, s_a.belt.1);
|
||||
next.belt.orientation = Quaternion::rotation_x(velocity.z.abs() * -0.005 + abstilt * 1.0)
|
||||
* Quaternion::rotation_z(short * -0.2 * intensity);
|
||||
next.belt.scale = Vec3::one();
|
||||
|
||||
next.back.position = Vec3::new(0.0, s_a.back.0, s_a.back.1);
|
||||
next.back.scale = Vec3::one() * 1.02;
|
||||
@ -122,7 +121,6 @@ impl Animation for SwimAnimation {
|
||||
next.shorts.position = Vec3::new(0.0, s_a.shorts.0, s_a.shorts.1);
|
||||
next.shorts.orientation = Quaternion::rotation_x(velocity.z.abs() * -0.005 + abstilt * 1.0)
|
||||
* Quaternion::rotation_z(short * -0.3 * intensity);
|
||||
next.shorts.scale = Vec3::one();
|
||||
|
||||
next.hand_l.position = Vec3::new(
|
||||
-1.0 - s_a.hand.0,
|
||||
@ -203,7 +201,6 @@ impl Animation for SwimAnimation {
|
||||
Quaternion::rotation_y(2.5) * Quaternion::rotation_z(1.57);
|
||||
},
|
||||
}
|
||||
next.second.scale = Vec3::one();
|
||||
|
||||
next.lantern.position = Vec3::new(s_a.lantern.0, s_a.lantern.1, s_a.lantern.2);
|
||||
next.lantern.scale = Vec3::one() * 0.65;
|
||||
|
@ -133,7 +133,7 @@ impl Animation for SwimWieldAnimation {
|
||||
next.hand_r.position = Vec3::new(0.75, -1.5, -5.5);
|
||||
next.hand_r.orientation =
|
||||
Quaternion::rotation_x(1.47) * Quaternion::rotation_y(0.3);
|
||||
next.hand_r.scale = Vec3::one() * 1.05;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(0.0, 0.0, -3.0);
|
||||
next.main.orientation = Quaternion::rotation_x(-0.1)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
@ -143,7 +143,6 @@ impl Animation for SwimWieldAnimation {
|
||||
next.control.orientation = Quaternion::rotation_x(u_slow * 0.15)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
* Quaternion::rotation_z(u_slowalt * 0.08);
|
||||
next.control.scale = Vec3::one();
|
||||
},
|
||||
Some(ToolKind::Dagger(_)) => {
|
||||
let hand_scale = 1.12;
|
||||
@ -173,7 +172,6 @@ impl Animation for SwimWieldAnimation {
|
||||
next.second.orientation = Quaternion::rotation_x(0.0 * PI)
|
||||
* Quaternion::rotation_y(0.0 * PI)
|
||||
* Quaternion::rotation_z(0.0 * PI);
|
||||
next.second.scale = Vec3::one();
|
||||
|
||||
next.control_r.position = Vec3::new(7.0, 0.0, 0.0);
|
||||
},
|
||||
@ -197,23 +195,21 @@ impl Animation for SwimWieldAnimation {
|
||||
next.control.orientation = Quaternion::rotation_x(1.8)
|
||||
* Quaternion::rotation_y(-0.5)
|
||||
* Quaternion::rotation_z(PI - 0.2);
|
||||
next.control.scale = Vec3::one();
|
||||
} else {
|
||||
next.control.orientation = Quaternion::rotation_x(2.1)
|
||||
* Quaternion::rotation_y(-0.4)
|
||||
* Quaternion::rotation_z(PI - 0.2);
|
||||
next.control.scale = Vec3::one();
|
||||
}
|
||||
next.hand_l.position = Vec3::new(-0.5, 0.0, 4.0);
|
||||
next.hand_l.orientation = Quaternion::rotation_x(PI / 2.0)
|
||||
* Quaternion::rotation_z(0.0)
|
||||
* Quaternion::rotation_y(0.0);
|
||||
next.hand_l.scale = Vec3::one() * 1.08;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(0.5, 0.0, -2.5);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(PI / 2.0)
|
||||
* Quaternion::rotation_z(0.0)
|
||||
* Quaternion::rotation_y(0.0);
|
||||
next.hand_r.scale = Vec3::one() * 1.06;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(-0.0, -2.0, -1.0);
|
||||
next.main.orientation = Quaternion::rotation_x(0.0)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
@ -225,10 +221,10 @@ impl Animation for SwimWieldAnimation {
|
||||
next.hand_l.position = Vec3::new(-12.0, 0.0, 0.0);
|
||||
next.hand_l.orientation =
|
||||
Quaternion::rotation_x(-0.0) * Quaternion::rotation_y(0.0);
|
||||
next.hand_l.scale = Vec3::one() * 1.08;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(2.0, 0.0, 0.0);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(0.0) * Quaternion::rotation_y(0.0);
|
||||
next.hand_r.scale = Vec3::one() * 1.06;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(0.0, 0.0, 0.0);
|
||||
next.main.orientation = Quaternion::rotation_x(0.0)
|
||||
* Quaternion::rotation_y(-1.57)
|
||||
@ -238,18 +234,17 @@ impl Animation for SwimWieldAnimation {
|
||||
next.control.orientation = Quaternion::rotation_x(0.3 + u_slow * 0.15)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
* Quaternion::rotation_z(u_slowalt * 0.08);
|
||||
next.control.scale = Vec3::one();
|
||||
},
|
||||
Some(ToolKind::Staff(_)) | Some(ToolKind::Sceptre(_)) => {
|
||||
next.hand_l.position = Vec3::new(1.5, 0.5, -4.0);
|
||||
next.hand_l.orientation =
|
||||
Quaternion::rotation_x(1.47) * Quaternion::rotation_y(-0.3);
|
||||
next.hand_l.scale = Vec3::one() * 1.05;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(8.0, 4.0, 2.0);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(1.8)
|
||||
* Quaternion::rotation_y(0.5)
|
||||
* Quaternion::rotation_z(-0.27);
|
||||
next.hand_r.scale = Vec3::one() * 1.05;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(12.0, 8.4, 13.2);
|
||||
next.main.orientation = Quaternion::rotation_x(-0.3)
|
||||
* Quaternion::rotation_y(3.14 + 0.3)
|
||||
@ -259,7 +254,6 @@ impl Animation for SwimWieldAnimation {
|
||||
next.control.orientation = Quaternion::rotation_x(u_slow * 0.2)
|
||||
* Quaternion::rotation_y(-0.2)
|
||||
* Quaternion::rotation_z(u_slowalt * 0.1);
|
||||
next.control.scale = Vec3::one();
|
||||
},
|
||||
Some(ToolKind::Shield(_)) => {
|
||||
let hand_scale = 1.12;
|
||||
@ -289,7 +283,6 @@ impl Animation for SwimWieldAnimation {
|
||||
next.second.orientation = Quaternion::rotation_x(0.0 * PI)
|
||||
* Quaternion::rotation_y(0.0 * PI)
|
||||
* Quaternion::rotation_z(0.0 * PI);
|
||||
next.second.scale = Vec3::one();
|
||||
|
||||
next.control_r.position = Vec3::new(7.0, 0.0, 0.0);
|
||||
},
|
||||
@ -298,12 +291,12 @@ impl Animation for SwimWieldAnimation {
|
||||
next.hand_l.orientation = Quaternion::rotation_x(1.20)
|
||||
* Quaternion::rotation_y(-0.6)
|
||||
* Quaternion::rotation_z(-0.3);
|
||||
next.hand_l.scale = Vec3::one() * 1.05;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(5.9, 4.5, -5.0);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(1.20)
|
||||
* Quaternion::rotation_y(-0.6)
|
||||
* Quaternion::rotation_z(-0.3);
|
||||
next.hand_r.scale = Vec3::one() * 1.05;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(3.0, 2.0, -13.0);
|
||||
next.main.orientation = Quaternion::rotation_x(-0.3)
|
||||
* Quaternion::rotation_y(0.3)
|
||||
@ -318,28 +311,25 @@ impl Animation for SwimWieldAnimation {
|
||||
next.control.position = Vec3::new(-7.0, 6.0, 6.0);
|
||||
next.control.orientation =
|
||||
Quaternion::rotation_x(u_slow * 0.2) * Quaternion::rotation_z(u_slowalt * 0.1);
|
||||
next.control.scale = Vec3::one();
|
||||
},
|
||||
Some(ToolKind::Debug(_)) => {
|
||||
next.hand_l.position = Vec3::new(-7.0, 4.0, 3.0);
|
||||
next.hand_l.orientation = Quaternion::rotation_x(1.27)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
* Quaternion::rotation_z(0.0);
|
||||
next.hand_l.scale = Vec3::one() * 1.01;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(7.0, 2.5, -1.25);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(1.27)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
* Quaternion::rotation_z(-0.3);
|
||||
next.hand_r.scale = Vec3::one() * 1.01;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(5.0, 8.75, -2.0);
|
||||
next.main.orientation = Quaternion::rotation_x(-0.3)
|
||||
* Quaternion::rotation_y(-1.27)
|
||||
* Quaternion::rotation_z(0.0);
|
||||
next.main.scale = Vec3::one();
|
||||
next.control.position = Vec3::new(0.0, 6.0, 6.0);
|
||||
next.control.orientation =
|
||||
Quaternion::rotation_x(u_slow * 0.2) * Quaternion::rotation_z(u_slowalt * 0.1);
|
||||
next.control.scale = Vec3::one();
|
||||
},
|
||||
Some(ToolKind::Farming(_)) => {
|
||||
if velocity < 0.5 {
|
||||
@ -350,12 +340,12 @@ impl Animation for SwimWieldAnimation {
|
||||
next.hand_l.position = Vec3::new(9.0, 1.0, 1.0);
|
||||
next.hand_l.orientation =
|
||||
Quaternion::rotation_x(1.57) * Quaternion::rotation_y(0.0);
|
||||
next.hand_l.scale = Vec3::one() * 1.05;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.position = Vec3::new(9.0, 1.0, 11.0);
|
||||
next.hand_r.orientation = Quaternion::rotation_x(1.57)
|
||||
* Quaternion::rotation_y(0.0)
|
||||
* Quaternion::rotation_z(0.0);
|
||||
next.hand_r.scale = Vec3::one() * 1.05;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.main.position = Vec3::new(7.5, 7.5, 13.2);
|
||||
next.main.orientation = Quaternion::rotation_x(0.0)
|
||||
* Quaternion::rotation_y(3.14)
|
||||
@ -365,14 +355,11 @@ impl Animation for SwimWieldAnimation {
|
||||
next.control.orientation = Quaternion::rotation_x(u_slow * 0.1)
|
||||
* Quaternion::rotation_y(0.6 + u_slow * 0.1)
|
||||
* Quaternion::rotation_z(u_slowalt * 0.1);
|
||||
next.control.scale = Vec3::one();
|
||||
},
|
||||
_ => {},
|
||||
}
|
||||
|
||||
next.control_l.scale = Vec3::one();
|
||||
|
||||
next.control_r.scale = Vec3::one();
|
||||
|
||||
next.second.scale = match (
|
||||
active_tool_kind.map(|tk| tk.hands()),
|
||||
|
@ -77,7 +77,6 @@ impl Animation for FlyAnimation {
|
||||
|
||||
next.chest_front.position = Vec3::new(0.0, s_a.chest_front.0, s_a.chest_front.1);
|
||||
next.chest_front.orientation = Quaternion::rotation_y(center * 0.05);
|
||||
next.chest_front.scale = Vec3::one();
|
||||
|
||||
next.chest_rear.position = Vec3::new(0.0, s_a.chest_rear.0, s_a.chest_rear.1);
|
||||
next.chest_rear.orientation = Quaternion::rotation_y(center * 0.05);
|
||||
|
@ -21,29 +21,35 @@ impl Animation for IdleAnimation {
|
||||
) -> Self::Skeleton {
|
||||
let mut next = (*skeleton).clone();
|
||||
|
||||
next.head.scale = Vec3::one() / 10.88;
|
||||
next.torso.scale = Vec3::one() * 1.01;
|
||||
next.rear.scale = Vec3::one() * 0.98;
|
||||
next.tail.scale = Vec3::one() / 11.0;
|
||||
next.fin_l.scale = Vec3::one() / 11.0;
|
||||
next.fin_r.scale = Vec3::one() / 10.5;
|
||||
|
||||
next.head.position = Vec3::new(0.0, 7.5, 15.0) / 11.0;
|
||||
next.head.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.0);
|
||||
next.head.scale = Vec3::one() / 10.88;
|
||||
|
||||
|
||||
next.torso.position = Vec3::new(0.0, 4.5, 2.0);
|
||||
next.torso.orientation = Quaternion::rotation_x(0.0);
|
||||
next.torso.scale = Vec3::one() * 1.01;
|
||||
|
||||
|
||||
next.rear.position = Vec3::new(0.0, 3.1, -4.5);
|
||||
next.rear.orientation = Quaternion::rotation_z(0.0);
|
||||
next.rear.scale = Vec3::one() * 0.98;
|
||||
|
||||
|
||||
next.tail.position = Vec3::new(0.0, -13.0, 8.0) / 11.0;
|
||||
next.tail.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.0);
|
||||
next.tail.scale = Vec3::one() / 11.0;
|
||||
|
||||
|
||||
next.fin_l.position = Vec3::new(0.0, -11.7, 11.0) / 11.0;
|
||||
next.fin_l.orientation = Quaternion::rotation_y(0.0);
|
||||
next.fin_l.scale = Vec3::one() / 11.0;
|
||||
|
||||
|
||||
next.fin_r.position = Vec3::new(0.0, 0.0, 12.0) / 11.0;
|
||||
next.fin_r.orientation = Quaternion::rotation_y(0.0);
|
||||
next.fin_r.scale = Vec3::one() / 10.5;
|
||||
next
|
||||
}
|
||||
}
|
||||
|
@ -21,29 +21,35 @@ impl Animation for JumpAnimation {
|
||||
) -> Self::Skeleton {
|
||||
let mut next = (*skeleton).clone();
|
||||
|
||||
next.head.scale = Vec3::one() / 10.88;
|
||||
next.torso.scale = Vec3::one() * 1.01;
|
||||
next.rear.scale = Vec3::one() * 0.98;
|
||||
next.tail.scale = Vec3::one() / 11.0;
|
||||
next.fin_l.scale = Vec3::one() / 11.0;
|
||||
next.fin_r.scale = Vec3::one() / 10.5;
|
||||
|
||||
next.head.position = Vec3::new(0.0, 7.5, 15.0) / 11.0;
|
||||
next.head.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.0);
|
||||
next.head.scale = Vec3::one() / 10.88;
|
||||
|
||||
|
||||
next.torso.position = Vec3::new(0.0, 4.5, 2.0);
|
||||
next.torso.orientation = Quaternion::rotation_x(0.0);
|
||||
next.torso.scale = Vec3::one() * 1.01;
|
||||
|
||||
|
||||
next.rear.position = Vec3::new(0.0, 3.1, -4.5);
|
||||
next.rear.orientation = Quaternion::rotation_z(0.0);
|
||||
next.rear.scale = Vec3::one() * 0.98;
|
||||
|
||||
|
||||
next.tail.position = Vec3::new(0.0, -13.0, 8.0) / 11.0;
|
||||
next.tail.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.0);
|
||||
next.tail.scale = Vec3::one() / 11.0;
|
||||
|
||||
|
||||
next.fin_l.position = Vec3::new(0.0, -11.7, 11.0) / 11.0;
|
||||
next.fin_l.orientation = Quaternion::rotation_y(0.0);
|
||||
next.fin_l.scale = Vec3::one() / 11.0;
|
||||
|
||||
|
||||
next.fin_r.position = Vec3::new(0.0, 0.0, 12.0) / 11.0;
|
||||
next.fin_r.orientation = Quaternion::rotation_y(0.0);
|
||||
next.fin_r.scale = Vec3::one() / 10.5;
|
||||
next
|
||||
}
|
||||
}
|
||||
|
@ -21,29 +21,35 @@ impl Animation for RunAnimation {
|
||||
) -> Self::Skeleton {
|
||||
let mut next = (*skeleton).clone();
|
||||
|
||||
next.head.scale = Vec3::one() / 10.88;
|
||||
next.torso.scale = Vec3::one() * 1.01;
|
||||
next.rear.scale = Vec3::one() * 0.98;
|
||||
next.tail.scale = Vec3::one() / 11.0;
|
||||
next.fin_l.scale = Vec3::one() / 11.0;
|
||||
next.fin_r.scale = Vec3::one() / 10.5;
|
||||
|
||||
next.head.position = Vec3::new(0.0, 7.5, 15.0) / 11.0;
|
||||
next.head.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.0);
|
||||
next.head.scale = Vec3::one() / 10.88;
|
||||
|
||||
|
||||
next.torso.position = Vec3::new(0.0, 4.5, 2.0);
|
||||
next.torso.orientation = Quaternion::rotation_x(0.0);
|
||||
next.torso.scale = Vec3::one() * 1.01;
|
||||
|
||||
|
||||
next.rear.position = Vec3::new(0.0, 3.1, -4.5);
|
||||
next.rear.orientation = Quaternion::rotation_z(0.0);
|
||||
next.rear.scale = Vec3::one() * 0.98;
|
||||
|
||||
|
||||
next.tail.position = Vec3::new(0.0, -13.0, 8.0) / 11.0;
|
||||
next.tail.orientation = Quaternion::rotation_z(0.0) * Quaternion::rotation_x(0.0);
|
||||
next.tail.scale = Vec3::one() / 11.0;
|
||||
|
||||
|
||||
next.fin_l.position = Vec3::new(0.0, -11.7, 11.0) / 11.0;
|
||||
next.fin_l.orientation = Quaternion::rotation_y(0.0);
|
||||
next.fin_l.scale = Vec3::one() / 11.0;
|
||||
|
||||
|
||||
next.fin_r.position = Vec3::new(0.0, 0.0, 12.0) / 11.0;
|
||||
next.fin_r.orientation = Quaternion::rotation_y(0.0);
|
||||
next.fin_r.scale = Vec3::one() / 10.5;
|
||||
next
|
||||
}
|
||||
}
|
||||
|
@ -42,8 +42,8 @@ impl Animation for IdleAnimation {
|
||||
next.head.scale = Vec3::one() * 1.02;
|
||||
next.jaw.scale = Vec3::one() * 1.02;
|
||||
next.upper_torso.scale = Vec3::one() / 8.0;
|
||||
next.hand_l.scale = Vec3::one() * 1.02;
|
||||
next.hand_r.scale = Vec3::one() * 1.02;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.leg_l.scale = Vec3::one() * 1.02;
|
||||
next.leg_r.scale = Vec3::one() * 1.02;
|
||||
|
||||
|
@ -25,8 +25,8 @@ impl Animation for JumpAnimation {
|
||||
next.head.scale = Vec3::one() * 1.02;
|
||||
next.jaw.scale = Vec3::one() * 1.02;
|
||||
next.upper_torso.scale = Vec3::one() / 8.0;
|
||||
next.hand_l.scale = Vec3::one() * 1.02;
|
||||
next.hand_r.scale = Vec3::one() * 1.02;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.leg_l.scale = Vec3::one() * 1.02;
|
||||
next.leg_r.scale = Vec3::one() * 1.02;
|
||||
|
||||
|
@ -73,8 +73,8 @@ impl Animation for RunAnimation {
|
||||
next.head.scale = Vec3::one() * 1.02;
|
||||
next.jaw.scale = Vec3::one() * 1.02;
|
||||
next.upper_torso.scale = Vec3::one() / 8.0;
|
||||
next.hand_l.scale = Vec3::one() * 1.02;
|
||||
next.hand_r.scale = Vec3::one() * 1.02;
|
||||
next.hand_l.scale = Vec3::one() * 1.04;
|
||||
next.hand_r.scale = Vec3::one() * 1.04;
|
||||
next.leg_l.scale = Vec3::one() * 1.02;
|
||||
next.leg_r.scale = Vec3::one() * 1.02;
|
||||
|
||||
@ -89,7 +89,6 @@ impl Animation for RunAnimation {
|
||||
|
||||
next.lower_torso.position = Vec3::new(0.0, s_a.lower_torso.0, s_a.lower_torso.1);
|
||||
next.lower_torso.orientation = Quaternion::rotation_z(tilt * 4.0 + shortalt * 0.2);
|
||||
next.lower_torso.scale = Vec3::one();
|
||||
|
||||
next.shoulder_l.position = Vec3::new(-s_a.shoulder.0, s_a.shoulder.1, s_a.shoulder.2);
|
||||
next.shoulder_l.orientation = Quaternion::rotation_z(footrotl * 0.07)
|
||||
|
@ -76,7 +76,6 @@ impl Animation for IdleAnimation {
|
||||
next.tail.position = Vec3::new(0.0, s_a.tail.0, s_a.tail.1);
|
||||
next.tail.orientation =
|
||||
Quaternion::rotation_z(0.0 + slow * 0.2 + tailmove.x) * Quaternion::rotation_x(0.0);
|
||||
next.tail.scale = Vec3::one();
|
||||
|
||||
next.torso_front.position =
|
||||
Vec3::new(0.0, s_a.torso_front.0, s_a.torso_front.1 + slower * 0.3) * s_a.scaler / 11.0;
|
||||
|
Loading…
Reference in New Issue
Block a user