参考文档:
http://www.wraiyth.com/?p=198 //create and serialize Json in UE4.
http://www.wraiyth.com/?p=222 //deserialize Json in UE4
//文件管理操作(包括路径)(读写普通的文件,二进制文件)
https://wiki.unrealengine.com/File_Management,_Create_Folders,_Delete_Files,_and_More
源代码路径:
Engine-Source-Runtime-Json;
Engine-Source-Runtime-JsonUtilities;
//路径,读写文件工具类
FPaths,FFileHelper
注意:
1.类型只能为:bool;number;FString;
2.TSharedPtr<FJsonObject> t_ptr;需要先判断共享指针是否为空,再判断里面是否有值:
比如:if (_ptrJsonObj.IsValid()&&_ptrJsonObj->Values.Num()>0);注意前面为点,空面为指针。
3.存取路径文件时,需要先判断是否已经存在。
序列化:
1.在build.s里加入两个模块:Json and JsonUtilities。
2.