TrimList

From Second Life Wiki
Jump to navigation Jump to search

this function will trim a list of strings for the output of a dialog box.

Function <source lang="lsl2"> list TrimList(list dlist, integer length) {

   integer i;
   integer dl = llGetListLength(dlist);
   list temp = [];
   while(~--dl)
       temp += llGetSubString(llList2String(dlist,i++),0, length-1);
   return temp;

}

</source>