Don't click here unless you want to be banned.

LSL Wiki : ExampleAttachmentTypeChecker

HomePage :: PageIndex :: RecentChanges :: RecentlyCommented :: UserSettings :: You are crawl338.us.archive.org
// Attachment Type Checker 1.0
// Is this object a HUD attachment, a regular attachment, or is it unattached?


checkAttachmentSlot()
{
    integer slot = llGetAttached();
    if (slot == 0)
    {
        llOwnerSay("Not attached.");
    }

    else if (slot > 0 && slot <= 30)
    {
        llOwnerSay("Attached to the avatar.");
    }

    else if (slot > 30 && slot <= 38)
    {
        llOwnerSay("Attached to the HUD.");
    }
}


default
{
    state_entry()
    {
        checkAttachmentSlot();
    }

    on_rez(integer start_param)
    {
        llResetScript();
    }

    attach(key id)
    {
        llResetScript();
    }
}


Examples | Attachments | llGetAttached
There is no comment on this page. [Display comments/form]