public static string AppContentPath() { string path = string.Empty; switch (Application.platform) { case RuntimePlatform.Android: path = "jar:file://" + Application.dataPath + "!/assets/"; break; case RuntimePlatform.IPhonePlayer: path = Application.dataPath + "/Raw/"; break; default: path = Application.streamingAssetsPath + "/"; break; } return path; }
static int AppContentPath(IntPtr L) { try { ToLua.CheckArgsCount(L, 0); string o = Tools.AppContentPath(); LuaDLL.lua_pushstring(L, o); return(1); } catch (Exception e) { return(LuaDLL.toluaL_exception(L, e)); } }