예제 #1
0
        private void HandleOptionsEvent(OptionsEventInfo obj)
        {
            switch (obj.Type)
            {
            case OptionsType.Toggle:
                ToggleOptions();
                break;

            default:
                throw new ArgumentOutOfRangeException();
            }
        }
예제 #2
0
        private void HandleEvent(OptionsEventInfo optionsEventInfo)
        {
            switch (optionsEventInfo.Type)
            {
            case OptionsType.Toggle:
                if (uiButtonObject != null)
                {
                    uiButtonObject.Text    = uiButtonObject.Text.Equals("Easy") ? "Hard" : "Easy";
                    uiButtonObject.Texture = uiButtonObject.Text.Equals("Easy") ? textureEasy : textureHard;
                }

                break;

            default:
                throw new ArgumentOutOfRangeException();
            }
        }