-
Notifications
You must be signed in to change notification settings - Fork 0
/
rezzerExploit.lsl
27 lines (27 loc) · 997 Bytes
/
rezzerExploit.lsl
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
integer channel;
string object = "Object2"; // Name of object in inventory
vector relativePosOffset = < 2.0, 0.0, 1.0 > ; // "Forward" and a little "above" this prim
vector relativeVel = < 1.0, 0.0, 0.0 > ; // Traveling in this prim's "forward" direction at 1m/s
rotation relativeRot = < 0.707107, 0.0, 0.0, 0.707107 > ; // Rotated 90 degrees on the x-axis compared to this prim
integer startParam = 10;
default {
touch_start(integer num_detected) {
llResetTime();
channel = llRound(llFrand(10000));
llSetTimerEvent(0);
llDialog(llDetectedKey(0), "Touch me for more than 2 seconds to start, else I'll stop", ["Ok"], channel);
}
touch_end(integer num_detected) {
if (llGetTime() >= 2) {
llSetTimerEvent(2);
}
}
timer() {
vector myPos = llGetPos();
rotation myRot = llGetRot();
vector rezPos = myPos + relativePosOffset * myRot;
vector rezVel = relativeVel * myRot;
rotation rezRot = relativeRot * myRot;
llRezObject(object, rezPos, rezVel, rezRot, startParam);
}
}