Difference between revisions of "CHANGED REGION START"

From Second Life Wiki
Jump to navigation Jump to search
m (Replaced <source> with <syntaxhighlight>)
 
(4 intermediate revisions by 3 users not shown)
Line 6: Line 6:
|notes=When a region is (re)started all [[http request|HTTP server]] URLs are automatically released and invalidated.
|notes=When a region is (re)started all [[http request|HTTP server]] URLs are automatically released and invalidated.
|examples=
|examples=
<lsl>
<syntaxhighlight lang="lsl2">
default
default
{
{
     changed(integer change)
     changed(integer change)
     {
     {
        if (change & CHANGED_REGION_START) //note that it's & and not &&... it's bitwise!
    // note that it's & and not &&... it's bitwise!
         { //As of October 25, 2009 on the llOwnerSay only works while you are in the same region.
        if (change & CHANGED_REGION_START)
          //If you Teleported to another region and waiting for that message, try the llInstantMessage line instead.
         {
             llOwnerSay("The region has come online.");
            key owner = llGetOwner();
             llInstantMessage(llGetOwner(),llKey2Name(llGetOwner()) + ", your region, " + llGetRegionName() + " has restarted.");
             string region = llGetRegionName();
             llInstantMessage(owner, "Region '" + region + "' has restarted.");
         }
         }
     }
     }
}
}
</lsl>
</syntaxhighlight>
|functions=
|functions=
{{LSL DefineRow||[[llRequestSimulatorData]]|}}
{{LSL DefineRow||[[llRequestSimulatorData]]|}}

Latest revision as of 02:49, 17 June 2023

Description

Constant: integer CHANGED_REGION_START = 0x400;

The integer constant CHANGED_REGION_START has the value 0x400

The region containing the object has just come online.

Caveats


Related Articles

Functions

•  llRequestSimulatorData

Events

•  changed

Examples

default
{
    changed(integer change)
    {
    //  note that it's & and not &&... it's bitwise!
        if (change & CHANGED_REGION_START)
        {
            key owner = llGetOwner();
            string region = llGetRegionName();
            llInstantMessage(owner, "Region '" + region + "' has restarted.");
        }
    }
}

Notes

When a region is (re)started all HTTP server URLs are automatically released and invalidated.

Deep Notes

History

Search JIRA for related Issues

Signature

integer CHANGED_REGION_START = 0x400;