少年修仙传客户端基础资源
dabaoji
2025-06-09 8ee0256378cbf5dbc9d76ed10b60b65a844ef4dd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
 
using System.IO;
using vnxbqy.UI;
using UnityEditor;
using UnityEngine;
 
public class ExportGuides
{
 
    [MenuItem("Tools/导出引导提示")]
    public static void ExportTipContent()
    {
        Debug.Log("开始导出");
        var path = StringUtility.Contact("Assets/", "GuidesTips.txt");
        if (File.Exists(path))
            File.Delete(path);
        var writer = File.CreateText(path);
        var guides = GuideConfig.GetValues();
        foreach (var config in guides)
        {
            var prefix = "";
            if (config.Type == 1)
                prefix = NewBieGuideScriptableObject.GuidesPrefixNewBie;
            else if (config.Type == 2)
                prefix = NewBieGuideScriptableObject.GuidesPrefixFun;
            else
                continue;
            foreach (var setpId in config.Steps)
            {
                NewBieGuideScriptableObject so = null;
                if (config.Type == 1)
                    so = ScriptableObjectLoader.LoadSoNewBieGuideStep(setpId);
                else
                    so = ScriptableObjectLoader.LoadSoFunctionalGuideStep(setpId);
                if (so == null || string.IsNullOrEmpty(so.tipContent))
                    continue;
                writer.WriteLine(string.Format("{0}{1} \t{2}", prefix, setpId, so.tipContent));
            }
        }
        writer.Close();
        Debug.Log("导出成功");
    }
 
}