Dynamic Array of Bytes
Options
Manmax75
✭
in Photon Bolt
Hey all,
I'm just wondering if anyone has come up with a solution to syncing a varying size array of bytes. Currently Bolt supports fixed sizes in its properties but nothing for an array who's size may change. I have used streams in the past, but they seem like an unnecessarily bulky side-step for what I'm trying to achieve.
Any suggestions are greatly appreciated
Thanks!
I'm just wondering if anyone has come up with a solution to syncing a varying size array of bytes. Currently Bolt supports fixed sizes in its properties but nothing for an array who's size may change. I have used streams in the past, but they seem like an unnecessarily bulky side-step for what I'm trying to achieve.
Any suggestions are greatly appreciated
Thanks!
0
Comments
-
You will probably want to use streaming for syncing like this0
-
I remember way, way back when fholm said he had a solution for this and was going to put it in; alas, that was like February or something and was only casually mentioned in the jabbr chat.
I was thinking... can you send tokens and use it to determine the size of the expected array and then serialize/deserialize a number of objects based on that, but it's probably just as effective (or less) than streaming bytes.0 -
If you send tokens you can just use them to hold your byte arrays. I noticed in the latest update that tokens are now a syncable property. And I was curious to see if bolt syncs them on change just like any other property type.Yukichu said:I remember way, way back when fholm said he had a solution for this and was going to put it in; alas, that was like February or something and was only casually mentioned in the jabbr chat.
I was thinking... can you send tokens and use it to determine the size of the expected array and then serialize/deserialize a number of objects based on that, but it's probably just as effective (or less) than streaming bytes.0