You are currently in the Forum Archive. All content within this area is Read-Only and cannot be modified. Active Forums can be found here.
Reply
Honored Resident
Tails Zelin
Posts: 13

Please help with a cloak script ^^

If someone can help me with this simple script it would make me so happy right now. So can someone show me how to do this or do it for me.I just really need this script ad i been trying to do it. But every time i fail i have never done these before and i am bit confused. So what i need is a script to uncloak the single object and turn cloak by a comand like /SykesRazz or :smileytongue:. After that the cloaked prim becomes visible then after 5 seconds it goes invisible again. Thanks alot people for your time looking at this. ^^ To be basic the prim will start cloaked but the person types /sykesrazz or ;p the prim thats cloaked becomes visible but after 5 seconds the prim goes in invisible again.

The script i was useing to mod

default
{
state_entry()
{
key owner = llGetOwner();
llWhisper(100,"Cloaking ready");
llListen(5,"",owner,"");
}

listen( integer channel, string name, key id, string message )
{
if( message == "cloak" )
{
llSetStatus(STATUS_PHANTOM, TRUE);
llWhisper(100,"Cloaking");
llSetAlpha(0,ALL_SIDES);
}
if( message == "uncloak" )
{
llSetStatus(STATUS_PHANTOM, FALSE);
llWhisper(100,"Uncloaking");
llSetAlpha(1,ALL_SIDES);
}
}
}

Rolig Loon
Posts: 24,907
Registered: ‎10-05-2009

Re: Please help with a cloak script ^^

Reply to Tails Zelin - view message

You almost have it.  All you need is a timer. Here's one way to do it.

default
{
    state_entry()
    {
        llWhisper(0,"Cloaking ready"); //I assume that you want it to whisper in public chat, right?
        llListen(5,"",llGetOwner(),"");
    }

    listen( integer channel, string name, key id, string message )
    {
        if( message == "/SykesRazz" || message == ":smileytongue:" )
        {
            llSetStatus(STATUS_PHANTOM, FALSE);
            llWhisper(0,"Uncloaking");
            llSetAlpha(1.0,ALL_SIDES);
            llSetTimerEvent(5.0);
        }
    }

    timer()
    {
        llSetStatus(STATUS_PHANTOM, TRUE);
        llSetAlpha(0.0,ALL_SIDES);
        llSetTimerEvent(0.0);  //Turns the timer off again
    }
}

BTW, I don't know why you want to change phantom, but I left that alone.

Not as dumb as I look
Honored Resident
Tails Zelin
Posts: 13

Re: Please help with a cloak script ^^

Reply to Tails Zelin - view message

Its for an avi head the tongue is going to stick out when the gesture i played.

Honored Resident
Tails Zelin
Posts: 13

Re: Please help with a cloak script ^^

Reply to Tails Zelin - view message

Ok its already has to be invisible. now when the person type the comand it becomes visible. Now when the timer is up it becomes invisible again.

Honored Resident
Tails Zelin
Posts: 13

Re: Please help with a cloak script ^^

Reply to Tails Zelin - view message

Thanks alot for helping me with this script ^^