Object rez

From Second Life Wiki
Revision as of 06:53, 13 July 2015 by Rolig Loon (Talk | contribs)

Jump to: navigation, search


Event: object_rez( key id ){ ; }

Triggered when the object rezzes an object.

• key id UUID of object rezzed.


  • Triggers in all running scripts with an object_rez event, AND in the same prim as the script calling llRezObject or llRezAtRoot.
    • Does NOT trigger in linked prims.
  • A message sent to the rezzed object may arrive before the object has opened a channel and is ready to receive it unless you include a brief delay ( llSleep(0.2) ) in the object_rez event.
All Issues ~ Search JIRA for related Bugs


//gives inventory to object when it rezzes.
string inventory;
string object;
    touch_start(integer count)
        object=llGetInventoryName(INVENTORY_OBJECT,0);  //get name of the 1st object in inventory
        llRezObject(object, llGetPos() + <0.0, 0.0, 0.5>, ZERO_VECTOR, ZERO_ROTATION, 0);  //rez the 1st object
    object_rez(key id)
        inventory=llGetInventoryName(INVENTORY_OBJECT,1);  //get name of the 2nd object in inventory
        llGiveInventory(id,inventory);  //give 2nd object to 1st object when rezzed

See Also


•  on_rez Triggered when the object the script is in is rezzed


•  llRezObject Used to rez an object at the center of mass
•  llRezAtRoot Used to rez an object at the root

Deep Notes


All Issues

~ Search JIRA for related Issues
   object_rez() erroneously triggers on full parcel
   Possible Mono bug with object_rez


event void object_rez( key id );