mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Fix bug with ignoring second_tool in EntityInfo
This commit is contained in:
parent
d920f911a2
commit
6654c9e372
@ -208,6 +208,7 @@ impl<'a> System<'a> for Sys {
|
||||
let EntityInfo {
|
||||
skillset_asset,
|
||||
main_tool,
|
||||
second_tool,
|
||||
loadout_asset,
|
||||
make_loadout,
|
||||
trading_information: economy,
|
||||
@ -234,6 +235,11 @@ impl<'a> System<'a> for Sys {
|
||||
loadout_builder = loadout_builder.with_default_maintool(&body);
|
||||
}
|
||||
|
||||
// If second tool is passed, use it as well
|
||||
if let Some(second_tool) = second_tool {
|
||||
loadout_builder = loadout_builder.active_offhand(Some(second_tool));
|
||||
}
|
||||
|
||||
// If there is config, apply it.
|
||||
// If not, use default equipement for this body.
|
||||
if let Some(asset) = loadout_asset {
|
||||
|
Loading…
Reference in New Issue
Block a user