Jump to content

Pavcules Superior

Resident
  • Posts

    0
  • Joined

  • Last visited

Posts posted by Pavcules Superior

  1. Just to say, becareful on using the new function in making things.   It is possible that the Server Update with fhis function can be rolled back.

    Although gaining this new function, we have now lost the 3 new LSL functions I mentioned the other week.  Not sure when they will return.

  2. Just need to point out, there seems to be some on-going problems with the Server Updates, as the server release with the script functions keep getting rolled back.  There is other fixes in the server release as well.

    http://wiki.secondlife.com/wiki/Release_Notes/Second_Life_RC_LeTigre/11#11.04.22.227477

    On the sim I work on these functions were working, but since April 27th, the scripts that had these functions stopped working.  So if you do get some non-execution of scripts with these new functions, check your server not been rolled back with the upgrades again.

  3. For those who are unaware, we have seen to have got several new LSL functions, as the the LSL Functions section of the WIki has been recently updated.  http://wiki.secondlife.com/wiki/Category:LSL_Functions

     

    The following functions seem to be working in SL without problems.

    llGetUsedMemory - http://wiki.secondlife.com/wiki/LlGetUsedMemory

    llScriptProfiler - http://wiki.secondlife.com/wiki/LlScriptProfiler

    llGetSPMaxMemory - http://wiki.secondlife.com/wiki/LlGetSPMaxMemory

     

  4.  


    CrystalShard Foo wrote:

     No offense, but isn't this a somewhat overly-complicated way to send strings from one script to another? Why not just use the built in link message functionality?

     

     

    Sending information via Linked Messages is perfectly okay, and I use it all the time.  The LSL Library Function System shows the ability of calling functions from other scripts, but returns the function result on the line it is currently executing on.   So if you are running some code, but do not want to stop the flow of things, then the Description polling is currently the easiest way around the problem.

     

    So, for example:    (CallFunction would be the function in the script to handle the data transfer via the Description)

    string strValue = CallFunction("Text","ReverseString","Hello");    // Call ReverseString function in other script, and get the result.

    llOwnerSay("Reversed: " + strValue);    // Output the result.

     

    But, using the Linked Message appraoch, you would have a complicated setup.  You would have to fire the Linked Message, then wait for a Linked Message from the other script.  And then call another function / place code in the message event to carry on triggering the rest of the code, which would be very messy.

    ReverseString()

    {

    llLinkedMessage(LINK_THIS,1234,"ReverseString=Hello",NULL_KEY);     // Send message to other script. and wait for linked message response.

    }

    state_entry()

    {

        ReverseString();     // Start executing.

    }

    linked_message(...etc..)

    {

      if(message=="ReverseStringResult")                // Message retrieved from other script.

      {

            strValue = ... Extracted Result.

           llOwnerSay("Reversed: " + strValue);    // Output the result.

           // Carry on executing the rest of the code, etc.

     }

    }

     

     

     

     

     

  5. Hi Domitan,

    Yes it is possible to create your own function libraries by using the Prim "Description" field hack.

    When Script A calls a function in Script B, it first issues a Linked Message command.  After Script A has issued the command, then sits in a Loop polling the Description field.  Script B will process the message, executes the required command, and the output passed via the Description field.  Script A notices a change in the Description filed, processes the information, and returns the result.

    Ok, it won't be the fastest or neatest way, but it works!

    You can download the LSL Library Function System from the Marketplace (free of charge), which demostrates this technique.

    https://marketplace.secondlife.com/p/LSL-Library-Function-System-Powerful-set-of-functions-to-make-scripting-easier/354418

    Have fun.

×
×
  • Create New...