Question Is there a good way in Lua to determine vertical velocity?

dgatsoulis

ele2png user
Joined
Dec 2, 2009
Messages
1,774
Reaction score
7
Points
38
Location
Sparta
From Orbiterroot\Html\Orbiter.chm Orbiter Scripting→Reference→Class Methods→Vessel Methods

vel = v:get_airspeedvector(frame)
Returns the true airspeed vector in the requested frame of reference.

Parameters:
frame (integer): frame of reference flag (see REFFRAME identifiers)

Return values:
vel (vector): true airspeed vector [m/s]

Notes:
Valid entries for frame are:

REFFRAME.GLOBAL airspeed in global frame
REFFRAME.LOCAL airspeed in local vessel frame
REFFRAME.REFLOCAL airspeed in local planet frame
REFFRAME.HORIZON airspeed in local horizon frame

See also:
get_airspeed, get_groundspeedvector
If you want the vertical velocity as indicated in SurfaceMFD you need:

vel = v:get_airspeedvector(REFFRAME.HORIZON)
vertical_v = vel.y
 
Top