示例#1
0
        public void UpdateDayInfo(GameInfo gameInfo)
        {
            // 日の情報を更新
            TodayInfo.Update(gameInfo);

            // 新規会話の処理
            for (int i = talkOffset; i < TodayInfo.TalkList.Count; i++)
            {
                Talk    talk    = TodayInfo.TalkList[i];
                Content content = TodayInfo.TalkList[i].Content;

                // 単文か
                if (content.Operator == Operator.NOP)
                {
                    switch (content.Topic)
                    {
                    case Topic.COMINGOUT:
                        // カミングアウト
                        // 自分に対するCOのみ対象
                        if (talk.Agent == content.Target)
                        {
                            if (content.Role.GetTeam() == Team.VILLAGER)
                            {
                                // 村陣営CO
                                UpdateComingOut(content.Target, content.Role, talk);
                            }
                            else
                            {
                                // 人外CO
                                UpdateMonsterSideComingOut(content.Target, content.Role, talk);
                            }
                        }
                        break;

                    case Topic.DIVINED:
                        // 占い結果

                        // カミングアウトの更新
                        UpdateComingOut(talk.Agent, Role.SEER, talk);

                        // 判定の追加
                        Judge newSeerJudge = new Judge(talk);
                        SeerJudge.Add(newSeerJudge);

                        // 内訳の削除
                        if (IsRemoveVillagerFakeCO)
                        {
                            RemovePatternFromJudge(newSeerJudge);
                        }

                        break;

                    case Topic.IDENTIFIED:
                        // 霊媒結果

                        // カミングアウトの更新
                        UpdateComingOut(talk.Agent, Role.MEDIUM, talk);

                        // 判定の追加
                        Judge newMediumJudge = new Judge(talk);
                        MediumJudge.Add(newMediumJudge);

                        // 内訳の削除
                        if (IsRemoveVillagerFakeCO)
                        {
                            RemovePatternFromJudge(newMediumJudge);
                        }

                        break;

                    case Topic.GUARDED:
                        // 護衛履歴
                        break;

                    default:
                        break;
                    }
                }
            }
            talkOffset = TodayInfo.TalkList.Count;

            // 新規囁きの処理
        }
示例#2
0
        public void UpdateDayInfo()
        {
            // 新規会話の処理
            if (!TalkContent.ContainsKey(LatestGameInfo.Day))
            {
                TalkContent.Add(LatestGameInfo.Day, new List <Content>());
            }
            List <Content> ContentList = TalkContent[LatestGameInfo.Day];

            for (int i = talkOffset; i < LatestGameInfo.TalkList.Count; i++)
            {
                Talk    srcTalk    = LatestGameInfo.TalkList[i];
                Content newContent = new Content(srcTalk.Text);

                // Content版を作成する
                ContentList.Add(newContent);

                // 単文か
                if (newContent.Operator == Operator.NOP)
                {
                    switch (newContent.Topic)
                    {
                    case Topic.COMINGOUT:
                        // カミングアウト
                        // 自分に対する村陣営COのみ対象
                        if (srcTalk.Agent == newContent.Target && newContent.Role.GetTeam() == Team.VILLAGER)
                        {
                            // カミングアウトの更新
                            UpdateComingOut(newContent.Target, newContent.Role, srcTalk);
                        }
                        break;

                    case Topic.DIVINED:
                        // 占い結果

                        // カミングアウトの更新
                        UpdateComingOut(srcTalk.Agent, Role.SEER, srcTalk);

                        // 判定の追加
                        Judge newSeerJudge = new Judge(srcTalk);
                        SeerJudge.Add(newSeerJudge);

                        break;

                    case Topic.IDENTIFIED:
                        // 霊媒結果

                        // カミングアウトの更新
                        UpdateComingOut(srcTalk.Agent, Role.MEDIUM, srcTalk);

                        // 判定の追加
                        Judge newMediumJudge = new Judge(srcTalk);
                        MediumJudge.Add(newMediumJudge);

                        break;

                    case Topic.GUARDED:
                        // 護衛履歴
                        break;

                    default:
                        break;
                    }
                }
            }
            talkOffset = LatestGameInfo.TalkList.Count;

            // 新規囁きの処理

            /*            for (int i = todayInfo.WhisperContentList.Count; i < todayInfo.WhisperList.Count; i++)
             *          {
             *              Content newContent = new Content(todayInfo.WhisperList[i].Text);
             *
             *              // Content版を作成する
             *              todayInfo.WhisperContentList.Add(newContent);
             *          }*/
        }