|
@ -933,16 +933,8 @@ impl ItemManager { |
|
|
character_id: character.id,
|
|
|
character_id: character.id,
|
|
|
slot: slot,
|
|
|
slot: slot,
|
|
|
equipped: true,
|
|
|
equipped: true,
|
|
|
}).await;
|
|
|
|
|
|
entity_gateway.save_item(&ItemEntity{
|
|
|
|
|
|
id: inventory_item.entity_id,
|
|
|
|
|
|
location: ItemLocation::Inventory{
|
|
|
|
|
|
character_id: character.id,
|
|
|
|
|
|
slot: slot,
|
|
|
|
|
|
equipped: true,
|
|
|
|
|
|
},
|
|
|
|
|
|
item: inventory_item.item.clone(),
|
|
|
|
|
|
}).await;
|
|
|
|
|
|
|
|
|
}).await?;
|
|
|
|
|
|
entity_gateway.change_item(&inventory_item.entity_id, &inventory_item.item).await?;
|
|
|
Ok(())
|
|
|
Ok(())
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
@ -968,15 +960,7 @@ impl ItemManager { |
|
|
slot: slot,
|
|
|
slot: slot,
|
|
|
equipped: false,
|
|
|
equipped: false,
|
|
|
}).await;
|
|
|
}).await;
|
|
|
entity_gateway.save_item(&ItemEntity{
|
|
|
|
|
|
id: inventory_item.entity_id,
|
|
|
|
|
|
location: ItemLocation::Inventory{
|
|
|
|
|
|
character_id: character.id,
|
|
|
|
|
|
slot: slot,
|
|
|
|
|
|
equipped: false,
|
|
|
|
|
|
},
|
|
|
|
|
|
item: inventory_item.item.clone(),
|
|
|
|
|
|
}).await;
|
|
|
|
|
|
|
|
|
entity_gateway.change_item(&inventory_item.entity_id, &inventory_item.item).await?;
|
|
|
Ok(())
|
|
|
Ok(())
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|