Unity3D Json

读取:
JSONNode jdNodes = JSONNode.Parse((Resources.Load("Rich/Map/level_unlock",typeof(TextAsset)) as TextAsset).ToString());
or
guide_json = JSONNode . Parse (( Resources . Load ( "Mt/Task/guide" , typeof ( TextAsset )) as TextAsset ). text );
写入:
string strJd = jdAniList.ToJson();
AnimationJsonFilePath = Application.dataPath + "/Resources/Rich/Map/AnimationTxtData";
StreamWriter sw = new StreamWriter(AnimationJsonFilePath + ".txt", false);
sw.Write(strJd);
sw.Close();


你可能感兴趣的:(json,代码,unity3d)