User:Daemonika Nightfire/Scripts/Anti Rezz

From Second Life Wiki
Jump to navigation Jump to search
⚠️ Warning: There are no scripts available in Second Life that can protect objects against copybots!
  • It is unrealistic to believe that the control event is of any use here, because if scripts are already disabled on the parcel, a script like this cannot even start in the first place. I have also seen creators trying to force such scripts into working with brute force like methods, but the only result is unnecessary lag. It does not improve anything when both version 1 and version 2 are placed into the same object, the effect remains exactly the same, if scripts are already disabled on the parcel before rezzing, any object can still be rezzed on the ground without issue.
  • If clothing is stuffed with useless scripts like these, it can even cause customers to be kicked or banned from certain locations because they may end up wearing too many scripts without even knowing it. The result is simple, your clothing will not be seen in clubs or similar places, which also means no free advertising for your products.

*DS* Anti Rezz

  • Thats just a great tool to annoy your customers. It delete the complete object by rezzing on ground.
/*
    *DS* Anti Rezz
    Dear content creator, this script will not protect your creations from copybots.
    It is nothing more than a stupid placebo, because a copybot only needs a few seconds to copy everything it can see.
    Rezzing is not required for that, mesh objects and attachments are equally insecure.
    This script also does not work on no-script parcels, even if it requests control permissions, because it cannot start on parcels where scripts are disabled.
    
    The only thing you achieve with scripts like this is losing customers.
*/

default
{
    on_rez(integer Dae)
    {
        if(llGetAttached() == 0) // check for rezzing on ground
        {
            llSay(0, "This placebo delete your object when you rez it on ground");
            llDie(); // delete the complete object
        }
    }
}

*DS* Anti Rezz & DEMO Detach

  • It delete the complete object by rezzing on ground and detach it after 5 minutes from avatar.
/*
    *DS* Anti Rezz
    Dear content creator, this script will not protect your creations from copybots.
    It is nothing more than a stupid placebo, because a copybot only needs a few seconds to copy everything it can see.
    Rezzing is not required for that, mesh objects and attachments are equally insecure.
    This script also does not work on no-script parcels, even if it requests control permissions, because it cannot start on parcels where scripts are disabled.
    
    The only thing you achieve with scripts like this is losing customers.
*/

integer Limit = 300;    // 5 minutes
integer count = 0;      // empty counter

default
{
    state_entry()
    {
        //llSay(0, "Hello, Avatar!");
    }
    
    attach(key id) // gets AvatarKey who wear it automatically
    {
        if(id) // check the available key
        {
            llRequestPermissions(id, PERMISSION_ATTACH); // asks for permissions to attach/detach
        }
    }
    
    run_time_permissions(integer perm)
    {
        if(perm & PERMISSION_ATTACH) // check the requested permission
        {
            if(count < Limit) // check the counter-limit
            {
                llSetTimerEvent(1); // start the timer
                llSay(0, "This placebo detach your object after 5 minutes.");
            }
            else if(count >= Limit) // check the counter-limit
            {
                llSay(0, "Time's up, this placebo will now always remove the object immediately.");
                llDetachFromAvatar(); // detach the object from avatar when permission is given
            }
        }
    }

    timer()
    {
        if(count == Limit) // check the counter-limit
        {
            llSetTimerEvent(0); // stop the timer
            llDetachFromAvatar(); // detach the object from avatar when permission is given
            return; // leave the event immediately
        }
        count += 1; // counts the seconds
    }
    
    on_rez(integer Dae)
    {
        if(llGetAttached() == 0) // check for rezzing on ground
        {
            llSay(0, "This placebo delete your object when you rez it on ground");
            llDie(); // delete the complete object
        }
    }
}