public static List <NetFriendlyHierarchyBookShelf> ProcessLibrary(Librarian.Library Library)
    {
        List <NetFriendlyHierarchyBookShelf> Toreturn = new List <NetFriendlyHierarchyBookShelf>();

        foreach (var roots in Library.Roots)
        {
            Toreturn.Add(ProcessLibraryBookShelf(Librarian.TransformToBookShelf[roots.Shelf.transform]));
            RecursiveProcessLibrary(roots, Toreturn);
        }

        return(Toreturn);
    }
Ejemplo n.º 2
0
        public static NetMessage Send(Librarian.Library Library, GameObject ToWho)
        {
            NetMessage msg          = new NetMessage();
            var        ListsOfLists = VariableViewerNetworking.ProcessLibrary(Library).Chunk(700).ToList();

            foreach (var List in ListsOfLists)
            {
                msg.data   = JsonConvert.SerializeObject(List.ToList());
                msg.Number = ListsOfLists.Count;
                SendTo(ToWho, msg, channel: 3);
            }

            return(msg);
        }