void Update()
        {
            systemListView.UpdateTimings();

            systemListView.UpdateIfNecessary();
            componentGroupListView.UpdateIfNecessary();
            entityListView.UpdateIfNecessary();

            if (Time.realtimeSinceStartup > lastUpdate + 0.5f)
            {
                Repaint();
            }
        }
예제 #2
0
        private void OnGUI()
        {
            if (Event.current.type == EventType.Layout)
            {
                systemListView.UpdateIfNecessary();
                componentGroupListView.UpdateIfNecessary();
                filterUI.GetTypes();
                entityListView.UpdateIfNecessary();
            }

            if (Selection.activeObject == selectionProxy)
            {
                if (!selectionProxy.Exists)
                {
                    Selection.activeObject = null;
                    entityListView.SelectNothing();
                }
            }

            GUILayout.BeginHorizontal();

            GUILayout.BeginVertical(GUILayout.Width(kSystemListWidth)); // begin System side
            SystemHeader();

            GUILayout.BeginVertical(Box);
            SystemList();
            GUILayout.EndVertical();

            GUILayout.EndVertical();                                          // end System side

            GUILayout.BeginVertical(GUILayout.Width(CurrentEntityViewWidth)); // begin Entity side

            EntityHeader();
            ComponentGroupList();
            EntityList();

            GUILayout.EndVertical(); // end Entity side

            if (showingChunkInfoView)
            {
                GUILayout.Space(1f);
                GUILayout.BeginVertical(GUILayout.Width(kChunkInfoViewWidth));
                ChunkInfoView();
                GUILayout.EndVertical();
            }

            GUILayout.EndHorizontal();

            lastUpdate = Time.realtimeSinceStartup;
        }