|
Mrc Homewood
Mentor of Randomness
Join date: 24 Feb 2007
Posts: 779
|
11-01-2007 15:23
ive been looking into this for a wile, i came up with a idea today about making a script that would allow a object to fly around, like a airplane for example, like cubey terra has at his airport, im a intermediate scripter, still have alot to learn but, dose anyone have any idea on how to make it?
|
|
Void Singer
Int vSelf = Sing(void);
Join date: 24 Sep 2005
Posts: 6,973
|
11-02-2007 08:09
you may want to look for the following for RC style objects camera followers non-physical vehicles vehicles some of those will help you get started... you can then use a base object that you 'sit' on that takes control inputs and controls the actual object at a distance
if you are looking for something that just moves in a (relatively) set path, look into llMove2Target and then script it's path
there are also some good pet scripts that do semi-random movement including flight (humming birds, dragonflies, etc)
_____________________
| | . "Cat-Like Typing Detected" | . This post may contain errors in logic, spelling, and | . grammar known to the SL populace to cause confusion | | - Please Use PHP tags when posting scripts/code, Thanks. | - Can't See PHP or URL Tags Correctly? Check Out This Link... | - 
|
|
Atom Burma
Registered User
Join date: 30 May 2006
Posts: 685
|
11-02-2007 08:19
This is a modification of the "Linden Elevator" script I used to move a ski lift in 1 direction back and forth. It uses the key words 'first' and 'second', you have to also say 'align' at the first location to get it to know it's coirdinates. You can modify its axis, right now its E-W if I remember correctly. The reason that you don't see any airplanes around is that you can only link 30 prims in an actual vehicle. And people sitting count for 1 prim. So if you can figure out a way to make an airplane with 25 prims you are all good to go, lol NOTE: I almost forgot, quite obvious if you can read code, I made buttons to say the first, second commands, set to channel 1034, but you can modify that easily key owner; default { state_entry() { owner=llGetOwner(); llListen(1034,"","","first"  ; llListen(1034,"","","second"  ; llSetStatus(STATUS_ROTATE_X|STATUS_ROTATE_Y|STATUS_ROTATE_Z,FALSE); } listen(integer a, string n, key id, string m) { integer x;//looper // For the first floor, we want the elevator to be at its base position, so end(final resting place of the elevator) is the same as pos. I showed the addition of the vector <0,0,0> merely for continuity. The same comments about tau that apply to the llSetHoverHeight, apply to llMoveTarget. if(m=="first"  { for (x=0; x < 6; x++) { llMoveToTarget((llGetPos()+<50,0,0>  ,6.0); llSleep(6); } } if(m=="second"  { for (x=0; x < 6; x++) { llMoveToTarget((llGetPos()+<-50,10,0>  ,6.0); llSleep(6); } } } }
|
|
Mrc Homewood
Mentor of Randomness
Join date: 24 Feb 2007
Posts: 779
|
11-03-2007 09:27
it works prutymuch exacly like i wont it, is there a way to make it go to nect location after geting to that location without a timer messing with the script?
llMoveToTarget(****) //will get to target llMoveToTarget(****) //get to that location //move to next location
more or less like checkpoints
|