ES3Settings Class
Description
The ES3Settings object is used to override default settings (such as encryption settings), and can be used to specify file and directory paths.
Constructors
ES3Settings Constructor | Creates a new ES3Settings object. |
Properties
location | The storage location where we wish to store data by default. |
path | The path this ES3Settings object points to, if any. |
encryptionType | The type of encryption to use when saving data, if any. |
encryptionPassword | The password to use to encrypt the data if encryption is enabled. |
compressionType | The type of compression to use when saving data, if any. |
directory | The default directory in which to store files when using the File save location, and the location which relative paths should be relative to. |
bufferSize | Any stream buffers will be set to this length in bytes. |
encoding | What text encoding to use when writing and reading text from a file. |
Examples
Save data using an ES3Settings object to specify settings.
1 2 3 4 5 6 7 |
// Create a new ES3Settings to enable encryption. var settings = new ES3Settings(ES3.EncryptionType.AES, myPassword); // Change the save location to Resources. settings.location = ES3.Location.Resoucres; // Use the ES3Settings object to encrypt data and save to PlayerPrefs. ES3.Save<Transform>("myTransform", this.transform, settings); |
1 |