qnw Posted August 5 Posted August 5 The'moddata'in'inventoryitem' cannot be synchronized to other clients when the client is modified. Now I can only synchronize data through'additemonserver'by recreating an identical item. But this brings many problems, especially the compatibility with other mods. It may be possible to synchronize the ID of'inventoryitem'with the command between the client and the server, but I can't find a way to get'inventoryitem' through the ID on the client. Does anyone know how to solve it? Or new ideas Quote Share this post Link to post Share on other sites More sharing options...
Zeros Posted August 10 Posted August 10 Data that needs to be synchronized to other clients should be transmitted from source client > server > the rest of clients. Therefore, you should do it through 'OnServerCommand' and 'OnClientCommand' events. 1. Source player do 'sendClientCommand' containing the mod id, command and mod data 2. Server receive client command through 'OnClientCommand', process the transmitted data and send the mod data to all players except the source player through 'sendServerCommand'. 3. Other players receive the server command and synchronize according to the received mod data. Quote Share this post Link to post Share on other sites More sharing options...