mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Use unreachable instead of panic
This commit is contained in:
parent
a0b78ffd16
commit
cbc6cdfad1
@ -1858,7 +1858,7 @@ impl<'a> AgentData<'a> {
|
|||||||
let direction_weight = match tactic {
|
let direction_weight = match tactic {
|
||||||
Tactic::Hammer => 0.1,
|
Tactic::Hammer => 0.1,
|
||||||
Tactic::Axe => 0.3,
|
Tactic::Axe => 0.3,
|
||||||
_ => panic!("Direction weight called on unknown tactic."),
|
_ => unreachable!("Direction weight called on incorrect tactic."),
|
||||||
};
|
};
|
||||||
|
|
||||||
let tgt_pos = tgt_data.pos.0;
|
let tgt_pos = tgt_data.pos.0;
|
||||||
|
Loading…
Reference in New Issue
Block a user