49 lines
1.4 KiB
C#
49 lines
1.4 KiB
C#
|
|
//using System.Collections;
|
|
//using System.Collections.Generic;
|
|
//using System.Text;
|
|
//using UnityEngine;
|
|
|
|
//namespace Ether
|
|
//{
|
|
// public static class GenerateInputScript
|
|
// {
|
|
// private static string inputFunctionCfgPath = PathTools.InputFunctionConfig;
|
|
// private static string generatePath = PathTools.EtherInputTypePath;
|
|
// private static string tempPath = PathTools.InputActionDataTempPath;
|
|
|
|
// public static bool Generate()
|
|
// {
|
|
// if (!FileTools.FileExists(inputFunctionCfgPath))
|
|
// {
|
|
// return false;
|
|
// }
|
|
|
|
// if (!FileTools.ReadFileForJson(PathTools.InputFunctionConfig, out InputFunctionConfig inputFunctionCfg))
|
|
// {
|
|
// return false;
|
|
// }
|
|
|
|
// List<InputFunctionClass> functionList = inputFunctionCfg.functionList;
|
|
|
|
// string template = FileTools.ReadFile(tempPath);
|
|
|
|
// string str = "";
|
|
|
|
// foreach (InputFunctionClass function in functionList)
|
|
// {
|
|
// if (!string.IsNullOrEmpty(function.inputKeyName))
|
|
// {
|
|
// str += "\t\t" + function.inputKeyName + ",\n";
|
|
// }
|
|
// }
|
|
|
|
// string outStr = template.Replace("%Content%", str);
|
|
|
|
// FileTools.WriteFile(generatePath, outStr);
|
|
|
|
// return true;
|
|
// }
|
|
// }
|
|
//}
|