Exemplo n.º 1
0
 private static void AddToStorage(Player player, ref MsgStorage packet)
 {
     if (!player.Inventory.TryGetItem(packet.Param, out var found))
     {
         return;
     }
     if (StorageSystem.PutIn(player, packet.UniqueId, found))
     {
         player.Send(packet);
         StorageSystem.ShowStock(player);
     }
 }
Exemplo n.º 2
0
        private static void AddToStorage(Player player, ref MsgStorage packet)
        {
            var found = player.Inventory.FindByUID(packet.Param);

            if (found.UniqueId == packet.Param)
            {
                if (StorageSystem.PutIn(player, packet.UniqueId, found))
                {
                    player.Send(packet);
                    StorageSystem.ShowStock(player);
                }
            }
        }