试玩功能属性加成
This commit is contained in:
parent
f93c89c162
commit
43d34f274e
@ -29,6 +29,7 @@ namespace BFEditor
|
|||||||
string boardFiledName = "board";
|
string boardFiledName = "board";
|
||||||
string boardEdgeFiledName = "grid_edge";
|
string boardEdgeFiledName = "grid_edge";
|
||||||
string randomTypeStr = "";
|
string randomTypeStr = "";
|
||||||
|
string boardEdgeStr = "";
|
||||||
int curIndex = 1;
|
int curIndex = 1;
|
||||||
int maxRow = 7;
|
int maxRow = 7;
|
||||||
Dictionary<int, Dictionary<string, string>> boardGridTypeDict = new Dictionary<int, Dictionary<string, string>>();
|
Dictionary<int, Dictionary<string, string>> boardGridTypeDict = new Dictionary<int, Dictionary<string, string>>();
|
||||||
@ -341,6 +342,45 @@ namespace BFEditor
|
|||||||
boardDict[curIndex] = ja;
|
boardDict[curIndex] = ja;
|
||||||
}
|
}
|
||||||
GUILayout.EndHorizontal();
|
GUILayout.EndHorizontal();
|
||||||
|
GUILayout.EndVertical();
|
||||||
|
GUILayout.EndArea();
|
||||||
|
GUILayout.BeginArea(new Rect(730, 650, 500, 100));
|
||||||
|
GUILayout.BeginVertical();
|
||||||
|
GUILayout.Label("棋盘边缘元素");
|
||||||
|
boardEdgeStr = GUILayout.TextField(boardEdgeStr, GUILayout.Width(500), GUILayout.Height(300));
|
||||||
|
if(GUILayout.Button("重新加载边缘元素"))
|
||||||
|
{
|
||||||
|
string[] units = boardEdgeStr.Split('{');
|
||||||
|
List<string> edgeList = new List<string>();
|
||||||
|
for (int i = 0; i < units.Length; i++)
|
||||||
|
{
|
||||||
|
string formatStr = units[i].Replace("[", "").Replace("]", "").Replace(" ", "").Replace("}", "");
|
||||||
|
string[] unitList = formatStr.Split(',');
|
||||||
|
if (unitList.Length >= 3)
|
||||||
|
{
|
||||||
|
string str = "[";
|
||||||
|
for(int j = 0; j < 3; j++)
|
||||||
|
{
|
||||||
|
str = str + unitList[j];
|
||||||
|
if (j != 2)
|
||||||
|
{
|
||||||
|
str = str + ",";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
str = str + "]";
|
||||||
|
edgeList.Add(str);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
JArray ja = new JArray();
|
||||||
|
for (int i = 0; i < edgeList.Count; i++)
|
||||||
|
{
|
||||||
|
JArray unit = (JArray)JsonConvert.DeserializeObject(edgeList[i]);
|
||||||
|
ja.Add(unit);
|
||||||
|
}
|
||||||
|
edgeDict[curIndex] = ja;
|
||||||
|
}
|
||||||
|
GUILayout.EndVertical();
|
||||||
GUILayout.EndArea();
|
GUILayout.EndArea();
|
||||||
if(GUI.Button(new Rect(1050, 10, 100, 30), "导出到Excel"))
|
if(GUI.Button(new Rect(1050, 10, 100, 30), "导出到Excel"))
|
||||||
{
|
{
|
||||||
|
|||||||
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user