ExtractAssets allows to extract folders and files from your compiled APK to the local storage.
But it works for local DroidScript projects as well. When override is false, already existant files will be kept and not overridden.
Example - Extract File
function OnStart()
{
app.WriteFile( "myData.txt", "main: " + app.GetAppName() );
app.ExtractAssets( "myData.txt", "/sdcard/myData.txt" );
app.Alert(app.ReadFile("/sdcard/myData.txt"));
}
Example - Extract Folder
function OnStart()
{
app.MakeFolder( app.GetAppPath() + "/myFolder" );
app.WriteFile( app.GetAppPath() + "/myFolder/myData.txt", "main: " + app.GetAppName() );
app.ExtractAssets( "myFolder", "/sdcard/myFolder" );
app.Alert(app.ReadFile("/sdcard/myFolder/myData.txt"));
}