Join us in Outworldz at www.outworldz.com:9000 or follow us:

Search dozens of selected web sites for OpenSim and LSL script

New! Script Meta-Search will search thousands of scripts here and at other sites for LSL or Opensim scripts.
Loading

Want to add a script or a project? Upload it and a half million people will see it and your name here this year.

Home   Show All
Category: Contributor: Creator
Rezzers Rez_a_Bowling_Pin_above_a_prim  

Rez_a_Bowling_Pin_above_a_prim

Rez_a_Bowling_Pin_above_a_prim

Category: Rezzers
By : Martin
Created: 2010-06-21 Edited: 2010-06-21
Worlds: Second Life

the Zip file

Download all files for Rez_a_Bowling_Pin_above_a_prim
Contents are in zip format, with .LSL (text) source code and LSLEdit (text + Solution) formats.
Get file # 1. Rez_a_Bowling_Pin_above_a_prim_1.lsl
1 string object = "bowling_pins"; // Name of object in inventory
2 vector relativePosOffset = <-0.5, 0.0, .0>; // "Forward" and a little "above" this prim
3 vector relativeVel = <0.0, 0.0, 0.0>; // Traveling in this prim's "forward" direction at 1m/s
4 rotation relativeRot = <0.0, 0.0, 0.0, 0.0>; // Rotated 90 degrees on the x-axis compared to this prim
5 integer startParam = 10;
6
7 default
8 {
10 {
11 llListen(0,"","","");
12 }
13 listen(integer channel,string name,key id,string message)
14 {
15 if(id == llGetOwner())
16 {
17 if(message == "")
18 {
20 }
21 else if(message == "reset")
22 {
24 }
25
26 }}timer()
27 {
28
29 {
30 vector myPos = llGetPos();
31 rotation myRot = llGetRot();
32
33 vector rezPos = myPos+relativePosOffset*myRot;
34 vector rezVel = relativeVel*myRot;
35 rotation rezRot = relativeRot*myRot;
36
37 llRezObject(object, rezPos, rezVel, rezRot, startParam);
39
40 }
41 }}

Back to the Best Free Tools in Second Life and OpenSim.