Beispiel #1
0
        private static void Activate()
        {
            if (Active)
            {
                return;
            }
            if (!GUIHandler.CurrentMenu)
            {
                return;
            }
            Active = true;

            int            c = 0, n = 0;
            uGUI_CraftNode menuRoot = GUIHandler.CurrentMenu.icons;

            ForeachChildRecursively(menuRoot, x => ReplaceNodeTech(x));
            menuRoot?.UpdateRecursively(ref c, ref n);
            ForeachChildRecursively(menuRoot, x => GUIFormatter.PaintNodeColorAnimated(x));
        }
Beispiel #2
0
        private static void Activate()
        {
            if (Active)
            {
                return;
            }
            if (!GUIHandler.CurrentMenu)
            {
                return;
            }
            Active = true;

            int c = 0, n = 0;
            var menuRoot = uGUI_CraftingMenuReflector.GetIcons(GUIHandler.CurrentMenu);

            ForeachChildRecursively(menuRoot, x => ReplaceNodeTech(x));
            if (menuRoot != null)
            {
                menuRoot.UpdateRecursively(ref c, ref n);
            }
            ForeachChildRecursively(menuRoot, x => GUIFormatter.PaintNodeColorAnimated(x));
        }
Beispiel #3
0
        private static void Activate()
        {
            if (Active)
            {
                return;
            }
            if (!GUIHandler.CurrentMenu)
            {
                return;
            }
            Active = true;

            int c = 0, n = 0;
            var menuRoot = GUIHandler.CurrentMenu.tree;

            if (menuRoot != null)
            {
                ForeachChildRecursively(menuRoot, x => ReplaceNodeTech(x));
                GUIHandler.CurrentMenu.UpdateNotifications(menuRoot, ref c, ref n);
                ForeachChildRecursively(menuRoot, x => GUIFormatter.PaintNodeColorAnimated(x));
            }
        }