mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
adlet tracker tweaks
This commit is contained in:
parent
f936c2f00e
commit
86803c43bf
@ -3,11 +3,14 @@ BasicRanged(
|
||||
buildup_duration: 0.75,
|
||||
recover_duration: 0.75,
|
||||
projectile: Trap(
|
||||
damage: 25,
|
||||
damage: 12,
|
||||
knockback: 0,
|
||||
energy_regen: 0,
|
||||
),
|
||||
projectile_body: Object(AdletTrap),
|
||||
projectile_light: None,
|
||||
projectile_speed: 10.0,
|
||||
num_projectiles: 1,
|
||||
projectile_spread: 0.0,
|
||||
move_efficiency: 0.3,
|
||||
)
|
||||
)
|
@ -1261,6 +1261,12 @@
|
||||
threshold: 0.2,
|
||||
subtitle: "subtitle-arrow_shot",
|
||||
),
|
||||
Yeet: (
|
||||
files: [
|
||||
"voxygen.audio.sfx.abilities.yeet",
|
||||
],
|
||||
threshold: 0.3,
|
||||
),
|
||||
FireShot: (
|
||||
files: [
|
||||
"voxygen.audio.sfx.abilities.fire_shot_1",
|
||||
@ -1283,6 +1289,18 @@
|
||||
threshold: 0.2,
|
||||
subtitle: "subtitle-arrow_hit",
|
||||
),
|
||||
Klonk: (
|
||||
files: [
|
||||
"voxygen.audio.sfx.abilities.klonk",
|
||||
],
|
||||
threshold: 0.4,
|
||||
),
|
||||
SmashKlonk: (
|
||||
files: [
|
||||
"voxygen.audio.sfx.abilities.smashklonk",
|
||||
],
|
||||
threshold: 0.4,
|
||||
),
|
||||
SkillPointGain: (
|
||||
files: [
|
||||
"voxygen.audio.sfx.character.level_up_sound_-_shorter_wind_up",
|
||||
|
BIN
assets/voxygen/audio/sfx/abilities/klonk.ogg
(Stored with Git LFS)
Normal file
BIN
assets/voxygen/audio/sfx/abilities/klonk.ogg
(Stored with Git LFS)
Normal file
Binary file not shown.
BIN
assets/voxygen/audio/sfx/abilities/smashklonk.ogg
(Stored with Git LFS)
Normal file
BIN
assets/voxygen/audio/sfx/abilities/smashklonk.ogg
(Stored with Git LFS)
Normal file
Binary file not shown.
BIN
assets/voxygen/audio/sfx/abilities/yeet.ogg
(Stored with Git LFS)
Normal file
BIN
assets/voxygen/audio/sfx/abilities/yeet.ogg
(Stored with Git LFS)
Normal file
Binary file not shown.
@ -127,6 +127,8 @@ pub enum ProjectileConstructor {
|
||||
},
|
||||
Trap {
|
||||
damage: f32,
|
||||
knockback: f32,
|
||||
energy_regen: f32,
|
||||
},
|
||||
}
|
||||
|
||||
@ -793,27 +795,57 @@ impl ProjectileConstructor {
|
||||
is_point: true,
|
||||
}
|
||||
},
|
||||
Trap { damage } => {
|
||||
let damage = AttackDamage::new(
|
||||
Trap {
|
||||
damage,
|
||||
knockback,
|
||||
energy_regen,
|
||||
} => {
|
||||
let knockback = AttackEffect::new(
|
||||
Some(GroupTarget::OutOfGroup),
|
||||
CombatEffect::Knockback(Knockback {
|
||||
strength: knockback,
|
||||
direction: KnockbackDir::Away,
|
||||
})
|
||||
.adjusted_by_stats(tool_stats),
|
||||
)
|
||||
.with_requirement(CombatRequirement::AnyDamage);
|
||||
let energy = AttackEffect::new(None, CombatEffect::EnergyReward(energy_regen))
|
||||
.with_requirement(CombatRequirement::AnyDamage);
|
||||
let buff = CombatEffect::Buff(CombatBuff {
|
||||
kind: BuffKind::Bleeding,
|
||||
dur_secs: 10.0,
|
||||
strength: CombatBuffStrength::DamageFraction(0.5),
|
||||
chance: 0.3,
|
||||
})
|
||||
.adjusted_by_stats(tool_stats);
|
||||
let mut damage = AttackDamage::new(
|
||||
Damage {
|
||||
source: DamageSource::Explosion,
|
||||
source: DamageSource::Projectile,
|
||||
kind: DamageKind::Piercing,
|
||||
value: damage,
|
||||
},
|
||||
Some(GroupTarget::OutOfGroup),
|
||||
instance,
|
||||
);
|
||||
)
|
||||
.with_effect(buff);
|
||||
if let Some(damage_effect) = damage_effect {
|
||||
damage = damage.with_effect(damage_effect);
|
||||
}
|
||||
let attack = Attack::default()
|
||||
.with_damage(damage)
|
||||
.with_crit(crit_chance, crit_mult);
|
||||
.with_crit(crit_chance, crit_mult)
|
||||
.with_effect(energy)
|
||||
.with_effect(knockback)
|
||||
.with_combo_increment();
|
||||
|
||||
Projectile {
|
||||
hit_solid: vec![],
|
||||
hit_solid: vec![Effect::Stick, Effect::Bonk],
|
||||
hit_entity: vec![Effect::Attack(attack), Effect::Vanish],
|
||||
time_left: Duration::from_secs(300),
|
||||
time_left: Duration::from_secs(15),
|
||||
owner,
|
||||
ignore_group: true,
|
||||
is_sticky: true,
|
||||
is_point: false,
|
||||
is_point: true,
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -939,8 +971,13 @@ impl ProjectileConstructor {
|
||||
*damage *= power;
|
||||
*radius *= range;
|
||||
},
|
||||
Trap { ref mut damage } => {
|
||||
Trap {
|
||||
ref mut damage,
|
||||
ref mut energy_regen,
|
||||
..
|
||||
} => {
|
||||
*damage *= power;
|
||||
*energy_regen *= regen;
|
||||
},
|
||||
}
|
||||
self
|
||||
|
@ -115,29 +115,21 @@ impl Animation for ShootAnimation {
|
||||
let pullback = 1.0 - move3;
|
||||
let move1abs = move1base * pullback;
|
||||
let move2abs = move2base * pullback;
|
||||
next.main.position = Vec3::new(2.0, -3.0, -3.0);
|
||||
|
||||
next.control_l.position = Vec3::new(
|
||||
0.0,
|
||||
0.0 + move1abs * 4.0 + move2abs * -4.0,
|
||||
-2.0 + move1abs * -8.0,
|
||||
);
|
||||
next.control_r.position = Vec3::new(-1.0 + s_a.grip.0 * 2.0, 2.0, -2.0);
|
||||
|
||||
next.control.position = Vec3::new(
|
||||
-1.0,
|
||||
0.0 + move1abs * -8.0 + move2abs * 8.0 + s_a.grip.2,
|
||||
3.0 + move1abs * 7.0 - s_a.grip.2 / 2.5 + s_a.grip.0 * -2.0,
|
||||
next.hand_l.position = Vec3::new(-s_a.hand.0, s_a.hand.1, s_a.hand.2 - 2.0);
|
||||
next.hand_r.position = Vec3::new(
|
||||
s_a.hand.0,
|
||||
s_a.hand.1 + move2abs * 1.5,
|
||||
s_a.hand.2 - 2.5 + move1abs * 2.5,
|
||||
);
|
||||
|
||||
next.control_l.orientation =
|
||||
Quaternion::rotation_x(PI / 2.0) * Quaternion::rotation_y(-0.3);
|
||||
next.control_r.orientation =
|
||||
Quaternion::rotation_x(PI / 2.0 + s_a.grip.0 * 0.2)
|
||||
* Quaternion::rotation_y(0.5 + s_a.grip.0 * 0.2);
|
||||
next.hand_r.orientation =
|
||||
Quaternion::rotation_x(move1abs * 4.0 + move2abs * -0.7)
|
||||
* Quaternion::rotation_y(0.0 + move1abs * -0.7);
|
||||
|
||||
next.control.orientation =
|
||||
Quaternion::rotation_x(-0.3 + move1abs * 0.5 + move2abs * -0.5)
|
||||
* Quaternion::rotation_y(0.5 * speednorm);
|
||||
next.hand_l.orientation = Quaternion::rotation_x(PI / 3.0 * move1abs)
|
||||
* Quaternion::rotation_y(-0.7 * move1abs + move2abs * 0.1);
|
||||
},
|
||||
_ => {
|
||||
let (move1base, move2base, move3) = match stage_section {
|
||||
|
@ -174,6 +174,9 @@ pub enum SfxEvent {
|
||||
CyclopsCharge,
|
||||
LaserBeam,
|
||||
Music(ToolKind, AbilitySpec),
|
||||
Yeet,
|
||||
Klonk,
|
||||
SmashKlonk,
|
||||
}
|
||||
|
||||
#[derive(Copy, Clone, Debug, PartialEq, Deserialize, Hash, Eq)]
|
||||
@ -493,6 +496,10 @@ impl SfxMgr {
|
||||
let sfx_trigger_item = triggers.get_key_value(&SfxEvent::LaserBeam);
|
||||
audio.emit_sfx(sfx_trigger_item, *pos, None, underwater);
|
||||
},
|
||||
Body::Object(object::Body::AdletTrap) => {
|
||||
let sfx_trigger_item = triggers.get_key_value(&SfxEvent::Yeet);
|
||||
audio.emit_sfx(sfx_trigger_item, *pos, None, underwater);
|
||||
},
|
||||
_ => {
|
||||
// not mapped to sfx file
|
||||
},
|
||||
@ -529,6 +536,23 @@ impl SfxMgr {
|
||||
audio.emit_sfx(sfx_trigger_item, *pos, Some(2.0), underwater);
|
||||
}
|
||||
},
|
||||
Body::Object(object::Body::AdletTrap) => {
|
||||
if target.is_none() {
|
||||
let sfx_trigger_item = triggers.get_key_value(&SfxEvent::Klonk);
|
||||
audio.emit_sfx(sfx_trigger_item, *pos, Some(2.0), underwater);
|
||||
} else if *source == client.uid() {
|
||||
let sfx_trigger_item = triggers.get_key_value(&SfxEvent::SmashKlonk);
|
||||
audio.emit_sfx(
|
||||
sfx_trigger_item,
|
||||
client.position().unwrap_or(*pos),
|
||||
Some(2.0),
|
||||
underwater,
|
||||
);
|
||||
} else {
|
||||
let sfx_trigger_item = triggers.get_key_value(&SfxEvent::SmashKlonk);
|
||||
audio.emit_sfx(sfx_trigger_item, *pos, Some(2.0), underwater);
|
||||
}
|
||||
},
|
||||
_ => {},
|
||||
},
|
||||
Outcome::SkillPointGain { uid, .. } => {
|
||||
|
@ -1471,7 +1471,7 @@ impl Structure for AdletStronghold {
|
||||
// 4 hide pieces
|
||||
for dir in CARDINALS {
|
||||
let hide_size =
|
||||
6 + (RandomField::new(0).get((wpos + dir).with_z(alt as i32)) % 4);
|
||||
6 + (RandomField::new(0).get((wpos + dir).with_z(alt as i32)) % 2);
|
||||
let hide_color =
|
||||
match RandomField::new(0).get((wpos + dir).with_z(alt as i32)) % 4 {
|
||||
0 => Fill::Block(Block::new(BlockKind::Wood, Rgb::new(73, 29, 0))),
|
||||
|
Loading…
Reference in New Issue
Block a user