Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

llAirPressure()

Cid Jacobs
Theoretical Meteorologist
Join date: 18 Jul 2004
Posts: 4,304
11-22-2005 04:11
float llAirPressure(vector offset)

Returns the air pressure at the current position + offset.

How air pressure works:

* The X and Y values in the vector are irrelevant (air pressure is based on absolute height).
* It returns a float value of air pressure in KiloPascal.

The math for this function is easy enough to implement, but can anyone see any real use for it? Other than the obvious air pressure gauge. Would making it an actual LSL function prompt anyone to use it more often then calculating the pressure via math? I am rather curious if I am alone or not in my quest for more LSL weather functions, post if you have any thoughts on this function please and its potential usefulness or unusefulness.

~Cid
_____________________
Strife Onizuka
Moonchild
Join date: 3 Mar 2004
Posts: 5,887
11-22-2005 06:36
What would you use this for?

would it be possible to just fudge it by asserting a connection between cloud density and height?

*thinks*
wait doesn't this require alot of complex math? as currents of air would create local low pressures.
Why would i want this?

The moon direction function sounds interesting and useful for those who want to create night time shadows.
_____________________
Truth is a river that is always splitting up into arms that reunite. Islanded between the arms, the inhabitants argue for a lifetime as to which is the main river.
- Cyril Connolly

Without the political will to find common ground, the continual friction of tactic and counter tactic, only creates suspicion and hatred and vengeance, and perpetuates the cycle of violence.
- James Nachtwey
Cid Jacobs
Theoretical Meteorologist
Join date: 18 Jul 2004
Posts: 4,304
11-22-2005 07:12
From: Strife Onizuka
What would you use this for?

would it be possible to just fudge it by asserting a connection between cloud density and height?


Not really since 1000 meters up has the same cloud density as 100000 meters up. The bulk of cloud density seems to be between 180-200 meters absolute sim height.

From: Strife Onizuka

*thinks*
wait doesn't this require alot of complex math? as currents of air would create local low pressures.

The way I see it there are two ways of doing it.

1. A close guess without taking llWind into account. (The probable choice sense it would be less resource intensive).

2. Use llWind data extrapolated on top of the base line readings for the current altitude. This would probably need a throttle on it so you can't call it too often, perhaps 0.2 seconds.

Either way both do require a small bit of "Advanced Math" but it isn't too dificult to achive via LSL. I have on older script that does 1., and a newer one that does 2. while taking llWind into account. They are "doable" already, I would just like to see if anyone besides 3-4 people would be interested in it as an actual function. If a small group are, I will hound LL to get it on there for ages if I have to. :)

From: Strife Onizuka

Why would i want this?


I'm still working on that one too. I can't find a good reason "for it", but I also can not find a reason "against it" especially since it is already doable.

From: Strife Onizuka

The moon direction function sounds interesting and useful for those who want to create night time shadows.


Yes! I'm hoping that if we get this function, LL may toss around the idea of speeding up the moon's orbit and rotating it, so that we can have moon cycles as well as a more dynamic sky overall.
_____________________
Moriash Moreau
Registered User
Join date: 1 Jan 2005
Posts: 39
11-22-2005 08:33
Could be interesting for some vehicles, such as hot air balloons. You could create a realistic balloon whose lift characteristics and ultimate max height was determined by the vagaries of the surrounding air pressure systems. Couple this with some kind of system for simulating updrafts/downdrafts from wind direction and ground slope data, and you could come up with some pretty realistic gliders, too. It's a shame you can't remotely detect prim and ground colors. Thermals rising off of the huge black-box clubs and lengths of black asphalt Linden roads could be fun, too.

Is there a demand for this? Who knows.
Cid Jacobs
Theoretical Meteorologist
Join date: 18 Jul 2004
Posts: 4,304
11-22-2005 08:34
From: Moriash Moreau
Could be interesting for some vehicles, such as hot air balloons. You could create a realistic balloon whose lift characteristics and ultimate max height was determined by the vagaries of the surrounding air pressure systems. Couple this with some kind of system for simulating updrafts/downdrafts from wind direction and ground slope data, and you could come up with some pretty realistic gliders, too. It's a shame you can't remotely detect prim and ground colors. Thermals rising off of the huge black-box clubs and lengths of black asphalt Linden roads could be fun, too.

Is there a demand for this? Who knows.

Thank you, I knew there had to be *some* reason to have it. Now I can grab on to it like a pitbull. :)
_____________________
Davan Camus
Registered User
Join date: 13 Sep 2005
Posts: 67
llGetTemperature()
11-22-2005 10:51
I'll weigh in on this!

I'd be much more excited to have llGetTemperature(). Then we could analyze the seasons, and know when to dress more warmly.

Sure, pressure would be nice, too...

I built a small orbital tracker, it has discovered that the sun and the moon don't follow the same course in the sky! Very curious orbits, but explains the 3:1 day:night cycle very clearly. You can see the tracker on a platform around Alice (128,20,700) or so. It's near one of the platform corners. It has rendered a simple model of the heavens.

llGetCelestialBodyDirection(string celestialBodyName)...
_____________________
Visit Cubes at Alice 100,18.
--------------------------------------------------
Davan Camus, born: 2005 September 8
Out-world location: Santa Cruz, CA
UI Proposal: http://davancamus.hexaflexagon.com/blog/?p=39
Jeffrey Gomez
Cubed™
Join date: 11 Jun 2004
Posts: 3,522
11-22-2005 11:01
llFluidDynamics(integer brainASplode);

Need I say more?
_____________________
---
Strife Onizuka
Moonchild
Join date: 3 Mar 2004
Posts: 5,887
11-22-2005 11:48
llWaterPressure would rock too. I've always wanted to build a realistic sub. Been too lazy to work out the math for the depths. Not to mention too lazy to build any subs.
_____________________
Truth is a river that is always splitting up into arms that reunite. Islanded between the arms, the inhabitants argue for a lifetime as to which is the main river.
- Cyril Connolly

Without the political will to find common ground, the continual friction of tactic and counter tactic, only creates suspicion and hatred and vengeance, and perpetuates the cycle of violence.
- James Nachtwey
Cid Jacobs
Theoretical Meteorologist
Join date: 18 Jul 2004
Posts: 4,304
11-22-2005 15:45
From: Davan Camus
I'll weigh in on this!

I'd be much more excited to have llGetTemperature(). Then we could analyze the seasons, and know when to dress more warmly.

You can stop by the weather archives in Neualtenburg to see the temperature. You need air pressure to calculate temperature. The seasons themselves are goverened by the sun direction and its slight movement throughout the SL year.
_____________________
Cid Jacobs
Theoretical Meteorologist
Join date: 18 Jul 2004
Posts: 4,304
11-22-2005 15:46
From: Strife Onizuka
llWaterPressure would rock too. I've always wanted to build a realistic sub. Been too lazy to work out the math for the depths. Not to mention too lazy to build any subs.

I'm activly working on this one.... just as soon as I can figure out the saturated vapor pressure for SL!
_____________________
Cid Jacobs
Theoretical Meteorologist
Join date: 18 Jul 2004
Posts: 4,304
11-22-2005 19:30
From: Strife Onizuka
llWaterPressure would rock too. I've always wanted to build a realistic sub. Been too lazy to work out the math for the depths. Not to mention too lazy to build any subs.

I decided to go ahead and do this and put off evaportation rates for later. This is a close approximation to water Pressure.

CODE
float Water_Pressure;
vector Position;
default
{
touch_start(integer total_number)
{
Position = llGetPos();
if(llWater(ZERO_VECTOR) > Position.z)
{
Water_Pressure = (9.8 * (llWater(ZERO_VECTOR) - Position.z));
llSay(0, "Current water pressure is :" + (string)Water_Pressure + " Pascal");
}
}
}
_____________________