blob: 6d7b360c56aa5ff9eea7d2ff6e5eea0f8b3ffe81 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
integer mychannel = -8888;
integer particle_chan = -270510;
string listenfor;
string response;
string detach;
key masterid;
key handle;
default
{
state_entry()
{
masterid = llGetOwner();
handle = llGetKey();
listenfor = (string)masterid + "handle";
response = (string)masterid + "handle ok";
detach = (string)masterid + "handle detached";
llListen(mychannel, "", NULL_KEY, listenfor);
llSay(mychannel, response);
}
attach(key id)
{
if (NULL_KEY == id)
llSay(mychannel, detach);
}
listen(integer channel, string name, key id, string message)
{
llSay(mychannel, response);
llSay(particle_chan, handle + "#" + masterid);
}
on_rez(integer param)
{
llResetScript();
}
touch_start(integer total_number)
{
llSay(particle_chan, handle + "#" + masterid);
}
}
|