Scene Reference serialization #26
-
Hi!
Andrea PS: I'm also new to GitHub, so forgive me if I'm asking things the wrong way or in the wrong place |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 3 replies
-
Hello, Don't worry, you asked your question in the right place. Can you give me a little more detail on exactly what you are trying to do? Are we talking about Unity's binary serialization or something else? Also, can you kindly share the full exception you are getting, along with the steps to reproduce it? |
Beta Was this translation helpful? Give feedback.
-
OK, I think I understand what you are trying to do. I will test myself to see what problems binary serialization would have. As a sidenote, to prevent confusion, this is not the binary serialization of Unity, this is your custom binary serialization solution. In the meantime, however, I think you have a much more elegant way to tackle this issue. Instead of serializing the whole |
Beta Was this translation helpful? Give feedback.
-
Support for custom serialization is included in 1.4.0. |
Beta Was this translation helpful? Give feedback.
OK, I think I understand what you are trying to do. I will test myself to see what problems binary serialization would have. As a sidenote, to prevent confusion, this is not the binary serialization of Unity, this is your custom binary serialization solution.
In the meantime, however, I think you have a much more elegant way to tackle this issue. Instead of serializing the whole
SceneReference
to your save file, you can just serialize the GUID of the scene. You can get it viamySceneReference.AssetGuidHex
. Then, in the runtime, you can access the scene GUID to scene path map directly, and load the scene from its path.