示例#1
0
        private static void PrintTask(StringBuilder sb, QuestTask task)
        {
            sb.AppendLine(task.Log);
            sb.AppendLine($"Task: {task.Type}");

            switch (task.Task)
            {
            case FLD_QuestBattle battle:
                if (battle.EnemyID > 0)
                {
                    var enemy = battle._EnemyID;
                    var rsc   = enemy._ParamID?._ResourceID;
                    sb.AppendLine($"{enemy._Name?.name}; {enemy.Debug_Name} ;{rsc?.DebugName}; {rsc?._TypeFamily?._name.name} {rsc?._TypeGenus?._NAME?.name}");
                }

                if (battle.EnemyGroupID > 0)
                {
                    foreach (var enemy in battle._EnemyGroupID._EnemyID.Where(x => x != null))
                    {
                        var rsc = enemy._ParamID?._ResourceID;
                        sb.AppendLine($"{enemy._Name?.name}; {enemy.Debug_Name} ;{rsc?.DebugName}; {rsc?._TypeFamily?._name.name} {rsc?._TypeGenus?._NAME?.name}");
                    }
                }

                break;
            }
        }
示例#2
0
        public static QuestChild ReadChildQuest(FLD_QuestList childQuest)
        {
            var quest = new QuestChild();

            quest.Id   = childQuest.Id;
            quest.Flag = childQuest.FlagCLD;

            FLD_QuestTask purpose = childQuest._PurposeID;

            if (purpose?.TaskType1 > 0)
            {
                var task = new QuestTask();
                task.Type      = purpose._TaskType1;
                task.Id        = purpose.TaskID1;
                task.Log       = purpose._TaskLog1?.name;
                task.Condition = purpose._TaskCondition1;
                task.Task      = purpose._TaskID1;

                quest.Tasks.Add(task);
            }

            if (purpose?.TaskType2 > 0)
            {
                var task = new QuestTask();
                task.Type      = purpose._TaskType2;
                task.Id        = purpose.TaskID2;
                task.Log       = purpose._TaskLog2?.name;
                task.Condition = purpose._TaskCondition2;
                task.Task      = purpose._TaskID2;

                quest.Tasks.Add(task);
            }

            return(quest);
        }
示例#3
0
文件: Export.cs 项目: natsu-k/XbTool
        private static void PrintTask(StringBuilder sb, QuestTask task, BdatCollection tables)
        {
            sb.AppendLine(task.Log);
            sb.AppendLine($"Task: {task.Type}");

            switch (task.Task)
            {
            case FLD_QuestBattle battle:
                PrintBattleTask(sb, battle);
                break;

            case FLD_QuestTalk talk:
                PrintTalkTask(sb, talk, tables);
                break;

            case FLD_QuestReach reach:
                PrintReachTask(sb, reach, tables);
                break;
            }
        }