Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Found a Reproducable Crash

Madox Kobayashi
Madox Labs R&D
Join date: 28 Jun 2003
Posts: 402
07-03-2003 17:41
I was sitting down to create a debugging tool and the first thing was going to be dealing with statuses. So first I needed a mapping of status codes to text.

I entered this:

list statuses = [ [STATUS_PHYSICS, "physics"], [STATUS_PHANTOM, "phantom"] ];

I tried to save it and the game crashed hard.

Turns out, list x = [ [ 1 ] ]; will crash the game.
But:
list x = [1];
list y = [x];
gives a nice warning message that you cant do this.

Both syntaxes should ptrobably give the warning :p

On another note: I'm a bit sad that list in a list can not be done. Not only for applications such as my mapping, but I was hoping it might be a work around way to get a pointer :p
_____________________
Madox Kobayashi

Andrew Linden
Linden staff
Join date: 18 Nov 2002
Posts: 692
07-08-2003 10:53
Thanks, I'll try to reproduce this.
Ama Omega
Lost Wanderer
Join date: 11 Dec 2002
Posts: 1,770
07-08-2003 13:25
Workaround to list in a list.

Use llList2CSV and llCSV2List on the list to be stored in the other list. I have yet to meet a list I couldn't cram into a string. ;) It's not as nice or pretty but it works. One coveat, anything you pull out of a list made from a CSV2List will be a string. Which means you need to cast it back to what it should be.

For more advanced (a list in a list in a list) .... after you take your asparin bust out the llParseString (I'm at work that may not be what it is called). And use a different seperator.
Andrew Linden
Linden staff
Join date: 18 Nov 2002
Posts: 692
07-10-2003 13:43
This crash-bug has been fixed on our development version and wil be included in the 1.1 release or else in a 1.0.x patch (not sure yet).

The script will now declare a runtime error and inform you that lists within lists are not supported.
Tcoz Bach
Tyrell Victim
Join date: 10 Dec 2002
Posts: 973
07-12-2003 10:47
You can insert lists into lists...sort of.

ListInsertList will return a list that is the result of the old list plus the new list inserted at index. I use this in my multidim functions.

Not exact but close.
_____________________
** ...you want to do WHAT with that cube? **