Jump to content

llObjectDesc Question


Wandering Soulstar
 Share

You are about to reply to a thread that has been inactive for 3203 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

Hi All,

In a script I am working on I use the description field to store data for persistence across resets. On start up I basically do:

 

string storage = llStringTrim(llGetObjectDesc(), STRING_TRIM);

if (storage != "")
{
     //Do some stuff with the data

}
else
{
    //Do default stuff
}

Which is all well and good, except ... if a prim has been taken into inventory with nothing entered into the desciprion field, when it rezes again it now has (no description) in the dewscription field, and so the check for "" fails. I can obviously check for that string as well, but here my question: Does the value (no description) that is added to the prim when taken into inventory change depending on the language of the user/viewer, or is consistent?

Thanks in advance!!!

 

Wanda Soulstar

Link to comment
Share on other sites

If it's in an attachment, and your using the root prim, change it to a description of a child prim,

llGetLinkPrimitiveParams( 2, [ PRIM_DESC ]);   

If it's not in the root, it's reading the description of the prim it's in.  you could change it to read the root, llList2String(llGetLinkPrimitiveParams(LINK_ROOT, [ PRIM_DESC ]), 0); 

or use the first fix to read the prim it's in.

see caveats here:

http://wiki.secondlife.com/wiki/LlGetObjectDesc

 

 

 

 

Link to comment
Share on other sites

You are about to reply to a thread that has been inactive for 3203 days.

Please take a moment to consider if this thread is worth bumping.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...