示例#1
0
 /// <summary>
 /// Quick file saving
 /// </summary>
 /// <param name="location">Location of file. Must include file name.</param>
 /// <param name="contents">Contents of file</param>
 /// <param name="filesystem">Predefined filesystem</param>
 /// <param name="owner">Owner of file?</param>
 public void saveFile(string location, string contents, IO.FileSystem.VirtualFileSystem filesystem, string owner = "root")
 {
     byte[] dat = new byte[contents.Length];
     for (int i = 0; i < contents.Length; i++)
     {
         dat[i] = (byte)contents[i];
     }
     filesystem.saveFile(dat, location, owner);
 }