Ejemplo n.º 1
0
        private void EndMerchantStory0()
        {
            this._eventPoint.SetDedicatedNumber(1);
            MapUIContainer.SetVisibleHUD(true);
            if (!Singleton <Manager.Map> .IsInstance())
            {
                return;
            }
            Manager.Map instance = Singleton <Manager.Map> .Instance;
            instance.SetActiveMapEffect(true);
            MerchantActor merchant     = instance.Merchant;
            MerchantData  merchantData = merchant.MerchantData;

            if (Object.op_Inequality((Object)merchant, (Object)null))
            {
                if (merchantData != null)
                {
                    merchantData.Unlock = true;
                }
                merchant.SetLookPtn(0, 3);
                merchant.SetLookTarget(0, 0, (Transform)null);
                merchant.ChangeBehavior(merchant.LastNormalMode);
            }
            AgentActor tutorialAgent = instance.TutorialAgent;

            if (Object.op_Inequality((Object)tutorialAgent, (Object)null))
            {
                tutorialAgent.ChangeFirstNormalBehavior();
                instance.TutorialAgent = (AgentActor)null;
                Manager.Map.SetTutorialProgressAndUIUpdate(16);
            }
            PlayerActor player = instance.Player;

            if (Object.op_Inequality((Object)player, (Object)null))
            {
                if (Manager.Config.GraphicData.CharasEntry[0])
                {
                    player.CameraControl.Mode = CameraMode.Normal;
                    player.PlayerController.ChangeState("Idle");
                    ObservableExtensions.Subscribe <long>(Observable.Take <long>(Observable.SkipWhile <long>((IObservable <M0>)Observable.EveryUpdate(), (Func <M0, bool>)(_ => player.CameraControl.CinemachineBrain.get_IsBlending())), 1), (System.Action <M0>)(_ =>
                    {
                        player.AddTutorialUI(Popup.Tutorial.Type.Girl, false);
                        player.PlayerController.ChangeState("Normal");
                    }));
                }
                else
                {
                    player.PlayerController.ChangeState("Idle");
                    Singleton <Manager.Map> .Instance.ApplyConfig((System.Action)(() =>
                    {
                        // ISSUE: cast to a reference type
                        // ISSUE: explicit reference operation
                        CinemachineBlendDefinition.Style prevStyle = (CinemachineBlendDefinition.Style)(^ (CinemachineBlendDefinition&)ref player.CameraControl.CinemachineBrain.m_DefaultBlend).m_Style;
                        // ISSUE: cast to a reference type
                        // ISSUE: explicit reference operation
                        (^ (CinemachineBlendDefinition&)ref player.CameraControl.CinemachineBrain.m_DefaultBlend).m_Style = (__Null)0;
                        player.CameraControl.Mode = CameraMode.Normal;
                        // ISSUE: cast to a reference type
                        // ISSUE: explicit reference operation
                        ObservableExtensions.Subscribe <long>(Observable.Take <long>(Observable.Skip <long>((IObservable <M0>)Observable.EveryLateUpdate(), 1), 1), (System.Action <M0>)(_ => (^ (CinemachineBlendDefinition&)ref player.CameraControl.CinemachineBrain.m_DefaultBlend).m_Style = (__Null)prevStyle));
                    }), (System.Action)(() =>
                    {
                        player.AddTutorialUI(Popup.Tutorial.Type.Girl, false);
                        player.PlayerController.ChangeState("Normal");
                    }));
                }
            }
            Singleton <Manager.Map> .Instance.SetBaseOpenState(-1, true);

            instance.Simulator.EnabledTimeProgression = true;
        }