Dropping an Item Over the network

Hi if i want to drop a weapon from the character (Pun Character) it disappears. I have used item.drop() && inventory.removeitem but it isn't showing on any of the character apart from the Master Client. API for remove all is available but not for dropping and a single Item or am i missing something. Because it seems like dropping item by Using Y key works while it doesn't work on item.drop

If you can please tell me what i need to do Thanks.

The problem is only with multiplayer
 
You should start the drop ability instead of calling Item.Drop/RemoveItem directly. This will then sync over the network.
 
But what it will do is that it will drop currently equipped item. What if the user wants to drop something else, instead of currently equipped item?

Let me give you an example. If i have a weapon and i am trying to pickup another one. and i need to drop the older weapon once the new one is equipped?

Also if the user wants to drop health packs etc.
 
In that case you should create a new ability similar to the drop ability that will drop the item that you want. This will then allow it to sync over the network.

Alternatively when you call Drop/RemoveItem you can create your own RPC that syncs those calls over the network.
 
Unfortunately I am not able to debug custom code, but just based off of that I would insert a breakpoint within DropSingleItem and see if the correct item is being removed.
 
Top