Esempio n. 1
0
        public void loadObjects(string corePath, SimplexProjectStructure sps)
        {
            currentProject = sps;
            Dictionary <Type, SimplexProjectItem> fList = new Dictionary <Type, SimplexProjectItem>();

            SimplexIdeApi.GetResourceClasses(corePath, "Objects", ref fList, sps.Objects);
            SimplexIdeApi.TreeParseNodes(objects, "Objects", fList);
            SimplexIdeApi.RegisterColliderTypes(fList, ref reflectedTypes);
            CollisionsTree.ComputeActiveColliders();

            fList.Clear();
            SimplexIdeApi.RegisterSimple(corePath, "Rooms", ref fList, sps.Rooms);

            foreach (var t in fList)
            {
                rooms.Nodes[0].Nodes.Add(new DarkTreeNode(t.Key.Name)
                {
                    Icon = Properties.Resources.MapTileLayer_16x
                });
                reflectedTypes.Add(t.Key);
            }

            activeRoom = null;
            sr.drawTest1.InitializeNodes(objects.Nodes);
        }