schaderDev
Member
Hi @Justin
I am currently creating a Mirror integration based on the pun add-on.
I have everything synchronized except the inventory.
When a new client joins the inventory of the remoteplayers stays empty "(Nothing in inventory)". The weapon is visually there (equipped) and abilities are working (for example reloading), the weapon just doesn`t show up in the inventory.
Here an example:
Host
Localplayer Host: inventory is correct
Remoteplayer Client1: inventory is correct
Remoteplayer Client2: inventory is correct
Client1
Localplayer Client1: inventory is correct
Remoteplayer Host: inventory is empty
Remoteplayer Client2: inventory is empty
Client2
Localplayer Client2: inventory is correct
Remoteplayer Host: inventory is empty
Remoteplayer Client1: inventory is empty
What is weird is that the remoteplayers on the host have there inventory synchronized but it stays empty for the remoteplayers on the clients.
I assume this is the line where the inventory synchronization happens?
But I have converted that just like the other RPC´s. Do I have to look somewhere else?
Maybe there is more to it to synchronize the inventory? I just don´t know where to look at.
I am currently creating a Mirror integration based on the pun add-on.
I have everything synchronized except the inventory.
When a new client joins the inventory of the remoteplayers stays empty "(Nothing in inventory)". The weapon is visually there (equipped) and abilities are working (for example reloading), the weapon just doesn`t show up in the inventory.
Here an example:
Host
Localplayer Host: inventory is correct
Remoteplayer Client1: inventory is correct
Remoteplayer Client2: inventory is correct
Client1
Localplayer Client1: inventory is correct
Remoteplayer Host: inventory is empty
Remoteplayer Client2: inventory is empty
Client2
Localplayer Client2: inventory is correct
Remoteplayer Host: inventory is empty
Remoteplayer Client1: inventory is empty
What is weird is that the remoteplayers on the host have there inventory synchronized but it stays empty for the remoteplayers on the clients.
I assume this is the line where the inventory synchronization happens?
C#:
photonView.RPC("PickupItemIdentifierRPC", player, item.ItemIdentifier.ID, m_Inventory.GetItemIdentifierAmount(item.ItemIdentifier));
Maybe there is more to it to synchronize the inventory? I just don´t know where to look at.