Merge branch 'nepo/dullahan' into 'master'

nepo/dullahan

See merge request veloren/veloren!1266
This commit is contained in:
Justin Shipsey 2020-08-07 03:57:00 +00:00
commit 44febaabdf
18 changed files with 441 additions and 282 deletions

View File

@ -529,6 +529,10 @@
"troll": {
"keyword": "troll",
"generic": "Troll"
},
"dullahan": {
"keyword": "dullahan",
"generic": "Dullahan"
}
}
},

View File

@ -143,4 +143,43 @@
center: ("armor.empty"),
)
),
(Dullahan, Male): (
head: (
offset: (-8.0, -5.0, -6.0),
center: ("armor.empty"),
),
torso_upper: (
offset: (-9.0, -7.5, -7.0),
center: ("npc.dullahan.male.torso_upper"),
),
torso_lower: (
offset: (-8.0, -6.0, -9.0),
center: ("npc.dullahan.male.torso_lower"),
),
main: (
offset: (-1.5, -9.0, -10.0),
center: ("npc.dullahan.male.sword"),
)
),
(Dullahan, Female): (
head: (
offset: (-8.0, -5.0, -6.0),
center: ("armor.empty"),
),
torso_upper: (
offset: (-9.0, -7.5, -7.0),
center: ("npc.dullahan.male.torso_upper"),
),
torso_lower: (
offset: (-8.0, -6.0, -9.0),
center: ("npc.dullahan.male.torso_lower"),
),
main: (
offset: (-1.5, -9.0, -10.0),
center: ("npc.dullahan.male.sword"),
)
),
})

View File

@ -31,7 +31,7 @@
foot_r: (
offset: (-3.0, -5.0, -2.5),
lateral: ("npc.ogre.male.foot_r"),
)
),
),
(Ogre, Female): (
shoulder_l: (
@ -65,7 +65,7 @@
foot_r: (
offset: (-3.0, -5.0, -2.5),
lateral: ("npc.ogre.male.foot_r"),
)
),
),
(Cyclops, Male): (
shoulder_l: (
@ -99,7 +99,7 @@
foot_r: (
offset: (-3.0, -5.0, -5.0),
lateral: ("npc.cyclops.male.foot_r"),
)
),
),
(Cyclops, Female): (
shoulder_l: (
@ -133,7 +133,7 @@
foot_r: (
offset: (-3.0, -5.0, -5.0),
lateral: ("npc.cyclops.male.foot_r"),
)
),
),
(Wendigo, Male): (
shoulder_l: (
@ -167,7 +167,7 @@
foot_r: (
offset: (-4.0, -5.0, -5.5),
lateral: ("npc.wendigo.male.foot_r"),
)
),
),
(Wendigo, Female): (
shoulder_l: (
@ -201,7 +201,7 @@
foot_r: (
offset: (-4.0, -5.0, -5.5),
lateral: ("npc.wendigo.male.foot_r"),
)
),
),
(Troll, Male): (
shoulder_l: (
@ -235,7 +235,7 @@
foot_r: (
offset: (-3.0, -5.0, -2.5),
lateral: ("npc.troll.male.foot_r"),
)
),
),
(Troll, Female): (
shoulder_l: (
@ -269,6 +269,74 @@
foot_r: (
offset: (-3.0, -5.0, -2.5),
lateral: ("npc.troll.male.foot_r"),
)
),
),
(Dullahan, Male): (
shoulder_l: (
offset: (-7.5, -5.5, -6.0),
lateral: ("npc.dullahan.male.shoulder_l"),
),
shoulder_r: (
offset: (-7.5, -5.5, -6.0),
lateral: ("npc.dullahan.male.shoulder_r"),
),
hand_l: (
offset: (-4.5, -4.5, -15.0),
lateral: ("npc.dullahan.male.hand_l"),
),
hand_r: (
offset: (-4.5, -4.5, -15.0),
lateral: ("npc.dullahan.male.hand_r"),
),
leg_l: (
offset: (-6.0, -3.0, -7.0),
lateral: ("npc.dullahan.male.leg_l"),
),
leg_r: (
offset: (0.0, -3.0, -7.0),
lateral: ("npc.dullahan.male.leg_r"),
),
foot_l: (
offset: (-3.0, -5.0, -8.0),
lateral: ("npc.dullahan.male.foot_l"),
),
foot_r: (
offset: (-3.0, -5.0, -8.0),
lateral: ("npc.dullahan.male.foot_r"),
),
),
(Dullahan, Female): (
shoulder_l: (
offset: (-7.5, -5.5, -6.0),
lateral: ("npc.dullahan.male.shoulder_l"),
),
shoulder_r: (
offset: (-7.5, -5.5, -6.0),
lateral: ("npc.dullahan.male.shoulder_r"),
),
hand_l: (
offset: (-4.5, -4.5, -15.0),
lateral: ("npc.dullahan.male.hand_l"),
),
hand_r: (
offset: (-4.5, -4.5, -15.0),
lateral: ("npc.dullahan.male.hand_r"),
),
leg_l: (
offset: (-6.0, -3.0, -7.0),
lateral: ("npc.dullahan.male.leg_l"),
),
leg_r: (
offset: (0.0, -3.0, -7.0),
lateral: ("npc.dullahan.male.leg_r"),
),
foot_l: (
offset: (-3.0, -5.0, -8.0),
lateral: ("npc.dullahan.male.foot_l"),
),
foot_r: (
offset: (-3.0, -5.0, -8.0),
lateral: ("npc.dullahan.male.foot_r"),
),
),
})

BIN
assets/voxygen/voxel/npc/dullahan/male/foot_l.vox (Stored with Git LFS) Normal file

Binary file not shown.

BIN
assets/voxygen/voxel/npc/dullahan/male/foot_r.vox (Stored with Git LFS) Normal file

Binary file not shown.

BIN
assets/voxygen/voxel/npc/dullahan/male/hand_l.vox (Stored with Git LFS) Normal file

Binary file not shown.

BIN
assets/voxygen/voxel/npc/dullahan/male/hand_r.vox (Stored with Git LFS) Normal file

Binary file not shown.

BIN
assets/voxygen/voxel/npc/dullahan/male/leg_l.vox (Stored with Git LFS) Normal file

Binary file not shown.

BIN
assets/voxygen/voxel/npc/dullahan/male/leg_r.vox (Stored with Git LFS) Normal file

Binary file not shown.

BIN
assets/voxygen/voxel/npc/dullahan/male/shoulder_l.vox (Stored with Git LFS) Normal file

Binary file not shown.

BIN
assets/voxygen/voxel/npc/dullahan/male/shoulder_r.vox (Stored with Git LFS) Normal file

Binary file not shown.

BIN
assets/voxygen/voxel/npc/dullahan/male/sword.vox (Stored with Git LFS) Normal file

Binary file not shown.

BIN
assets/voxygen/voxel/npc/dullahan/male/torso_lower.vox (Stored with Git LFS) Normal file

Binary file not shown.

BIN
assets/voxygen/voxel/npc/dullahan/male/torso_upper.vox (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -32,6 +32,7 @@ pub enum Species {
Cyclops = 1,
Wendigo = 2,
Troll = 3,
Dullahan = 4,
}
/// Data representing per-species generic data.
@ -43,6 +44,7 @@ pub struct AllSpecies<SpeciesMeta> {
pub cyclops: SpeciesMeta,
pub wendigo: SpeciesMeta,
pub troll: SpeciesMeta,
pub dullahan: SpeciesMeta,
}
impl<'a, SpeciesMeta> core::ops::Index<&'a Species> for AllSpecies<SpeciesMeta> {
@ -55,15 +57,17 @@ impl<'a, SpeciesMeta> core::ops::Index<&'a Species> for AllSpecies<SpeciesMeta>
Species::Cyclops => &self.cyclops,
Species::Wendigo => &self.wendigo,
Species::Troll => &self.troll,
Species::Dullahan => &self.dullahan,
}
}
}
pub const ALL_SPECIES: [Species; 4] = [
pub const ALL_SPECIES: [Species; 5] = [
Species::Ogre,
Species::Cyclops,
Species::Wendigo,
Species::Troll,
Species::Dullahan,
];
impl<'a, SpeciesMeta: 'a> IntoIterator for &'a AllSpecies<SpeciesMeta> {

View File

@ -141,42 +141,49 @@ impl<'a> From<&'a comp::biped_large::Body> for SkeletonAttr {
(Cyclops, _) => (4.5, 7.5),
(Wendigo, _) => (3.0, 13.5),
(Troll, _) => (6.0, 10.0),
(Dullahan, _) => (3.0, 6.0),
},
upper_torso: match (body.species, body.body_type) {
(Ogre, _) => (0.0, 19.0),
(Cyclops, _) => (-2.0, 27.0),
(Wendigo, _) => (-1.0, 29.0),
(Troll, _) => (-1.0, 27.5),
(Dullahan, _) => (0.0, 29.0),
},
lower_torso: match (body.species, body.body_type) {
(Ogre, _) => (1.0, -5.5),
(Cyclops, _) => (1.0, -4.5),
(Wendigo, _) => (-1.5, -6.0),
(Troll, _) => (1.0, -10.5),
(Dullahan, _) => (0.0, -6.5),
},
shoulder: match (body.species, body.body_type) {
(Ogre, _) => (6.1, 0.5, 2.5),
(Cyclops, _) => (9.5, 2.5, 2.5),
(Wendigo, _) => (9.0, 0.5, -0.5),
(Troll, _) => (11.0, 0.5, -2.5),
(Dullahan, _) => (14.0, 0.5, 4.5),
},
hand: match (body.species, body.body_type) {
(Ogre, _) => (10.5, -1.0, -0.5),
(Cyclops, _) => (10.0, 2.0, -0.5),
(Wendigo, _) => (12.0, 0.0, -0.5),
(Troll, _) => (11.5, 0.0, -1.5),
(Dullahan, _) => (14.5, 0.0, -2.5),
},
leg: match (body.species, body.body_type) {
(Ogre, _) => (0.0, 0.0, 0.0),
(Cyclops, _) => (0.0, 0.0, -5.0),
(Wendigo, _) => (2.0, 2.0, -2.5),
(Troll, _) => (5.0, 0.0, -6.0),
(Dullahan, _) => (0.0, 0.0, -5.0),
},
foot: match (body.species, body.body_type) {
(Ogre, _) => (4.0, 2.5, 2.5),
(Cyclops, _) => (4.0, 0.5, 5.0),
(Wendigo, _) => (5.0, 0.5, 6.0),
(Troll, _) => (6.0, 0.5, 4.0),
(Dullahan, _) => (4.0, 2.5, 8.0),
},
}
}

View File

@ -21,6 +21,8 @@ impl Animation for JumpAnimation {
) -> Self::Skeleton {
let mut next = (*skeleton).clone();
let wave = (_anim_time as f32 * 1.0).sin();
next.head.offset = Vec3::new(0.0, skeleton_attr.head.0, skeleton_attr.head.1);
next.head.ori = Quaternion::rotation_z(0.8) * Quaternion::rotation_x(0.5);
next.head.scale = Vec3::one();
@ -30,11 +32,11 @@ impl Animation for JumpAnimation {
next.chest.scale = Vec3::one() / 18.0;
next.feet_f.offset = Vec3::new(0.0, skeleton_attr.feet_f.0, skeleton_attr.feet_f.1);
next.feet_f.ori = Quaternion::rotation_z(0.0);
next.feet_f.ori = Quaternion::rotation_x(wave * 0.4);
next.feet_f.scale = Vec3::one();
next.feet_b.offset = Vec3::new(0.0, skeleton_attr.feet_b.0, skeleton_attr.feet_b.1);
next.feet_b.ori = Quaternion::rotation_x(0.0);
next.feet_b.ori = Quaternion::rotation_x(wave * 0.4);
next.feet_b.scale = Vec3::one();
next.tail.offset = Vec3::new(0.0, skeleton_attr.tail.0, skeleton_attr.tail.1);

View File

@ -22,8 +22,8 @@ impl Animation for RunAnimation {
) -> Self::Skeleton {
let mut next = (*skeleton).clone();
let wave = (anim_time as f32 * 13.0).sin();
let wave_cos = (anim_time as f32 * 13.0).sin();
let wave = (anim_time as f32 * 8.0).sin();
let wavealt = (anim_time as f32 * 8.0 + PI / 2.0).sin();
let wave_slow = (anim_time as f32 * 6.5 + PI).sin();
next.head.offset = Vec3::new(0.0, skeleton_attr.head.0, skeleton_attr.head.1);
@ -35,15 +35,17 @@ impl Animation for RunAnimation {
skeleton_attr.chest.0 + wave * 1.0,
skeleton_attr.chest.1,
) / 18.0;
next.chest.ori = Quaternion::rotation_y(0.0);
next.chest.ori = Quaternion::rotation_x(wave * 0.1);
next.chest.scale = Vec3::one() / 18.0;
next.feet_f.offset = Vec3::new(0.0, skeleton_attr.feet_f.0, skeleton_attr.feet_f.1);
next.feet_f.ori = Quaternion::rotation_x(wave * 1.0);
next.feet_f.ori =
Quaternion::rotation_x(wave * 0.8) * Quaternion::rotation_z(wavealt / 6.0);
next.feet_f.scale = Vec3::one();
next.feet_b.offset = Vec3::new(0.0, skeleton_attr.feet_b.0, skeleton_attr.feet_b.1);
next.feet_b.ori = Quaternion::rotation_x(wave_cos * 1.0);
next.feet_b.ori =
Quaternion::rotation_x(wavealt * 0.8) * Quaternion::rotation_z(wavealt / 6.0);
next.feet_b.scale = Vec3::one();
next.tail.offset = Vec3::new(0.0, skeleton_attr.tail.0 + wave * 1.0, skeleton_attr.tail.1);