public void HsceneEnter(
            Actor actor,
            int isMerchantLimitType        = -1,
            AgentActor agent2              = null,
            HSceneManager.HEvent _numEvent = HSceneManager.HEvent.Normal)
        {
            this._isH            = true;
            this.enterPoint      = (HPoint)null;
            this.IsHousingHEnter = false;
            MapUIContainer.SetActiveCommandList(false);
            this.choiceDisposable = ObservableExtensions.Subscribe <Unit>(Observable.Take <Unit>((IObservable <M0>)MapUIContainer.CommandList.OnCompletedStopAsObservable(), 1), (System.Action <M0>)(_ => MapUIContainer.SetCommandLabelAcception(CommandLabel.AcceptionState.None)));
            Singleton <MapUIContainer> .Instance.MinimapUI.MiniMap.SetActive(false);

            Singleton <MapUIContainer> .Instance.MinimapUI.MiniMapIcon.SetActive(false);

            Singleton <Map> .Instance.SetActiveMapEffect(false);

            if (Object.op_Equality((Object)this.HSceneSet, (Object)null))
            {
                this.HSceneSet = Singleton <Resources> .Instance.HSceneTable.HSceneSet;
            }
            if (Object.op_Equality((Object)this.HSceneUISet, (Object)null))
            {
                this.HSceneUISet = Singleton <Resources> .Instance.HSceneTable.HSceneUISet;
            }
            this.Player = Singleton <Map> .Instance.Player;
            ((Behaviour)this.Player).set_enabled(false);
            this.handsIK = ((Behaviour)this.Player.HandsHolder).get_enabled();
            if (this.handsIK)
            {
                ((Behaviour)this.Player.HandsHolder).set_enabled(false);
            }
            this.Player.SetActiveOnEquipedItem(false);
            this.Player.ChaControl.setAllLayerWeight(0.0f);
            this.bMerchant           = Object.op_Inequality((Object)((Component)actor).GetComponent <MerchantActor>(), (Object)null);
            this.MerchantLimit       = isMerchantLimitType;
            this.FemaleLumpActive[0] = false;
            this.FemaleLumpActive[1] = false;
            if (!this.bMerchant)
            {
                this.Agent[0] = (AgentActor)((Component)actor).GetComponent <AgentActor>();
                this.Agent[0].BehaviorResources.ChangeMode(Desire.ActionType.Idle);
                this.Agent[0].DisableBehavior();
                this.Agent[0].AnimationAgent.DisableItems();
                ((Behaviour)this.Agent[0].Controller).set_enabled(false);
                ((Behaviour)this.Agent[0].AnimationAgent).set_enabled(false);
                this.PersonalPhase[0] = this.Agent[0].ChaControl.fileGameInfo.phase;
                this.Personality[0]   = this.Agent[0].ChaControl.chaFile.parameter.personality;
                if (Object.op_Inequality((Object)this.Agent[0].ChaControl.objExtraAccessory[3], (Object)null))
                {
                    this.FemaleLumpActive[0] = this.Agent[0].ChaControl.objExtraAccessory[3].get_activeSelf();
                    this.Agent[0].ChaControl.ShowExtraAccessory(ChaControlDefine.ExtraAccessoryParts.Waist, false);
                }
                this.Agent[0].SetActiveOnEquipedItem(false);
                this.Agent[0].ChaControl.setAllLayerWeight(0.0f);
                this.HSkil = this.Agent[0].ChaControl.fileGameInfo.hSkill;
            }
            else
            {
                this.merchantActor = (MerchantActor)((Component)actor).GetComponent <MerchantActor>();
                this.merchantActor.DisableBehavior();
                ((Behaviour)this.merchantActor.Controller).set_enabled(false);
                ((Behaviour)this.merchantActor.AnimationMerchant).set_enabled(false);
                this.PersonalPhase[0] = 3;
            }
            if (Object.op_Inequality((Object)agent2, (Object)null))
            {
                this.Agent[1] = agent2;
                this.Agent[1].BehaviorResources.ChangeMode(Desire.ActionType.Idle);
                this.Agent[1].DisableBehavior();
                this.Agent[1].AnimationAgent.DisableItems();
                ((Behaviour)this.Agent[1].Controller).set_enabled(false);
                ((Behaviour)this.Agent[1].AnimationAgent).set_enabled(false);
                this.PersonalPhase[1] = this.Agent[1].ChaControl.fileGameInfo.phase;
                this.Personality[1]   = this.Agent[1].ChaControl.chaFile.parameter.personality;
                if (Object.op_Inequality((Object)this.Agent[1].ChaControl.objExtraAccessory[3], (Object)null))
                {
                    this.FemaleLumpActive[1] = this.Agent[1].ChaControl.objExtraAccessory[3].get_activeSelf();
                    this.Agent[1].ChaControl.ShowExtraAccessory(ChaControlDefine.ExtraAccessoryParts.Waist, false);
                }
                this.Agent[1].SetActiveOnEquipedItem(false);
                this.Agent[1].ChaControl.setAllLayerWeight(0.0f);
            }
            this.isCtrl              = false;
            this.endStatus           = (byte)0;
            AnimalBase.CreateDisplay = false;
            AnimalManager instance = Singleton <AnimalManager> .Instance;

            for (int index1 = 0; index1 < instance.Animals.Count; ++index1)
            {
                int index2 = index1;
                instance.Animals[index2].BodyEnabled = false;
                ((Behaviour)instance.Animals[index2]).set_enabled(false);
            }
            instance.ClearAnimalPointBehavior();
            if (!this.bMerchant)
            {
                this.Temperature = this.Agent[0].AgentData.StatsTable[0];
                this.Mood[0]     = this.Agent[0].AgentData.StatsTable[1];
                this.Mood[1]     = !Object.op_Implicit((Object)this.Agent[1]) ? 0.0f : this.Agent[1].AgentData.StatsTable[1];
                if (this.ReserveToilet.HasValue)
                {
                    this.Toilet        = this.ReserveToilet.Value;
                    this.ReserveToilet = new float?();
                }
                else
                {
                    this.Toilet = this.Agent[0].AgentData.DesireTable[Desire.GetDesireKey(Desire.Type.Toilet)];
                }
                this.Bath           = this.Agent[0].AgentData.DesireTable[Desire.GetDesireKey(Desire.Type.Bath)];
                this.Reliability    = this.Agent[0].GetFlavorSkill(FlavorSkill.Type.Reliability);
                this.Instinct       = this.Agent[0].GetFlavorSkill(FlavorSkill.Type.Instinct);
                this.Dirty          = this.Agent[0].GetFlavorSkill(FlavorSkill.Type.Dirty);
                this.RiskManagement = this.Agent[0].GetFlavorSkill(FlavorSkill.Type.Wariness);
                this.Darkness       = this.Agent[0].GetFlavorSkill(FlavorSkill.Type.Darkness);
                this.Sociability    = this.Agent[0].GetFlavorSkill(FlavorSkill.Type.Sociability);
                this.Pheromone      = this.Agent[0].GetFlavorSkill(FlavorSkill.Type.Pheromone);
                this.isHAddTaii     = new bool[2]
                {
                    this.Agent[0].ChaControl.fileGameInfo.isHAddTaii0,
                    this.Agent[0].ChaControl.fileGameInfo.isHAddTaii1
                };
            }
            this.Player.Controller.ChangeState("Sex");
            this.ReturnActionTypes.Clear();
            this.EventKind = _numEvent;
            Singleton <Voice> .Instance.StopAll(true);

            if (!this.bMerchant)
            {
                this.StartCoroutine(this.HsceneInit(this.Agent));
            }
            else
            {
                this.StartCoroutine(this.HsceneInit(this.merchantActor, !Object.op_Inequality((Object)agent2, (Object)null) ? (AgentActor)null : this.Agent[1]));
            }
        }
        public void HousingHEnter(Actor actor, HPoint hpoint)
        {
            this._isH            = true;
            this.IsHousingHEnter = true;
            MapUIContainer.SetActiveCommandList(false);
            this.choiceDisposable = ObservableExtensions.Subscribe <Unit>(Observable.Take <Unit>((IObservable <M0>)MapUIContainer.CommandList.OnCompletedStopAsObservable(), 1), (System.Action <M0>)(_ => MapUIContainer.SetCommandLabelAcception(CommandLabel.AcceptionState.None)));
            Singleton <MapUIContainer> .Instance.MinimapUI.MiniMap.SetActive(false);

            Singleton <MapUIContainer> .Instance.MinimapUI.MiniMapIcon.SetActive(false);

            Singleton <Map> .Instance.SetActiveMapEffect(false);

            if (Object.op_Equality((Object)this.HSceneSet, (Object)null))
            {
                this.HSceneSet = Singleton <Resources> .Instance.HSceneTable.HSceneSet;
            }
            if (Object.op_Equality((Object)this.HSceneUISet, (Object)null))
            {
                this.HSceneUISet = Singleton <Resources> .Instance.HSceneTable.HSceneUISet;
            }
            this.Player = Singleton <Map> .Instance.Player;
            ((Behaviour)this.Player).set_enabled(false);
            this.handsIK = ((Behaviour)this.Player.HandsHolder).get_enabled();
            if (this.handsIK)
            {
                ((Behaviour)this.Player.HandsHolder).set_enabled(false);
            }
            this.Player.SetActiveOnEquipedItem(false);
            this.Player.ChaControl.setAllLayerWeight(0.0f);
            this.Agent[0] = (AgentActor)((Component)actor).GetComponent <AgentActor>();
            this.Agent[0].BehaviorResources.ChangeMode(Desire.ActionType.Idle);
            this.Agent[0].DisableBehavior();
            this.Agent[0].AnimationAgent.DisableItems();
            ((Behaviour)this.Agent[0].Controller).set_enabled(false);
            ((Behaviour)this.Agent[0].AnimationAgent).set_enabled(false);
            this.PersonalPhase[0] = this.Agent[0].ChaControl.fileGameInfo.phase;
            this.Personality[0]   = this.Agent[0].ChaControl.chaFile.parameter.personality;
            this.Agent[0].SetActiveOnEquipedItem(false);
            this.Agent[0].ChaControl.setAllLayerWeight(0.0f);
            this.HSkil               = this.Agent[0].ChaControl.fileGameInfo.hSkill;
            this.isCtrl              = false;
            this.endStatus           = (byte)0;
            AnimalBase.CreateDisplay = false;
            AnimalManager instance = Singleton <AnimalManager> .Instance;

            for (int index1 = 0; index1 < instance.Animals.Count; ++index1)
            {
                int index2 = index1;
                instance.Animals[index2].BodyEnabled = false;
                ((Behaviour)instance.Animals[index2]).set_enabled(false);
            }
            instance.ClearAnimalPointBehavior();
            if (!this.bMerchant)
            {
                this.Temperature = this.Agent[0].AgentData.StatsTable[0];
                this.Mood[0]     = this.Agent[0].AgentData.StatsTable[1];
                this.Mood[1]     = !Object.op_Implicit((Object)this.Agent[1]) ? 0.0f : this.Agent[1].AgentData.StatsTable[1];
                if ((double)this.Mood[0] < (double)this.Agent[0].ChaControl.fileGameInfo.moodBound.lower)
                {
                    this.isForce = true;
                }
                this.Toilet         = this.Agent[0].AgentData.DesireTable[Desire.GetDesireKey(Desire.Type.Toilet)];
                this.Bath           = this.Agent[0].AgentData.DesireTable[Desire.GetDesireKey(Desire.Type.Bath)];
                this.Reliability    = this.Agent[0].GetFlavorSkill(FlavorSkill.Type.Reliability);
                this.Instinct       = this.Agent[0].GetFlavorSkill(FlavorSkill.Type.Instinct);
                this.Dirty          = this.Agent[0].GetFlavorSkill(FlavorSkill.Type.Dirty);
                this.RiskManagement = this.Agent[0].GetFlavorSkill(FlavorSkill.Type.Wariness);
                this.Darkness       = this.Agent[0].GetFlavorSkill(FlavorSkill.Type.Darkness);
                this.Sociability    = this.Agent[0].GetFlavorSkill(FlavorSkill.Type.Sociability);
                this.Pheromone      = this.Agent[0].GetFlavorSkill(FlavorSkill.Type.Pheromone);
                this.isHAddTaii     = new bool[2]
                {
                    this.Agent[0].ChaControl.fileGameInfo.isHAddTaii0,
                    this.Agent[0].ChaControl.fileGameInfo.isHAddTaii1
                };
            }
            this.Player.Controller.ChangeState("Sex");
            this.ReturnActionTypes.Clear();
            this.EventKind = HSceneManager.HEvent.Normal;
            if (this.EventKind == HSceneManager.HEvent.Back)
            {
                Singleton <HSceneFlagCtrl> .Instance.AddParam(31, 1);
            }
            Singleton <Voice> .Instance.StopAll(true);

            this.height     = (int)hpoint._nPlace[0].Item1;
            this.enterPoint = hpoint;
            this.StartCoroutine(this.HsceneInit(this.Agent));
        }
 public void SetEventInfo(HSceneManager.HEvent _event)
 {
     this.EventKind = _event;
 }