minotaur moves, added claygolem

This commit is contained in:
jshipsey 2021-02-22 01:04:45 -05:00
parent 417f4638ed
commit 16a44cd532
47 changed files with 477 additions and 144 deletions

View File

@ -0,0 +1,19 @@
DashMelee(
energy_cost: 0,
base_damage: 80,
scaled_damage: 160,
base_poise_damage: 0,
scaled_poise_damage: 0,
base_knockback: 8.0,
scaled_knockback: 7.0,
range: 3.0,
angle: 15.0,
energy_drain: 0,
forward_speed: 3.0,
buildup_duration: 0.5,
charge_duration: 3.0,
swing_duration: 0.35,
recover_duration: 1.2,
infinite_charge: true,
is_interruptible: true,
)

View File

@ -0,0 +1,39 @@
ComboMelee(
stage_data: [
(
stage: 1,
base_damage: 90,
damage_increase: 10,
base_poise_damage: 0,
poise_damage_increase: 0,
knockback: 4.0,
range: 3.5,
angle: 50.0,
base_buildup_duration: 0.6,
base_swing_duration: 0.12,
base_recover_duration: 0.6,
forward_movement: 3.5,
),
(
stage: 2,
base_damage: 130,
damage_increase: 15,
base_poise_damage: 0,
poise_damage_increase: 0,
knockback: 16.0,
range: 5.5,
angle: 15.0,
base_buildup_duration: 0.5,
base_swing_duration: 0.15,
base_recover_duration: 1.2,
forward_movement: 4.5,
),
],
initial_energy_gain: 0,
max_energy_gain: 0,
energy_increase: 0,
speed_increase: 0.0,
max_speed_increase: 0.0,
scales_from_combo: 0,
is_interruptible: false,
)

View File

@ -11,7 +11,7 @@ DashMelee(
energy_drain: 0,
forward_speed: 2.0,
buildup_duration: 0.5,
charge_duration: 0.6,
charge_duration: 1.0,
swing_duration: 0.1,
recover_duration: 0.5,
infinite_charge: true,

View File

@ -1,6 +1,6 @@
BasicBeam(
buildup_duration: 0.25,
recover_duration: 0.25,
buildup_duration: 0.5,
recover_duration: 0.5,
beam_duration: 1.0,
base_hps: 0,
base_dps: 150,

View File

@ -39,7 +39,11 @@
primary: "common.abilities.hammersimple.doublestrike",
secondary: "common.abilities.hammersimple.doublestrike",
abilities: [],
),
AxeSimple: (
primary: "common.abilities.axesimple.doublestrike",
secondary: "common.abilities.axesimple.dash",
abilities: [],
),
SwordSimple: (
primary: "common.abilities.swordsimple.doublestrike",

View File

@ -0,0 +1,18 @@
ItemDef(
name: "Minotaur Axe",
description: "Placeholder",
kind: Tool(
(
kind: AxeSimple,
hands: Two,
stats: (
equip_time_millis: 500,
power: 1.8,
poise_strength: 1.00,
speed: 1.0
),
)
),
quality: Low,
tags: [],
)

View File

@ -6,7 +6,7 @@ ItemDef(
kind: StaffSimple,
hands: Two,
stats: Direct((
equip_time_millis: 300,
equip_time_millis: 1,
power: 3.0,
poise_strength: 1.00,
speed: 1.5,

View File

@ -871,6 +871,10 @@
treant: (
keyword: "treant",
generic: "Treant"
),
claygolem: (
keyword: "claygolem",
generic: "ClayGolem"
)
)
),

View File

@ -754,6 +754,10 @@
vox_spec: ("armor.empty", (0.0, 0.0, 0.0)),
color: None
),
"common.items.npc_weapons.axe.minotaur_axe": (
vox_spec: ("weapon.axe.minotaur_axe", (-2.5, -9.0, -6.0)),
color: None
),
//BIPEDSMALL
"common.items.npc_weapons.biped_small.gnarling.wooden_spear": (
vox_spec: ("weapon.spear.sahagin", (-1.5, -3.0, -5.0)),

View File

@ -71,4 +71,40 @@
central: ("npc.treant.male.chest_lower"),
),
),
(ClayGolem, Male): (
head: (
offset: (-10.5, -6.0, -5.0),
central: ("npc.claygolem.male.head"),
),
jaw: (
offset: (-9.5, 0.0, -3.0),
central: ("armor.empty"),
),
torso_upper: (
offset: (-9.5, -7.0, -6.5),
central: ("npc.claygolem.male.chest_upper"),
),
torso_lower: (
offset: (-9.5, -7.0, -8.0),
central: ("npc.claygolem.male.chest_lower"),
),
),
(ClayGolem, Female): (
head: (
offset: (-10.5, -6.0, -5.0),
central: ("npc.claygolem.male.head"),
),
jaw: (
offset: (-9.5, 0.0, -3.0),
central: ("armor.empty"),
),
torso_upper: (
offset: (-9.5, -7.0, -6.5),
central: ("npc.claygolem.male.chest_upper"),
),
torso_lower: (
offset: (-9.5, -7.0, -8.0),
central: ("npc.claygolem.male.chest_lower"),
),
),
})

View File

@ -135,4 +135,72 @@
lateral: ("npc.treant.male.foot_r"),
)
),
(ClayGolem, Male): (
shoulder_l: (
offset: (-13.0, -3.5, -6.5),
lateral: ("npc.claygolem.male.shoulder_l"),
),
shoulder_r: (
offset: (0.0, -3.5, -6.5),
lateral: ("npc.claygolem.male.shoulder_r"),
),
hand_l: (
offset: (-7.5, -6.5, -17.0),
lateral: ("npc.claygolem.male.hand_l"),
),
hand_r: (
offset: (-7.5, -6.5, -17.0),
lateral: ("npc.claygolem.male.hand_r"),
),
leg_l: (
offset: (-8.0, -4.0, -10.0),
lateral: ("npc.claygolem.male.leg_l"),
),
leg_r: (
offset: (0.0, -4.0, -10.0),
lateral: ("npc.claygolem.male.leg_r"),
),
foot_l: (
offset: (-2.5, -3.0, -7.0),
lateral: ("npc.claygolem.male.foot_l"),
),
foot_r: (
offset: (-2.5, -3.0, -7.0),
lateral: ("npc.claygolem.male.foot_r"),
)
),
(ClayGolem, Female): (
shoulder_l: (
offset: (-13.0, -3.5, -6.5),
lateral: ("npc.claygolem.male.shoulder_l"),
),
shoulder_r: (
offset: (0.0, -3.5, -6.5),
lateral: ("npc.claygolem.male.shoulder_r"),
),
hand_l: (
offset: (-7.5, -6.5, -17.0),
lateral: ("npc.claygolem.male.hand_l"),
),
hand_r: (
offset: (-7.5, -6.5, -17.0),
lateral: ("npc.claygolem.male.hand_r"),
),
leg_l: (
offset: (-8.0, -4.0, -10.0),
lateral: ("npc.claygolem.male.leg_l"),
),
leg_r: (
offset: (0.0, -4.0, -10.0),
lateral: ("npc.claygolem.male.leg_r"),
),
foot_l: (
offset: (-2.5, -3.0, -7.0),
lateral: ("npc.claygolem.male.foot_l"),
),
foot_r: (
offset: (-2.5, -3.0, -7.0),
lateral: ("npc.claygolem.male.foot_r"),
)
),
})

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

Binary file not shown.

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

Binary file not shown.

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

Binary file not shown.

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

Binary file not shown.

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

Binary file not shown.

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

Binary file not shown.

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

Binary file not shown.

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

Binary file not shown.

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

Binary file not shown.

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

Binary file not shown.

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

Binary file not shown.

Binary file not shown.

BIN
assets/voxygen/voxel/weapon/axe/minotaur_axe.vox (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -368,6 +368,7 @@ impl Body {
biped_large::Species::Mindflayer => 8000,
biped_large::Species::Tidalwarrior => 2500,
biped_large::Species::Yeti => 2000,
biped_large::Species::Minotaur => 5000,
_ => 1000,
},
Body::BipedSmall(biped_small) => match biped_small.species {
@ -383,7 +384,12 @@ impl Body {
object::Body::Crossbow => 800,
_ => 10000,
},
<<<<<<< HEAD
Body::Golem(_) => 2740,
=======
Body::Object(_) => 10000,
Body::Golem(_) => 3000,
>>>>>>> minotaur moves, added claygolem
Body::Theropod(theropod) => match theropod.species {
theropod::Species::Archaeos => 3000,
theropod::Species::Odonto => 2700,

View File

@ -36,6 +36,7 @@ make_case_elim!(
pub enum Species {
StoneGolem = 0,
Treant = 1,
ClayGolem = 2,
}
);
@ -46,6 +47,7 @@ make_case_elim!(
pub struct AllSpecies<SpeciesMeta> {
pub stonegolem: SpeciesMeta,
pub treant: SpeciesMeta,
pub claygolem: SpeciesMeta,
}
impl<'a, SpeciesMeta> core::ops::Index<&'a Species> for AllSpecies<SpeciesMeta> {
@ -56,11 +58,12 @@ impl<'a, SpeciesMeta> core::ops::Index<&'a Species> for AllSpecies<SpeciesMeta>
match index {
Species::StoneGolem => &self.stonegolem,
Species::Treant => &self.treant,
Species::ClayGolem => &self.claygolem,
}
}
}
pub const ALL_SPECIES: [Species; 2] = [Species::StoneGolem, Species::Treant];
pub const ALL_SPECIES: [Species; 3] = [Species::StoneGolem, Species::Treant, Species::ClayGolem];
impl<'a, SpeciesMeta: 'a> IntoIterator for &'a AllSpecies<SpeciesMeta> {
type IntoIter = std::iter::Copied<std::slice::Iter<'static, Self::Item>>;

View File

@ -22,6 +22,7 @@ pub enum ToolKind {
SwordSimple,
StaffSimple,
BowSimple,
AxeSimple,
Bow,
Dagger,
Staff,

View File

@ -88,6 +88,11 @@ impl LoadoutBuilder {
"common.items.npc_weapons.unique.stone_golems_fist",
));
},
golem::Species::ClayGolem => {
main_tool = Some(Item::new_from_asset_expect(
"common.items.npc_weapons.unique.stone_golems_fist",
));
},
_ => {},
},
Body::QuadrupedMedium(quadruped_medium) => match quadruped_medium.species {
@ -243,7 +248,7 @@ impl LoadoutBuilder {
},
(biped_large::Species::Minotaur, _) => {
main_tool = Some(Item::new_from_asset_expect(
"common.items.npc_weapons.hammer.cyclops_hammer",
"common.items.npc_weapons.axe.minotaur_axe",
));
},
(biped_large::Species::Tidalwarrior, _) => {

View File

@ -136,7 +136,7 @@ impl Body {
Body::Dragon(_) => 5.0,
Body::BirdSmall(_) => 35.0,
Body::FishSmall(_) => 10.0,
Body::BipedLarge(_) => 12.0,
Body::BipedLarge(_) => 8.0,
Body::BipedSmall(_) => 12.0,
Body::Object(_) => 10.0,
Body::Golem(_) => 8.0,

View File

@ -145,6 +145,7 @@ pub fn skill_to_db_string(skill: comp::skills::Skill) -> String {
| UnlockGroup(SkillGroupKind::Weapon(ToolKind::HammerSimple))
| UnlockGroup(SkillGroupKind::Weapon(ToolKind::StaffSimple))
| UnlockGroup(SkillGroupKind::Weapon(ToolKind::BowSimple))
| UnlockGroup(SkillGroupKind::Weapon(ToolKind::AxeSimple))
| UnlockGroup(SkillGroupKind::Weapon(ToolKind::SwordSimple))
| UnlockGroup(SkillGroupKind::Weapon(ToolKind::Debug))
| UnlockGroup(SkillGroupKind::Weapon(ToolKind::Farming))
@ -285,6 +286,7 @@ pub fn skill_group_to_db_string(skill_group: comp::skills::SkillGroupKind) -> St
| Weapon(ToolKind::HammerSimple)
| Weapon(ToolKind::StaffSimple)
| Weapon(ToolKind::BowSimple)
| Weapon(ToolKind::AxeSimple)
| Weapon(ToolKind::SwordSimple)
| Weapon(ToolKind::Debug)
| Weapon(ToolKind::Farming)

View File

@ -502,6 +502,7 @@ impl<'a> System<'a> for Sys {
Some(ToolKind::Sword) => Tactic::Sword,
Some(ToolKind::Spear) => Tactic::Sword,
Some(ToolKind::SwordSimple) => Tactic::Sword,
Some(ToolKind::AxeSimple) => Tactic::Sword,
Some(ToolKind::Axe) => Tactic::Axe,
Some(ToolKind::Unique(UniqueKind::StoneGolemFist)) => {
Tactic::StoneGolemBoss

View File

@ -134,6 +134,31 @@ impl Animation for AlphaAnimation {
* Quaternion::rotation_y(-1.8 + move1 * -0.8 + move2 * 3.0)
* Quaternion::rotation_z(move1 * -0.8 + move2 * -0.8);
},
Some(ToolKind::AxeSimple) => {
next.control_l.position = Vec3::new(-1.0, 2.0, 12.0 + move2 * -10.0);
next.control_r.position = Vec3::new(1.0, 2.0, -2.0);
next.control.position = Vec3::new(
4.0 + move1 * -12.0 + move2 * 28.0,
(s_a.grip / 1.0) + move1 * -3.0 + move2 * -5.0,
(-s_a.grip / 0.8) + move1 * 2.0 + move2 * 8.0,
);
next.head.orientation = Quaternion::rotation_x(move1 * -0.25)
* Quaternion::rotation_z(move1 * -0.2 + move2 * 0.6);
next.upper_torso.orientation = Quaternion::rotation_z(move1 * 0.6 + move2 * -0.9);
next.lower_torso.orientation = Quaternion::rotation_z(move1 * -0.6 + move2 * 0.9);
next.control_l.orientation =
Quaternion::rotation_x(PI / 2.0 + move2 * 0.8) * Quaternion::rotation_y(-0.0);
next.control_r.orientation = Quaternion::rotation_x(PI / 2.0 + 0.2 + move2 * 0.8)
* Quaternion::rotation_y(0.0)
* Quaternion::rotation_z(0.0);
next.control.orientation =
Quaternion::rotation_x(-1.0 + move1 * -0.5 + move2 * -0.3)
* Quaternion::rotation_y(-1.8 + move1 * -0.4 + move2 * 3.5)
* Quaternion::rotation_z(move1 * -1.0 + move2 * -1.5);
},
Some(ToolKind::Unique(UniqueKind::WendigoMagic)) => {
next.torso.position = Vec3::new(0.0, 0.0, move1 * -0.3);
next.upper_torso.orientation = Quaternion::rotation_x(move1 * -0.5 + move2 * -0.4);

View File

@ -12,8 +12,9 @@ impl Animation for BeamAnimation {
Option<ToolKind>,
Option<ToolKind>,
f64,
f32,
Vec3<f32>,
Option<StageSection>,
f32,
);
type Skeleton = BipedLargeSkeleton;
@ -24,7 +25,7 @@ impl Animation for BeamAnimation {
#[allow(clippy::single_match)] // TODO: Pending review in #587
fn update_skeleton_inner(
skeleton: &Self::Skeleton,
(active_tool_kind, _second_tool_kind, _global_time, velocity, stage_section): Self::Dependency,
(active_tool_kind, _second_tool_kind, _global_time, velocity, stage_section, acc_vel): Self::Dependency,
anim_time: f64,
rate: &mut f32,
s_a: &SkeletonAttr,
@ -32,95 +33,89 @@ impl Animation for BeamAnimation {
*rate = 1.0;
let mut next = (*skeleton).clone();
let (movement1, movement2, movement3) = match stage_section {
Some(StageSection::Buildup) => (anim_time as f32, 0.0, 0.0),
Some(StageSection::Cast) => (1.0, anim_time as f32, 0.0),
Some(StageSection::Recover) => (1.0, 1.0, anim_time as f32),
_ => (0.0, 0.0, 0.0),
};
let speed = Vec2::<f32>::from(velocity).magnitude();
let lab = 0.65 * s_a.tempo;
let speednorm = (speed / 12.0).powf(0.4);
let foothoril = (acc_vel * lab as f32 + PI * 1.45).sin() * speednorm;
let foothorir = (acc_vel * lab as f32 + PI * (0.45)).sin() * speednorm;
let footrotl =
(((1.0) / (0.5 + (0.5) * ((acc_vel * lab as f32 + PI * 1.4).sin()).powi(2))).sqrt())
* ((acc_vel * lab as f32 + PI * 1.4).sin())
* speednorm;
let footrotr =
(((1.0) / (0.5 + (0.5) * ((acc_vel * lab as f32 + PI * 0.4).sin()).powi(2))).sqrt())
* ((acc_vel * lab as f32 + PI * 0.4).sin())
* speednorm;
next.jaw.position = Vec3::new(0.0, s_a.jaw.0, s_a.jaw.1);
next.jaw.orientation = Quaternion::rotation_x(0.0);
next.hand_l.position = Vec3::new(s_a.sthl.0, s_a.sthl.1, s_a.sthl.2);
next.hand_l.orientation =
Quaternion::rotation_x(s_a.sthl.3) * Quaternion::rotation_y(s_a.sthl.4);
next.hand_r.position = Vec3::new(s_a.sthr.0, s_a.sthr.1, s_a.sthl.2);
next.hand_r.orientation =
Quaternion::rotation_x(s_a.sthr.3) * Quaternion::rotation_y(s_a.sthr.4);
next.main.position = Vec3::new(0.0, 0.0, 0.0);
next.main.orientation = Quaternion::rotation_x(0.0);
next.control.position = Vec3::new(-4.0, 7.0, 4.0);
next.control.orientation = Quaternion::rotation_x(-0.3)
* Quaternion::rotation_y(0.15)
* Quaternion::rotation_z(0.0);
next.hand_l.position = Vec3::new(0.0, 0.0, s_a.grip);
next.hand_r.position = Vec3::new(0.0, 0.0, s_a.grip);
next.hand_l.orientation = Quaternion::rotation_x(0.0);
next.hand_r.orientation = Quaternion::rotation_x(0.0);
match active_tool_kind {
Some(ToolKind::Staff) | Some(ToolKind::Sceptre) => {
next.control.position = Vec3::new(
s_a.stc.0 + (movement1 * 26.0) * (1.0 - movement3),
s_a.stc.1 + (movement1 + (movement2 * 8.0).sin() * 2.0) * (1.0 - movement3),
s_a.stc.2 + (movement1 * 16.0) * (1.0 - movement3),
);
next.control.orientation =
Quaternion::rotation_x(s_a.stc.3 + (movement1 * -0.8) * (1.0 - movement3))
* Quaternion::rotation_y(
s_a.stc.4
+ (movement1 * -1.4 + (movement2 * 16.0).sin() * 0.07)
* (1.0 - movement3),
)
* Quaternion::rotation_z(
(movement1 * -1.7 + (movement2 * 8.0 + PI / 4.0).sin() * 0.3)
* (1.0 - movement3),
);
next.head.orientation = Quaternion::rotation_x(0.0);
next.hand_l.position = Vec3::new(
0.0 + (movement1 * -1.0 + (movement2 * 8.0).sin() * 3.5) * (1.0 - movement3),
0.0 + (movement1 * -8.0
+ (movement2 * 8.0).sin() * -2.0
+ (movement2 * 16.0).sin() * -1.5)
* (1.0 - movement3),
0.0 + (movement1 * 19.0 + (movement2 * 8.0 + PI / 2.0).sin() * 3.5)
* (1.0 - movement3),
);
next.hand_l.orientation =
Quaternion::rotation_x(s_a.sthr.3 + (movement1 * -0.3) * (1.0 - movement3))
* Quaternion::rotation_y(
(movement1 * -1.1 + (movement2 * 8.0 + PI / 2.0).sin() * -0.3)
* (1.0 - movement3),
)
* Quaternion::rotation_z((movement1 * -2.8) * (1.0 - movement3));
next.shoulder_l.orientation = Quaternion::rotation_z(0.2)
* Quaternion::rotation_x(
(movement1 * 0.6 + (movement2 * 8.0 + PI / 2.0).sin() * -0.1)
* (1.0 - movement3),
);
next.shoulder_r.orientation = Quaternion::rotation_z(-0.2)
* Quaternion::rotation_x(
(movement1 * 1.1 + (movement2 * 8.0 + PI / 2.0).sin() * -0.1)
* (1.0 - movement3),
);
if velocity < 0.5 {
next.head.orientation =
Quaternion::rotation_z(movement1 * -0.5 + (movement2 * 16.0).sin() * 0.05);
next.foot_l.position =
Vec3::new(-s_a.foot.0, s_a.foot.1 + movement1 * -3.0, s_a.foot.2);
next.foot_l.orientation = Quaternion::rotation_x(movement1 * -0.5)
* Quaternion::rotation_z(movement1 * 0.5);
next.foot_r.position =
Vec3::new(s_a.foot.0, s_a.foot.1 + movement1 * 4.0, s_a.foot.2);
next.foot_r.orientation = Quaternion::rotation_z(movement1 * 0.5);
next.upper_torso.orientation =
Quaternion::rotation_x(movement1 * -0.2 + (movement2 * 8.0).sin() * 0.01)
* Quaternion::rotation_z(movement1 * 0.1);
next.lower_torso.orientation = Quaternion::rotation_x(movement1 * 0.05)
* Quaternion::rotation_z(movement1 * -0.2);
} else {
Some(ToolKind::StaffSimple) | Some(ToolKind::Sceptre) => {
let (move1base, move2shake, _move2base, move3) = match stage_section {
Some(StageSection::Buildup) => (
((anim_time as f32).powf(0.25)).min(1.0),
(anim_time as f32 * 10.0 + PI).sin(),
(anim_time as f32 * 10.0 + PI).sin(),
0.0,
),
Some(StageSection::Cast) => (
1.0,
(anim_time as f32 * 10.0 + PI).sin(),
(anim_time as f32).powf(0.25),
0.0,
),
Some(StageSection::Recover) => (1.0, 1.0, 1.0, anim_time as f32),
_ => (0.0, 0.0, 0.0, 0.0),
};
let pullback = 1.0 - move3;
let move1 = move1base * pullback;
next.control_l.position = Vec3::new(-1.0, 3.0, 12.0);
next.control_r.position =
Vec3::new(1.0 + move1 * 5.0, 2.0 + move1 * 1.0, 2.0 + move1 * 8.0);
next.control.position = Vec3::new(
-3.0 + move1 * 5.0,
3.0 + s_a.grip / 1.2 + move1 * 5.0 + move2shake * 1.0,
-11.0 + -s_a.grip / 2.0 + move1 * -4.0,
);
next.head.orientation = Quaternion::rotation_x(move1 * -0.2);
next.jaw.orientation = Quaternion::rotation_x(0.0);
next.control_l.orientation =
Quaternion::rotation_x(PI / 2.0) * Quaternion::rotation_y(-0.5);
next.control_r.orientation = Quaternion::rotation_x(PI / 2.5 + move1 * 0.4)
* Quaternion::rotation_y(0.5)
* Quaternion::rotation_z(move1 * 1.2 + move2shake * 0.5);
next.control.orientation = Quaternion::rotation_x(-0.2 + move1 * -0.2)
* Quaternion::rotation_y(-0.1 + move1 * -0.4);
next.shoulder_l.position = Vec3::new(
-s_a.shoulder.0,
s_a.shoulder.1,
s_a.shoulder.2 - foothorir * 1.0,
);
next.shoulder_l.orientation =
Quaternion::rotation_x(move1 * 0.2 + 0.3 + 0.8 * speednorm + (footrotr * -0.2));
next.shoulder_r.position = Vec3::new(
s_a.shoulder.0,
s_a.shoulder.1,
s_a.shoulder.2 - foothoril * 1.0,
);
next.shoulder_r.orientation =
Quaternion::rotation_x(move1 * 0.2 + 0.3 + 0.6 * speednorm + (footrotl * -0.2));
next.torso.orientation = Quaternion::rotation_x(move1 * -0.1);
next.torso.position = Vec3::new(0.0, 0.0, move1 * 1.0);
},
_ => {},
}

View File

@ -50,7 +50,7 @@ impl Animation for BetaAnimation {
let (move1base, move2base, move3) = match stage_section {
Some(StageSection::Buildup) => ((anim_time as f32).powf(0.25), 0.0, 0.0),
Some(StageSection::Swing) => (1.0, anim_time as f32, 0.0),
Some(StageSection::Recover) => (1.0, 1.0, (anim_time as f32).powi(4)),
Some(StageSection::Recover) => (1.0, 1.0, (anim_time as f32).powi(6)),
_ => (0.0, 0.0, 0.0),
};
let pullback = 1.0 - move3;
@ -135,6 +135,31 @@ impl Animation for BetaAnimation {
* Quaternion::rotation_y(-1.8 + move1 * -0.8 + move2 * 3.0)
* Quaternion::rotation_z(move1 * -0.8 + move2 * -0.8);
},
Some(ToolKind::AxeSimple) => {
next.control_l.position = Vec3::new(-1.0, 2.0, 12.0 + move2 * -10.0);
next.control_r.position = Vec3::new(1.0, 2.0, -2.0);
next.control.position = Vec3::new(
4.0 + move1 * -18.0 + move2 * 20.0,
(s_a.grip / 1.0) + move1 * -3.0 + move2 * 12.0,
(-s_a.grip / 0.8) + move1 * -2.0 + move2 * 4.0,
);
next.head.orientation = Quaternion::rotation_x(move1 * -0.25)
* Quaternion::rotation_z(move1 * -0.9 + move2 * 0.6);
next.upper_torso.orientation = Quaternion::rotation_z(move1 * 1.2 + move2 * -1.0);
next.lower_torso.orientation = Quaternion::rotation_z(move1 * -1.2 + move2 * 1.0);
next.control_l.orientation =
Quaternion::rotation_x(PI / 2.0 + move2 * 0.8) * Quaternion::rotation_y(-0.0);
next.control_r.orientation = Quaternion::rotation_x(PI / 2.0 + 0.2 + move2 * 0.8)
* Quaternion::rotation_y(0.0)
* Quaternion::rotation_z(0.0);
next.control.orientation =
Quaternion::rotation_x(-1.0 + move1 * 0.0 + move2 * -0.8)
* Quaternion::rotation_y(-1.8 + move1 * 3.0 + move2 * -0.9)
* Quaternion::rotation_z(move1 * -0.2 + move2 * -1.5);
},
Some(ToolKind::Unique(UniqueKind::WendigoMagic)) => {
next.torso.position = Vec3::new(0.0, 0.0, move1 * -0.3);
next.upper_torso.orientation = Quaternion::rotation_x(move1 * -0.5 + move2 * -0.4);

View File

@ -25,7 +25,7 @@ impl Animation for DashAnimation {
#[allow(clippy::single_match)] // TODO: Pending review in #587
fn update_skeleton_inner(
skeleton: &Self::Skeleton,
(_active_tool_kind, _second_tool_kind, velocity, _global_time, stage_section, acc_vel): Self::Dependency,
(active_tool_kind, _second_tool_kind, velocity, _global_time, stage_section, acc_vel): Self::Dependency,
anim_time: f64,
rate: &mut f32,
s_a: &SkeletonAttr,
@ -57,7 +57,7 @@ impl Animation for DashAnimation {
let (move1base, move2base, move3base, move4) = match stage_section {
Some(StageSection::Buildup) => ((anim_time as f32).powf(0.25), 0.0, 0.0, 0.0),
Some(StageSection::Charge) => (1.0, ((anim_time as f32).powf(4.0)).min(1.0), 0.0, 0.0),
Some(StageSection::Swing) => (1.0, 1.0, anim_time as f32, 0.0),
Some(StageSection::Swing) => (1.0, 1.0, (anim_time as f32).powf(4.0), 0.0),
Some(StageSection::Recover) => (1.1, 1.0, 1.0, (anim_time as f32).powf(4.0)),
_ => (0.0, 0.0, 0.0, 0.0),
};
@ -82,30 +82,64 @@ impl Animation for DashAnimation {
next.shoulder_r.orientation =
Quaternion::rotation_x(0.6 * speednorm + (footrotl * -0.2) * speednorm);
next.torso.orientation = Quaternion::rotation_z(0.0);
match active_tool_kind {
Some(ToolKind::SwordSimple) => {
next.control_l.position = Vec3::new(-1.0, 1.0, 1.0);
next.control_r.position = Vec3::new(0.0, 2.0, -3.0);
next.head.orientation = Quaternion::rotation_x(move1 * -0.25)
* Quaternion::rotation_z(move1 * -0.2 + move2 * 0.6);
next.control.position = Vec3::new(
-3.0 + move1 * -2.0 + move2 * 2.0,
5.0 + s_a.grip / 1.2 + move1 * -4.0 + move2 * 2.0 + move3 * 8.0,
-4.0 + -s_a.grip / 2.0 + move2 * -5.0 + move3 * 5.0,
);
next.upper_torso.orientation = Quaternion::rotation_x(move2 * -0.2 + move3 * 0.2)
* Quaternion::rotation_z(move1 * 0.8 + move3 * -0.7);
next.lower_torso.orientation = Quaternion::rotation_x(move2 * 0.2 + move3 * -0.2)
* Quaternion::rotation_z(move1 * -0.8 + move3 * 0.7);
next.control_l.orientation =
Quaternion::rotation_x(PI / 2.0 + move1 * -0.5 + move2 * 1.5)
* Quaternion::rotation_y(-0.2);
next.control_r.orientation =
Quaternion::rotation_x(PI / 2.2 + move1 * -0.5 + move2 * 1.5)
* Quaternion::rotation_y(0.2)
* Quaternion::rotation_z(0.0);
next.control_l.position = Vec3::new(-1.0, 1.0, 1.0);
next.control_r.position = Vec3::new(0.0, 2.0, -3.0);
next.head.orientation = Quaternion::rotation_x(move1 * -0.25)
* Quaternion::rotation_z(move1 * -0.2 + move2 * 0.6);
next.control.position = Vec3::new(
-3.0 + move1 * -2.0 + move2 * 2.0,
5.0 + s_a.grip / 1.2 + move1 * -4.0 + move2 * 2.0 + move3 * 8.0,
-4.0 + -s_a.grip / 2.0 + move2 * -5.0 + move3 * 5.0,
);
next.upper_torso.orientation = Quaternion::rotation_x(move2 * -0.2 + move3 * 0.2)
* Quaternion::rotation_z(move1 * 0.8 + move3 * -0.7);
next.lower_torso.orientation = Quaternion::rotation_x(move2 * 0.2 + move3 * -0.2)
* Quaternion::rotation_z(move1 * -0.8 + move3 * 0.7);
next.control_l.orientation = Quaternion::rotation_x(PI / 2.0 + move1 * -0.5 + move2 * 1.5)
* Quaternion::rotation_y(-0.2);
next.control_r.orientation = Quaternion::rotation_x(PI / 2.2 + move1 * -0.5 + move2 * 1.5)
* Quaternion::rotation_y(0.2)
* Quaternion::rotation_z(0.0);
next.control.orientation =
Quaternion::rotation_x(-0.2 + move1 * 0.5 + move2 * -1.5 + move3 * -0.2)
* Quaternion::rotation_y(-0.1 + move1 * -0.5 + move2 * 1.5 + move3 * -1.0)
* Quaternion::rotation_z(-move3 * -1.5);
},
Some(ToolKind::AxeSimple) => {
next.control_l.position = Vec3::new(-1.0, 2.0, 12.0 + move3 * -10.0);
next.control_r.position = Vec3::new(1.0, 2.0, -2.0);
next.control.orientation =
Quaternion::rotation_x(-0.2 + move1 * 0.5 + move2 * -1.5 + move3 * -0.2)
* Quaternion::rotation_y(-0.1 + move1 * -0.5 + move2 * 1.5 + move3 * -1.0)
* Quaternion::rotation_z(-move3 * -1.5);
next.control.position = Vec3::new(
4.0 + move1 * -3.0 + move3 * -8.0,
(s_a.grip / 1.0) + move1 * -1.0 + move3 * 12.0,
(-s_a.grip / 0.8) + move1 * 2.0 + move3 * -6.0,
);
next.head.orientation = Quaternion::rotation_x(move1 * -0.5 + move3 * 0.5)
* Quaternion::rotation_z(move1 * 0.3 + move3 * 0.3);
next.upper_torso.orientation = Quaternion::rotation_x(move1 * -0.4 + move3 * 0.9)
* Quaternion::rotation_z(move1 * 0.6 + move3 * -1.5);
next.lower_torso.orientation = Quaternion::rotation_y(move1 * -0.2 + move3 * -0.1)
* Quaternion::rotation_x(move1 * 0.4 + move3 * -0.7)
* Quaternion::rotation_z(move1 * -0.6 + move3 * 1.6);
next.control_l.orientation = Quaternion::rotation_x(PI / 2.0 + move3 * 0.8)
* Quaternion::rotation_y(move1 * 0.7);
next.control_r.orientation = Quaternion::rotation_x(PI / 2.0 + 0.2 + move3 * 0.8)
* Quaternion::rotation_y(0.0)
* Quaternion::rotation_z(0.0);
next.control.orientation =
Quaternion::rotation_x(-1.0 + move1 * -0.2 + move3 * -1.1)
* Quaternion::rotation_y(-1.8 + move1 * -0.2 + move3 * 1.5)
* Quaternion::rotation_z(move1 * -0.8 + move3 * -1.5);
},
_ => {},
}
next
}

View File

@ -103,7 +103,7 @@ impl Animation for IdleAnimation {
next.main.position = Vec3::new(-10.0, -8.0, 12.0);
next.main.orientation = Quaternion::rotation_y(2.5) * Quaternion::rotation_z(1.57);
},
Some(ToolKind::HammerSimple) => {
Some(ToolKind::HammerSimple) | Some(ToolKind::AxeSimple) => {
next.main.position = Vec3::new(-10.0, -8.0, 12.0);
next.main.orientation = Quaternion::rotation_y(2.5) * Quaternion::rotation_z(1.57);
},

View File

@ -72,7 +72,7 @@ impl Animation for JumpAnimation {
next.main.position = Vec3::new(-10.0, -8.0, 12.0);
next.main.orientation = Quaternion::rotation_y(2.5) * Quaternion::rotation_z(1.57);
},
Some(ToolKind::HammerSimple) => {
Some(ToolKind::HammerSimple) | Some(ToolKind::AxeSimple) => {
next.main.position = Vec3::new(-10.0, -8.0, 12.0);
next.main.orientation = Quaternion::rotation_y(2.5) * Quaternion::rotation_z(1.57);
},

View File

@ -193,7 +193,7 @@ impl<'a> From<&'a Body> for SkeletonAttr {
use comp::biped_large::{BodyType::*, Species::*};
Self {
head: match (body.species, body.body_type) {
(Ogre, Male) => (3.0, 9.0),
(Ogre, Male) => (5.0, 6.0),
(Ogre, Female) => (1.0, 7.5),
(Cyclops, _) => (4.5, 7.5),
(Wendigo, _) => (3.0, 7.5),

View File

@ -309,7 +309,7 @@ impl Animation for RunAnimation {
next.main.orientation =
Quaternion::rotation_y(2.5) * Quaternion::rotation_z(1.57);
},
Some(ToolKind::HammerSimple) => {
Some(ToolKind::HammerSimple) | Some(ToolKind::AxeSimple) => {
next.main.position = Vec3::new(-10.0, -8.0, 12.0);
next.main.orientation =
Quaternion::rotation_y(2.5) * Quaternion::rotation_z(1.57);
@ -327,7 +327,7 @@ impl Animation for RunAnimation {
s_a.shoulder.2 - foothorir * 1.5,
);
next.shoulder_l.orientation =
Quaternion::rotation_x(0.6 * speednorm + (footrotr * -0.8) * speednorm)
Quaternion::rotation_x(0.6 * speednormlow + (footrotr * -0.8) * speednorm)
* Quaternion::rotation_y(0.0)
* Quaternion::rotation_z(0.0);
@ -337,7 +337,7 @@ impl Animation for RunAnimation {
s_a.shoulder.2 - foothoril * 1.5,
);
next.shoulder_r.orientation =
Quaternion::rotation_x(0.6 * speednorm + (footrotl * -0.8) * speednorm)
Quaternion::rotation_x(0.6 * speednormlow + (footrotl * -0.8) * speednorm)
* Quaternion::rotation_y(0.0);
next.hand_l.position = Vec3::new(

View File

@ -55,11 +55,13 @@ impl Animation for ShootAnimation {
let foothorir = (acc_vel * lab as f32 + PI * (0.45)).sin() * speednorm;
let footrotl =
(((1.0) / (0.5 + (0.5) * ((acc_vel * lab as f32 + PI * 1.4).sin()).powi(2))).sqrt())
* ((acc_vel * lab as f32 + PI * 1.4).sin());
* ((acc_vel * lab as f32 + PI * 1.4).sin())
* speednorm;
let footrotr =
(((1.0) / (0.5 + (0.5) * ((acc_vel * lab as f32 + PI * 0.4).sin()).powi(2))).sqrt())
* ((acc_vel * lab as f32 + PI * 0.4).sin());
* ((acc_vel * lab as f32 + PI * 0.4).sin())
* speednorm;
next.shoulder_l.position = Vec3::new(
-s_a.shoulder.0,
@ -139,9 +141,8 @@ impl Animation for ShootAnimation {
s_a.shoulder.1,
s_a.shoulder.2 - foothoril * 1.0,
);
next.shoulder_r.orientation = Quaternion::rotation_x(
move1 * 0.8 + 0.6 * speednorm + (footrotl * -0.2) * speednorm,
);
next.shoulder_r.orientation =
Quaternion::rotation_x(move1 * 0.8 + 0.6 * speednorm + (footrotl * -0.2));
},
Some(ToolKind::BowSimple) => {
let (move1base, move2base, move3) = match stage_section {
@ -177,18 +178,16 @@ impl Animation for ShootAnimation {
s_a.shoulder.1,
s_a.shoulder.2 - foothorir * 1.0,
);
next.shoulder_l.orientation = Quaternion::rotation_x(
move1 * 0.8 + 1.2 * speednorm + (footrotr * -0.2) * speednorm,
);
next.shoulder_l.orientation =
Quaternion::rotation_x(move1 * 0.8 + 1.2 * speednorm + (footrotr * -0.2));
next.shoulder_r.position = Vec3::new(
s_a.shoulder.0,
s_a.shoulder.1,
s_a.shoulder.2 - foothoril * 1.0,
);
next.shoulder_r.orientation = Quaternion::rotation_x(
move1 * 0.8 + 1.2 * speednorm + (footrotl * -0.2) * speednorm,
);
next.shoulder_r.orientation =
Quaternion::rotation_x(move1 * 0.8 + 1.2 * speednorm + (footrotl * -0.2));
},
Some(ToolKind::Unique(UniqueKind::WendigoMagic)) => {
let (move1base, _move2base, move3) = match stage_section {

View File

@ -196,7 +196,7 @@ impl Animation for WieldAnimation {
* Quaternion::rotation_y(1.0)
* Quaternion::rotation_z(-0.3);
},
Some(ToolKind::HammerSimple) => {
Some(ToolKind::HammerSimple) | Some(ToolKind::AxeSimple) => {
next.control_l.position = Vec3::new(-1.0, 2.0, 12.0);
next.control_r.position = Vec3::new(1.0, 2.0, -2.0);

View File

@ -42,7 +42,7 @@ impl Animation for AlphaAnimation {
next.torso.position = Vec3::new(0.0, 0.0, 0.1) * s_a.scaler;
next.torso.orientation = Quaternion::rotation_z(0.0);
match active_tool_kind {
Some(ToolKind::Sword) => {
Some(ToolKind::Sword) | Some(ToolKind::SwordSimple) => {
next.main.position = Vec3::new(0.0, 0.0, 0.0);
next.main.orientation = Quaternion::rotation_x(0.0);
@ -116,7 +116,7 @@ impl Animation for AlphaAnimation {
next.head.orientation =
Quaternion::rotation_z(0.0 + move1 * -1.5 + move2 * 2.5 + move3 * -1.0);
},
Some(ToolKind::Hammer) => {
Some(ToolKind::Hammer) | Some(ToolKind::HammerSimple) => {
let (move1, move2, move3) = match stage_section {
Some(StageSection::Buildup) => ((anim_time as f32).powf(0.25), 0.0, 0.0),
Some(StageSection::Swing) => (1.0, anim_time as f32, 0.0),

View File

@ -143,7 +143,7 @@ impl Animation for WieldAnimation {
next.shorts.position = Vec3::new(0.0, s_a.shorts.0, s_a.shorts.1);
}
match active_tool_kind {
Some(ToolKind::Sword) => {
Some(ToolKind::Sword) | Some(ToolKind::SwordSimple) => {
next.main.position = Vec3::new(0.0, 0.0, 0.0);
next.main.orientation = Quaternion::rotation_x(0.0);

View File

@ -120,42 +120,52 @@ impl<'a> From<&'a Body> for SkeletonAttr {
head: match (body.species, body.body_type) {
(StoneGolem, _) => (0.0, 2.0),
(Treant, _) => (18.0, -8.0),
(ClayGolem, _) => (2.0, 9.0),
},
jaw: match (body.species, body.body_type) {
(StoneGolem, _) => (0.0, 0.0),
(Treant, _) => (-6.5, -1.0),
(ClayGolem, _) => (0.0, 0.0),
},
upper_torso: match (body.species, body.body_type) {
(StoneGolem, _) => (0.0, 34.5),
(Treant, _) => (0.0, 28.5),
(ClayGolem, _) => (0.0, 26.5),
},
lower_torso: match (body.species, body.body_type) {
(StoneGolem, _) => (0.0, -10.5),
(Treant, _) => (0.0, -10.5),
(ClayGolem, _) => (0.0, -4.5),
},
shoulder: match (body.species, body.body_type) {
(StoneGolem, _) => (8.0, -1.5, 4.0),
(Treant, _) => (8.0, 4.5, -3.0),
(ClayGolem, _) => (8.0, 4.5, 3.0),
},
hand: match (body.species, body.body_type) {
(StoneGolem, _) => (12.5, -1.0, -7.0),
(Treant, _) => (8.5, -1.0, -7.0),
(ClayGolem, _) => (8.5, -1.0, -7.0),
},
leg: match (body.species, body.body_type) {
(StoneGolem, _) => (4.0, 0.0, -3.5),
(Treant, _) => (2.0, 9.5, -1.0),
(ClayGolem, _) => (1.0, 0.5, -6.0),
},
foot: match (body.species, body.body_type) {
(StoneGolem, _) => (3.5, 0.5, -9.5),
(Treant, _) => (3.5, -5.0, -8.5),
(ClayGolem, _) => (3.5, -1.0, -8.5),
},
scaler: match (body.species, body.body_type) {
(StoneGolem, _) => 1.8,
(Treant, _) => 1.8,
(ClayGolem, _) => 1.8,
},
tempo: match (body.species, body.body_type) {
(StoneGolem, _) => 1.0,
(Treant, _) => 1.0,
(ClayGolem, _) => 1.0,
},
}
}

View File

@ -157,6 +157,7 @@ fn tool_desc(tool: &Tool, components: &[Item], msm: &MaterialStatManifest, desc:
ToolKind::HammerSimple => "HammerSimple",
ToolKind::SwordSimple => "SwordSimple",
ToolKind::StaffSimple => "StaffSimple",
ToolKind::AxeSimple => "AxeSimple",
ToolKind::BowSimple => "BowSimple",
ToolKind::Unique(_) => "Unique",
ToolKind::Debug => "Debug",

View File

@ -3653,8 +3653,9 @@ impl FigureMgr {
active_tool_kind,
second_tool_kind,
time,
vel.0.magnitude(),
vel.0,
Some(s.stage_section),
state.acc_vel,
),
stage_progress,
&mut state_animation_rate,

View File

@ -942,10 +942,10 @@ impl Floor {
.with_body(comp::Body::Golem(
comp::golem::Body::random_with(
dynamic_rng,
&comp::golem::Species::StoneGolem,
&comp::golem::Species::ClayGolem,
),
))
.with_name("Stonework Defender".to_string())
.with_name("Clay Golem".to_string())
.with_loot_drop(comp::Item::new_from_asset_expect(chosen)),
],
4 => vec![