Fixed various issues from better-things branch

This commit is contained in:
Snowram 2020-09-20 17:58:54 +02:00 committed by jshipsey
parent 2f2e766ebb
commit fa2dd28587
8 changed files with 37 additions and 24 deletions

View File

@ -104,6 +104,8 @@ impl<'a> From<&'a Body> for Psyche {
quadruped_medium::Species::Frostfang => 0.9, quadruped_medium::Species::Frostfang => 0.9,
quadruped_medium::Species::Mouflon => 0.8, quadruped_medium::Species::Mouflon => 0.8,
quadruped_medium::Species::Catoblepas => 0.8, quadruped_medium::Species::Catoblepas => 0.8,
quadruped_medium::Species::Deer => 0.6,
quadruped_medium::Species::Hirdrasil => 0.7,
_ => 1.0, _ => 1.0,
}, },
Body::QuadrupedLow(quadruped_low) => match quadruped_low.species { Body::QuadrupedLow(quadruped_low) => match quadruped_low.species {

View File

@ -238,6 +238,8 @@ impl Body {
quadruped_medium::Species::Mouflon => 500, quadruped_medium::Species::Mouflon => 500,
quadruped_medium::Species::Catoblepas => 1000, quadruped_medium::Species::Catoblepas => 1000,
quadruped_medium::Species::Bonerattler => 400, quadruped_medium::Species::Bonerattler => 400,
quadruped_medium::Species::Deer => 300,
quadruped_medium::Species::Hirdrasil => 500,
_ => 400, _ => 400,
}, },
Body::BirdMedium(bird_medium) => match bird_medium.species { Body::BirdMedium(bird_medium) => match bird_medium.species {
@ -305,6 +307,8 @@ impl Body {
quadruped_medium::Species::Mouflon => 30, quadruped_medium::Species::Mouflon => 30,
quadruped_medium::Species::Catoblepas => 50, quadruped_medium::Species::Catoblepas => 50,
quadruped_medium::Species::Bonerattler => 30, quadruped_medium::Species::Bonerattler => 30,
quadruped_medium::Species::Deer => 30,
quadruped_medium::Species::Hirdrasil => 30,
_ => 20, _ => 20,
}, },
Body::BirdMedium(bird_medium) => match bird_medium.species { Body::BirdMedium(bird_medium) => match bird_medium.species {
@ -372,6 +376,8 @@ impl Body {
quadruped_medium::Species::Mouflon => 7, quadruped_medium::Species::Mouflon => 7,
quadruped_medium::Species::Catoblepas => 10, quadruped_medium::Species::Catoblepas => 10,
quadruped_medium::Species::Bonerattler => 10, quadruped_medium::Species::Bonerattler => 10,
quadruped_medium::Species::Deer => 7,
quadruped_medium::Species::Hirdrasil => 10,
_ => 6, _ => 6,
}, },
Body::BirdMedium(bird_medium) => match bird_medium.species { Body::BirdMedium(bird_medium) => match bird_medium.species {
@ -438,6 +444,7 @@ impl Body {
Body::QuadrupedSmall(quadruped_small) => match quadruped_small.species { Body::QuadrupedSmall(quadruped_small) => match quadruped_small.species {
quadruped_small::Species::Dodarock => 30, quadruped_small::Species::Dodarock => 30,
quadruped_small::Species::Hyena => 40, quadruped_small::Species::Hyena => 40,
quadruped_small::Species::Porcupine => 30,
_ => 20, _ => 20,
}, },
Body::QuadrupedMedium(quadruped_medium) => match quadruped_medium.species { Body::QuadrupedMedium(quadruped_medium) => match quadruped_medium.species {
@ -447,6 +454,8 @@ impl Body {
quadruped_medium::Species::Mouflon => 30, quadruped_medium::Species::Mouflon => 30,
quadruped_medium::Species::Catoblepas => 20, quadruped_medium::Species::Catoblepas => 20,
quadruped_medium::Species::Bonerattler => 50, quadruped_medium::Species::Bonerattler => 50,
quadruped_medium::Species::Deer => 30,
quadruped_medium::Species::Hirdrasil => 50,
_ => 40, _ => 40,
}, },
Body::BirdMedium(bird_medium) => match bird_medium.species { Body::BirdMedium(bird_medium) => match bird_medium.species {

View File

@ -79,7 +79,7 @@ impl Animation for FeedAnimation {
next.jaw.position = Vec3::new( next.jaw.position = Vec3::new(
0.0, 0.0,
skeleton_attr.jaw.0 - slower * 0.12, skeleton_attr.jaw.0 - slower * 0.12,
skeleton_attr.jaw.1 + slow * 0.2 + 0.5, skeleton_attr.jaw.1 + slow * 0.2,
); );
next.jaw.orientation = Quaternion::rotation_x((fast * 0.18 + faster * 0.26).min(0.0)); next.jaw.orientation = Quaternion::rotation_x((fast * 0.18 + faster * 0.26).min(0.0));
next.jaw.scale = Vec3::one() * 1.02; next.jaw.scale = Vec3::one() * 1.02;

View File

@ -71,7 +71,7 @@ impl Animation for IdleAnimation {
next.jaw.position = Vec3::new( next.jaw.position = Vec3::new(
0.0, 0.0,
skeleton_attr.jaw.0 - slower * 0.12, skeleton_attr.jaw.0 - slower * 0.12,
skeleton_attr.jaw.1 + slow * 0.2 + 0.5, skeleton_attr.jaw.1 + slow * 0.2,
); );
next.jaw.orientation = Quaternion::rotation_x(slow * 0.05 - 0.08); next.jaw.orientation = Quaternion::rotation_x(slow * 0.05 - 0.08);
next.jaw.scale = Vec3::one() * 1.02; next.jaw.scale = Vec3::one() * 1.02;

View File

@ -167,23 +167,23 @@ impl<'a> From<&'a Body> for SkeletonAttr {
(Hirdrasil, _) => (-1.0, 0.5), (Hirdrasil, _) => (-1.0, 0.5),
}, },
jaw: match (body.species, body.body_type) { jaw: match (body.species, body.body_type) {
(Grolgar, _) => (7.0, 1.5), (Grolgar, _) => (7.0, 2.0),
(Saber, _) => (2.5, -2.0), (Saber, _) => (2.5, -2.0),
(Tuskram, _) => (5.5, -4.0), (Tuskram, _) => (5.5, -3.5),
(Lion, _) => (3.5, -4.5), (Lion, _) => (3.5, -4.0),
(Tarasque, _) => (9.0, -10.0), (Tarasque, _) => (9.0, -9.5),
(Tiger, _) => (3.5, -4.0), (Tiger, _) => (3.0, -3.5),
(Wolf, _) => (5.0, -3.0), (Wolf, _) => (5.0, -2.5),
(Frostfang, _) => (4.0, -3.0), (Frostfang, _) => (4.0, -2.5),
(Mouflon, _) => (6.0, 0.5), (Mouflon, _) => (6.0, 1.0),
(Catoblepas, _) => (1.0, -4.0), (Catoblepas, _) => (1.0, -3.5),
(Bonerattler, _) => (3.0, -3.0), (Bonerattler, _) => (3.0, -2.5),
(Deer, _) => (3.5, 2.0), (Deer, _) => (3.5, 2.5),
(Hirdrasil, _) => (2.5, 2.5), (Hirdrasil, _) => (2.5, 3.0),
}, },
tail: match (body.species, body.body_type) { tail: match (body.species, body.body_type) {
(Grolgar, _) => (-11.5, -0.5), (Grolgar, _) => (-11.5, -0.5),
(Saber, _) => (-11.0, 1.0), (Saber, _) => (-11.0, 0.0),
(Tuskram, _) => (-9.0, 2.0), (Tuskram, _) => (-9.0, 2.0),
(Lion, _) => (-11.0, 1.0), (Lion, _) => (-11.0, 1.0),
(Tarasque, _) => (-11.0, 0.0), (Tarasque, _) => (-11.0, 0.0),
@ -191,21 +191,21 @@ impl<'a> From<&'a Body> for SkeletonAttr {
(Wolf, _) => (-11.0, 0.0), (Wolf, _) => (-11.0, 0.0),
(Frostfang, _) => (-7.0, -3.5), (Frostfang, _) => (-7.0, -3.5),
(Mouflon, _) => (-10.5, 3.0), (Mouflon, _) => (-10.5, 3.0),
(Catoblepas, _) => (-8.5, -2.0), (Catoblepas, _) => (-8.0, -2.0),
(Bonerattler, _) => (-10.0, 1.5), (Bonerattler, _) => (-10.0, 1.5),
(Deer, _) => (-8.5, 0.5), (Deer, _) => (-8.5, 0.5),
(Hirdrasil, _) => (-11.0, 2.0), (Hirdrasil, _) => (-11.0, 2.0),
}, },
torso_front: match (body.species, body.body_type) { torso_front: match (body.species, body.body_type) {
(Grolgar, _) => (10.0, 13.0), (Grolgar, _) => (10.0, 13.0),
(Saber, _) => (14.0, 14.0), (Saber, _) => (14.0, 13.0),
(Tuskram, _) => (10.0, 14.5), (Tuskram, _) => (10.0, 14.5),
(Lion, _) => (10.0, 12.5), (Lion, _) => (10.0, 12.5),
(Tarasque, _) => (11.5, 18.5), (Tarasque, _) => (11.5, 17.5),
(Tiger, _) => (10.0, 13.0), (Tiger, _) => (10.0, 13.0),
(Wolf, _) => (12.0, 13.0), (Wolf, _) => (12.0, 13.0),
(Frostfang, _) => (9.0, 11.5), (Frostfang, _) => (9.0, 11.5),
(Mouflon, _) => (11.0, 13.5), (Mouflon, _) => (11.0, 14.0),
(Catoblepas, _) => (7.5, 19.5), (Catoblepas, _) => (7.5, 19.5),
(Bonerattler, _) => (6.0, 12.5), (Bonerattler, _) => (6.0, 12.5),
(Deer, _) => (11.0, 13.5), (Deer, _) => (11.0, 13.5),
@ -243,7 +243,7 @@ impl<'a> From<&'a Body> for SkeletonAttr {
}, },
leg_f: match (body.species, body.body_type) { leg_f: match (body.species, body.body_type) {
(Grolgar, _) => (7.5, -5.5, -1.0), (Grolgar, _) => (7.5, -5.5, -1.0),
(Saber, _) => (7.0, -4.0, -3.5), (Saber, _) => (7.0, -4.0, -2.5),
(Tuskram, _) => (6.0, -6.5, -4.0), (Tuskram, _) => (6.0, -6.5, -4.0),
(Lion, _) => (6.5, -6.5, -1.5), (Lion, _) => (6.5, -6.5, -1.5),
(Tarasque, _) => (7.0, -8.0, -6.0), (Tarasque, _) => (7.0, -8.0, -6.0),

View File

@ -27,10 +27,10 @@ impl Animation for RunAnimation {
//let increasefreqtest = (((1.0/speed)*3.0).round()).min(5.0); //let increasefreqtest = (((1.0/speed)*3.0).round()).min(5.0);
let lab = 0.72; //0.72 let lab = 0.72; //0.72
let amplitude = (speed / 24.0).max(0.25); let amplitude = (speed / 24.0).max(0.25);
let amplitude2 = (speed * 1.4 / 24.0).max(0.6); let amplitude2 = (speed * 1.4 / 24.0).powf(0.5).max(0.6);
let amplitude3 = (speed / 24.0).max(0.35); let amplitude3 = (speed / 24.0).powf(0.5).max(0.35);
let speedmult = skeleton_attr.tempo; let speedmult = skeleton_attr.tempo;
let canceler = speed / 24.0; let canceler = (speed / 24.0).powf(0.5);
let short = (((1.0) let short = (((1.0)
/ (0.72 / (0.72
+ 0.28 + 0.28

View File

@ -250,7 +250,7 @@ impl<'a> From<&'a Body> for SkeletonAttr {
(Turtle, _) => (0.9), (Turtle, _) => (0.9),
(Squirrel, _) => (0.7), (Squirrel, _) => (0.7),
(Fungome, _) => (0.9), (Fungome, _) => (0.9),
(Porcupine, _) => (1.0), (Porcupine, _) => (0.8),
(Beaver, _) => (1.0), (Beaver, _) => (1.0),
}, },
tempo: match (body.species, body.body_type) { tempo: match (body.species, body.body_type) {

View File

@ -244,6 +244,8 @@ impl World {
quadruped_medium::Species::Catoblepas => is_hostile = false, quadruped_medium::Species::Catoblepas => is_hostile = false,
quadruped_medium::Species::Mouflon => is_hostile = false, quadruped_medium::Species::Mouflon => is_hostile = false,
quadruped_medium::Species::Tuskram => is_hostile = false, quadruped_medium::Species::Tuskram => is_hostile = false,
quadruped_medium::Species::Deer => is_hostile = false,
quadruped_medium::Species::Hirdrasil => is_hostile = false,
_ => is_hostile = true, _ => is_hostile = true,
} }
}, },