Send equipped item bodypart attachments over RFR

develop
JapaMala 2018-08-02 21:50:29 +05:30
parent 5e95bd9cf2
commit efe4926df0
3 changed files with 3 additions and 1 deletions

@ -1 +1 @@
Subproject commit 57928311390bb67fe0cd5deec14e2d4621b13a58 Subproject commit de83a453d7e55aa48ffc92c8f4c147b1a1acd525

@ -426,6 +426,7 @@ message InventoryItem
{ {
optional InventoryMode mode = 1; optional InventoryMode mode = 1;
optional Item item = 2; optional Item item = 2;
optional int32 body_part_id = 3;
} }
message UnitDefinition message UnitDefinition

@ -1807,6 +1807,7 @@ static command_result GetUnitListInside(color_ostream &stream, const BlockReques
auto inventory_item = unit->inventory[j]; auto inventory_item = unit->inventory[j];
auto sent_item = send_unit->add_inventory(); auto sent_item = send_unit->add_inventory();
sent_item->set_mode((InventoryMode)inventory_item->mode); sent_item->set_mode((InventoryMode)inventory_item->mode);
sent_item->set_body_part_id(inventory_item->body_part_id);
CopyItem(sent_item->mutable_item(), inventory_item->item); CopyItem(sent_item->mutable_item(), inventory_item->item);
} }