Example #1
0
        private void ModeChanged(UIMainPanelMode obj)
        {
            Clock?.SetHidden(obj != UIMainPanelMode.LIVE);
            DesktopUCP?.SetMode(obj);
            var lotType = MainPanel.GetLotType(true);
            var hit     = FSO.HIT.HITVM.Get();

            switch (obj)
            {
            case UIMainPanelMode.LIVE:
            case UIMainPanelMode.OPTIONS:
                hit.PlaySoundEvent(UIMusic.None); break;

            case UIMainPanelMode.BUY:
                switch (lotType)
                {
                case UICatalogMode.Downtown:
                    hit.PlaySoundEvent(UIMusic.Downtown); break;

                case UICatalogMode.Vacation:
                    hit.PlaySoundEvent(UIMusic.Vacation); break;

                case UICatalogMode.Community:
                    hit.PlaySoundEvent(UIMusic.Unleashed); break;

                case UICatalogMode.Studiotown:
                    hit.PlaySoundEvent(UIMusic.SuperstarTransition); break;

                case UICatalogMode.Magictown:
                    hit.PlaySoundEvent(UIMusic.MagictownBuy); break;

                default:
                    hit.PlaySoundEvent(UIMusic.Buy); break;
                }
                break;

            case UIMainPanelMode.BUILD:
                switch (lotType)
                {
                case UICatalogMode.Downtown:
                    hit.PlaySoundEvent(UIMusic.Downtown); break;

                case UICatalogMode.Vacation:
                    hit.PlaySoundEvent(UIMusic.Vacation); break;

                case UICatalogMode.Community:
                    hit.PlaySoundEvent(UIMusic.Unleashed); break;

                case UICatalogMode.Studiotown:
                    hit.PlaySoundEvent(UIMusic.SuperstarTransition); break;

                case UICatalogMode.Magictown:
                    hit.PlaySoundEvent(UIMusic.MagictownBuild); break;

                default:
                    hit.PlaySoundEvent(UIMusic.Build); break;
                }
                break;
            }
        }