Mintoris Forum

Author Topic: loadcode$() issue  (Read 2991 times)

suduadib

  • Full Member
  • ***
  • Posts: 15
loadcode$() issue
« on: Jul 27, 2016, 01:10 PM »
Bonjour,

It appears that loadcode$(x, code$) crashes Mintoris when x is a non-empty arraylist data structure.

do you can test?

x=createarraylist()
code$=savecode$(x)
print code$
wait
loadcode$(x,code$) … works


x=createarraylist()
a=1
put x,a
code$=savecode$(x)
print code$
wait
loadcode$(x,code$) … crash

Thanks

Chuck

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1899
Re: loadcode$() issue
« Reply #1 on: Jul 27, 2016, 04:23 PM »
Thanks for reporting this problem. I will try to get it fixed by the end of the day.

suduadib

  • Full Member
  • ***
  • Posts: 15
Re: loadcode$() issue
« Reply #2 on: Jul 27, 2016, 05:01 PM »
Super, savecode$() loadcode$() mecanic is definitely a great idea

Chuck

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1899
Re: loadcode$() issue
« Reply #3 on: Jul 27, 2016, 10:37 PM »
I just released 7.3.3 to fix this problem. Give it a few hours to work it's way through the system.

suduadib

  • Full Member
  • ***
  • Posts: 15
Re: loadcode$() issue
« Reply #4 on: Jul 28, 2016, 07:53 AM »
Thank you Chuck, you are the best.

(I use arraylist of arraylist for encoding graphs)




Chuck

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1899
Re: loadcode$() issue
« Reply #5 on: Jul 28, 2016, 05:32 PM »
Great, it's so good to see some of the new features being used. Let me know if you have any other problems.

Chuck

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1899
Re: loadcode$() issue
« Reply #6 on: Jul 28, 2016, 08:21 PM »
I've just released Basic 7.3.4 to fix some other SaveCode$() issues I discovered over night.

Strings and string arrays will now be automatically UTF-8 encoded within the save code. This is transparent to you as the programmer. By encoding the strings as UTF-8 you can have the tab character and any other binary data in a string and it will not affect the save code format.

There was also a problem with the encoding of a sprite's hash table.

Under the hood these commands are complex and recursive, but I think this system is working fairly well now.
« Last Edit: Jul 29, 2016, 07:29 PM by Chuck »

Chuck

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1899
Re: loadcode$() issue
« Reply #7 on: Jul 31, 2016, 01:54 AM »
Let me know how the load/save commands are working for you. I'm very interested.

Save and Load Variables
« Last Edit: Aug 03, 2016, 12:23 AM by Chuck »

suduadib

  • Full Member
  • ***
  • Posts: 15
Re: loadcode$() issue
« Reply #8 on: Jul 31, 2016, 03:53 PM »
So far everything is perfect :-)

WandaTog

  • Full Member
  • ***
  • Posts: 15
loadcode issue
« Reply #9 on: Oct 21, 2019, 07:38 AM »
Thanks for the upgrade  We definitely appreciate it.

I'm going to look into the issue further for future reference and see what I can come up with.  It might actually be the recurring payment, as you mentioned.  Unfortunately, the forum software defaults to recurring payments for upgrades, wih no way that I could find to change that.