mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Fixed masses, mount offsets and mountability for quad_low
This commit is contained in:
parent
3238863c26
commit
306c3e1423
@ -337,14 +337,24 @@ impl Body {
|
||||
// alligator or smaller, so whatever
|
||||
quadruped_low::Species::Crocodile => 360.0,
|
||||
quadruped_low::Species::SeaCrocodile => 410.0,
|
||||
quadruped_low::Species::Deadwood => 400.0,
|
||||
quadruped_low::Species::Deadwood => 150.0,
|
||||
quadruped_low::Species::Lavadrake => 500.0,
|
||||
quadruped_low::Species::Monitor => 100.0,
|
||||
quadruped_low::Species::Pangolin => 100.0,
|
||||
quadruped_low::Species::Salamander => 65.0,
|
||||
quadruped_low::Species::Monitor => 200.0,
|
||||
quadruped_low::Species::Pangolin => 300.0,
|
||||
quadruped_low::Species::Salamander => 350.0,
|
||||
quadruped_low::Species::Elbst => 65.0,
|
||||
quadruped_low::Species::Tortoise => 200.0,
|
||||
quadruped_low::Species::Tortoise => 300.0,
|
||||
quadruped_low::Species::Lavadrake => 500.0,
|
||||
quadruped_low::Species::Icedrake => 500.0,
|
||||
quadruped_low::Species::Mossdrake => 500.0,
|
||||
quadruped_low::Species::Rocksnapper => 450.0,
|
||||
quadruped_low::Species::Rootsnapper => 450.0,
|
||||
quadruped_low::Species::Reefsnapper => 450.0,
|
||||
quadruped_low::Species::Maneater => 350.0,
|
||||
quadruped_low::Species::Sandshark => 450.0,
|
||||
quadruped_low::Species::Hakulaq => 300.0,
|
||||
quadruped_low::Species::Dagon => 400.0,
|
||||
quadruped_low::Species::Basilisk => 500.0,
|
||||
_ => 200.0,
|
||||
},
|
||||
Body::QuadrupedMedium(body) => match body.species {
|
||||
@ -1022,9 +1032,12 @@ impl Body {
|
||||
/// Component of the mounting offset specific to the mount
|
||||
pub fn mount_offset(&self) -> Vec3<f32> {
|
||||
match self {
|
||||
Body::Humanoid(_) => (self.dimensions() * Vec3::new(0.5, 0.0, 0.6)).into_array(),
|
||||
Body::Humanoid(_) | Body::BipedLarge(_) => {
|
||||
(self.dimensions() * Vec3::new(0.5, 0.0, 0.6)).into_array()
|
||||
(self.dimensions() * Vec3::new(0.5, 0.0, 0.7)).into_array()
|
||||
},
|
||||
Body::BirdLarge(_) => (self.dimensions() * Vec3::new(0.0, 0.2, 0.7)).into_array(),
|
||||
Body::QuadrupedLow(_) => (self.dimensions() * Vec3::new(0.0, 0.15, 0.4)).into_array(),
|
||||
Body::QuadrupedMedium(quadruped_medium) => {
|
||||
match (quadruped_medium.species, quadruped_medium.body_type) {
|
||||
(quadruped_medium::Species::Grolgar, _) => [0.0, 0.5, 1.8],
|
||||
|
@ -91,12 +91,7 @@ pub fn is_mountable(mount: &Body, rider: Option<&Body>) -> bool {
|
||||
},
|
||||
_ => false,
|
||||
},
|
||||
Body::QuadrupedLow(body) => matches!(
|
||||
body.species,
|
||||
quadruped_low::Species::Salamander
|
||||
| quadruped_low::Species::Elbst
|
||||
| quadruped_low::Species::Tortoise
|
||||
),
|
||||
Body::QuadrupedLow(_) => mount.mass() >= Mass(300.0) && is_light_enough(rider),
|
||||
Body::Ship(_) => true,
|
||||
_ => false,
|
||||
}
|
||||
|
@ -391,27 +391,27 @@ impl<'a> From<&'a Body> for SkeletonAttr {
|
||||
fn mount_point(body: &Body) -> Vec3<f32> {
|
||||
use comp::quadruped_low::Species::*;
|
||||
match (body.species, body.body_type) {
|
||||
(Crocodile, _) => (0.0, 4.5, -2.0),
|
||||
(SeaCrocodile, _) => (0.0, 4.5, -2.0),
|
||||
(Alligator, _) => (0.0, 4.25, -2.0),
|
||||
(Crocodile, _) => (0.0, 3.5, 4.5),
|
||||
(SeaCrocodile, _) => (0.0, 3.5, 5.0),
|
||||
(Alligator, _) => (0.0, 2.5, 3.0),
|
||||
(Salamander, _) => (0.0, 5.0, -1.0),
|
||||
(Elbst, _) => (0.0, 5.0, -1.0),
|
||||
(Monitor, _) => (0.0, 2.0, -2.0),
|
||||
(Asp, _) => (0.0, 2.0, 0.0),
|
||||
(Tortoise, _) => (0.0, -7.0, -1.0),
|
||||
(Rocksnapper, _) => (0.0, -7.0, 4.5),
|
||||
(Rootsnapper, _) => (0.0, -7.0, 4.5),
|
||||
(Reefsnapper, _) => (0.0, -7.0, 4.5),
|
||||
(Pangolin, _) => (0.0, -6.5, -2.0),
|
||||
(Tortoise, _) => (0.0, 0.0, 3.0),
|
||||
(Rocksnapper, _) => (0.0, 7.0, 5.0),
|
||||
(Rootsnapper, _) => (0.0, -2.0, 9.0),
|
||||
(Reefsnapper, _) => (0.0, 2.0, 2.0),
|
||||
(Pangolin, _) => (0.0, -1.0, 0.5),
|
||||
(Maneater, _) => (0.0, 4.0, -11.5),
|
||||
(Sandshark, _) => (0.0, -4.0, -2.0),
|
||||
(Hakulaq, _) => (0.0, 4.0, -4.5),
|
||||
(Hakulaq, _) => (0.0, 4.0, -2.5),
|
||||
(Dagon, _) => (0.0, 4.0, -4.5),
|
||||
(Lavadrake, _) => (0.0, 2.0, -2.5),
|
||||
(Icedrake, _) => (0.0, -8.0, 2.5),
|
||||
(Basilisk, _) => (0.0, -2.0, 2.0),
|
||||
(Basilisk, _) => (0.0, -2.0, 5.0),
|
||||
(Deadwood, _) => (0.0, -2.0, -3.0),
|
||||
(Mossdrake, _) => (0.0, 2.0, -2.5),
|
||||
(Mossdrake, _) => (0.0, 2.0, -0.5),
|
||||
}
|
||||
.into()
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user