I am using ES3 with encryption to store data in my ios game. It works fine when I build it manually on my mac, but when the app is built by Unity Cloud build, it fails like that:
Code: Select all
ArgumentOutOfRangeException: Positive number required.
Parameter name: bufferSize
at System.IO.FileStream..ctor (System.String path, System.IO.FileMode mode, System.IO.FileAccess access, System.IO.FileShare share, System.Int32 bufferSize, System.Boolean anonymous, System.IO.FileOptions options) [0x00000] in <00000000000000000000000000000000>:0
at System.IO.FileStream..ctor (System.String path, System.IO.FileMode mode, System.IO.FileAccess access, System.IO.FileShare share, System.Int32 bufferSize, System.Boolean useAsync) [0x00000] in <00000000000000000000000000000000>:0
at ES3Internal.ES3Stream.CreateStream (ES3Settings settings, ES3Internal.ES3FileMode fileMode) [0x00000] in <00000000000000000000000000000000>:0
at ES3Writer.Create (ES3Settings settings, System.Boolean writeHeaderAndFooter, System.Boolean overwriteKeys, System.Boolean append) [0x00000] in <00000000000000000000000000000000>:0
at ES3.Save[T] (System.String key, System.Object value, ES3Settings settings) [0x00000] in <000<…>
I have found this thread describing similar problem:
https://moodkie.com/forum/viewtopic.php?f=13&t=1483
The advice was to remove Assembly-CSharp-firstpass from the Assemblies in the settings. Can someone explain to me why this is happening and why default settings won't work? I am only saving basic types, not using scene saving etc.
Thank you!