Str_to_Int not working in BMax, why?

BlitzMax Forums/BlitzMax Programming/Str_to_Int not working in BMax, why?

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

Koriolis I have to say I'm Impressed! The code is public right?
Thanks. And yes it's public.

Because it is a very very convinient way to do it, but it adds uneccecery data. Perhaps some bytes +/- doesn't matter in the end.. I don't know.
If you read the whole thread you'll see a function that returns the length of the packed integer. It's called VarLenStrLen and returns the size of the *first* packed integer in the string. With it you do not need any separator, just concatenate every packed value, and extract them one by one on the other side (get the extracted value with VarLenStrToInt, then get the size of the packed int just extracted and trash these characters - ie keep the rightmost characters, minus the N characters just extracted -. Then continue until there is no data anymore).
In your example this means 5 to 10 bytes needed rather than 9 to 14.

Also this a very good way to send changes (delta) because they are usually small.
Yep. Generally speaking the method is efficient because integers values that a program manipulate tend to be pretty small.