Example #1
0
        private void OnReturnedToTitle(object sender, ReturnedToTitleEventArgs e)
        {
            Helper.Events.GameLoop.UpdateTicked -= OnUpdateTicked;
            Helper.Events.Input.ButtonPressed   -= OnButtonPressed;

            SpeechHandlerPolly.stop();
        }
        private void SaveEvents_AfterReturnToTitle(object sender, EventArgs e)
        {
            GameEvents.OneSecondTick -= GameEvents_OneSecondTick;
            ControlEvents.KeyPressed -= ControlEvents_KeyPressed;
            ModConfig config = Helper.ReadConfig <ModConfig>();

            if (config.polly == "on" && pollySetup)
            {
                SpeechHandlerPolly.stop();
            }
            else
            {
                SpeechHandler.stop();
            }
        }