pBytes = cocos2d::CCFileUtils::sharedFileUtils()->getFileData("Book1.json","r", &size); CC_BREAK_IF(pBytes == NULL || strcmp((char*)pBytes,"") == 0); std::string load_str((constchar*)pBytes, size); CC_SAFE_DELET
local str = cc.FileUtils:getInstance():getStringFromFile("xxxx.json") local ok, datatable = pcall(function() return cjson.decode(str) end) if true == ok and type(datatable) == "table" then dump(datatable, "文字", 6) --todo else --todo end...