mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Made handle_jump use it's own jump_modifier stat
This commit is contained in:
parent
bb2adfb2e5
commit
b6c67a7f41
@ -58,6 +58,7 @@ pub struct Stats {
|
||||
pub heal_multiplier: f32,
|
||||
pub max_health_modifiers: StatsModifier,
|
||||
pub move_speed_modifier: f32,
|
||||
pub jump_modifier: f32,
|
||||
pub attack_speed_modifier: f32,
|
||||
pub friction_modifier: f32,
|
||||
pub max_energy_modifiers: StatsModifier,
|
||||
@ -85,6 +86,7 @@ impl Stats {
|
||||
heal_multiplier: 1.0,
|
||||
max_health_modifiers: StatsModifier::default(),
|
||||
move_speed_modifier: 1.0,
|
||||
jump_modifier: 1.0,
|
||||
attack_speed_modifier: 1.0,
|
||||
friction_modifier: 1.0,
|
||||
max_energy_modifiers: StatsModifier::default(),
|
||||
|
@ -1190,7 +1190,7 @@ pub fn handle_jump(
|
||||
data.entity,
|
||||
strength * impulse / data.mass.0
|
||||
* data.scale.map_or(1.0, |s| s.0.powf(13.0).powf(0.25))
|
||||
* data.stats.move_speed_modifier,
|
||||
* data.stats.jump_modifier,
|
||||
));
|
||||
})
|
||||
.is_some()
|
||||
|
Loading…
Reference in New Issue
Block a user