コード例 #1
0
        public CommandViewBuilder(List <Command> commands)
        {
            _commands = commands;
            foreach (var command in _commands)
            {
                CategoryNodeView currentNode = CreateCategories(command.info.categories);
                AddButton(command.info.name, "command", OnCommandSelected, currentNode);
            }

            CategoryPlayerPrefs.LoadCategoryStates(_rootNode, ClassName);

            if (LogConsoleSettings.Instance.useCategoryColor)
            {
                NodeColor.AdjustIconColor(_rootNode);
            }

            _rootNode.Sort(DefaultCompareNode);
        }
コード例 #2
0
        public SettingViewBuilder(List <Command> commands)
        {
            _commands = commands;
            foreach (var command in _commands)
            {
                Node currentNode = CreateCategories(command.info.categories);
                AddCommandFields(command, currentNode);
            }

            CategoryPlayerPrefs.LoadCategoryStates(_rootNode, ClassName);

            if (LogConsoleSettings.Instance.useCategoryColor)
            {
                NodeColor.AdjustIconColor(_rootNode);
            }

            _rootNode.children.Sort(DefaultCompareNode);
        }