|
False Sands
Registered User
Join date: 15 Jun 2007
Posts: 8
|
12-22-2007 17:44
I just can't get this right!! lol, Just wondering if anyone could help me, i just need a script that will make an object float very smoothly, kind of like a balloon. (on rez). please!!!!!!
1. Floats up and down randomly 2.Smooth 3. Average speed
I would be soooo appreciative.
please if anyone can help just Instant message me in the game or drop me a notecard, or if you are just awsome, send me the script! Wooot!
THANK-YOU!!
|
|
Pale Spectre
Registered User
Join date: 2 Sep 2005
Posts: 586
|
12-23-2007 03:16
Hi, False. I'm not going to write you a script. One thing I think you'll find if you work with physical objects is that it's more of an art then a science, and you can spend a lot of time tweaking things to fit your particular needs. However, here are some basics tips: To make the object physical, ie. capable of floating: llSetStatus(STATUS_PHYSICS, TRUE); To make the object float: llSetBuoyancy(1.0); Float up gently: llSetBuoyancy(1.01); Float down gently: llSetBuoyancy(0.99); Drop like a stone: llSetBuoyancy(0.0); Nudge it gently: llApplyImpulse(<0.1, 0.0, 0.0>, TRUE); Warning: It is very easy to lose control of physical objects. So, experiment with small values and work in a contained area. Resist creating lots of physical objects until you're very confident you have things under control. It can, and does, get messy. Good luck! 
|
|
False Sands
Registered User
Join date: 15 Jun 2007
Posts: 8
|
12-23-2007 11:07
Thanx pale,
ya, i knew most of that, the big help was the llApplyImpulse(<0.1, 0.0, 0.0>, TRUE);
Thanx Alot that should do it!
|
|
Xhawkx Holden
Registered User
Join date: 1 Nov 2006
Posts: 86
|
12-23-2007 11:22
You probably want to use the llGetMass also... this help to set the proportion for the apply impulse. The mroe mass.. the more impulse needed..
|
|
Void Singer
Int vSelf = Sing(void);
Join date: 24 Sep 2005
Posts: 6,973
|
12-23-2007 20:22
to add to what hawk said something like float vFltMass = llGetMass() * .1; llApplyImpulse( vFltMass * llVecNorm( <.0, .0, 1.0> ), TRUE );
vecnorm is not neccessary if you have a total of 1 for all fields in the vector, I included it in case you wanted to do more than move in one axis
_____________________
| | . "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... | - 
|