Heathcliff Harbrough
King of Dubai
Join date: 30 Jul 2009
Posts: 231
|
09-29-2009 05:00
Dear Sirs,
Well let's make it simple. It must be an elevator system that moves the objects to different heights(tops 3 a 4 meter). I tried several FREE elevators scripts but without positive success.
PLease IM me heathcliff harbrough
Thank you
if i am positive i have more projects in petto
|
Heathcliff Harbrough
King of Dubai
Join date: 30 Jul 2009
Posts: 231
|
Adjusted
09-29-2009 09:04
Topic adjusted. Instead of a bouncing object, just a object that goes up and down. Please understand i pay for this project.
|
Klug Kuhn
Registered User
Join date: 7 Sep 2007
Posts: 126
|
09-29-2009 20:23
You could try this script, simply put it in the object's content and it will go up and down 1 meter in every 0.5 second. You can also adjust the offset and time settings from the first 2 lines of the script.  vector offset = <0.0,0.0,1.0>; // 1m in z-direction float time = 0.5; // 0.5 seconds vector rez_pos = ZERO_VECTOR; integer toggle = TRUE; default { state_entry() { rez_pos = llGetPos(); llSetTimerEvent(time); } on_rez(integer int) { llResetScript(); } timer() { toggle = !toggle; if (toggle) llSetPos(rez_pos + offset); else llSetPos(rez_pos); } }
|
Heathcliff Harbrough
King of Dubai
Join date: 30 Jul 2009
Posts: 231
|
09-30-2009 02:44
From: Klug Kuhn You could try this script, simply put it in the object's content and it will go up and down 1 meter in every 0.5 second. You can also adjust the offset and time settings from the first 2 lines of the script.  vector offset = <0.0,0.0,1.0>; // 1m in z-direction float time = 0.5; // 0.5 seconds vector rez_pos = ZERO_VECTOR; integer toggle = TRUE; default { state_entry() { rez_pos = llGetPos(); llSetTimerEvent(time); } on_rez(integer int) { llResetScript(); } timer() { toggle = !toggle; if (toggle) llSetPos(rez_pos + offset); else llSetPos(rez_pos); } }
Dear sirs, I've tested it and it worked great. I was wondering how i add multiple heights? vector offset = <0.0,0.0,1.0>; // 1m in z-direction vector offset = <0.0,0.0,1.5>; // 1m in z-direction vector offset = <0.0,0.0,0.5>; // 1m in z-direction In order to let it bounce in different Z Directions?
|
Pete Littlebird
Registered User
Join date: 30 Sep 2009
Posts: 44
|
09-30-2009 10:01
list offsets = [<0.0,0.0,0.5>, <0.0,0.0,1.0>, <0.0,0.0,1.5>, <0.0, 0.0, 1.0>]; // 1m in z-direction integer number_of_offsets; float time = 0.5; // 0.5 seconds vector rez_pos = ZERO_VECTOR; integer index = 0; default { state_entry() { number_of_offsets = llGetListLength (offsets); rez_pos = llGetPos(); llSetTimerEvent(time); } on_rez(integer int) { llResetScript(); } timer() { llSetPos(rez_pos + llList2Vector (offsets, index = ++index % number_of_offsets)); } }
|