mirror of
https://github.com/doukutsu-rs/doukutsu-rs
synced 2024-09-28 13:09:07 +00:00
get_weapon_type_mut -> get_weapon_by_type_mut
This commit is contained in:
parent
87591f4a3d
commit
3c5f5c7496
|
@ -110,7 +110,7 @@ impl Inventory {
|
|||
self.weapons.get(idx)
|
||||
}
|
||||
|
||||
pub fn get_weapon_type_mut(&mut self, wtype: WeaponType) -> Option<&mut Weapon> {
|
||||
pub fn get_weapon_by_type_mut(&mut self, wtype: WeaponType) -> Option<&mut Weapon> {
|
||||
self.weapons.iter_mut().find(|weapon| weapon.wtype == wtype)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue