Пример #1
0
        public override void Unload()
        {
            clickerUI.Deactivate();

            instance            = null;
            OpenCookieClickerUI = null;
            clickerUI           = null;
        }
Пример #2
0
        public override void Load()
        {
            instance            = this;
            _achievements       = new AchievementManager();
            OpenCookieClickerUI = RegisterHotKey("Open Cookie Clicker UI", "C");

            if (!Main.dedServ)
            {
                clickerUI = new CookieClickerUI();
            }

            //Adding our achievement tag handler. Cleared on Unload().
            ChatManager.Register <AchievementTagHandler>(new string[2]
            {
                "ca",
                "cookieachievement"
            });

            Hooks.On_AddMenuButtons       += Hooks_On_AddMenuButtons;
            On.Terraria.Player.SavePlayer += Player_SavePlayer;
        }