Clients should not be able to see each other's inventories
Currently, all (nearby?) entities' inventories are made visible to the client, and are accessible through client::Client::inventories
.
This is required by the current trade implementation (to show the items that the other party is offering), but should eventually be changed.
A possibility is to maintain a server-side map of which entities should be able to view each entity's inventory, redact inventory updates based on that, and update the map when trades are {started, stopped}.
This should probably be done after the economy patch has landed, so that this can be designed with NPC inventories and NPC trade in mind.